Module xmlrat_dsig_signer

Behaviour for callback modules which sign XML-DSIG payloads.

This module defines the xmlrat_dsig_signer behaviour.
Required callback functions: algorithms/1, key_details/1, sign/3.

Description

Behaviour for callback modules which sign XML-DSIG payloads.

The signing operation is replaceable so that consumers of this library may use keys not stored in the memory of the Erlang process (e.g. stored in a hardware token accessed via PKCS11 or the ssh-agent protocol).

The default implementation of this behaviour can be seen in xmlrat_dsig_signer_stdlib.

Data Types

algo()

algo() = {pubkey_algo(), hash_algo()}

cert()

cert() = #'OTPCertificate'{}

hash_algo()

hash_algo() = sha | sha256 | sha384 | sha512

key_details()

key_details() = #{public_key => pubkey(), certificate => cert(), name => binary()}

msg()

msg() = binary()

options()

options() = map()

pubkey()

pubkey() = #'RSAPublicKey'{} | {integer(), #'Dss-Parms'{}} | {#'ECPoint'{}, {namedCurve, tuple() | atom()}}

pubkey_algo()

pubkey_algo() = rsa | dsa | ecdsa | hmac

signature()

signature() = binary()


Generated by EDoc