Riddhi Valecha

Riddhi Valecha

  • 441
  • 3.3k
  • 413.1k

Single Sign On

Feb 3 2015 2:11 AM
Hi all....
I need help in Single Sign On...

There is a file - applicationhost.config in C:\..\IISExpress  Folder.

Observations -
1.
If Authentication Settings are

<annonumusAuthentication enabled ="true">
<Windows Authentication enables = "false">

Then, in aspx.cs page -
HttpContext.Current.User.Identity.Name.ToString(); -> blank
System.Security.Principal.WindowsIdentity.GetCurrent().Name.ToString(); -> Current loggedIn User
--------------
2.
If Authentication Settings are

<annonumusAuthentication enabled ="false">
<Windows Authentication enables = "true">

Then, in aspx.cs page -
HttpContext.Current.User.Identity.Name.ToString(); -> Current loggedIn User
System.Security.Principal.WindowsIdentity.GetCurrent().Name.ToString(); -> Current loggedIn User
---------
My Requirement-
I have 2 applications that are NOT SINGLE SIGN ON.
I have 5 applications that need SSO Functionality.
------
Can this be done without modifying the applicationhost.config file ??
-------
Reasons -
In IIS Server,
string s1 = System.Environment.UserName;
string s2 = HttpContext.Current.User.Identity.Name.ToString();
string s3 = System.Security.Principal.WindowsIdentity.GetCurrent().Name.ToString();
---
are not working.
SSO works fine on localhost, not on server.

PLease help...