summary refs log tree commit diff
path: root/crypto/src/asn1/Asn1InputStream.cs
diff options
context:
space:
mode:
authorPeter Dettman <peter.dettman@bouncycastle.org>2021-10-15 16:10:37 +0700
committerPeter Dettman <peter.dettman@bouncycastle.org>2021-10-15 16:10:37 +0700
commit2e690b9bb3da422608a86f70fc9090923b398694 (patch)
tree6f2a7da682fce10b58d8615e86ba5d2ef4d882fe /crypto/src/asn1/Asn1InputStream.cs
parentReplace Obsolete tag (diff)
downloadBouncyCastle.NET-ed25519-2e690b9bb3da422608a86f70fc9090923b398694.tar.xz
Refactor ASN.1 parsers
Diffstat (limited to 'crypto/src/asn1/Asn1InputStream.cs')
-rw-r--r--crypto/src/asn1/Asn1InputStream.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/crypto/src/asn1/Asn1InputStream.cs b/crypto/src/asn1/Asn1InputStream.cs
index 8ce55a2b7..76bc3076d 100644
--- a/crypto/src/asn1/Asn1InputStream.cs
+++ b/crypto/src/asn1/Asn1InputStream.cs
@@ -215,13 +215,13 @@ namespace Org.BouncyCastle.Asn1
             switch (tagNo)
             {
             case Asn1Tags.OctetString:
-                return new BerOctetStringParser(sp).ToAsn1Object();
+                return BerOctetStringParser.Parse(sp);
             case Asn1Tags.Sequence:
-                return new BerSequenceParser(sp).ToAsn1Object();
+                return BerSequenceParser.Parse(sp);
             case Asn1Tags.Set:
-                return new BerSetParser(sp).ToAsn1Object();
+                return BerSetParser.Parse(sp);
             case Asn1Tags.External:
-                return new DerExternalParser(sp).ToAsn1Object();
+                return DerExternalParser.Parse(sp);
             default:
                 throw new IOException("unknown BER object encountered");
             }