Control iSignServer

This control is used for performing verification activities on the application server.

VB.Net Syntax:

Dim object As ISIGNSERVERCONTROLLib.iSignServer = New ISIGNSERVERCONTROLLib.iSignServer
object.VerifySignature(sSignature);

 

C# Syntax:

ISIGNSERVERCONTROLLib.iSignServerClass object = new ISIGNSERVERCONTROLLib.iSignServerClass( );
object.VerifySignature(sSignature);

Property Summary
_EncrAlg

EncryptionAlgorithm

Sets the encryption algorithm

int

EncryptionEnabled

Enables/disables the encryption of the ink.

string

EncryptionKey

Sets the encryption key

long

HashVal

Return the result(s) of the hashing done using InitHash, AddHash and FinishHash.  Each hash value is a long integer. 

int

SamplingRate

READ-ONLY. The current sampling rate for the signature. This is needed for verifying the signature.

string

Template

The template data. Access this property to save or restore the control's contents from disk or a database.

bool

UpdateTemplate

Set this to True if the current Template is to be updated with the new signature, otherwise set it to False.

 

Method Summary
long

AddHash(String sHash)

Adds string to be hashed to the current hashing session.

long

FinishHash( )

Finalizes the hashing session and returns the result in HashVal1 through HashVal5 or HashVal.

void

InitHash( )

Initiates a hashing session. Is used in conjunction with AddHash and FinishHash

void

SetHashAlgorithm (int alg)

Set the hash mode.

long

VerifySignature( )

Verifies a signature against a signature template.

 

 

Property Details

EncryptionAlgorithm

public static ISIGNSERVERCONTROLLib._EncrAlg EncryptionAlgorithm

Sets the encryption algorithm

Options:

-1
NONE
No encryption algorithm specified.
0
FAST CIC's FAST encryption algorithm
1
DES DES 56 bit encryption algorithm
2
DES_40 DES 40 bit encryption algorithm
3
TRIPLE_DES DES 128 bit encryption algorithm

VB.Net Usage: object.EncryptionAlgorithm = 3  ' Triple_DES used here

C# Usage: object.EncryptionAlgorithm = (ISIGNSERVERCONTROLLib._EncrAlg)  3;  // Triple_DES used here


EncryptionEnabled

public static int EncryptionEnabled

Enables/disables the encryption of the ink.

Options:

0
Disabled
1
Enabled

VB.Net Usage: object.EncryptionEnabled = 1

C# Usage: object.EncryptionEnabled = 1;


EncryptionKey

public static string Encryptionkey

Sets the encryption key

VB.Net Usage: object.Encryptionkey = "12345678"

C# Usage: object.Encryptionkey = "12345678";


HashVal

public static string HashVal

Return the result(s) of the hashing done using InitHash, AddHash and FinishHash.  Each hash value is a long integer. 

VB.Net Usage: Dim s As String = object.HashVal

C# Usage: object.HashVal;


SamplingRate

public static int SamplingRate

READ-ONLY. The current sampling rate for the signature. This is needed for verifying the signature.

VB.Net Usage: Dim i As Integer = object.SamplingRate

C# Usage: object.SamplingRate;


Template

public static string Template

The template data. Access this property to save or restore the control's contents from disk or a database.

VB.Net Usage: object.Template

C# Usage: object.Template;


UpdateTemplate

public static bool UpdateTemplate

The timeout for the InkReady event in milliseconds.

VB.Net Usage: object.UpdateTemplate

C# Usage: object.UpdateTemplate;

 

Method Details

AddHash(String sHash)

public long AddHash(String sHash)

Adds string to be hashed to the current hashing session.

Returns:

0
Success
100 MaxLengthExceeded
101 Bad Mode

VB.Net Usage: Dim r As Long = object.AddHash(signature)

C# Usage: object.AddHash(signature );


FinishHash()

public long FinishHash()

Finalizes the hashing session and returns the result in HashVal1 through HashVal5.

Returns: Always returns Success = 0

VB.Net Usage: object.FinishHash

C# Usage: object.FinishHash( );


HasInk( )

public long HasInk( )

Returns whether or not control contains any ink.

Returns:

0
no ink
1 ink exists

VB.Net Usage: Dim r As Long = object.HasInk

C# Usage: object.HasInk( );


InitHash()

public void InitHash()

Initiates a hashing session. Is used in conjunction with AddHash and FinishHash.

VB.Net Usage: object.InitHash

C# Usage: object.InitHash( );


SetHashAlgorithm (int alg)

public void SetHashAlgorithm (int alg)

Set the hash mode.

Mode :

0
HASH_SHA0
SHAO Algorithm
1
HASH_SHA1
SHA1 Algorithm

Default is SHA0. Once set, all hash operation are done in this mode until control is unloaded.

VB.Net Usage: object.SetHashAlgorithm (1)

C# Usage: object.SetHashAlgorithm (1)


VerifySignature()

public long VerifySignature()

Verifies a signature against a signature template.

Returns:

0
Valid Signature
100
No Template
101
No Signature
-499
Forgery
-482 Bad Encryption Key

VB.Net Usage: object.VerifySignature

C# Usage: object.VerifySignature( );