Repository navigation
fix(remote-image): images from a URL can no longer reach your local network through older IPv6 ranges - #116
Conversation
…etwork through older IPv6 ranges The image-from-URL fetch treats site-local (fec0::/10) and local-use NAT64 (64:ff9b:1::/48) addresses as not public. Both can still route to the local network. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
-OpenMouse-Project#119) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The image-from-URL fetch already refuses loopback, link-local, unique-local and the other private IPv6 ranges. Two ranges that can still route to the local network got through: site-local
fec0::/10(deprecated, but some LANs still route it) and local-use NAT6464:ff9b:1::/48(RFC 8215, which a network can map to its private IPv4 addresses).What changed:
is_public_v6treatsfec0::/10and64:ff9b:1::/48as not public, so the fetch refuses them like the other local ranges. The well-known NAT64 prefix64:ff9b::/96is still judged by its embedded IPv4 address, as before. The local-use prefix is refused whole, since the IPv4 address can sit at a different offset in it.Tested:
fec0::1and64:ff9b:1::a00:1toaddresses_on_this_pc_or_the_local_network_are_refused.cargo fmt --check,cargo test --locked, and clippy with-D warningsfor Linux and x86_64-pc-windows-gnu all pass.Thanks for merging the first four so quickly. This is the first of a few more small ones.
🤖 Generated with Claude Code
Summary by CodeRabbit