Discuss this help topic in SecureBlackbox Forum

TElX509CertificateEx.Verify

TElX509CertificateEx     See also     


Filter: C#  VB.NET  Pascal  C++  PHP  Java  


Verifies the signature of the data signed with the private key of this certificate

Declaration

[C#]
    bool Verify(byte[] InBuffer, byte[] Signature);
    bool Verify(byte[] InBuffer, int InStartIndex, int InCount, byte[] SigBuffer, int SigStartIndex, int SigCount);

[VB.NET]
    Function Verify(ByVal InBuffer As Byte(), ByVal Signature As Byte()) As Boolean
    Function Verify(ByVal InBuffer As Byte(), ByVal InStartIndex As Integer, ByVal InCount As Integer, ByVal SigBuffer As Byte(), ByVal SigStartIndex As Integer, ByVal SigCount As Integer) As Boolean

[Pascal]
    function Verify( InBuffer : pointer; InSize : integer; Signature : pointer; SignatureSize : integer) : boolean;

[C++]
    bool Verify(void * InBuffer, int32_t InSize, void * Signature, int32_t SignatureSize);

[PHP]
    bool Verify(TSBPointer|array of byte|string|NULL $InBuffer, integer $InSize, TSBPointer|array of byte|string|NULL $Signature, integer $SignatureSize)

[Java]
    boolean verify(byte[] InBuffer, int InStartIndex, int InCount, byte[] SigBuffer, int SigStartIndex, int SigCount);
    boolean verify(byte[] InBuffer, byte[] Signature);

Parameters

  • InBuffer - should contain the data which should be verified
  • InSize - the size of InBuffer in bytes
  • Signature - buffer with digital signature
  • SignatureSize - the size of Signature in bytes
  • InStartIndex - the start position in the InBuffer from which the data must be read
  • InCount - number of bytes to be read
  • SigBuffer - buffer with digital signature
  • SigStartIndex - the start position in the SigBuffer from which the data must be read
  • SigCount - number of bytes in SigBuffer ti be read

Return value

     True if the signature is successfully verified.
     False otherwise.

Description

    This method causes TElX509Certificate object to validate the signature of data contained in InBuffer.
    it is a good idea not to trust the data whose signature is invalid.
     Note: If the signature includes certificates, they are used for verification instead of certificate, whose method is called. To avoid this, set IncludeCertificates parameter of Sign method to False.

See also:     Sign    

Discuss this help topic in SecureBlackbox Forum