[Mono-bugs] [Bug 68903][Nor] Changed - ASN.1 doesn't support undefined length encoding
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Sun, 14 Nov 2004 23:57:27 -0500 (EST)
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by sebastien@ximian.com.
http://bugzilla.ximian.com/show_bug.cgi?id=68903
--- shadow/68903 2004-10-29 11:42:28.000000000 -0400
+++ shadow/68903.tmp.6811 2004-11-14 23:57:27.000000000 -0500
@@ -41,6 +41,25 @@
recursive algorithm. This will need some refactoring...
So for the time being the class has been updated to throw an
NotSupportedException in the case it encounters (1d20 ;-) an undefined
length.
+
+------- Additional Comments From sebastien@ximian.com 2004-11-14 23:57 -------
+I couldn't easily fix this problem with the current class (at least
+not without breaking other things). The ASN1 class is great as a
+general purpose class (both encoding and decoding) on small objects
+(it's first objective was to decode, then encode, X.509 certificates).
+However we're already dealing with larger structures (e.g PKCS#7), and
+they gonna get larger with Fx 2.0 (System.Security.Cryptography.Pkcs).
+Adding more features to it seems a bad idea.
+
+I wrote a new class, specialized to decode ASN.1 (with much lower
+memory requirements). It does fix the underlying problem but this
+won't be visible until PKCS7 (which SPC is using is updated to use it
+- which also means that we need a new encoder - or use the old one...).
+
+I'll be doing more tests on the new implementation (as this wasn't the
+only known problem with the class) and probably starts to gradually
+migrate some code to the new decoder. The old ASN1 class will stays in
+Mono.Security to ensure compatibility with existing software.