internal Saml2QueryBinding(Saml2Document document, XmlSignatureAlgorithmType?signatureAlgorithm) { this.BindingDirection = document.BindingDirection; this.SignatureAlgorithm = signatureAlgorithm; this.Document = document.GetSaml(); }
internal Saml2StreamBinding(Saml2Document document, XmlSignatureAlgorithmType?signatureAlgorithm = null, XmlDigestAlgorithmType?digestAlgorithm = null) { this.BindingDirection = document.BindingDirection; this.Document = document.GetSaml(); this.HasSignature = X509XmlSigner.HasSignature(this.Document.DocumentElement); }
internal Saml2FormBinding(Saml2Document document, XmlSignatureAlgorithmType?signatureAlgorithm, XmlDigestAlgorithmType?digestAlgorithm, XmlEncryptionAlgorithmType?encryptionAlgorithm) { this.BindingDirection = document.BindingDirection; this.SignatureAlgorithm = signatureAlgorithm; this.DigestAlgorithm = digestAlgorithm; this.EncryptionAlgorithm = encryptionAlgorithm; this.Document = document.GetSaml(); this.HasSignature = X509XmlSigner.HasSignature(this.Document.DocumentElement); if (this.HasSignature) { this.SignatureAlgorithm = X509XmlSigner.GetSignatureAlgorithm(this.Document.DocumentElement); this.DigestAlgorithm = X509XmlSigner.GetDigestAlgorithm(this.Document.DocumentElement); } this.HasEncryption = X509XmlEncryptor.HasEncryptedDataElements(this.Document.DocumentElement); if (this.HasEncryption) { this.EncryptionAlgorithm = X509XmlEncryptor.GetEncryptionAlgorithm(this.Document.DocumentElement); } }