IKey.signAsync(final byte[] digest, final String algorithm) 方法
定义
Signs the specified digest using the specified algorithm, or the keys DefaultSignatureAlgorithm if no algorithm is specified.
public ListenableFuture<Pair<byte[], String>> signAsync(final byte[] digest, final String algorithm)
参数
- digest
- final byte []
The digest to sign
- algorithm
- final String
The signature algorithm to use
返回
ListenableFuture<Pair<byte[], String>>
A ListenableFuture containing the signature and the algorithm used.
例外
NoSuchAlgorithmException
the algorithm is not valid