Include accept within non-digest http signature

main
Bob Mottram 2021-08-31 21:53:53 +01:00
parent ed516c8ff7
commit a69ac4c883
3 changed files with 4 additions and 3 deletions

View File

@ -199,7 +199,8 @@ def createSignedHeader(privateKeyPem: str, nickname: str,
headers = {
'(request-target)': f'post {path}',
'host': headerDomain,
'date': dateStr
'date': dateStr,
'accept': contentType
}
signatureHeader = \
signPostHeaders(dateStr, privateKeyPem, nickname,

View File

@ -181,7 +181,7 @@ def _getJsonSigned(session, url: str, domainFull: str, sessionHeaders: {},
print('Signed GET url: ' + url)
print('Signed GET httpPrefix: ' + httpPrefix)
messageStr = ''
withDigest = True
withDigest = False
signatureHeaderJson = \
createSignedHeader(signingPrivateKeyPem, nickname, domain, port,
toDomain, toPort, url, httpPrefix, withDigest,

View File

@ -1457,7 +1457,7 @@ def testSharedItemsFederation():
}
bobInstanceActorJson = \
getJson(signingPrivateKeyPem, sessionClient,
'http://' + bobAddress + '/@actor', testHeaders, {}, True,
'http://' + bobAddress + '/@actor', testHeaders, {}, True,
__version__, 'http', 'somedomain.or.other', 10, True)
assert bobInstanceActorJson
pprint(bobInstanceActorJson)