summary refs log tree commit diff
path: root/crypto/src/asn1/crmf/ProofOfPossession.cs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src/asn1/crmf/ProofOfPossession.cs')
-rw-r--r--crypto/src/asn1/crmf/ProofOfPossession.cs9
1 files changed, 5 insertions, 4 deletions
diff --git a/crypto/src/asn1/crmf/ProofOfPossession.cs b/crypto/src/asn1/crmf/ProofOfPossession.cs
index d7d9fe7b1..0b0ce1c3a 100644
--- a/crypto/src/asn1/crmf/ProofOfPossession.cs
+++ b/crypto/src/asn1/crmf/ProofOfPossession.cs
@@ -28,10 +28,8 @@ namespace Org.BouncyCastle.Asn1.Crmf
             throw new ArgumentException("Invalid object: " + Platform.GetTypeName(obj), nameof(obj));
         }
 
-        public static ProofOfPossession GetInstance(Asn1TaggedObject taggedObject, bool declaredExplicit)
-        {
-            return Asn1Utilities.GetInstanceFromChoice(taggedObject, declaredExplicit, GetInstance);
-        }
+        public static ProofOfPossession GetInstance(Asn1TaggedObject taggedObject, bool declaredExplicit) =>
+            Asn1Utilities.GetInstanceChoice(taggedObject, declaredExplicit, GetInstance);
 
         public static ProofOfPossession GetOptional(Asn1Encodable element)
         {
@@ -51,6 +49,9 @@ namespace Org.BouncyCastle.Asn1.Crmf
             return null;
         }
 
+        public static ProofOfPossession GetTagged(Asn1TaggedObject taggedObject, bool declaredExplicit) =>
+            Asn1Utilities.GetTaggedChoice(taggedObject, declaredExplicit, GetInstance);
+
         private static Asn1Encodable GetOptionalBaseObject(Asn1TaggedObject taggedObject)
         {
             if (taggedObject.HasContextTag())