Signature.Verify Method

Definition

Overloads

Verify(Byte[])

Verifies the passed-in signature.

Verify(Byte[], Int32, Int32)

Verifies the passed-in signature in the specified array of bytes, starting at the specified offset.

Verify(Byte[])

Verifies the passed-in signature.

[Android.Runtime.Register("verify", "([B)Z", "")]
public bool Verify (byte[]? signature);
[<Android.Runtime.Register("verify", "([B)Z", "")>]
member this.Verify : byte[] -> bool

Parameters

signature
Byte[]

the signature bytes to be verified.

Returns

true if the signature was verified, false if not.

Attributes

Exceptions

if this Signature instance is not initialized properly.

Remarks

Verifies the passed-in signature.

A call to this method resets this signature object to the state it was in when previously initialized for verification via a call to initVerify(PublicKey). That is, the object is reset and available to verify another signature from the identity whose public key was specified in the call to initVerify.

Java documentation for java.security.Signature.verify(byte[]).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Verify(Byte[], Int32, Int32)

Verifies the passed-in signature in the specified array of bytes, starting at the specified offset.

[Android.Runtime.Register("verify", "([BII)Z", "")]
public bool Verify (byte[]? signature, int offset, int length);
[<Android.Runtime.Register("verify", "([BII)Z", "")>]
member this.Verify : byte[] * int * int -> bool

Parameters

signature
Byte[]

the signature bytes to be verified.

offset
Int32

the offset to start from in the array of bytes.

length
Int32

the number of bytes to use, starting at offset.

Returns

true if the signature was verified, false if not.

Attributes

Exceptions

if this Signature instance is not initialized properly.

if offset or length are not valid in respect to signature.

Remarks

Verifies the passed-in signature in the specified array of bytes, starting at the specified offset.

A call to this method resets this signature object to the state it was in when previously initialized for verification via a call to initVerify(PublicKey). That is, the object is reset and available to verify another signature from the identity whose public key was specified in the call to initVerify.

Added in 1.4.

Java documentation for java.security.Signature.verify(byte[], int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to