473,395 Members | 1,454 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Forms Auth cross multiple sub domains

Hi,
I have several company sites (a1.company.com, a2.company.com,
a3.company.com, etc). Each site used a custom Forms Auth (all use the same
code). I have been ask if there could be just one login screen and then have
a menu of the different systems.
So, the users would go to webapps.company.com to login and then click on
links that would take them to a1.company.com or a4.company.com with out
having to login again.
Can this be done?
Nov 17 '05 #1
2 1871
Sure, that can be done. The first thing that comes to my
mind would be to use cookies to store the information on
the users browser. Each sub domains checks this cookie if
this particular user has been authenticated, if so, then
accept the user, if not, redirect that user to the login
page. There might be better ways than what i suggest so
let this be just another option.

Hope this helps.

-----Original Message-----
Hi,
I have several company sites (a1.company.com, a2.company.com,a3.company.com, etc). Each site used a custom Forms Auth (all use the samecode). I have been ask if there could be just one login screen and then havea menu of the different systems.
So, the users would go to webapps.company.com to login and then click onlinks that would take them to a1.company.com or a4.company.com with outhaving to login again.
Can this be done?
.

Nov 17 '05 #2
The best way to do this is to modify the machineKey in the machine.config
file.

By default, the machineKey node is setup as:

<machineKey validationKey="AutoGenerate,IsolateApps"
decryptionKey="AutoGenerate,IsolateApps" validation="SHA1"/>

If you eliminate the ,IsolateApps (remove the comma too) in the
validationKey and the decryptionKey, one login can be used for all websites
that are on the same machine.

This works as these values are the keys used to encrypt and decrypt the data
stored in the logon cookie. By making this change, all sites on the machine
use the same keys (and thus, can share the cookies).

One other thing; if you are using a web farm, you have to specify the
validationKey and decryptionKey values. Otherwise, the cookies can't be
shared across servers.

The following MSDN article tells how to generate key values for a web farm:
http://support.microsoft.com/default...oduct=NETFrame

Jeff

"Edward" <an*******@discussions.microsoft.com> wrote in message
news:13****************************@phx.gbl...
Sure, that can be done. The first thing that comes to my
mind would be to use cookies to store the information on
the users browser. Each sub domains checks this cookie if
this particular user has been authenticated, if so, then
accept the user, if not, redirect that user to the login
page. There might be better ways than what i suggest so
let this be just another option.

Hope this helps.

-----Original Message-----
Hi,
I have several company sites (a1.company.com,

a2.company.com,
a3.company.com, etc). Each site used a custom Forms Auth

(all use the same
code). I have been ask if there could be just one login

screen and then have
a menu of the different systems.
So, the users would go to webapps.company.com to login

and then click on
links that would take them to a1.company.com or

a4.company.com with out
having to login again.
Can this be done?
.

Nov 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Angus SC2 | last post by:
Hi I am trying to set up cross domain cookies on a server I have running that currently has 2 domains running on it (on different IPs). Basically I have a forums site (using UBB threads) and I...
4
by: 23s | last post by:
I had this problem in the past, after a server reformat it went away, and now after another server reformat it's back again - no clue what's doing it. Here's the flow: Website root is public, no...
1
by: AVance | last post by:
Hi, I've come across this scenario in ASP.NET 1.1 with forms authentication where the forms auth doesn't seem to timeout correctly, nor redirect to the login page. I have done some testing, and...
6
by: Ludvig | last post by:
I have various domains using the same application/assembly They differ in contents and design, based on a "site id", and get its information from an SQL server. Now I have to deploy the...
3
by: Serdar Kalayci | last post by:
Hi there, I have a website which utilizes forms authentication under domain name like www.mydomain.com... On some pages I have to redirect https://secure.mydomain.com for ssl issues. The secure...
2
by: code | last post by:
Hi, I have stumbled across an interesting problem regarding forms authentication over multiple sub domains. The topic has been covered in various forms online but never really gets a definitive...
1
by: @sh | last post by:
Guys, Anyone know of a way to allow a cookie to be read by multiple domains, or even better a specific IIS server IP? We're looking to track users across multiple domains within our website...
4
by: =?Utf-8?B?RmFyaWJh?= | last post by:
It know that we can use the following method http://msdn2.microsoft.com/en-us/library/eb0zx8fc.aspx to form authenticate across multiple applications. I have created an asp.net application...
5
by: Spam Catcher | last post by:
Hello Everyone, I need to implement single sign on across serveral applications. Some applications are under my control while others are under the control of 3rd parties. Can anyone suggest a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.