0
내가 로컬로 실행 때 ASP.NET 응용 프로그램다른 NT 그룹 반환 지역/서버
Private Function getUserGroups() As Boolean
' collect the user domain and identity
Dim arr As String() = System.Web.HttpContext.Current.Request.LogonUserIdentity.Name.Split("\"c)
Dim al As New ArrayList()
al = GetGroups()
For Each s As String In al
testt.InnerHtml += s & "<br />"
Next
Return auth
End Function
Public Function GetGroups() As ArrayList
Dim groups As New ArrayList()
For Each group As System.Security.Principal.IdentityReference In System.Web.HttpContext.Current.Request.LogonUserIdentity.Groups
groups.Add(group.Translate(GetType(System.Security.Principal.NTAccount)).ToString())
Next
Return groups
End Function
에 사용자 NT 그룹을 나열 두 가지 기능을 가지고 (개발 모드) I 때보다 내가 훨씬 긴 목록을 나는 원격 서버에서 실행 :
Local:
DOMAIN_EX\Domain Users
Everyone
BUILTIN\Administrators
BUILTIN\Users
NT AUTHORITY\INTERACTIVE
CONSOLE LOGON
NT AUTHORITY\Authenticated Users
NT AUTHORITY\This Organization
LOCAL
DOMAIN_EX\Eg12w
DOMAIN_EX\Eg12
DOMAIN_EX\SEC_PGP_CommunicationsGroup
DOMAIN_EX\More
Remote:
Everyone
BUILTIN\Users
CONSOLE LOGON
NT AUTHORITY\Authenticated Users
NT AUTHORITY\This Organization
LOCAL
사람이 차이를 설명 할 수와 나는 사용자 권한을 인증하기 위해 그룹의 배열을 사용하려고 해요으로 나는이 문제를 해결하는 방법에 대해 설명합니다.