Skip to content

Commit 2036016

Browse files
committed
feature/add_internal_notification_filters: Fixed security.py (removed unnecessary line).
1 parent e6d036a commit 2036016

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

bunq/sdk/security/security.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -187,15 +187,14 @@ def validate_response(public_key_server: RsaKey,
187187

188188

189189
def is_valid_response_header_with_body(public_key_server: RsaKey,
190-
status_code: int,
191-
body_bytes: bytes,
192-
headers: Dict[str, str]) -> bool:
190+
status_code: int,
191+
body_bytes: bytes,
192+
headers: Dict[str, str]) -> bool:
193193
head_bytes = _generate_response_head_bytes(status_code, headers)
194194
bytes_signed = head_bytes + body_bytes
195195
signer = PKCS1_v1_5.pkcs1_15.new(public_key_server)
196196
digest = SHA256.new()
197197
digest.update(bytes_signed)
198-
signer.verify(digest, base64.b64decode(headers[_HEADER_SERVER_SIGNATURE]))
199198

200199
try:
201200
signer.verify(digest, base64.b64decode(headers[_HEADER_SERVER_SIGNATURE]))

0 commit comments

Comments
 (0)