Skip to content

Commit

Permalink
fix(st2common/router): don't log sensitive information
Browse files Browse the repository at this point in the history
  • Loading branch information
arthurzenika committed Oct 5, 2023
1 parent 6f5ac8a commit 2ff818d
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion st2common/st2common/router.py
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,12 @@ def __call__(self, req):
At the time of writing, the only property being utilized by middleware was `x-log-result`.
"""
LOG.debug("Received call with WebOb: %s", req)
LOG.debug("Received call with WebOb: %s %s", req.method, req.url)
# if a more detailed log is required:
# loggable_req = req.copy()
# loggable_req.headers.pop('Authorization', None)
# loggable_req.headers.pop('X-Request-Id', None)
# LOG.debug("Received call with WebOb: %s", loggable_req)
endpoint, path_vars = self.match(req)
LOG.debug("Parsed endpoint: %s", endpoint)
LOG.debug("Parsed path_vars: %s", path_vars)
Expand Down

0 comments on commit 2ff818d

Please sign in to comment.