|
Home > Archive > Commerce Server General > January 2006 > Login problems
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
|
| Hello,
I'm quite new to Commerce Server. I've taken over a project already
made, and I have been assigned the fun task to fix all the bugs :-)
My greatest concern is the login. In my login page the authentication
always succeeds. I've double-checked that isAuthenticated() returns
true. I redirect to a "membership" page that checks for authentication.
The request contains both the MSCSProfile and MSCSAuth cookies.
However, when I check the isAuthenticated flag when arriving at the new
page it is set to false.
This behaviour doesn't occur always, but most of the times. If I put a
breakpoint in the login page (before the redirect) and enter VS debug
mode, and just resume execution directly, it always works for some
reason.
Any ideas where the problem might be? All ideas appreciated, the site
will go live in a few days :-/
Kind Regards,
Eric
| |
| Tomas Vera 2006-01-19, 6:07 pm |
| Eric,
I had a similar problem. As I recall it had to do with case. Here's
what was heppenning (it may not be your problem, however):
1. User lands on www.MySite.com/Login.aspx
2. Login succeeds.
3. User is redirected to www.mysite.com/myaccount.aspx
4. "Not Authenticated" error.
The problem was that the authentication cookie was set when the URL
contained "www.MySite.com" and I redirected the user to
"www.mysite.com".
For some reason, the cookie appears to be case-sensitive. So when the
user landed on "myaccount.aspx" the proper cookie was not set.
Again, this might not be your problem, but it killed a day and half
for me!
HTH
-tomas
On 16 Jan 2006 07:06:12 -0800, "Eric" <spam@rallymedia.nu> wrote:
>Hello,
>
>I'm quite new to Commerce Server. I've taken over a project already
>made, and I have been assigned the fun task to fix all the bugs :-)
>
>My greatest concern is the login. In my login page the authentication
>always succeeds. I've double-checked that isAuthenticated() returns
>true. I redirect to a "membership" page that checks for authentication.
>The request contains both the MSCSProfile and MSCSAuth cookies.
>However, when I check the isAuthenticated flag when arriving at the new
>page it is set to false.
>
>This behaviour doesn't occur always, but most of the times. If I put a
>breakpoint in the login page (before the redirect) and enter VS debug
>mode, and just resume execution directly, it always works for some
>reason.
>
>Any ideas where the problem might be? All ideas appreciated, the site
>will go live in a few days :-/
>
>Kind Regards,
>Eric
| |
|
| Hi,
I solved the problem, turned out to be the "set cookie path to
application"-checkbox found in the site properties in Commerce Server
Manager. Unchecking this solved the problem.. Took me ages to find 
I'm not sure why it worked something, but I'm running multiple
instances of the site on the same (test-)server, so sometimes I tried
logging in on one of the other sites, which probably made the login for
the new version work too while the cookie was active.. or something.
Anyway, I'm just happy it works now 
|
|
|
|
|