Android APIs
public class

OAEPParameterSpec

extends Object
implements AlgorithmParameterSpec
java.lang.Object
   ↳ javax.crypto.spec.OAEPParameterSpec

Class Overview

The algorithm parameter specification for the OAEP Padding algorithm.

This padding algorithm is defined in the PKCS #1 standard.

Summary

Fields
public static final OAEPParameterSpec DEFAULT The algorithm parameter instance with default values.
Public Constructors
OAEPParameterSpec(String mdName, String mgfName, AlgorithmParameterSpec mgfSpec, PSource pSrc)
Creates a new OAEPParameterSpec instance with the specified message digest algorithm name, mask generation function (mgf) algorithm name, parameters for the mgf algorithm and the source of the label L.
Public Methods
String getDigestAlgorithm()
Returns the algorithm name of the message digest.
String getMGFAlgorithm()
Returns the algorithm name of the mask generation function.
AlgorithmParameterSpec getMGFParameters()
Returns the algorithm parameter specification for the mask generation function algorithm.
PSource getPSource()
Returns the source of the label L.
[Expand]
Inherited Methods
From class java.lang.Object

Fields

public static final OAEPParameterSpec DEFAULT

Added in API level 1

The algorithm parameter instance with default values.

It uses the following parameters:

  • message digest : "SHA-1"
  • mask generation function (mgf) : "MGF1"
  • parameters for the mgf : "SHA-1" SHA1
  • the source of the label L: DEFAULT

Public Constructors

public OAEPParameterSpec (String mdName, String mgfName, AlgorithmParameterSpec mgfSpec, PSource pSrc)

Added in API level 1

Creates a new OAEPParameterSpec instance with the specified message digest algorithm name, mask generation function (mgf) algorithm name, parameters for the mgf algorithm and the source of the label L.

Parameters
mdName String: the message digest algorithm name.
mgfName String: the mask generation function algorithm name.
mgfSpec AlgorithmParameterSpec: the algorithm parameter specification for the mask generation function algorithm.
pSrc PSource: the source of the label L.
Throws
NullPointerException if one of mdName, mgfName or pSrc is null.

Public Methods

public String getDigestAlgorithm ()

Added in API level 1

Returns the algorithm name of the message digest.

Returns
String the algorithm name of the message digest.

public String getMGFAlgorithm ()

Added in API level 1

Returns the algorithm name of the mask generation function.

Returns
String the algorithm name of the mask generation function.

public AlgorithmParameterSpec getMGFParameters ()

Added in API level 1

Returns the algorithm parameter specification for the mask generation function algorithm.

Returns
AlgorithmParameterSpec the algorithm parameter specification for the mask generation function algorithm.

public PSource getPSource ()

Added in API level 1

Returns the source of the label L.

Returns
PSource the source of the label L.