Penetration Test Report (X41 D-Sec): X41 Mullvad Audit Public Report 2024 12 10

SecurityReview
forMullvadVPNAB
FinalReportandManagementSummary
2024-12-10
PUBLIC
X41 D-Sec GmbH
Krefelder Str. 123
D-52070 Aachen
Amtsgericht Aachen: HRB19989
https://x41-dsec.de/
info@x41-dsec.de
SecurityReview MullvadVPNAB
Revision Date Change Author(s)
1 2024-11-30 FinalReportandManagement Eric Sesterhenn, JM, Markus
Summary Vervier,andRobertFemmer
2 2024-12-10 Improved wording according JM
tofeedback
X41D-SecGmbH PUBLIC Page1of39
SecurityReview MullvadVPNAB
Contents
1 ExecutiveSummary 4
2 Introduction 6
2.1 ThreatModel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
2.2 Methodology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.3 FindingsOverview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
2.4 Scope . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.5 Coverage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
2.6 RecommendedFurtherTests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
3 RatingMethodology 16
3.1 CVSS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
3.2 SeverityMapping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
3.3 CommonWeaknessEnumeration . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
4 Results 20
4.1 Findings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
4.2 InformationalNotes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
5 AboutX41D-SecGmbH 37
X41D-SecGmbH PUBLIC Page2of39
SecurityReview MullvadVPNAB
Dashboard
Target
Customer MullvadVPNAB
Name MullvadVPNApplication
Type DesktopandPhoneApplications
Version Android:2024.8-beta1,iOS:2024.8,Desktop:2024.6
Engagement
Type WhiteBoxPenetrationTest
Consultants 4:EricSesterhenn,JM,MarkusVervier,andRobertFemmer
EngagementEffort 30person-days,2024-10-23to2024-11-28
Totalissuesfound 6
Critical - 0
High - 3 CWE-426(1)
CWE-203(2)
Medium - 2 CWE-200(1)
Low - 1
CWE-479(1)CWE-400(1)
None - 3
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2 2.2 2.4 2.6 2.8 3
Figure1:IssueOverview(l:Severity,r:CWEDistribution)
6
5
4
3
2
1
0
0 1 2 3 4
Exploitability
tcapmI
Figure2:CVSSImpactandExploitabilityDistribution
X41D-SecGmbH PUBLIC Page3of39
SecurityReview MullvadVPNAB
1 Executive Summary
InOctoberandNovember2024,X41D-SecGmbHperformedawhiteboxpenetrationtestwith
sourcecodeaccessagainsttheMullvadVPNApplication.Theeffortsincludedformulatingalight
threatmodel.
AtotalofsixvulnerabilitieswerediscoveredduringthetestbyX41.Nonewereratedashavinga
criticalseverity,threeashigh,twoasmedium,andoneaslow.Additionally,threeissueswithout
adirectsecurityimpactwereidentified.
Medium - 2
High - 3
Low - 1
Figure1.1:IssuesandSeverity
TheMullvadVPNApplicationconnectsausertotheMullvadVPNservice.Internettrafficgener-
atedbytheuseristhenroutedthroughtheserversoperatedbyMullvad. Theservicemasquer-
ades the public IP address of the user, which is considered a proxy to their real identity. The
applicationisavailableforLinux,macOS,Windows,AndroidandiOS.
Thisauditinvestigatedhowattackerscouldusetheclientsoftwareandtheserviceforprivilege
X41D-SecGmbH PUBLIC Page4of39
SecurityReview MullvadVPNAB
escalationattacksandtoinvestigatewaysinwhichtherealidentityofausercouldbeleaked,or
inwhichwaythebehaviorofausercouldbemonitoredbythirdparties.
In a white box penetration test, the testers receive all available information about the target,
including source code. The test was performed by four experienced security experts between
2024-10-23and2024-11-28.
Overall, the Mullvad VPN Application appear to have a high security level and are well posi-
tioned to protect from the threat model proposed in this report. The use of safe coding and
designpatternsincombinationwithregularauditsandpenetrationtestsledtoaveryhardened
environment.
Themostseriousvulnerabilitiesareconsideredtoberaceconditionsandtemporalsafetyviola-
tionsleadingtomemorycorruptionissuesinthesignalhandlercode. Whileexploitationofthe
signal handler code once triggered seems not unlikely, the fact that an attacker first needs to
trigger a signal via another fault reduces the severity of the issues. Other vulnerabilities allow
leaking information about the identity of a user by network adjacent attackers and to perform
side channel attacks that could in specific circumstances reveal which site a client is currently
accessing.
The aspect of side channel attacks is mitigated in most parts, except for protocol level attacks
that are not within the control of Mullvad VPN AB because they root from a combination of
differenttechnologiessuchasNATandmodernvariantsoftheHTTPprotocol.Theintroduction
ofobfuscationtechnologiesandproxyserviceswithintheprotectedVPNisanoptionforusers
withhighersecurityandprivacydemands.
Inconclusion,theclientapplicationsexposedalimitednumberofrelevantvulnerabilities. Mull-
vadVPNABaddressedthemswiftlyandthefixeswereauditedtobeworkingproperly.
X41D-SecGmbH PUBLIC Page5of39
SecurityReview MullvadVPNAB
2 Introduction
X41reviewedtheMullvadClientapplicationsusedtoconnecttotheMullvadVPN1service.The
productisdesignedtoprotecttheuser’sprivacybyobscuringtheIP2addressoftheuser’sInter-
netconnectionsandencrypttheuser’strafficonthewaybetweentheuserandMullvad’sservers.
TheInternetprovidersandnetworkadjacentobserversarepreventedfromlearningwhichsites
theuservisitsandwhichhoststheuserconnectsto.
The confidentiality, integrity and availability of these connections are considered sensitive be-
causeusersrelyonthemtoprotectagainstthesurveillanceofemployers,ISPs3,orgovernment
entities.Theymayalsobeusedbycitizensofcountrieswithauthoritariangovernmentstoaccess
informationorservicesthatmaybeconsideredillegal. Afailuretoprovideadequateanonymity
totheusermayleadtotheirprosecution.
1VirtualPrivateNetwork
2InternetProtocol
3Internetserviceproviders
X41D-SecGmbH PUBLIC Page6of39
SecurityReview MullvadVPNAB
2.1 Threat Model
The following light threat model was created during this security audit and should serve as a
benchmarkforratingthefindings.Itisintendedtobeabaseforsecurityauditsandtheratingof
vulnerabilitiesandcanbeextendedovertimeinfuturesecurityaudits.
2.1.1 Rationale
1. End-userswanttomakeinformedchoicesaboutwhetherornotaVPNserviceisableto
covertheirperceivedthreat.Adocumentedthreatmodelcanhelpmakingthesechoices.
2. Whetherornotacertainbehaviorofthesoftwareisasecurityissueornot,maycomedown
tonuance. Itis advantageoustochecktheseagainstadocumented threatmodel. Thisis
helpfulfordevelopersandfuturesecurityreviews.
The Mullvad VPN Application is available on Windows, Linux, MacOS, iOS and Android. Every
platform differs in interfacing with the operating system, the network device, the firewall and
other parts of the system. While potentially hostile code (3rd party applications) is part of the
threatmodeloniOSandAndroid,itisoutofscopeforLinux,WindowsandMacOS,wherethe
environment is generally considered trusted. Therefore, there must be one threat model per
distinctplatform.Somethreatsaresharedacrossallplatforms.Here,thethreatseitherapplyfor
allplatformsorformobileplatforms.
2.1.2 Threats
Thissubsectionliststhenomenclatureusedinthisthreatmodelandtheassumedrelevantthreats.
2.1.2.1 Nomenclature
• User:Thepersonoperatingtheclient.
• Peer:OneInternetserver,whichrepresentstheultimatedestinationofthedataconnection
fromtheclient.
• Client:TheVPNclientsoftware(MullvadDaemon)runtoconnecttoarelayandestablish-
ingatunnel,whichisthenusedtofacilitatetheconnectionfromtheusertothepeer.
• Tunnel:TheencryptedconnectionbetweentheclientandthelastMullvadexitrelayserver.
• Leak:Trafficthatwasintendedtobesentthroughthetunnelconnection,butwasacciden-
tallynotorcanbeinferredusingothermethods.
X41D-SecGmbH PUBLIC Page7of39
SecurityReview MullvadVPNAB
• Networkadjacententity:Anentityonthesamelocalnetworkastheclient.
• Relay:VPNpeeroftheVPNclient,firsthopoftheVPNtunnel.
•