Skip to content

Commit

Permalink
ear: update Nonce size limits in validate()
Browse files Browse the repository at this point in the history
Update Nonce size limits to align with the latest updates to the EAT
draft:

ietf-rats-wg/eat#421

This also helps ups deal with CCA which mandates realm challenge to be
64 bytes that would exceed the old size limit when base64 encoded.

Signed-off-by: Sergei Trofimov <sergei.trofimov@arm.com>
  • Loading branch information
setrofim authored and thomas-fossati committed Sep 22, 2023
1 parent 74b034b commit 6dc8e80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ear.go
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ func (o AttestationResult) validate() error {

if o.Nonce != nil {
nLen := len(*o.Nonce)
if nLen > 74 || nLen < 10 {
if nLen > 88 || nLen < 8 {
invalid = append(invalid, fmt.Sprintf("eat_nonce (%d bytes)", nLen))
}
}
Expand Down

0 comments on commit 6dc8e80

Please sign in to comment.