FormsAuthentication.RedirectFromLoginPage is not passed fully qualified url

J

jacob

I have two web applications on the same server:

http://localhost/ModemUpgrade

and

http://localhost/TestFormAuth

The web.config of ModemUpgrade:

<authentication mode="Forms">
<forms name=".cuid"
loginUrl="http://localhost/TestFormAuth/MemberLogin.aspx" path="/">
</forms>
</authentication>

PROBLEM:
when I call FormsAuthentication.RedirectFromLoginPage from
MemberLogin.asp,

I notice that ReturnUrl=/ModemUpgrade/Agree.aspx
This keeps me on http://localhost/TestFormAuth/MemberLogin.aspx
because it doesn't have the fully qualified url
(http://localhost/TestFormAuth/MemberLogin.aspx?ReturnUrl=http://localhost/ModemUpgrade/Agree.aspx)
needed to complete the redirect

If I manually surf to:
http://localhost/TestFormAuth/MemberLogin.aspx?ReturnUrl=http://localhost/ModemUpgrade/Agree.aspx

the whole thing works...Please advise. Thanks.
 
W

Wes Henderson

Try modifying your application a bit so that MemberLogin.aspx is located in
the /ModemUpgrade folder. Have the redirect point to there instead of
putting it in a separate folder.

--
Regards,

Wes Henderson,
MCSE: Security

In order to help everyone, please direct all replies to this newsgroup.
This posting is my personal effort to provide help and is not on behalf of
any company.
Also, this posting is provided "AS IS" with no expressed or implied
warranties.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,001
Messages
2,570,254
Members
46,850
Latest member
VMRKlaus8

Latest Threads

Top