Revert "service: add owner key to a signed payload of SessionToken"

This reverts commit 1896264f
This commit is contained in:
Leonard Lyubich 2020-05-16 15:28:35 +03:00
parent abbb6e0e93
commit 22af538c98
2 changed files with 3 additions and 32 deletions

View file

@ -174,11 +174,11 @@ func NewVerifiedSessionToken(token SessionToken) DataWithSignature {
}
}
func tokenInfoSize(v SessionTokenInfo) int {
func tokenInfoSize(v SessionKeySource) int {
if v == nil {
return 0
}
return fixedTokenDataSize + len(v.GetSessionKey()) + len(v.GetOwnerKey())
return fixedTokenDataSize + len(v.GetSessionKey())
}
// Fills passed buffer with signing token information bytes.
@ -208,9 +208,7 @@ func copyTokenSignedData(buf []byte, token SessionTokenInfo) {
tokenEndianness.PutUint64(buf[off:], token.ExpirationEpoch())
off += 8
off += copy(buf[off:], token.GetSessionKey())
copy(buf[off:], token.GetOwnerKey())
copy(buf[off:], token.GetSessionKey())
}
// SignedData concatenates signed data with session token information. Returns concatenation result.