java.lang.Object | |
↳ | java.security.SignedObject |
A
SignedObject
instance acts as a container for another object. The
SignedObject
contains the target in serialized form along with a
digital signature of the serialized data.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
Constructs a new instance of
SignedObject
with the target object,
the private key and the engine to compute the signature.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
|
Returns the name of the algorithm of this
SignedObject
.
|
||||||||||
|
Returns the encapsulated object.
|
||||||||||
|
Returns the signature data of the encapsulated serialized object.
|
||||||||||
|
Indicates whether the contained signature for the encapsulated object is
valid.
|
[Expand]
Inherited Methods
|
|||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Constructs a new instance of
SignedObject
with the target object,
the private key and the engine to compute the signature. The given
object
is signed with the specified key and engine.
object | the object to bes signed. |
---|---|
signingKey |
the private key, used to sign the
object
.
|
signingEngine | the engine that performs the signature generation. |
IOException | if a serialization error occurs. |
---|---|
InvalidKeyException | if the private key is not valid. |
SignatureException | if signature generation failed. |
Returns the name of the algorithm of this
SignedObject
.
SignedObject
.
Returns the encapsulated object. Each time this method is invoked, the encapsulated object is deserialized before it is returned.
IOException | if deserialization failed. |
---|---|
ClassNotFoundException | if the class of the encapsulated object can not be found. |
Returns the signature data of the encapsulated serialized object.
Indicates whether the contained signature for the encapsulated object is valid.
verificationKey | the public key to verify the signature. |
---|---|
verificationEngine | the signature engine. |
true
if the contained signature for the encapsulated
object is valid,
false
otherwise.
InvalidKeyException | if the public key is invalid. |
---|---|
SignatureException | if signature verification failed. |