Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > The trust relationship between this workstation and the primary domain failed

Reply
Thread Tools

The trust relationship between this workstation and the primary domain failed

 
 
Namshub
Guest
Posts: n/a
 
      06-28-2006
Hi, I'm using Visual Studio 2005 and I'm currently working at home, this
line of code works perfectly well online
If Not (HttpContext.Current.User.IsInRole(SecurityGroup)) Then

But when run disconnected from the network I get the error below. Is this
correct? Is there a different line to determine if i'm in a group which uses
cached credentials????

Regards

Ric


System.SystemException was unhandled by user code
Message="The trust relationship between this workstation and the primary
domain failed.
"
Source="mscorlib"
StackTrace:
at
System.Security.Principal.NTAccount.TranslateToSid s(IdentityReferenceCollection
sourceAccounts, Boolean& someFailed)
at
System.Security.Principal.NTAccount.Translate(Iden tityReferenceCollection
sourceAccounts, Type targetType, Boolean& someFailed)
at
System.Security.Principal.NTAccount.Translate(Iden tityReferenceCollection
sourceAccounts, Type targetType, Boolean forceSuccess)
at System.Security.Principal.WindowsPrincipal.IsInRol e(String role)
at DieteticViewer.Global.Application_AuthenticateRequ est(Object
sender, EventArgs e) in
c:\inetpub\wwwroot\DieteticViewer\App_Code\Global. asax.vb:line 55
at
System.Web.HttpApplication.SyncEventExecutionStep. System.Web.HttpApplication.IExecutionStep.Execute( )
at System.Web.HttpApplication.ExecuteStep(IExecutionS tep step,
Boolean& completedSynchronously)


 
Reply With Quote
 
 
 
 
Joe Kaplan \(MVP - ADSI\)
Guest
Posts: n/a
 
      06-28-2006
This is probably because the LSA doesn't have the group name cached, so when
it goes to look it up, it has to ask the domain controller and can't since
you aren't online. I don't think you have much of an option if you are
using Windows authentication though.

You might consider switching to forms authentication for testing purposes
and then use Windows auth for staging and production. I do that frequently.
You can make forms auth do whatever you want, so it is pretty flexible.

Joe K.

--
Joe Kaplan-MS MVP Directory Services Programming
Co-author of "The .NET Developer's Guide to Directory Services Programming"
http://www.directoryprogramming.net
--
"Namshub" <> wrote in message
news:...
> Hi, I'm using Visual Studio 2005 and I'm currently working at home, this
> line of code works perfectly well online
> If Not (HttpContext.Current.User.IsInRole(SecurityGroup)) Then
>
> But when run disconnected from the network I get the error below. Is this
> correct? Is there a different line to determine if i'm in a group which
> uses cached credentials????
>
> Regards
>
> Ric
>
>
> System.SystemException was unhandled by user code
> Message="The trust relationship between this workstation and the primary
> domain failed.
> "
> Source="mscorlib"
> StackTrace:
> at
> System.Security.Principal.NTAccount.TranslateToSid s(IdentityReferenceCollection
> sourceAccounts, Boolean& someFailed)
> at
> System.Security.Principal.NTAccount.Translate(Iden tityReferenceCollection
> sourceAccounts, Type targetType, Boolean& someFailed)
> at
> System.Security.Principal.NTAccount.Translate(Iden tityReferenceCollection
> sourceAccounts, Type targetType, Boolean forceSuccess)
> at System.Security.Principal.WindowsPrincipal.IsInRol e(String role)
> at DieteticViewer.Global.Application_AuthenticateRequ est(Object
> sender, EventArgs e) in
> c:\inetpub\wwwroot\DieteticViewer\App_Code\Global. asax.vb:line 55
> at
> System.Web.HttpApplication.SyncEventExecutionStep. System.Web.HttpApplication.IExecutionStep.Execute( )
> at System.Web.HttpApplication.ExecuteStep(IExecutionS tep step,
> Boolean& completedSynchronously)
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
The trust relationship between this workstation and the primary do MrGrundh ASP .Net Security 0 08-27-2009 09:08 AM
"The trust relationship between this workstation and the primary domain failed" displayed on the web page Steve M ASP .Net 3 05-27-2009 10:01 AM
using AD security for authentication. The trust relationship betweenthe primary domain and the trusted domain failed. wildman@noclient.net ASP .Net 1 02-29-2008 04:01 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57