[Mono-bugs] [Bug 52532][Cri] New - Cannot find type `WindowsPrincipal'
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Wed, 24 Dec 2003 01:32:31 -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 xiaoming.lin@longshine.com.
http://bugzilla.ximian.com/show_bug.cgi?id=52532
--- shadow/52532 2003-12-24 01:32:31.000000000 -0500
+++ shadow/52532.tmp.14008 2003-12-24 01:32:31.000000000 -0500
@@ -0,0 +1,69 @@
+Bug#: 52532
+Product: Mono/Class Libraries
+Version: unspecified
+OS: Red Hat 9.0
+OS Details:
+Status: NEW
+Resolution:
+Severity: 040 One week
+Priority: Critical
+Component: System
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: xiaoming.lin@longshine.com
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: Cannot find type `WindowsPrincipal'
+
+Steps to reproduce the problem:
+1. I have a file can't be compiled
+using System;
+using System.Data;
+using System.Collections;
+using System.Collections.Specialized;
+using System.DirectoryServices;
+using System.Security;
+using System.Security.Principal;
+
+namespace Longshine.Indigo.Runtime.Security {
+
+ public sealed class SecurityToolkit {
+ private SecurityToolkit() {}
+
+ public static StringCollection GetUserProvinces(WindowsPrincipal
+user) {
+ if (user == null)
+ throw new ArgumentException("a", "user");
+
+ if (!user.Identity.IsAuthenticated)
+ throw new SecurityException("a");
+
+ using (DirectoryEntry userEntry = GetWindowsIdentityLdapEntry
+((WindowsIdentity)user.Identity)) {
+ return GetUserProvinces(userEntry);
+ }
+ }
+ }
+}
+2. mcs SecurityToolkit.cs -r:/usr/local/lib/System.dll -
+r:/usr/local/lib/System.Data.dll -
+r:/usr/local/lib/System.DirectoryServices.dll
+
+3.
+Actual Results:
+
+SecurityToolkit.cs(126) error CS0246: Cannot find type `WindowsPrincipal'
+Compilation failed: 1 error(s), 0 warnings
+
+Expected Results:
+Compilation succeeded
+
+How often does this happen?
+always
+
+Additional Information:
+it can be compiled in windows2003+framework1.1.
+we have develped a big project in windows2000+framework1.0,now we want it
+can run with linux+mono.
+thanks a lot