Skip to Content.
Sympa Menu

mace-opensaml-users - Re: Getting error when parsing SAML document

Subject: OpenSAML user discussion

List archive

Re: Getting error when parsing SAML document


Chronological Thread 
  • From: Chad La Joie <>
  • To:
  • Subject: Re: Getting error when parsing SAML document
  • Date: Tue, 21 Nov 2006 14:55:01 -0500

More likely it's a String that contains SAML while the method expects it to contain a URL to something to be parsed.

Alpino, Justin wrote:
Hi rameshpsg,

'sDecode' must be a URI, not the SAML token.

Thanks,

Justin


-----Original Message-----
From: [mailto:] Sent: Tuesday, November 21, 2006 2:40 PM
To:

Subject: Getting error when parsing SAML document


Hi,

This is the piece of code which I use for parsing the SAML document

XML.ParserPool _XMLParserPool = new XML.ParserPool();
Document _Document = _XMLParserPool.parse(sDecode);

I am getting the below error


Exception in thread "main" java.net.MalformedURLException: no protocol:
<saml:Assertion xmlns="urn:oasis:names:tc:SAML:1.0:assertion"
xmlns:ds="http://www.w3.org/2000/09/xmldsig#";
xmlns:saml="urn:oasis:names:tc:SAML:1.0:assertion"
xmlns:samlp="urn:oasis:names:tc:SAML:1.0:protocol"
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
AssertionID="cT_S_T-vKMwidT8_Pzkke8UkC68."
IssueInstant="2004-02-25T16:31:03Z" Issuer="http://aaremote.entegrity.com";
MajorVersion="1" MinorVersion="1"><saml:Conditions
NotBefore="2004-02-25T16:26:03Z"
NotOnOrAfter="2004-02-25T16:36:03Z"></saml:Conditions><saml:AuthenticationSt
atement AuthenticationInstant="2004-02-25T16:30:58Z"
AuthenticationMethod="urn:oasis:names:tc:SAML:1.0:am:password"><saml:Subject
<saml:NameIdentifier
Format="urn:oasis:names:tc:SAML:1.1:nameid-format:X509SubjectName"
NameQualifier="http://www.entegrity.com";>uid=charlie,ou=People,dc=entegrity,
dc=com</saml:NameIdentifier><saml:Sub
jectConfirmation><saml:ConfirmationMethod>urn:oasis:names:tc:SAML:1.0:cm:bea
rer</saml:ConfirmationMethod></saml:SubjectConfirmation></saml:Subject><saml
:SubjectLocality
IPAddress="192.168.4.1"></saml:SubjectLocality></saml:AuthenticationStatemen
t><saml:AttributeStatement><saml:Subject><saml:NameIdentifier
Format="urn:oasis:names:tc:SAML:1.1:nameid-format:X509SubjectName"
NameQualifier="http://www.entegrity.com";>uid=charlie,ou=People,dc=entegrity,
dc=com</saml:NameIdentifier><saml:SubjectConfirmation><saml:ConfirmationMeth
od>urn:oasis:names:tc:SAML:1.0:cm:bearer</saml:ConfirmationMethod></saml:Sub
jectConfirmation></saml:Subject><saml:Attribute
AttributeName="AssuranceLevel"
AttributeNamespace="http://www.oasis-open.org/RSA2004/attributes";><saml:Attr
ibuteValue>1</saml:AttributeValue></saml:Attribute><saml:Attribute
AttributeName="E-mail"
AttributeNamespace="http://www.oasis-open.org/RSA2004/attributes";><saml:Attr
ibuteValue></saml:AttributeValue></saml:Attribute>
<saml:Attribute AttributeName="MemberLevel"
AttributeNamespace="http://www.oasis-open.org/RSA2004/attributes";><saml:Attr
ibuteValue>gold</saml:AttributeValue></saml:Attribute><saml:Attribute
AttributeName="commonName"
AttributeNamespace="http://www.oasis-open.org/RSA2004/attributes";><saml:Attr
ibuteValue>Charles
Connors</saml:AttributeValue></saml:Attribute></saml:AttributeStatement><ds:
Signature>
<ds:SignedInfo>
<ds:CanonicalizationMethod
Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#";></ds:CanonicalizationMet
hod>
<ds:SignatureMethod
Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1";></ds:SignatureMethod>
<ds:Reference URI="#cT_S_T-vKMwidT8_Pzkke8UkC68.">
<ds:Transforms>
<ds:Transform
Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature";></ds:Trans
form>
<ds:Transform
Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#";><ec:InclusiveNamespaces
xmlns:ec="http://www.w3.org/2001/10/xml-exc-c14n#"; PrefixList="code ds kind
rw saml samlp typens #default xsd
xsi"></ec:InclusiveNamespaces></ds:Transform>
</ds:Transforms>
<ds:DigestMethod
Algorithm="http://www.w3.org/2000/09/xmldsig#sha1";></ds:DigestMethod>
<ds:DigestValue>+Yev+PwE9q5E9niQqM/+YpXxL6E=</ds:DigestValue>
</ds:Reference>
</ds:SignedInfo>
<ds:SignatureValue>
dZRJ2Fj9ImD41n2wisFwNrDK+uVjEExKlhTe2oCVmv/QNOsWQI4P9S0DdKwPa0rkrz3ksdlV7oxa
UOU3BPOmxQljyuX40vBO5/KLlrw6Wu3NC8/7gWJUkZW3Cb5c7gdPLS6ic8BXVEclxLbW8U9/3M1C
HHK8MpArNsQC07n/MUhgSicXCH6KREpyKOd4E0FWvt5H2K58Nf62CDlEqUY3P3C6drOlwjVBfMbv
1Nhll1VmATUa7tAA9s6tFeExwJtJdBSoO/5nJk3HkBkGzE9XvX7AprfLtidw6fC2dP61Y2x5A0gg
gzNjv4Dl9hWNcTkGLZH+SRdpCnjDQXGCuBQNRQ==
</ds:SignatureValue>
</ds:Signature></saml:Assertion>
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at
com.sun.org.apache.xerces.internal.impl.XMLEntityManager.setupCurrentEntity(
Unknown Source)
at
com.sun.org.apache.xerces.internal.impl.XMLVersionDetector.determineDocVersi
on(Unknown Source)
at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown
Source)
at
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown
Source)
at
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
at
com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(Unknown Source)
at
com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Unknown
Source)
at org.opensaml.XML$ParserPool.parse(Unknown Source)
at org.opensaml.XML$ParserPool.parse(Unknown Source)
at org.opensaml.SignatureTest.testSignature(SignatureTest.java:65)
at org.opensaml.SignatureTest.main(SignatureTest.java:80)


Can somebody tell me what could be the reason for the error.

"The sender believes that this E-mail and any attachments were free of any harmful and malicious code or defects when sent. The sender is not liable for any loss or damage arising in any way from this message or its attachments.
Confidentiality Note: This e-mail is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, is prohibited. If you have received this e-mail in error, please inform the sender, and destroy the original message and all copies."



Archive powered by MHonArc 2.6.16.

Top of Page