fm.liveswitch.RsaKey Class Reference

An RSA key. More...

Public Member Functions

byte[] getBytes ()
 Serializes this key to binary. More...
 
byte[] getCoefficient ()
 Gets the private value inverse-Q. More...
 
byte[] getExponent1 ()
 Gets the private value DP. More...
 
byte[] getExponent2 ()
 Gets the private value DQ. More...
 
byte[] getModulus ()
 Gets the public value N. More...
 
byte[] getPrime1 ()
 Gets the private value P. More...
 
byte[] getPrime2 ()
 Gets the private value Q. More...
 
byte[] getPrivateExponent ()
 Gets the private value D. More...
 
byte[] getPublicExponent ()
 Gets the public value E. More...
 
int getSize ()
 Gets the size of the key. More...
 
fm.liveswitch.AsymmetricKeyType getType ()
 Gets the key type. More...
 
boolean hasPrivate ()
 Returns. More...
 
boolean hasPublic ()
 Returns. More...
 
 RsaKey ()
 
void setCoefficient (byte[] value)
 Sets the private value inverse-Q. More...
 
void setExponent1 (byte[] value)
 Sets the private value DP. More...
 
void setExponent2 (byte[] value)
 Sets the private value DQ. More...
 
void setModulus (byte[] value)
 Sets the public value N. More...
 
void setPrime1 (byte[] value)
 Sets the private value P. More...
 
void setPrime2 (byte[] value)
 Sets the private value Q. More...
 
void setPrivateExponent (byte[] value)
 Sets the private value D. More...
 
void setPublicExponent (byte[] value)
 Sets the public value E. More...
 

Static Public Member Functions

static fm.liveswitch.RsaKey parseBuffer (fm.liveswitch.DataBuffer buffer)
 Deserializes a key from binary. More...
 
static fm.liveswitch.RsaKey parseBytes (byte[] bytes)
 Deserializes a key from binary. More...
 
- Static Public Member Functions inherited from fm.liveswitch.AsymmetricKey
static fm.liveswitch.AsymmetricKey createKey (fm.liveswitch.AsymmetricKeyType keyType)
 Creates a key. More...
 

Additional Inherited Members

- Protected Member Functions inherited from fm.liveswitch.AsymmetricKey
 AsymmetricKey ()
 

Detailed Description

An RSA key.

Constructor & Destructor Documentation

◆ RsaKey()

fm.liveswitch.RsaKey.RsaKey ( )

Member Function Documentation

◆ getBytes()

byte [] fm.liveswitch.RsaKey.getBytes ( )

Serializes this key to binary.

◆ getCoefficient()

byte [] fm.liveswitch.RsaKey.getCoefficient ( )

Gets the private value inverse-Q.

◆ getExponent1()

byte [] fm.liveswitch.RsaKey.getExponent1 ( )

Gets the private value DP.

◆ getExponent2()

byte [] fm.liveswitch.RsaKey.getExponent2 ( )

Gets the private value DQ.

◆ getModulus()

byte [] fm.liveswitch.RsaKey.getModulus ( )

Gets the public value N.

◆ getPrime1()

byte [] fm.liveswitch.RsaKey.getPrime1 ( )

Gets the private value P.

◆ getPrime2()

byte [] fm.liveswitch.RsaKey.getPrime2 ( )

Gets the private value Q.

◆ getPrivateExponent()

byte [] fm.liveswitch.RsaKey.getPrivateExponent ( )

Gets the private value D.

◆ getPublicExponent()

byte [] fm.liveswitch.RsaKey.getPublicExponent ( )

Gets the public value E.

◆ getSize()

int fm.liveswitch.RsaKey.getSize ( )

Gets the size of the key.

◆ getType()

fm.liveswitch.AsymmetricKeyType fm.liveswitch.RsaKey.getType ( )

Gets the key type.

Reimplemented from fm.liveswitch.AsymmetricKey.

◆ hasPrivate()

boolean fm.liveswitch.RsaKey.hasPrivate ( )

Returns.

true

if the key contains private information.

Reimplemented from fm.liveswitch.AsymmetricKey.

◆ hasPublic()

boolean fm.liveswitch.RsaKey.hasPublic ( )

Returns.

true

if the key contains public information.

Reimplemented from fm.liveswitch.AsymmetricKey.

◆ parseBuffer()

static fm.liveswitch.RsaKey fm.liveswitch.RsaKey.parseBuffer ( fm.liveswitch.DataBuffer  buffer)
static

Deserializes a key from binary.

Parameters
bufferThe buffer.

◆ parseBytes()

static fm.liveswitch.RsaKey fm.liveswitch.RsaKey.parseBytes ( byte[]  bytes)
static

Deserializes a key from binary.

Parameters
bytesThe bytes.

◆ setCoefficient()

void fm.liveswitch.RsaKey.setCoefficient ( byte[]  value)

Sets the private value inverse-Q.

◆ setExponent1()

void fm.liveswitch.RsaKey.setExponent1 ( byte[]  value)

Sets the private value DP.

◆ setExponent2()

void fm.liveswitch.RsaKey.setExponent2 ( byte[]  value)

Sets the private value DQ.

◆ setModulus()

void fm.liveswitch.RsaKey.setModulus ( byte[]  value)

Sets the public value N.

◆ setPrime1()

void fm.liveswitch.RsaKey.setPrime1 ( byte[]  value)

Sets the private value P.

◆ setPrime2()

void fm.liveswitch.RsaKey.setPrime2 ( byte[]  value)

Sets the private value Q.

◆ setPrivateExponent()

void fm.liveswitch.RsaKey.setPrivateExponent ( byte[]  value)

Sets the private value D.

◆ setPublicExponent()

void fm.liveswitch.RsaKey.setPublicExponent ( byte[]  value)

Sets the public value E.