Bug 736127
Summary: | /var/log/rhn/rhn_server_xmlrpc.log does not log IP addresses , only 0.0.0.0 | ||||||
---|---|---|---|---|---|---|---|
Product: | [Community] Spacewalk | Reporter: | Marcelo Moreira de Mello <mmello> | ||||
Component: | Server | Assignee: | Marcelo Moreira de Mello <mmello> | ||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Red Hat Satellite QA List <satqe-list> | ||||
Severity: | low | Docs Contact: | |||||
Priority: | low | ||||||
Version: | 1.6 | CC: | mmello, mmraka | ||||
Target Milestone: | --- | Keywords: | Patch | ||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | All | ||||||
Whiteboard: | |||||||
Fixed In Version: | spacewalk-backend-1.6.18-1 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | |||||||
: | 736130 (view as bug list) | Environment: | |||||
Last Closed: | 2011-12-22 16:50:04 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Bug Depends On: | |||||||
Bug Blocks: | 723481 | ||||||
Attachments: |
|
Description
Marcelo Moreira de Mello
2011-09-06 18:51:53 UTC
Working into this.. backend/common/rhnLog.py ---------------- 152 class rhnLog: 153 def __init__(self, log_file, level): 154 self.level = level 155 self.log_info = "0.0.0.0: " 156 self.file = log_file....... 157 self.pid = os.getpid() 158 self.real = 0........ 159 if self.file in ["stderr", "stdout"]: 160 self.fd = getattr(sys, self.file) 161 self.log_info = "" 162 return 226 # Reinitialize req info if req has changed. 227 def set_req(self, req = None): 228 remoteAddr = '0.0.0.0' 229 if req:. 230 if req.headers_in.has_key("X-Forwarded-For"): 231 remoteAddr = req.headers_in["X-Forwarded-For"] 232 else: 233 remoteAddr = req.connection.remote_ip 234 self.log_info = "%s: " % (remoteAddr, ) Created attachment 522328 [details] Patch proposed Hello, Patch sent to approval at spacewalk-devel maillist. Mail Thread: https://www.redhat.com/archives/spacewalk-devel/2011-September/msg00012.html Cheers, mmello Applied to spacewalk master as commit 33f707177bca9cc70a8b413385b428198761770d 736127 - fixed /var/log/rhn/rhn_server_xmlrpc.log does not log IP addresses Before: 2011/08/30 17:37:49 +13:00 19502 0.0.0.0: xmlrpc/queue.get(1000010000, 2,'checki 2011/08/30 17:37:50 +13:00 19135 0.0.0.0: xmlrpc/registration.update_packages(10 After: 2011/09/09 09:52:59 -02:00 11764 10.12.56.89: xmlrpc/registration.update_package 2011/09/09 09:52:59 -02:00 11764 10.12.56.89: rhnServer/server_solarispatches.di Spacewalk 1.6 has been released. |