JavaTM 2 Platform
Standard Ed. 6

javax.xml.crypto.dsig
接口 SignatureMethod

所有超级接口:
AlgorithmMethod, XMLStructure

public interface SignatureMethod
extends XMLStructure, AlgorithmMethod

W3C Recommendation for XML-Signature Syntax and Processing 中定义的 XML SignatureMethod 元素的表示形式。XML Schema Definition 的定义如下:

<element name="SignatureMethod" type="ds:SignatureMethodType"/>
<complexType name="SignatureMethodType" mixed="true">
<sequence>
<element name="HMACOutputLength" minOccurs="0" type="ds:HMACOutputLengthType"/>
<any namespace="##any" minOccurs="0" maxOccurs="unbounded"/>
<!-- (0,unbounded) elements from (1,1) namespace -->
</sequence>
<attribute name="Algorithm" type="anyURI" use="required"/>
</complexType>
 
调用 XMLSignatureFactory 类的 newSignatureMethod 方法可以创建 SignatureMethod 实例。

从以下版本开始:
1.6
另请参见:
XMLSignatureFactory.newSignatureMethod(String, SignatureMethodParameterSpec)

字段摘要
static String DSA_SHA1
          DSAwithSHA1 (DSS) 签名方法的算法 URI。
static String HMAC_SHA1
          HMAC-SHA1 MAC 签名方法的算法 URI。
static String RSA_SHA1
          RSAwithSHA1 (PKCS #1) 签名方法的算法 URI。
 
方法摘要
 AlgorithmParameterSpec getParameterSpec()
          返回此 SignatureMethod 的特定于算法的输入参数。
 
从接口 javax.xml.crypto.XMLStructure 继承的方法
isFeatureSupported
 
从接口 javax.xml.crypto.AlgorithmMethod 继承的方法
getAlgorithm
 

字段详细信息

DSA_SHA1

static final String DSA_SHA1
DSAwithSHA1 (DSS) 签名方法的算法 URI。

另请参见:
常量字段值

RSA_SHA1

static final String RSA_SHA1
RSAwithSHA1 (PKCS #1) 签名方法的算法 URI。

另请参见:
常量字段值

HMAC_SHA1

static final String HMAC_SHA1
HMAC-SHA1 MAC 签名方法的算法 URI。

另请参见:
常量字段值
方法详细信息

getParameterSpec

AlgorithmParameterSpec getParameterSpec()
返回此 SignatureMethod 的特定于算法的输入参数。

可将返回的参数强制转换为 SignatureMethodParameterSpec 对象。

指定者:
接口 AlgorithmMethod 中的 getParameterSpec
返回:
SignatureMethod 的特定于算法的输入参数(如果未指定,则返回 null

JavaTM 2 Platform
Standard Ed. 6

提交错误或意见

版权所有 2008 Sun Microsystems, Inc. 保留所有权利。请遵守GNU General Public License, version 2 only