Am I affected?

type your safeurl version to check

Description

Server-Side Request Forgery (SSRF) vulnerability in Slab safeurl allows an attacker who controls a validated URL to reach internal network destinations the library is configured to block.

Only IPv4 addresses are matched against the reserved ranges and the blocklist. Every other address is treated as matching nothing, so a destination that is rejected in its IPv4 form is accepted when written as an IPv6 address, IPv6 entries in the blocklist never match, and a host that resolves to no IPv4 address is accepted regardless of where it points. Deployments that rely on the allowlist instead are unaffected, because there an unmatched address is rejected.

This issue affects safeurl: from 0.1.0 onward.

Weaknesses & attack patterns

Weakness

CWE-918 · Server-Side Request Forgery (SSRF) in catalog → MITRE ↗
CWE-636 · Not Failing Securely ('Failing Open') in catalog → MITRE ↗

Attack patterns

CAPEC-664 · Server Side Request Forgery MITRE ↗

Affected — Hex / safeurl Hex.pm ↗ Repository ↗

0.1.0 and up affected
every other version: unaffected
cpe cpe:2.3:a:slab:safeurl:*:*:*:*:*:*:*:*
modules · source files · routines
modules 'Elixir.SafeURL'
source files lib/safeurl/safeurl.ex
routines 'Elixir.SafeURL':validate/2 · 'Elixir.SafeURL':allowed?/2

Affected — GitHub / slab/safeurl-elixir Repository ↗

feabbd0 and up affected
every other version: unaffected
cpe cpe:2.3:a:slab:safeurl:*:*:*:*:*:*:*:*
modules · source files · routines
modules 'Elixir.SafeURL'
source files lib/safeurl/safeurl.ex
routines 'Elixir.SafeURL':validate/2 · 'Elixir.SafeURL':allowed?/2

References

Credits

Mathias Polligkeit Reporter
Jonatan Männchen / EEF Coordinator

CVSS breakdown

CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:L/VA:N/SC:H/SI:L/SA:N
« All CVEs