def nonce.ok

bend-kit-postgres@0.3.0.0 · scram.bend:83

import bend-kit-postgres@0.3.0.0/scram.bend as Scram
import Base

83# The server nonce must be the client nonce plus at least one more printable char.
84def nonce.ok(+client: String, +server: String) -> Bool:
85  Bool.and(Bool.and(String.starts_with(server, client), Nat.is_lt(String.length(client), String.length(server))), printable(server))

Uses (7)

Used by (1)