org.bouncycastle.jce.spec

## Class MQVPrivateKeySpec

- java.lang.Object
- - org.bouncycastle.jce.spec.MQVPrivateKeySpec

All Implemented Interfaces:
  java.io.Serializable, java.security.Key, java.security.PrivateKey, java.security.spec.KeySpec, MQVPrivateKey

    public class MQVPrivateKeySpec
    extends java.lang.Object
    implements java.security.spec.KeySpec, MQVPrivateKey

Static/ephemeral private key (pair) for use with ECMQV key agreement (Optionally provides the ephemeral public key)

See Also:
  Serialized Form

### Field Summary

### Fields inherited from interface java.security.PrivateKey

`serialVersionUID`

### Constructor Summary

Constructors
Constructor and Description
`MQVPrivateKeySpec(java.security.PrivateKey staticPrivateKey, java.security.PrivateKey ephemeralPrivateKey)`
`MQVPrivateKeySpec(java.security.PrivateKey staticPrivateKey, java.security.PrivateKey ephemeralPrivateKey, java.security.PublicKey ephemeralPublicKey)`

### Method Summary

Methods
`java.lang.String` `getAlgorithm()` return "ECMQV"
`byte[]` `getEncoded()` returns null
`java.security.PrivateKey` `getEphemeralPrivateKey()` return the ephemeral private key
`java.security.PublicKey` `getEphemeralPublicKey()` return the ephemeral public key (may be null)
`java.lang.String` `getFormat()` return null
`java.security.PrivateKey` `getStaticPrivateKey()` return the static private key

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### MQVPrivateKeySpec

    public MQVPrivateKeySpec(java.security.PrivateKey staticPrivateKey,
                     java.security.PrivateKey ephemeralPrivateKey)

Parameters:
  `staticPrivateKey` - the static private key.
  `ephemeralPrivateKey` - the ephemeral private key.

#### MQVPrivateKeySpec

    public MQVPrivateKeySpec(java.security.PrivateKey staticPrivateKey,
                     java.security.PrivateKey ephemeralPrivateKey,
                     java.security.PublicKey ephemeralPublicKey)

Parameters:
  `staticPrivateKey` - the static private key.
  `ephemeralPrivateKey` - the ephemeral private key.
  `ephemeralPublicKey` - the ephemeral public key (may be null).

### Method Detail

#### getStaticPrivateKey

    public java.security.PrivateKey getStaticPrivateKey()

return the static private key

Specified by:
  `getStaticPrivateKey` in interface `MQVPrivateKey`

#### getEphemeralPrivateKey

    public java.security.PrivateKey getEphemeralPrivateKey()

return the ephemeral private key

Specified by:
  `getEphemeralPrivateKey` in interface `MQVPrivateKey`

#### getEphemeralPublicKey

    public java.security.PublicKey getEphemeralPublicKey()

return the ephemeral public key (may be null)

Specified by:
  `getEphemeralPublicKey` in interface `MQVPrivateKey`

#### getAlgorithm

    public java.lang.String getAlgorithm()

return "ECMQV"

Specified by:
  `getAlgorithm` in interface `java.security.Key`

#### getFormat

    public java.lang.String getFormat()

return null

Specified by:
  `getFormat` in interface `java.security.Key`

#### getEncoded

    public byte[] getEncoded()

returns null

Specified by:
  `getEncoded` in interface `java.security.Key`