def rsa.sign
bend-kit-jwt@0.11.0.1 · jwt.bend:521
import bend-kit-jwt@0.11.0.1/jwt.bend as Jwt
import Base
import bend-kit-crypto@0.2.2.2/crypto.bend as Crypto
import bend-kit-bytes@0.3.3.0/bytes.bend as Bytes
521def rsa.sign(p: Bytes.Bytes, input: Bytes.Bytes) -> IO(Result<&1, &1, Err, Bytes.Bytes>):
522 Bytes.Bytes{+pn, pb} = p
523 Bytes.Bytes{+dn, db} = input
524 do IO<Result<&1, &1, Err, Bytes.Bytes>>:
525 r : Result<&1, &1, U32 & String, U32 & Array<U32>> <- Crypto.rsa.sign.words("SHA256", pn, pb, dn, db)
526 return crypto.bytes(r)