473,396 Members | 2,039 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,396 software developers and data experts.

2 sites in IIS using formsauthetication - logout problems

I have 2 sites in IIS. One as a subfolder of the webroot. One a virtual
directory. They have seperate web.config enabled formsauthetication.

The login screen validates the credentials and redirects:
FormsAuthentication.RedirectFromLoginPage(txtUserN ame, true);

I want to be able to persist both authentication cookies, but everytime I
log in to one site, I seem to lose authentication in the other, and when I
return to it, I am forced to log in again.

Am i doing something wrong here?

Thanks
Nov 19 '05 #1
4 1212
Let me ask you a question.

Log on to any one of your two sites, and then go from that page to
Microsoft.com, then try to return to the site you logged onto, what happens
?

--
Best Regards

The Inimitable Mr Newbie º¿º


"Sarah" <Sa*********@nospam.hotmail.com> wrote in message
news:eM**************@TK2MSFTNGP09.phx.gbl...
I have 2 sites in IIS. One as a subfolder of the webroot. One a virtual
directory. They have seperate web.config enabled formsauthetication.

The login screen validates the credentials and redirects:
FormsAuthentication.RedirectFromLoginPage(txtUserN ame, true);

I want to be able to persist both authentication cookies, but everytime I
log in to one site, I seem to lose authentication in the other, and when I
return to it, I am forced to log in again.

Am i doing something wrong here?

Thanks

Nov 19 '05 #2
I go straight in, without having to log in. I am persisting the cookie.
"Mr Newbie" <he**@now.com> wrote in message
news:%2******************@TK2MSFTNGP12.phx.gbl...
Let me ask you a question.

Log on to any one of your two sites, and then go from that page to
Microsoft.com, then try to return to the site you logged onto, what
happens ?

--
Best Regards

The Inimitable Mr Newbie º¿º


"Sarah" <Sa*********@nospam.hotmail.com> wrote in message
news:eM**************@TK2MSFTNGP09.phx.gbl...
I have 2 sites in IIS. One as a subfolder of the webroot. One a virtual
directory. They have seperate web.config enabled formsauthetication.

The login screen validates the credentials and redirects:
FormsAuthentication.RedirectFromLoginPage(txtUserN ame, true);

I want to be able to persist both authentication cookies, but everytime I
log in to one site, I seem to lose authentication in the other, and when
I return to it, I am forced to log in again.

Am i doing something wrong here?

Thanks


Nov 19 '05 #3
Any ideas anyone?

It cannot be just me who has encountered this. Any pointers would be greatly
appreciated.

Thanks
"Sarah" <Sa*********@nospam.hotmail.com> wrote in message
news:eq*************@TK2MSFTNGP15.phx.gbl...
I go straight in, without having to log in. I am persisting the cookie.
"Mr Newbie" <he**@now.com> wrote in message
news:%2******************@TK2MSFTNGP12.phx.gbl...
Let me ask you a question.

Log on to any one of your two sites, and then go from that page to
Microsoft.com, then try to return to the site you logged onto, what
happens ?

--
Best Regards

The Inimitable Mr Newbie º¿º


"Sarah" <Sa*********@nospam.hotmail.com> wrote in message
news:eM**************@TK2MSFTNGP09.phx.gbl...
I have 2 sites in IIS. One as a subfolder of the webroot. One a virtual
directory. They have seperate web.config enabled formsauthetication.

The login screen validates the credentials and redirects:
FormsAuthentication.RedirectFromLoginPage(txtUserN ame, true);

I want to be able to persist both authentication cookies, but everytime
I log in to one site, I seem to lose authentication in the other, and
when I return to it, I am forced to log in again.

Am i doing something wrong here?

Thanks



Nov 19 '05 #4
Im not sure what the answer is really. But when I think about it, if you are
moving from one Authenticated session to another within the same browser
window, it will drop the cookie, it has to because you are disconnecting the
session to the first in facour of the second.

What Im not sure about is the relationship between the subfolder and its
root.

When you create a subfolder with its own web.config and change the
Authentication/Auhtorisation settings are you not simply creating a site
which just happens to be nested in the root of the parent site in which case
the experience you are having sounds as if it could be correct ? Have you
tried removing the Authentication section from the sub web.config ?

In essence, I thought that the seperate use of web.config in sub folders was
for the sole use of sub folder directory/resource persmissions, so that one
could further restrict the authorisation. It sounds like whatever setting
you have are forcing re-authentication.

Having said that, I am speculating here but trying to have a logical stab it
what may be the cause.

HTH

--
Best Regards

The Inimitable Mr Newbie º¿º
"Sarah" <Sa*********@nospam.hotmail.com> wrote in message
news:OU**************@TK2MSFTNGP12.phx.gbl...
Any ideas anyone?

It cannot be just me who has encountered this. Any pointers would be
greatly appreciated.

Thanks
"Sarah" <Sa*********@nospam.hotmail.com> wrote in message
news:eq*************@TK2MSFTNGP15.phx.gbl...
I go straight in, without having to log in. I am persisting the cookie.
"Mr Newbie" <he**@now.com> wrote in message
news:%2******************@TK2MSFTNGP12.phx.gbl...
Let me ask you a question.

Log on to any one of your two sites, and then go from that page to
Microsoft.com, then try to return to the site you logged onto, what
happens ?

--
Best Regards

The Inimitable Mr Newbie º¿º


"Sarah" <Sa*********@nospam.hotmail.com> wrote in message
news:eM**************@TK2MSFTNGP09.phx.gbl...
I have 2 sites in IIS. One as a subfolder of the webroot. One a virtual
directory. They have seperate web.config enabled formsauthetication.

The login screen validates the credentials and redirects:
FormsAuthentication.RedirectFromLoginPage(txtUserN ame, true);

I want to be able to persist both authentication cookies, but everytime
I log in to one site, I seem to lose authentication in the other, and
when I return to it, I am forced to log in again.

Am i doing something wrong here?

Thanks



Nov 19 '05 #5

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

Similar topics

3
by: Phil Powell | last post by:
class LoginSessionGenerator extends MethodGenerator { function LoginSessionGenerator() {} /** * Logout * * @access public */ function &logout() { // STATIC VOID METHOD
5
by: Hung Huynh | last post by:
Hello, I have 2 separate web sites on 2 different boxes www.xyz.com on box 1 www2.xyz.com on box 2 Users log into box 1 via regular ASP/Database authentication, and I keep a session...
8
by: Harlin Seritt | last post by:
I have a remote linux server where I can only access it via ssh. I have a script that I need to have run all the time. I run like so: python script.py & It runs fine. When I log off ssh I...
0
by: Michelle Keys | last post by:
I am trying to call a print function to print a string from a database using javascript. Which is RC_DATA of Varchar2(2500). This is a javascript is not being used. I have a thing that needs to...
2
by: Jeff | last post by:
hey asp.net 2.0 I've placed a LoginStatus control on a master page (so I don't need to have it on every webpage) in my project. When I click on this control to logout, I get this error: A...
0
MMcCarthy
by: MMcCarthy | last post by:
This is a list of technical site links that many of our experts find useful. They are often included in posts in answer to repeated questions so I am posting a list of them here for convenience. ...
10
by: chaos | last post by:
How to do logout alert message when i press on the logout image <a href="../logout.php" target="_top" onClick="return logout()"...
1
by: shrik | last post by:
hi everybody. I have following problem. There are two pages. index.jsp and main.jsp in my application Index.jsp contains logging interface in . It submits password and userid to loginform bean. ...
9
by: Robbe Morris - [MVP] C# | last post by:
For reasons I won't get into here, I'd be curious if anyone has tried to write an ASP.NET 2.0 site that could restrict the number of active sessions before disabling the application. By disable,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.