C# Class wSigner.DocumentSigner

A document signer
ファイルを表示 Open project: wpq0/Document-Signer

Public Methods

Method Description
For ( string type ) : DocumentSigner

Initialize a signer for the specified file name.

Sign ( Stream input, Stream output, X509Certificate2 certificate ) : void

Sign

Sign ( string input, string output, X509Certificate2 certificate ) : void

Signs the file.

Verify ( Stream input, string serial = null ) : bool

Verifies

Protected Methods

Method Description
CheckInputOutputAndCertificate ( Stream input, Stream output, X509Certificate2 certificate ) : void

Checks the input output and certificate.

Private Methods

Method Description
NormalizeExtension ( string input ) : string

Normalizes the extension.

Method Details

CheckInputOutputAndCertificate() protected static method

Checks the input output and certificate.
protected static CheckInputOutputAndCertificate ( Stream input, Stream output, X509Certificate2 certificate ) : void
input Stream The input.
output Stream The output.
certificate System.Security.Cryptography.X509Certificates.X509Certificate2 The certificate.
return void

For() public static method

Initialize a signer for the specified file name.
public static For ( string type ) : DocumentSigner
type string The type.
return DocumentSigner

Sign() public abstract method

Sign
public abstract Sign ( Stream input, Stream output, X509Certificate2 certificate ) : void
input Stream The input.
output Stream The output.
certificate System.Security.Cryptography.X509Certificates.X509Certificate2 The certificate.
return void

Sign() public method

Signs the file.
public Sign ( string input, string output, X509Certificate2 certificate ) : void
input string The input.
output string The output.
certificate System.Security.Cryptography.X509Certificates.X509Certificate2 The certificate.
return void

Verify() public abstract method

Verifies
public abstract Verify ( Stream input, string serial = null ) : bool
input Stream The input.
serial string The serial.
return bool