public class OAEPParameterSpec extends Object implements AlgorithmParameterSpec
RSAES-OAEP-params ::= SEQUENCE {
hashAlgorithm [0] OAEP-PSSDigestAlgorithms DEFAULT sha1,
maskGenAlgorithm [1] PKCS1MGFAlgorithms DEFAULT mgf1SHA1,
pSourceAlgorithm [2] PKCS1PSourceAlgorithms DEFAULT pSpecifiedEmpty
}
哪里
OAEP-PSSDigestAlgorithms ALGORITHM-IDENTIFIER ::= {
{ OID id-sha1 PARAMETERS NULL }|
{ OID id-sha256 PARAMETERS NULL }|
{ OID id-sha384 PARAMETERS NULL }|
{ OID id-sha512 PARAMETERS NULL },
... -- Allows for future expansion --
}
PKCS1MGFAlgorithms ALGORITHM-IDENTIFIER ::= {
{ OID id-mgf1 PARAMETERS OAEP-PSSDigestAlgorithms },
... -- Allows for future expansion --
}
PKCS1PSourceAlgorithms ALGORITHM-IDENTIFIER ::= {
{ OID id-pSpecified PARAMETERS OCTET STRING },
... -- Allows for future expansion --
}
注意:OAEPParameterSpec.DEFAULT使用以下消息:消息摘要 - “SHA-1”掩码生成函数(mgf) - mgf的“MGF1”参数 - MGF1ParameterSpec.SHA1编码输入源 - PSource.PSpecified.DEFAULT
MGF1ParameterSpec , PSource
| Modifier and Type | Field and Description |
|---|---|
static OAEPParameterSpec |
DEFAULT
OAEP参数设置为所有默认值。
|
| Constructor and Description |
|---|
OAEPParameterSpec(String mdName, String mgfName, AlgorithmParameterSpec mgfSpec, PSource pSrc)
使用指定的消息摘要算法
mdName ,掩码生成函数算法
mgfName ,掩码生成函数
mgfSpec和编码输入P
pSrc源构造用于PKCS#1标准中定义的OAEP填充的参数集。
|
| Modifier and Type | Method and Description |
|---|---|
String |
getDigestAlgorithm()
返回消息摘要算法名称。
|
String |
getMGFAlgorithm()
返回掩码生成函数算法名称。
|
AlgorithmParameterSpec |
getMGFParameters()
返回掩码生成函数的参数。
|
PSource |
getPSource()
返回编码输入P的来源。
|
public static final OAEPParameterSpec DEFAULT
public OAEPParameterSpec(String mdName, String mgfName, AlgorithmParameterSpec mgfSpec, PSource pSrc)
mdName ,掩码生成函数算法
mgfName ,掩码生成函数
mgfSpec和编码输入P
pSrc源构造用于PKCS#1标准中定义的OAEP填充的参数集。
mdName - 消息摘要的算法名称。
mgfName - 掩码生成函数的算法名称。
mgfSpec - 掩码生成功能的参数。
如果指定为null,则由getMGFParameters()返回null。
pSrc - 编码输入的源
NullPointerException如果-
mdName ,
mgfName ,或
pSrc为null。
public String getDigestAlgorithm()
public String getMGFAlgorithm()
public AlgorithmParameterSpec getMGFParameters()
public PSource getPSource()
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.