Documentation ¶
Index ¶
- func CompressedEncodedSignedString(data interface{}, privateKeyPath string) (string, error)
- func CompressedEncodedSignedStringFromKey(data interface{}, key string) (string, error)
- func CompressedEncodedString(data interface{}) (string, error)
- func DecodeAndInflateString(data string) ([]byte, error)
- func DecodeString(data string) ([]byte, error)
- func DeflateAndEncodeString(data []byte) string
- func EncodeString(data []byte) string
- func EncodedSignedString(data interface{}, privateKeyPath string) (string, error)
- func EncodedString(data interface{}) (string, error)
- func Sign(xml string, privateKeyPath string) (string, error)
- func SignWithKey(xml string, pemKey string) (string, error)
- func SignedString(data interface{}, privateKeyPath string) (string, error)
- func String(data interface{}) (string, error)
- func Verify(xml string, publicCertPath string) error
- func VerifyWithCert(xml string, certPem string) error
- type CanonicalizationMethod
- type DigestMethod
- type DigestValue
- type KeyInfo
- type SamlsigReference
- type Signature
- type SignatureMethod
- type SignatureValue
- type SignedInfo
- type Transform
- type Transforms
- type X509Certificate
- type X509Data
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CompressedEncodedSignedString ¶
CompressedEncodedSignedString sign xml document, compress, then base64 encode the xml document
func CompressedEncodedSignedStringFromKey ¶
CompressedEncodedSignedStringFromKey sign string with sp key, compress, then base64 encode the xml document
func CompressedEncodedString ¶
CompressedEncodedString compress, then base64 encode the xml document
func DecodeAndInflateString ¶
DecodeAndInflateString base64 decode and inflate string
func DecodeString ¶
DecodeString base64 decode string
func DeflateAndEncodeString ¶
DeflateAndEncodeString deflate string then base 64 encode
func EncodedSignedString ¶
EncodedSignedString get base64 encoded, xml signed string representation of xml document
func EncodedString ¶
EncodedString base64 encode xml document
func SignWithKey ¶
SignWithKey create signature for xml document using pem formatted string representing x509 key. Returns signed xml document.
func SignedString ¶
SignedString sign the xml document and return string representation
func VerifyWithCert ¶
VerifyWithCert validate xml document using pem formatted string
Types ¶
type CanonicalizationMethod ¶
CanonicalizationMethod TODO needs description
type DigestMethod ¶
DigestMethod algorithm used to create signature digest
type DigestValue ¶
DigestValue resulting signature digest
type KeyInfo ¶
KeyInfo key information for signature
func GetKeyInfoEntity ¶
GetKeyInfoEntity for specified namespace
type SamlsigReference ¶
type SamlsigReference struct { XMLName xml.Name URI string `xml:"URI,attr"` Transforms Transforms `xml:",innerxml"` DigestMethod DigestMethod `xml:",innerxml"` DigestValue DigestValue `xml:",innerxml"` }
SamlsigReference TODO needs description
type Signature ¶
type Signature struct { XMLName xml.Name ID string `xml:"Id,attr"` SignedInfo SignedInfo SignatureValue SignatureValue KeyInfo KeyInfo }
Signature xml signature
func GetSignatureEntity ¶
GetSignatureEntity get an xml signature entity
type SignatureMethod ¶
SignatureMethod Algorithm for signature
type SignatureValue ¶
SignatureValue signature information data
type SignedInfo ¶
type SignedInfo struct { XMLName xml.Name CanonicalizationMethod CanonicalizationMethod SignatureMethod SignatureMethod SamlsigReference SamlsigReference }
SignedInfo xml signature information
type Transforms ¶
Transforms set of transforms applied to signature
type X509Certificate ¶
X509Certificate X.509 formatted certificate
type X509Data ¶
type X509Data struct { XMLName xml.Name X509Certificate X509Certificate `xml:",innerxml"` }
X509Data X.509 formatted data