Edit

Share via


X509SecurityTokenHandler.ReadToken(XmlReader) Method

Definition

Deserializes the X.509 security token referenced by the specified XML reader.

public:
 override System::IdentityModel::Tokens::SecurityToken ^ ReadToken(System::Xml::XmlReader ^ reader);
public override System.IdentityModel.Tokens.SecurityToken ReadToken (System.Xml.XmlReader reader);
override this.ReadToken : System.Xml.XmlReader -> System.IdentityModel.Tokens.SecurityToken
Public Overrides Function ReadToken (reader As XmlReader) As SecurityToken

Parameters

reader
XmlReader

An XML reader that is pointing to an X.509 security token.

Returns

The security token deserialized from the XML. An instance of X509SecurityToken.

Exceptions

reader is null.

reader is not pointing to a valid X.509 security token as defined in the WS-Security X.509 Token Profile. Or the encodingType specified is other than Base64 or HexBinary.

Applies to