[Mono-bugs] [Bug 79375][Min] New - X509Certificate2.PublicKey.Key returns non-PublicOnly key

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Mon Sep 11 23:07:55 EDT 2006


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 atsushi at ximian.com.

http://bugzilla.ximian.com/show_bug.cgi?id=79375

--- shadow/79375	2006-09-11 23:07:55.000000000 -0400
+++ shadow/79375.tmp.11660	2006-09-11 23:07:55.000000000 -0400
@@ -0,0 +1,44 @@
+Bug#: 79375
+Product: Mono: Class Libraries
+Version: 1.1
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Minor
+Component: System
+AssignedTo: sebastien at ximian.com                            
+ReportedBy: atsushi at ximian.com               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: X509Certificate2.PublicKey.Key returns non-PublicOnly key
+
+Just a reminder for Sebastien ;-)
+
+using System;
+using System.Security.Cryptography;
+using System.Security.Cryptography.X509Certificates;
+
+public class Test
+{
+        public static void Main ()
+        {
+                X509Certificate2 cert = new X509Certificate2 ("test2.pfx",
+"mono");
+                Console.WriteLine (((RSACryptoServiceProvider)
+cert.PublicKey.Key).PublicOnly);
+        }
+}
+
+Actual Results:
+False
+
+Expected Results:
+True
+
+Additional Information:
+any certificate that contains a private key could be used here, such as the
+one from #79320.


More information about the mono-bugs mailing list