summary refs log tree commit diff
path: root/crypto/src/asn1/DERExternalParser.cs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src/asn1/DERExternalParser.cs')
-rw-r--r--crypto/src/asn1/DERExternalParser.cs11
1 files changed, 8 insertions, 3 deletions
diff --git a/crypto/src/asn1/DERExternalParser.cs b/crypto/src/asn1/DERExternalParser.cs
index 70e426fed..5e52e63c6 100644
--- a/crypto/src/asn1/DERExternalParser.cs
+++ b/crypto/src/asn1/DERExternalParser.cs
@@ -1,5 +1,4 @@
 using System;
-using System.IO;
 
 namespace Org.BouncyCastle.Asn1
 {
@@ -8,6 +7,7 @@ namespace Org.BouncyCastle.Asn1
 	{
 		private readonly Asn1StreamParser _parser;
 
+        [Obsolete("Will be removed")]
 		public DerExternalParser(Asn1StreamParser parser)
 		{
 			this._parser = parser;
@@ -20,7 +20,12 @@ namespace Org.BouncyCastle.Asn1
 
 		public override Asn1Object ToAsn1Object()
 		{
-			return new DerExternal(_parser.ReadVector());
+            return Parse(_parser);
 		}
-	}
+
+        internal static DerExternal Parse(Asn1StreamParser sp)
+        {
+            return new DerExternal(sp.ReadVector());
+        }
+    }
 }