Main Page | Modules | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

beecrypt::security::Signature Class Reference
[C++ classes mimicking java.security]

#include <Signature.h>

Inheritance diagram for beecrypt::security::Signature:

Inheritance graph
[legend]
Collaboration diagram for beecrypt::security::Signature:

Collaboration graph
[legend]
List of all members.

Public Member Functions

virtual ~Signature ()
AlgorithmParametersgetParameters () const
void setParameter (const AlgorithmParameterSpec &) throw (InvalidAlgorithmParameterException)
void initSign (const PrivateKey &) throw (InvalidKeyException)
void initSign (const PrivateKey &, SecureRandom *) throw (InvalidKeyException)
void initVerify (const PublicKey &) throw (InvalidKeyException)
bytearraysign () throw (IllegalStateException, SignatureException)
size_t sign (byte *, size_t, size_t) throw (ShortBufferException, IllegalStateException, SignatureException)
size_t sign (bytearray &) throw (IllegalStateException, SignatureException)
bool verify (const bytearray &) throw (IllegalStateException, SignatureException)
bool verify (const byte *, size_t, size_t) throw (IllegalStateException, SignatureException)
void update (byte) throw (IllegalStateException)
void update (const byte *, size_t, size_t) throw (IllegalStateException)
void update (const bytearray &) throw (IllegalStateException)
const StringgetAlgorithm () const throw ()
const ProvidergetProvider () const throw ()

Static Public Member Functions

static SignaturegetInstance (const String &algorithm) throw (NoSuchAlgorithmException)
 Returns a Signature object that implements the requested algorithm.
static SignaturegetInstance (const String &algorithm, const String &provider) throw (NoSuchAlgorithmException, NoSuchProviderException)
 Returns a Signature object that implements the requested algorithm, from the requested provider.
static SignaturegetInstance (const String &algorithm, const Provider &provider) throw (NoSuchAlgorithmException)

Protected Member Functions

 Signature (SignatureSpi *spi, const Provider *provider, const String &algorithm)

Protected Attributes

int state

Static Protected Attributes

static const int UNINITIALIZED = 0
static const int VERIFY = 1
static const int SIGN = 2

Detailed Description


Constructor & Destructor Documentation

beecrypt::security::Signature::Signature SignatureSpi spi,
const Provider provider,
const String algorithm
[protected]
 

virtual beecrypt::security::Signature::~Signature  )  [virtual]
 


Member Function Documentation

const String& beecrypt::security::Signature::getAlgorithm  )  const throw ()
 

static Signature* beecrypt::security::Signature::getInstance const String algorithm,
const Provider provider
throw (NoSuchAlgorithmException) [static]
 

static Signature* beecrypt::security::Signature::getInstance const String algorithm,
const String provider
throw (NoSuchAlgorithmException, NoSuchProviderException) [static]
 

Returns a Signature object that implements the requested algorithm, from the requested provider.

Parameters:
algorithm the standard algorithm name.
provider the name of the provider.
Exceptions:
NoSuchAlgorithmException if the requested algorithm is not available in the requested provider.
NoSuchProviderException if the requested provider is not available.

static Signature* beecrypt::security::Signature::getInstance const String algorithm  )  throw (NoSuchAlgorithmException) [static]
 

Returns a Signature object that implements the requested algorithm.

If the default provider has an implementation of the requested algorithm that one is used; otherwise other providers are searched.

Parameters:
algorithm the standard name of the requested algorithm.
Exceptions:
NoSuchAlgorithmException if the requested algorithm is not available.

AlgorithmParameters* beecrypt::security::Signature::getParameters  )  const
 

const Provider& beecrypt::security::Signature::getProvider  )  const throw ()
 

void beecrypt::security::Signature::initSign const PrivateKey ,
SecureRandom
throw (InvalidKeyException)
 

void beecrypt::security::Signature::initSign const PrivateKey  )  throw (InvalidKeyException)
 

void beecrypt::security::Signature::initVerify const PublicKey  )  throw (InvalidKeyException)
 

void beecrypt::security::Signature::setParameter const AlgorithmParameterSpec &   )  throw (InvalidAlgorithmParameterException)
 

size_t beecrypt::security::Signature::sign bytearray  )  throw (IllegalStateException, SignatureException)
 

size_t beecrypt::security::Signature::sign byte ,
size_t  ,
size_t 
throw (ShortBufferException, IllegalStateException, SignatureException)
 

bytearray* beecrypt::security::Signature::sign  )  throw (IllegalStateException, SignatureException)
 

void beecrypt::security::Signature::update const bytearray  )  throw (IllegalStateException)
 

void beecrypt::security::Signature::update const byte ,
size_t  ,
size_t 
throw (IllegalStateException)
 

void beecrypt::security::Signature::update byte   )  throw (IllegalStateException)
 

bool beecrypt::security::Signature::verify const byte ,
size_t  ,
size_t 
throw (IllegalStateException, SignatureException)
 

bool beecrypt::security::Signature::verify const bytearray  )  throw (IllegalStateException, SignatureException)
 


Member Data Documentation

const int beecrypt::security::Signature::SIGN = 2 [static, protected]
 

int beecrypt::security::Signature::state [protected]
 

const int beecrypt::security::Signature::UNINITIALIZED = 0 [static, protected]
 

const int beecrypt::security::Signature::VERIFY = 1 [static, protected]
 


The documentation for this class was generated from the following file:
Generated on Mon Jun 20 08:11:35 2005 for BeeCrypt by  doxygen 1.4.0