Exemple #1
0
 /// <summary>GetIdInRequest</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>Id</returns>
 public static string GetIdInRequest(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, @"/samlp:AuthnRequest", "ID", samlNsMgr));
 }
Exemple #2
0
 /// <summary>GetSubjectConfirmationMethodInAssertion</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>SubjectConfirmation - Method</returns>
 public static string GetSubjectConfirmationMethodInAssertion(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, SAML2Const.XPathSubjectConfirmationInAssertion, "Method", samlNsMgr));
 }
Exemple #3
0
 /// <summary>GetConditionsNotOnOrAfterInAssertion</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>Conditions - NotOnOrAfter</returns>
 public static string GetConditionsNotOnOrAfterInAssertion(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, SAML2Const.XPathConditionsInAssertion, "NotOnOrAfter", samlNsMgr));
 }
Exemple #4
0
 /// <summary>GetStatusCodeInResponse</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>StatusCode</returns>
 public static string GetStatusCodeInResponse(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, SAML2Const.XPathStatusCodeInResponse, "Value", samlNsMgr));
 }
Exemple #5
0
 /// <summary>GetAssertionConsumerServiceURLInRequest</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>AssertionConsumerServiceURL</returns>
 public static string GetAssertionConsumerServiceURLInRequest(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, SAML2Const.XPathRequest, "AssertionConsumerServiceURL", samlNsMgr));
 }
Exemple #6
0
 /// <summary>GetProtocolBindingInRequest</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>ProtocolBinding</returns>
 public static string GetProtocolBindingInRequest(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, SAML2Const.XPathRequest, "ProtocolBinding", samlNsMgr));
 }
Exemple #7
0
 /// <summary>GetNameIDPolicyFormatInRequest</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>NameIDPolicy - Format</returns>
 public static string GetNameIDPolicyFormatInRequest(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, SAML2Const.XPathNameIDPolicyInRequest, "Format", samlNsMgr));
 }
Exemple #8
0
 /// <summary>GetIdInAssertion</summary>
 /// <param name="xmlDoc">XmlDocument</param>
 /// <param name="samlNsMgr">XmlNamespaceManager</param>
 /// <returns>Id</returns>
 public static string GetIdInAssertion(
     XmlDocument xmlDoc, XmlNamespaceManager samlNsMgr)
 {
     return(XmlLib.GetAttributeByXPath(
                xmlDoc, @"/saml:Assertion", "ID", samlNsMgr));
 }