![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | NegotiateStream delegation problem Hello, I have following code from client: (it is just a test app) using ( System.Security.Principal.WindowsImpersonationContext wic = System.Security.Principal.WindowsIdentity.GetCurrent().Impersonate()) { System.Net.ICredentials creds = System.Net.CredentialCache.DefaultCredentials; // need a full duplex stream - loopback is easiest way to get that using (NegotiateStream clientSide = new NegotiateStream(new TcpClient(server, port).GetStream())) { clientSide.AuthenticateAsClient (System.Net.CredentialCache.DefaultNetworkCredentials, "", ProtectionLevel.EncryptAndSign, TokenImpersonationLevel.Delegation); } } Server side has SPN set and active directory attributes set and has the same settings as client (encryptandsign and require delegation), but when I run it, I got this error: The client side: A remote side security requirement was not fulfilled during authentication. Try increasing the ProtectionLevel and/or ImpersonationLevel. The server side error is: A security requirement was not fulfilled during authentication. Required: Delegation, negotiated: Impersonation. If I change the ImpersonationLevel to impersonate, no error will be thrown out. I suspect it is because I use System.Security.Principal.WindowsIdentity.GetCurrent().Impersonate(), instead of using username and password to do a logon. But I really want to just use windowsIdentity to achieve delegation, as delegation will be definitely required. Is it possible and can someone give me some help? Many Thanks Jerry |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| NegotiateStream.AuthenticateAsClient problem? | .NET General | |||
| Re: CredSSP and kerberos credentials delegation | Vista security | |||
| RDP/TS Single-sign-on with credentails delegation | Vista security | |||
| SQL + IIS Delegation woes | .NET General | |||
| View delegation permissions of OU | PowerShell | |||