Both servers are in same domain. When redirection should occur (on default.aspx page load) site asks me to enter my credentials, I tried to use my domain user and password and then got:
HTTP Error 401.1 - Unauthorized: Access is denied due to invalid credentials.
Internet Information Services (IIS)
How to pass my credentials to redirected server and how to solve this?
if you need to share the same authentication cookie across separate
web servers, you need to specify the decryptionKey and validationKey manually. You
cannot allow ASP.NET Framework to generate these keys automatically because you need
to share the keys across the different web servers.
You can add a machineKey element with explicit keys to either the machine root web
configuration file or to particular application web configuration files. If you don’t want to
share the same keys across all the applications on a web server, you should add the
machineKey element only to the applications that you need to share
----------------------------------------------------------------------------------------------------
Thanks for your reply, since I never done something similar can you please provide me with some aditional info?
Where do I have to configure machinekey on source server or on destination server, or on both, also how can I manualy generate decryption and validation keys?
Actually I still have same issue this solution with machinekey is working only if I use Forms authentication and not with Windows authentication where it still ask me for username and pass but with any domain user I can not access site. Please help I need
to solve this asap. I also tried with IIS on my compuer and to redirect iis on my computer to server but still same, authentication is configured same way on both servers and on my pc.
dfrimmel
Member
70 Points
73 Posts
redirecting servers via host file on client pc
Nov 05, 2012 09:49 AM|LINK
Hi,
I want to redirect one server to another on client computer. In host file I inserted line
server.ip.address(where it should redirect) server name(from which to redirect)
On both servers I have windows authentication turned on, and in config files:
Both servers are in same domain. When redirection should occur (on default.aspx page load) site asks me to enter my credentials, I tried to use my domain user and password and then got:
How to pass my credentials to redirected server and how to solve this?
Thanks for help. Have a nice day people.
UPDATE: Both servers use Windows 2003 SP2 / IIS6
dfrimmel
Member
70 Points
73 Posts
Re: redirecting servers via host file on client pc
Nov 06, 2012 06:17 AM|LINK
Anyone with any idea?
Alsaady
Participant
1792 Points
370 Posts
Re: redirecting servers via host file on client pc
Nov 06, 2012 09:20 AM|LINK
Hi..
if you need to share the same authentication cookie across separate
web servers, you need to specify the decryptionKey and validationKey manually. You
cannot allow ASP.NET Framework to generate these keys automatically because you need
to share the keys across the different web servers.
as :
You can add a machineKey element with explicit keys to either the machine root web
configuration file or to particular application web configuration files. If you don’t want to
share the same keys across all the applications on a web server, you should add the
machineKey element only to the applications that you need to share
----------------------------------------------------------------------------------------------------
(Stephen Wather)
www.rtoosh.net
dfrimmel
Member
70 Points
73 Posts
Re: redirecting servers via host file on client pc
Nov 06, 2012 09:59 AM|LINK
Thanks for your reply, since I never done something similar can you please provide me with some aditional info?
Where do I have to configure machinekey on source server or on destination server, or on both, also how can I manualy generate decryption and validation keys?
Alsaady
Participant
1792 Points
370 Posts
Re: redirecting servers via host file on client pc
Nov 06, 2012 02:58 PM|LINK
Please Check this
http://msdn.microsoft.com/en-us/library/eb0zx8fc.aspx
http://www.codeproject.com/Articles/106439/Single-Sign-On-SSO-for-cross-domain-ASP-NET-applic
www.rtoosh.net
dfrimmel
Member
70 Points
73 Posts
Re: redirecting servers via host file on client pc
Nov 07, 2012 01:32 PM|LINK
I get it now, manage to pass authentication value to redirected server and it works perfect. Thanks m8.
dfrimmel
Member
70 Points
73 Posts
Re: redirecting servers via host file on client pc
Nov 12, 2012 09:45 AM|LINK
Actually I still have same issue this solution with machinekey is working only if I use Forms authentication and not with Windows authentication where it still ask me for username and pass but with any domain user I can not access site. Please help I need to solve this asap. I also tried with IIS on my compuer and to redirect iis on my computer to server but still same, authentication is configured same way on both servers and on my pc.