EnvelopedSignatureWriter Class

Definition

Wraps a XmlWriter and generates a signature automatically when the envelope is written completely. By default the generated signature is inserted as the last element in the envelope. This can be modified by explicitly calling WriteSignature to indicate the location inside the envelope where the signature should be inserted.

public class EnvelopedSignatureWriter : Microsoft.IdentityModel.Xml.DelegatingXmlDictionaryWriter
type EnvelopedSignatureWriter = class
    inherit DelegatingXmlDictionaryWriter
Public Class EnvelopedSignatureWriter
Inherits DelegatingXmlDictionaryWriter
Inheritance

Constructors

EnvelopedSignatureWriter(XmlWriter, SigningCredentials, String)

Initializes an instance of EnvelopedSignatureWriter. The returned writer can be directly used to write the envelope. The signature will be automatically generated when the envelope is completed.

EnvelopedSignatureWriter(XmlWriter, SigningCredentials, String, String)

Initializes an instance of EnvelopedSignatureWriter. The returned writer can be directly used to write the envelope. The signature will be automatically generated when the envelope is completed.

Fields

SignaturePlaceholder

Default name of the SignaturePlaceholder element.

Properties

DSigSerializer

Gets or sets the DSigSerializer to use.

InnerWriter

Gets or sets the InnerWriter.

(Inherited from DelegatingXmlDictionaryWriter)
TracingWriter

Gets or sets a XmlDictionaryWriter for tracing.

(Inherited from DelegatingXmlDictionaryWriter)
UseInnerWriter

Gets the UseInnerWriter

(Inherited from DelegatingXmlDictionaryWriter)
WriteState

When overridden in a derived class, gets the state of the writer.

(Inherited from DelegatingXmlDictionaryWriter)

Methods

Dispose(Boolean)

Releases the unmanaged resources used by the System.IdentityModel.Protocols.XmlSignature.EnvelopedSignatureWriter and optionally releases the managed resources.

Flush()

Flushes the underlying stream.

(Inherited from DelegatingXmlDictionaryWriter)
LookupPrefix(String)

Returns the closest prefix defined in the current namespace scope for the namespace URI.

(Inherited from DelegatingXmlDictionaryWriter)
WriteBase64(Byte[], Int32, Int32)

Encodes the specified binary bytes as Base64 and writes out the resulting text.

(Inherited from DelegatingXmlDictionaryWriter)
WriteCData(String)

Writes out a CDATA block containing the specified text.

(Inherited from DelegatingXmlDictionaryWriter)
WriteCharEntity(Char)

Forces the generation of a character entity for the specified Unicode character value.

(Inherited from DelegatingXmlDictionaryWriter)
WriteChars(Char[], Int32, Int32)

When overridden in a derived class, writes text one buffer at a time.

(Inherited from DelegatingXmlDictionaryWriter)
WriteComment(String)

Writes out a comment containing the specified text.

(Inherited from DelegatingXmlDictionaryWriter)
WriteDocType(String, String, String, String)

Writes the DOCTYPE declaration with the specified name and optional attributes.

(Inherited from DelegatingXmlDictionaryWriter)
WriteEndAttribute()

Closes the previous System.Xml.XmlWriter.WriteStartAttribute(System.String,System.String) call.

(Inherited from DelegatingXmlDictionaryWriter)
WriteEndDocument()

Closes any open elements or attributes and puts the writer back in the Start state.

(Inherited from DelegatingXmlDictionaryWriter)
WriteEndElement()

Overrides the base class implementation. When the last element of the envelope is written the signature is automatically computed over the envelope and the signature is inserted at the appropriate position, if WriteSignature was explicitly called or is inserted at the end of the envelope.

WriteEntityRef(String)

Writes out an entity reference as name.

(Inherited from DelegatingXmlDictionaryWriter)
WriteFullEndElement()

Overrides the base class implementation. When the last element of the envelope is written the signature is automatically computed over the envelope and the signature is inserted at the appropriate position, if WriteSignature was explicitly called or is inserted at the end of the envelope.

WriteProcessingInstruction(String, String)

Writes out a processing instruction with a space between the name and text as follows: <?name text?>.

(Inherited from DelegatingXmlDictionaryWriter)
WriteRaw(Char[], Int32, Int32)

When overridden in a derived class, writes raw markup manually from a character buffer.

(Inherited from DelegatingXmlDictionaryWriter)
WriteRaw(String)

Writes raw markup manually from a string.

(Inherited from DelegatingXmlDictionaryWriter)
WriteSignature()

Call this method while writing the envelope to indicate at which point the signature should be inserted.

WriteStartAttribute(String, String, String)

Writes the start of an attribute with the specified local name and namespace URI.

(Inherited from DelegatingXmlDictionaryWriter)
WriteStartDocument()

When overridden in a derived class, writes the XML declaration with the version "1.0".

(Inherited from DelegatingXmlDictionaryWriter)
WriteStartDocument(Boolean)

When overridden in a derived class, writes the XML declaration with the version "1.0" and the standalone attribute.

(Inherited from DelegatingXmlDictionaryWriter)
WriteStartElement(String, String, String)

Overrides the base class. Writes the specified start tag and associates it with the given namespace.

WriteString(String)

Writes the given text content.

(Inherited from DelegatingXmlDictionaryWriter)
WriteSurrogateCharEntity(Char, Char)

Generates and writes the surrogate character entity for the surrogate character pair.

(Inherited from DelegatingXmlDictionaryWriter)
WriteWhitespace(String)

Writes out the given white space.

(Inherited from DelegatingXmlDictionaryWriter)
WriteXmlAttribute(String, String)

Writes an attribute as a xml attribute with the prefix 'xml:'.

(Inherited from DelegatingXmlDictionaryWriter)
WriteXmlnsAttribute(String, String)

Writes an xmlns namespace declaration.

(Inherited from DelegatingXmlDictionaryWriter)

Applies to