service: ad BearerToken to signed payload of the requests

This commit is contained in:
Leonard Lyubich 2020-06-18 15:26:56 +03:00
parent 3f7d3f8a86
commit a3569ad99e
3 changed files with 26 additions and 1 deletions

View file

@ -209,6 +209,9 @@ func SignRequestData(key *ecdsa.PrivateKey, src RequestSignedData) error {
NewSignedSessionToken(
src.GetSessionToken(),
),
NewSignedBearerToken(
src.GetBearerToken(),
),
)
if err != nil {
return err
@ -231,6 +234,9 @@ func VerifyRequestData(src RequestVerifyData) error {
NewVerifiedSessionToken(
src.GetSessionToken(),
),
NewVerifiedBearerToken(
src.GetBearerToken(),
),
)
if err != nil {
return err