Versions in this module Expand all Collapse all v0 v0.1.1 May 2, 2024 v0.1.0 May 2, 2024 Changes in this version + const AlgorithmAttr + const CanonicalizationMethodTag + const DefaultIdAttr + const DefaultPrefix + const DigestMethodTag + const DigestValueTag + const ECDSASHA1SignatureMethod + const ECDSASHA256SignatureMethod + const ECDSASHA384SignatureMethod + const ECDSASHA512SignatureMethod + const InclusiveNamespacesTag + const KeyInfoTag + const Namespace + const PrefixListAttr + const RSASHA1SignatureMethod + const RSASHA256SignatureMethod + const RSASHA384SignatureMethod + const RSASHA512SignatureMethod + const ReferenceTag + const SignatureMethodTag + const SignatureTag + const SignatureValueTag + const SignedInfoTag + const TransformTag + const TransformsTag + const URIAttr + const X509CertificateTag + const X509DataTag + var ErrInvalidSignature = errors.New("Invalid Signature") + var ErrMissingCertificates = fmt.Errorf("No public certificates provided") + var ErrMissingSignature = errors.New("Missing signature referencing the top-level element") + var ErrNonRSAKey = fmt.Errorf("Private key was not RSA") + type AlgorithmID string + const CanonicalXML10ExclusiveAlgorithmId + const CanonicalXML10ExclusiveWithCommentsAlgorithmId + const CanonicalXML10RecAlgorithmId + const CanonicalXML10WithCommentsAlgorithmId + const CanonicalXML11AlgorithmId + const CanonicalXML11WithCommentsAlgorithmId + const EnvelopedSignatureAltorithmId + func (id AlgorithmID) String() string + type Canonicalizer interface + Algorithm func() AlgorithmID + Canonicalize func(el *etree.Element) ([]byte, error) + func MakeC14N10ExclusiveCanonicalizerWithPrefixList(prefixList string) Canonicalizer + func MakeC14N10ExclusiveWithCommentsCanonicalizerWithPrefixList(prefixList string) Canonicalizer + func MakeC14N10RecCanonicalizer() Canonicalizer + func MakeC14N10WithCommentsCanonicalizer() Canonicalizer + func MakeC14N11Canonicalizer() Canonicalizer + func MakeC14N11WithCommentsCanonicalizer() Canonicalizer + func MakeNullCanonicalizer() Canonicalizer + type Clock struct + func NewFakeClock(wrapped clockwork.Clock) *Clock + func NewFakeClockAt(t time.Time) *Clock + func NewRealClock() *Clock + func (c *Clock) After(d time.Duration) <-chan time.Time + func (c *Clock) Now() time.Time + func (c *Clock) Sleep(d time.Duration) + type MemoryX509CertificateStore struct + Roots []*x509.Certificate + func (mX509cs *MemoryX509CertificateStore) Certificates() ([]*x509.Certificate, error) + type MemoryX509KeyStore struct + func (ks *MemoryX509KeyStore) GetKeyPair() (*rsa.PrivateKey, []byte, error) + type NullCanonicalizer struct + func (c *NullCanonicalizer) Algorithm() AlgorithmID + func (c *NullCanonicalizer) Canonicalize(el *etree.Element) ([]byte, error) + type SigningContext struct + Canonicalizer Canonicalizer + Hash crypto.Hash + IdAttribute string + KeyStore X509KeyStore + Prefix string + func NewDefaultSigningContext(ks X509KeyStore) *SigningContext + func NewSigningContext(signer crypto.Signer, certs [][]byte) (*SigningContext, error) + func (ctx *SigningContext) ConstructSignature(el *etree.Element, enveloped bool) (*etree.Element, error) + func (ctx *SigningContext) GetDigestAlgorithmIdentifier() string + func (ctx *SigningContext) GetSignatureMethodIdentifier() string + func (ctx *SigningContext) SetSignatureMethod(algorithmID string) error + func (ctx *SigningContext) SignEnveloped(el *etree.Element) (*etree.Element, error) + func (ctx *SigningContext) SignString(content string) ([]byte, error) + type TLSCertKeyStore tls.Certificate + func (d TLSCertKeyStore) GetChain() ([][]byte, error) + func (d TLSCertKeyStore) GetKeyPair() (*rsa.PrivateKey, []byte, error) + type ValidationContext struct + CertificateStore X509CertificateStore + Clock *Clock + IdAttribute string + func NewDefaultValidationContext(certificateStore X509CertificateStore) *ValidationContext + func (ctx *ValidationContext) Validate(el *etree.Element) (*etree.Element, error) + type X509CertificateStore interface + Certificates func() (roots []*x509.Certificate, err error) + type X509ChainStore interface + GetChain func() (certs [][]byte, err error) + type X509KeyStore interface + GetKeyPair func() (privateKey *rsa.PrivateKey, cert []byte, err error) + func RandomKeyStoreForTest() X509KeyStore