Skip to content

Commit c24b75b

Browse files
author
Inbal Tako
committed
Fix request parsing
1 parent cbbbaa3 commit c24b75b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

securenative/context/context_builder.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def from_http_request(request):
4848
client_token = None
4949

5050
try:
51-
headers = request.headers
51+
headers = dict(request.headers)
5252
except Exception:
5353
headers = None
5454

securenative/event_manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ def serialize(obj):
145145
"remoteIp": obj.request.remote_ip if obj.request else "",
146146
"method": obj.request.method if obj.request else "",
147147
"url": obj.request.url if obj.request else "",
148-
"headers": dict(obj.request.headers) if obj.request else None
148+
"headers": obj.request.headers if obj.request else None
149149
},
150150
"timestamp": obj.timestamp,
151151
"properties": obj.properties,

0 commit comments

Comments
 (0)