{"containers":{"cna":{"affected":[{"cpes":["cpe:2.3:a:erlang:erlang\\/otp:*:*:*:*:*:*:*:*"],"defaultStatus":"unknown","modules":["ftp_internal"],"packageName":"inets","packageURL":"pkg:otp/inets?repository_url=https:%2F%2Fgithub.com%2Ferlang%2Fotp&vcs_url=git%20https:%2F%2Fgithub.com%2Ferlang%2Fotp.git","product":"OTP","programFiles":["src/ftp/ftp_internal.erl"],"programRoutines":[{"name":"ftp_internal:handle_ctrl_result/2"}],"repo":"https://github.com/erlang/otp","vendor":"Erlang","versions":[{"lessThan":"7.0","status":"affected","version":"5.10.4","versionType":"otp"}]},{"cpes":["cpe:2.3:a:erlang:erlang\\/otp:*:*:*:*:*:*:*:*"],"defaultStatus":"unknown","modules":["ftp_internal"],"packageName":"ftp","packageURL":"pkg:otp/ftp?repository_url=https:%2F%2Fgithub.com%2Ferlang%2Fotp&vcs_url=git%20https:%2F%2Fgithub.com%2Ferlang%2Fotp.git","product":"OTP","programFiles":["src/ftp_internal.erl"],"programRoutines":[{"name":"ftp_internal:handle_ctrl_result/2"}],"repo":"https://github.com/erlang/otp","vendor":"Erlang","versions":[{"changes":[{"at":"1.2.6","status":"unaffected"},{"at":"1.2.4.1","status":"unaffected"},{"at":"1.2.3.1","status":"unaffected"}],"lessThan":"*","status":"affected","version":"1.0","versionType":"otp"}]},{"collectionURL":"https://github.com","cpes":["cpe:2.3:a:erlang:erlang\\/otp:*:*:*:*:*:*:*:*"],"defaultStatus":"unknown","modules":["ftp_internal"],"packageName":"erlang/otp","packageURL":"pkg:github/erlang/otp","product":"OTP","programFiles":["lib/inets/src/ftp/ftp_internal.erl","lib/ftp/src/ftp_internal.erl"],"programRoutines":[{"name":"ftp_internal:handle_ctrl_result/2"}],"repo":"https://github.com/erlang/otp","vendor":"Erlang","versions":[{"changes":[{"at":"29.0.2","status":"unaffected"},{"at":"28.5.0.2","status":"unaffected"},{"at":"27.3.4.13","status":"unaffected"}],"lessThan":"*","status":"affected","version":"17.4","versionType":"otp"},{"changes":[{"at":"2691a806231ffd0490a8a9e20500dec0c7e73727","status":"unaffected"},{"at":"521bcfa24407ee8cb5614823cf905c37ea3aa605","status":"unaffected"}],"lessThan":"*","status":"affected","version":"be95772ee1fcfe71045ef070130bea7a910b81e3","versionType":"git"}]}],"configurations":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"The vulnerable path is active under the default configuration: <tt>mode=passive</tt>, <tt>ipfamily=inet</tt>, and <tt>ftp_extension=false</tt> are all defaults for <tt>ftp:open/2</tt>."}],"value":"The vulnerable path is active under the default configuration: mode=passive, ipfamily=inet, and ftp_extension=false are all defaults for ftp:open/2."}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:a:erlang:erlang\\/otp:*:*:*:*:*:*:*:*","versionEndExcluding":"27.3.4.13","versionStartIncluding":"17.4","vulnerable":true},{"criteria":"cpe:2.3:a:erlang:erlang\\/otp:*:*:*:*:*:*:*:*","versionEndExcluding":"28.5.0.2","versionStartIncluding":"28.0","vulnerable":true},{"criteria":"cpe:2.3:a:erlang:erlang\\/otp:*:*:*:*:*:*:*:*","versionEndExcluding":"29.0.2","versionStartIncluding":"29.0","vulnerable":true}],"negate":false,"operator":"OR"}]}],"credits":[{"lang":"en","type":"finder","value":"Jonatan Männchen / EEF"},{"lang":"en","type":"remediation developer","value":"Jonatan Männchen / EEF"},{"lang":"en","type":"remediation reviewer","value":"Ingela Anderton Andin"}],"descriptions":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"<p>Server-Side Request Forgery (SSRF) vulnerability in Erlang/OTP ftp (ftp_internal module) allows FTP bounce attacks and SSRF via an unvalidated PASV response IP address.</p><p>The <tt>ftp_internal:handle_ctrl_result/2</tt> PASV handler (mode=passive, ipfamily=inet, ftp_extension=false) extracts the IP address from the server's 227 response and passes it directly to <tt>gen_tcp:connect/4</tt> without validating it against the control connection peer address. The adjacent EPSV handlers correctly call <tt>peername(CSock)</tt> to derive the IP from the control connection, but the PASV handler does not. A malicious or compromised FTP server can redirect the client's data connection to an arbitrary internal host and port. On read operations (<tt>ftp:ls/1,2</tt>, <tt>ftp:nlist/1,2</tt>, <tt>ftp:recv/2,3</tt>), data from the redirected target is returned to the caller. On write operations (<tt>ftp:send/2,3</tt>, <tt>ftp:append/2,3</tt>), file content is sent to the redirected target. This enables SSRF against internal hosts, cloud metadata endpoints, and FTP bounce attacks against third-party hosts.</p><p>The vulnerable path is the default configuration (mode=passive, ipfamily=inet, ftp_extension=false). RFC 2577 section 3 explicitly recommends validating the PASV response IP against the control connection peer.</p><p>The <tt>ftp</tt> application is deprecated and scheduled for removal in OTP-30.</p><p>This vulnerability is associated with program files <tt>lib/inets/src/ftp/ftp_internal.erl</tt> (inets 5.10.4 through 6.5, OTP 17.4 through 20.3) and <tt>lib/ftp/src/ftp_internal.erl</tt> (ftp 1.0 and later, OTP 21.0 and later).</p><p>This issue affects OTP from OTP 17.4 before 29.0.2, 28.5.0.2 and 27.3.4.13 corresponding to inets from 5.10.4 before 7.0 and ftp from 1.0 before 1.2.6, 1.2.4.1 and 1.2.3.1.</p>"}],"value":"Server-Side Request Forgery (SSRF) vulnerability in Erlang/OTP ftp (ftp_internal module) allows FTP bounce attacks and SSRF via an unvalidated PASV response IP address.\n\nThe ftp_internal:handle_ctrl_result/2 PASV handler (mode=passive, ipfamily=inet, ftp_extension=false) extracts the IP address from the server's 227 response and passes it directly to gen_tcp:connect/4 without validating it against the control connection peer address. The adjacent EPSV handlers correctly call peername(CSock) to derive the IP from the control connection, but the PASV handler does not. A malicious or compromised FTP server can redirect the client's data connection to an arbitrary internal host and port. On read operations (ftp:ls/1,2, ftp:nlist/1,2, ftp:recv/2,3), data from the redirected target is returned to the caller. On write operations (ftp:send/2,3, ftp:append/2,3), file content is sent to the redirected target. This enables SSRF against internal hosts, cloud metadata endpoints, and FTP bounce attacks against third-party hosts.\n\nThe vulnerable path is the default configuration (mode=passive, ipfamily=inet, ftp_extension=false). RFC 2577 section 3 explicitly recommends validating the PASV response IP against the control connection peer.\n\nThe ftp application is deprecated and scheduled for removal in OTP-30.\n\nThis vulnerability is associated with program files lib/inets/src/ftp/ftp_internal.erl (inets 5.10.4 through 6.5, OTP 17.4 through 20.3) and lib/ftp/src/ftp_internal.erl (ftp 1.0 and later, OTP 21.0 and later).\n\nThis issue affects OTP from OTP 17.4 before 29.0.2, 28.5.0.2 and 27.3.4.13 corresponding to inets from 5.10.4 before 7.0 and ftp from 1.0 before 1.2.6, 1.2.4.1 and 1.2.3.1."}],"impacts":[{"capecId":"CAPEC-664","descriptions":[{"lang":"en","value":"CAPEC-664 Server Side Request Forgery"}]}],"metrics":[{"cvssV4_0":{"attackComplexity":"LOW","attackRequirements":"PRESENT","attackVector":"NETWORK","baseScore":6.3,"baseSeverity":"MEDIUM","privilegesRequired":"NONE","subAvailabilityImpact":"NONE","subConfidentialityImpact":"LOW","subIntegrityImpact":"LOW","userInteraction":"NONE","vectorString":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N","version":"4.0","vulnAvailabilityImpact":"NONE","vulnConfidentialityImpact":"LOW","vulnIntegrityImpact":"LOW"},"format":"CVSS","scenarios":[{"lang":"en","value":"GENERAL"}]}],"problemTypes":[{"descriptions":[{"cweId":"CWE-918","description":"CWE-918 Server-Side Request Forgery (SSRF)","lang":"en","type":"CWE"}]}],"providerMetadata":{"dateUpdated":"2026-06-10T14:38:20.421Z","orgId":"6b3ad84c-e1a6-4bf7-a703-f496b71e49db","shortName":"EEF"},"references":[{"tags":["vendor-advisory","related"],"url":"https://github.com/erlang/otp/security/advisories/GHSA-24cv-hwgr-37fq"},{"tags":["related"],"url":"https://cna.erlef.org/cves/CVE-2026-48858.html"},{"tags":["related"],"url":"https://osv.dev/vulnerability/EEF-CVE-2026-48858"},{"tags":["x_version-scheme"],"url":"https://www.erlang.org/doc/system/versions.html#order-of-versions"},{"tags":["patch"],"url":"https://github.com/erlang/otp/commit/2691a806231ffd0490a8a9e20500dec0c7e73727"},{"tags":["patch"],"url":"https://github.com/erlang/otp/commit/521bcfa24407ee8cb5614823cf905c37ea3aa605"}],"source":{"discovery":"INTERNAL"},"title":"ftp client PASV response IP not validated against control peer, enabling SSRF and FTP bounce attacks","workarounds":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"Pass <tt>{ftp_extension, true}</tt> to <tt>ftp:open/2</tt> to use EPSV instead of PASV. Alternatively, pass <tt>{mode, active}</tt> to use active mode, or pass <tt>{ipfamily, inet6}</tt> to force IPv6, both of which bypass the vulnerable PASV path."}],"value":"Pass {ftp_extension, true} to ftp:open/2 to use EPSV instead of PASV. Alternatively, pass {mode, active} to use active mode, or pass {ipfamily, inet6} to force IPv6, both of which bypass the vulnerable PASV path."}],"x_generator":{"engine":"cvelib 1.8.0"}}},"cveMetadata":{"assignerOrgId":"6b3ad84c-e1a6-4bf7-a703-f496b71e49db","assignerShortName":"EEF","cveId":"CVE-2026-48858","datePublished":"2026-06-10T14:35:45.466Z","dateReserved":"2026-05-25T20:44:10.697Z","dateUpdated":"2026-06-10T14:38:20.421Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"}