From 6dc8e8048ba26c271f7d2ac6ddb271af5908499a Mon Sep 17 00:00:00 2001 From: Sergei Trofimov Date: Fri, 22 Sep 2023 20:50:19 +0100 Subject: [PATCH] ear: update Nonce size limits in validate() Update Nonce size limits to align with the latest updates to the EAT draft: https://github.com/ietf-rats-wg/eat/pull/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 --- ear.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ear.go b/ear.go index d2673a5..94e2f47 100644 --- a/ear.go +++ b/ear.go @@ -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)) } }