Skip to content

Conversation

@Airis101
Copy link

@Airis101 Airis101 commented Nov 11, 2025

Previously, the DNS rebinding protection only allowed localhost and 127.0.0.1, which prevented the plugin from working when a non-loopback address was configured in the host setting.

Changes:

  • Updated isValidOrigin(), isValidHost(), and isValidReferer() to accept the configured host address as an allowed host
  • Added configured host to CORS allowHost list when it's not localhost/127.0.0.1
  • All validation functions now check against the configured host in addition to the default loopback addresses

This fix ensures that when users configure a non-loopback address (e.g., 0.0.0.0 or a specific IP), requests from that address will pass validation while maintaining protection against DNS rebinding attacks.

Before: DNS Rebinding Protection Restriction
image
image

After: Enhanced Validation with Configured Host Support
image
image

…otection

Previously, the DNS rebinding protection only allowed localhost and 127.0.0.1,
which prevented the plugin from working when a non-loopback address was
configured in the host setting.

Changes:
- Updated isValidOrigin(), isValidHost(), and isValidReferer() to accept
  the configured host address as an allowed host
- Added configured host to CORS allowHost list when it's not localhost/127.0.0.1
- All validation functions now check against the configured host in addition
  to the default loopback addresses

This fix ensures that when users configure a non-loopback address (e.g., 0.0.0.0
or a specific IP), requests from that address will pass validation while
maintaining protection against DNS rebinding attacks.
@Airis101 Airis101 changed the title fix: Allow configured non-loopback host addresses in DNS rebinding protection fix: Fix issue where configured non-loopback addresses become invalid due to DNS rebinding protection. Nov 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant