summary refs log tree commit diff
path: root/crypto/src/asn1/DerInteger.cs
diff options
context:
space:
mode:
authorPeter Dettman <peter.dettman@bouncycastle.org>2024-06-21 17:21:34 +0700
committerPeter Dettman <peter.dettman@bouncycastle.org>2024-06-21 17:21:34 +0700
commita3f7b8ba1349d1e518661aa2723e64f595dfb3df (patch)
tree4136daa6b201fb432b0028168039279600ce8ea7 /crypto/src/asn1/DerInteger.cs
parentRefactoring in Asn1.Misc (diff)
downloadBouncyCastle.NET-ed25519-a3f7b8ba1349d1e518661aa2723e64f595dfb3df.tar.xz
ASN.1: GetTagged method for all universal types
Diffstat (limited to 'crypto/src/asn1/DerInteger.cs')
-rw-r--r--crypto/src/asn1/DerInteger.cs7
1 files changed, 6 insertions, 1 deletions
diff --git a/crypto/src/asn1/DerInteger.cs b/crypto/src/asn1/DerInteger.cs
index 666723527..c46aa99df 100644
--- a/crypto/src/asn1/DerInteger.cs
+++ b/crypto/src/asn1/DerInteger.cs
@@ -104,7 +104,12 @@ namespace Org.BouncyCastle.Asn1
             return null;
         }
 
-		public DerInteger(int value)
+        public static DerInteger GetTagged(Asn1TaggedObject taggedObject, bool declaredExplicit)
+        {
+            return (DerInteger)Meta.Instance.GetTagged(taggedObject, declaredExplicit);
+        }
+
+        public DerInteger(int value)
         {
             this.bytes = BigInteger.ValueOf(value).ToByteArray();
             this.start = 0;