KeyUtil.smali
.class public Lorg/spongycastle/jcajce/provider/asymmetric/util/KeyUtil;
.super Ljava/lang/Object;
.source "KeyUtil.java"
# direct methods
.method public constructor <init>()V
.registers 1
.prologue
.line 9
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
.method public static getEncodedPrivateKeyInfo(Lorg/spongycastle/asn1/pkcs/PrivateKeyInfo;)[B
.registers 2
.prologue
.line 65
:try_start_0
const-string v0, "DER"
invoke-virtual {p0, v0}, Lorg/spongycastle/asn1/pkcs/PrivateKeyInfo;->getEncoded(Ljava/lang/String;)[B
:try_end_5
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_5} :catch_7
move-result-object v0
.line 69
:goto_6
return-object v0
:catch_7
move-exception v0
const/4 v0, 0x0
goto :goto_6
.end method
.method public static getEncodedPrivateKeyInfo(Lorg/spongycastle/asn1/x509/AlgorithmIdentifier;Lorg/spongycastle/asn1/ASN1Encodable;)[B
.registers 4
.prologue
.line 51
:try_start_0
new-instance v0, Lorg/spongycastle/asn1/pkcs/PrivateKeyInfo;
invoke-interface {p1}, Lorg/spongycastle/asn1/ASN1Encodable;->toASN1Primitive()Lorg/spongycastle/asn1/ASN1Primitive;
move-result-object v1
invoke-direct {v0, p0, v1}, Lorg/spongycastle/asn1/pkcs/PrivateKeyInfo;-><init>(Lorg/spongycastle/asn1/x509/AlgorithmIdentifier;Lorg/spongycastle/asn1/ASN1Encodable;)V
.line 53
invoke-static {v0}, Lorg/spongycastle/jcajce/provider/asymmetric/util/KeyUtil;->getEncodedPrivateKeyInfo(Lorg/spongycastle/asn1/pkcs/PrivateKeyInfo;)[B
:try_end_c
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_c} :catch_e
move-result-object v0
.line 57
:goto_d
return-object v0
:catch_e
move-exception v0
const/4 v0, 0x0
goto :goto_d
.end method
.method public static getEncodedSubjectPublicKeyInfo(Lorg/spongycastle/asn1/x509/AlgorithmIdentifier;Lorg/spongycastle/asn1/ASN1Encodable;)[B
.registers 3
.prologue
.line 15
:try_start_0
new-instance v0, Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;
invoke-direct {v0, p0, p1}, Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;-><init>(Lorg/spongycastle/asn1/x509/AlgorithmIdentifier;Lorg/spongycastle/asn1/ASN1Encodable;)V
invoke-static {v0}, Lorg/spongycastle/jcajce/provider/asymmetric/util/KeyUtil;->getEncodedSubjectPublicKeyInfo(Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;)[B
:try_end_8
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_8} :catch_a
move-result-object v0
.line 19
:goto_9
return-object v0
:catch_a
move-exception v0
const/4 v0, 0x0
goto :goto_9
.end method
.method public static getEncodedSubjectPublicKeyInfo(Lorg/spongycastle/asn1/x509/AlgorithmIdentifier;[B)[B
.registers 3
.prologue
.line 27
:try_start_0
new-instance v0, Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;
invoke-direct {v0, p0, p1}, Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;-><init>(Lorg/spongycastle/asn1/x509/AlgorithmIdentifier;[B)V
invoke-static {v0}, Lorg/spongycastle/jcajce/provider/asymmetric/util/KeyUtil;->getEncodedSubjectPublicKeyInfo(Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;)[B
:try_end_8
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_8} :catch_a
move-result-object v0
.line 31
:goto_9
return-object v0
:catch_a
move-exception v0
const/4 v0, 0x0
goto :goto_9
.end method
.method public static getEncodedSubjectPublicKeyInfo(Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;)[B
.registers 2
.prologue
.line 39
:try_start_0
const-string v0, "DER"
invoke-virtual {p0, v0}, Lorg/spongycastle/asn1/x509/SubjectPublicKeyInfo;->getEncoded(Ljava/lang/String;)[B
:try_end_5
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_5} :catch_7
move-result-object v0
.line 43
:goto_6
return-object v0
:catch_7
move-exception v0
const/4 v0, 0x0
goto :goto_6
.end method