Technical Details: It's possible to conduct SSRF attacks because of the way URLs are parsed by URI
built in module and hackey
. Given the URL http://[email protected]/, the URI function will parse and see the host as 127.0.0.1 (which is correct), and hackney will see host as 127.2.2.2/ . This can be abused to conduct SSRF attacks where a user is relying on the URL function for host checking. See POC below
import :hackney
defmodule MyApp do
# Helper function to print the URL components
def parse_and_print_url() do
attack_string = "http://[email protected]/"