语言

KeyStoreManager.GetGrantedKeyPairFromId(Int64) 方法

定义

返回一个 KeyPair 包含与之前与所提供的 id应用共享的密钥关联的公钥和私钥。

[Android.Runtime.Register("getGrantedKeyPairFromId", "(J)Ljava/security/KeyPair;", "", ApiSince=36)]
public Java.Security.KeyPair GetGrantedKeyPairFromId(long id);
[<Android.Runtime.Register("getGrantedKeyPairFromId", "(J)Ljava/security/KeyPair;", "", ApiSince=36)>]
member this.GetGrantedKeyPairFromId : int64 -> Java.Security.KeyPair

参数

id
Int64

与应用共享的私钥的 ID

返回

包含与应用共享的公钥和私钥的 KeyPair

特性

注解

返回一个 KeyPair 包含与之前与所提供的 id应用共享的密钥关联的公钥和私钥。

如果尚未向具有指定id对象的调用方授予 ajava.security.PrivateKey,则会引发一个UnrecoverableKeyException。

Java文档android.security.keystore.KeyStoreManager.getGrantedKeyPairFromId(long)。

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于