ietf-wg-gnap / gnap-core-protocol

141 stars 26 forks source link

Unguessability of User Codes #481

Closed PedramHD closed 1 year ago

PedramHD commented 1 year ago

The specification does not require user codes to be unguessable. Section 3.3.3 (Display of a Short User Code) states that user codes have to be unique and should be short-lived, but this does not imply that codes should be unguessable. It seems that Section 13.27 (Exhaustion of Random Value Space) does not apply to user codes, but to values that are clearly random values "such as nonces, tokens, and randomized URIs".

If attackers can guess user codes, the same attack described in https://datatracker.ietf.org/doc/html/rfc8628#section-5.1 is possible.

jricher commented 1 year ago

Good catch! The intent is for these to be unguessable, so we can add that explicitly.