Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
As earlier described here #764796: $_SERVER['REMOTE_ADDR'] incorrectly used when performing validation REMOTE_ADDR
isn't working behind reverse proxies because it will always contain the ip of the proxy.
Proposed resolution
Use ip_address()
which is created exactly for this purpose.
Remaining tasks
Review needed.
User interface changes
None.
API changes
None.
Comment | File | Size | Author |
---|---|---|---|
recaptcha-use-ip_address_instead_REMOTE_ADDR.patch | 454 bytes | das-peter | |
Comments
Comment #1
Anonymous (not verified) CreditAttribution: Anonymous commentedThis is already applied in the 7.x-1.x branch but not on the 2.x. Works fine as ip_address() is made for this.
Comment #2
hass CreditAttribution: hass commented@Liam: When do you plan to commit this trivial bugfix?
Comment #4
hass CreditAttribution: hass commented