public class ArtifactImpl extends Object implements Artifact
Artifact
. It models
type urn:oasis:names:tc:SAML:2.0:artifact-04 Artifact
.
SAML_artifact := B64(TypeCode EndpointIndex RemainingArtifact) TypeCode := Byte1Byte2 EndpointIndex := Byte1Byte2 TypeCode := 0x0004 RemainingArtifact := SourceID messageHandle SourceID := 20-byte_sequence MessageHandle := 20-byte_sequence
Constructor and Description |
---|
ArtifactImpl(byte[] typecode,
int endpointindex,
String sourceid,
String messagehandle)
Constructor.
|
ArtifactImpl(Element element)
Class constructor with
Artifact in
Element format. |
ArtifactImpl(String encodedArtifactValue)
Constructor with
Base64 encoded Artifact
value. |
Modifier and Type | Method and Description |
---|---|
String |
getArtifactValue()
Returns the artifact.
|
int |
getEndpointIndex()
Returns the
EndpointIndex of the artifact. |
String |
getMessageHandle()
Returns the
MessageHandle of the artifact. |
String |
getSourceID()
Returns the
SourceID of the artifact. |
byte[] |
getTypeCode()
Returns the
TypeCode of the artifact. |
String |
toXMLString()
Returns a String representation of the element.
|
String |
toXMLString(boolean includeNS,
boolean declareNS)
Returns a String representation of the element.
|
public ArtifactImpl(Element element) throws SAML2Exception
Artifact
in
Element
format.SAML2Exception
public ArtifactImpl(String encodedArtifactValue) throws SAML2Exception
Base64
encoded Artifact
value.encodedArtifactValue
- the Artifact value.SAML2Exception
- if it fails to instantiate the object.public ArtifactImpl(byte[] typecode, int endpointindex, String sourceid, String messagehandle) throws SAML2Exception
typecode
- two byte sequence representing TypeCode
.endpointindex
- integer value of EndpointIndex
. Its
allowed range is between 0 and 65535.sourceid
- String format of 20-byte sequence. Usually obtained
from taking the SHA-1 hash of the identification URL (called
provider ID).messagehandle
- String format of 20-byte sequence identifying
a message. This value is constructed from a cryptographically
strong random or pseudorandom number sequence.SAML2Exception
- if it fails to instantiate the object.public String getArtifactValue()
getArtifactValue
in interface Artifact
Base64
encoded.public String getSourceID()
SourceID
of the artifact.getSourceID
in interface Artifact
SourceID
of the artifact.public String getMessageHandle()
MessageHandle
of the artifact.
The result will be decoded.getMessageHandle
in interface Artifact
MessageHandle
of the artifact.public byte[] getTypeCode()
TypeCode
of the artifact.getTypeCode
in interface Artifact
TypeCode
for the artifact.public int getEndpointIndex()
EndpointIndex
of the artifact.getEndpointIndex
in interface Artifact
EndpointIndex
for the
artifact.public String toXMLString() throws SAML2Exception
toXMLString
in interface Artifact
SAML2Exception
- if the object does not conform to the schema.public String toXMLString(boolean includeNS, boolean declareNS) throws SAML2Exception
toXMLString
in interface Artifact
includeNS
- Determines whether or not the namespace qualifier is
prepended to the Element when converteddeclareNS
- Determines whether or not the namespace is declared
within the Element.SAML2Exception
- if the object does not conform to the schema.Copyright © 2010–2025 Open Identity Platform Community. All rights reserved.