diff options
Diffstat (limited to 'client.py')
-rw-r--r-- | client.py | 6 |
1 files changed, 1 insertions, 5 deletions
@@ -17,11 +17,7 @@ message = f'date: {date}\ndigest: SHA-256={digest}' with open('private.pem', 'rb') as f: privkey = serialization.load_pem_private_key(f.read(), None) -signature = b64encode(privkey.sign( - message.encode('utf8'), - padding.PKCS1v15(), - hashes.SHA256() -)).decode() +signature = b64encode(privkey.sign(message.encode('utf8'), padding.PKCS1v15(), hashes.SHA256())).decode() header = f'keyId="https://0.exozy.me/users/test.jsonld#main-key",headers="date digest",signature="{signature}"' resp = post('https://0.exozy.me/users/test.outbox', headers={ |