Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 295869 Details for
Bug 434896
Hack for proxy pass through to get real client IP address
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Patch to pass through real client IP address when going through a proxy
3_2_xff.patch (text/plain), 967 bytes, created by
David Lawrence
on 2008-02-26 04:13:27 UTC
(
hide
)
Description:
Patch to pass through real client IP address when going through a proxy
Filename:
MIME Type:
Creator:
David Lawrence
Created:
2008-02-26 04:13:27 UTC
Size:
967 bytes
patch
obsolete
>Index: Bugzilla.pm >=================================================================== >RCS file: /cvs/qa/rh_bugzilla_3/Bugzilla.pm,v >retrieving revision 1.3 >diff -u -r1.3 Bugzilla.pm >--- Bugzilla.pm 8 Jan 2008 02:07:15 -0000 1.3 >+++ Bugzilla.pm 25 Feb 2008 18:43:23 -0000 >@@ -112,6 +112,17 @@ > }; > } > >+ # HACK FOR PROXY PASS-THROUGH >+ # If client if one of the proxy servers then we try to use the >+ # HTTP_X_FORWARDED_FOR address as the client's real address >+ my %rx = ( >+ proxy_ip => qr/^10\.8\.2\.15\d$/, >+ last_ip_in_chain => qr/([^,\s]+)$/, >+ ); >+ if (i_am_cgi() && $ENV{REMOTE_ADDR} =~ $rx{proxy_ip}) { >+ $ENV{REMOTE_ADDR} = $ENV{HTTP_X_FORWARDED_FOR} =~ $rx{last_ip_in_chain} >+ } >+ > # If Bugzilla is shut down, do not allow anything to run, just display a > # message to the user about the downtime and log out. Scripts listed in > # SHUTDOWNHTML_EXEMPT are exempt from this message.
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 434896
: 295869