Home All Groups Group Topic Archive Search About

ASP.NET form-based authentication help

Author
18 Aug 2005 9:13 PM
Sword
I have an ASP.NET application that using form-based authentication. I have a
logon page, the user can enter his user name and password – which stored on a
remote SQL server, after click the Logon button, if both are correct, the
application will redirect the user to a welcome page. It’s very simple, and
works totally fine on my localhost machine, which is installed with Windows
XP with SP2. But after I moved this application to my company’s web server,
on which I can use the www.mycompany.com type url to browser the logon page,
the page’s Click button is no longer working. I checked all the possible
reasons I can think about, such as virtual directory, user access control,
all the possible IIS and server security settings, still can’t find why it
doesn’t work on the web server, which is installed with Windows 2003 Server.
Anyone can help?

Author
18 Aug 2005 9:44 PM
Joseph Bittman MCSD
August 18, 2005

   I'm not sure what exactly you are running into? Are you getting a
SecurityException or? On XP, ASP.Net uses the ASPNET account; on Windows
Server 2003, ASP.Net uses the Network Service account.

--
                 Joseph Bittman
Microsoft Certified Solution Developer

Web Site: http://71.39.42.23/
Static IP





Show quoteHide quote
"Sword" <Sw***@discussions.microsoft.com> wrote in message
news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
>I have an ASP.NET application that using form-based authentication. I have
>a
> logon page, the user can enter his user name and password - which stored
> on a
> remote SQL server, after click the Logon button, if both are correct, the
> application will redirect the user to a welcome page. It's very simple,
> and
> works totally fine on my localhost machine, which is installed with
> Windows
> XP with SP2. But after I moved this application to my company's web
> server,
> on which I can use the www.mycompany.com type url to browser the logon
> page,
> the page's Click button is no longer working. I checked all the possible
> reasons I can think about, such as virtual directory, user access control,
> all the possible IIS and server security settings, still can't find why it
> doesn't work on the web server, which is installed with Windows 2003
> Server.
> Anyone can help?
Author
18 Aug 2005 9:58 PM
Sword
All my authentication codes are on the Click button's click event. When I
click it on the web server, nothing happened. No any error messages, no any
prompts. Just like no running codes for the event. It seems the server
doesn't run the codes at all.

Show quoteHide quote
"Joseph Bittman MCSD" wrote:

> August 18, 2005
>
>    I'm not sure what exactly you are running into? Are you getting a
> SecurityException or? On XP, ASP.Net uses the ASPNET account; on Windows
> Server 2003, ASP.Net uses the Network Service account.
>
> --
>                  Joseph Bittman
> Microsoft Certified Solution Developer
>
> Web Site: http://71.39.42.23/
> Static IP
>
>
>
>
>
> "Sword" <Sw***@discussions.microsoft.com> wrote in message
> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
> >I have an ASP.NET application that using form-based authentication. I have
> >a
> > logon page, the user can enter his user name and password - which stored
> > on a
> > remote SQL server, after click the Logon button, if both are correct, the
> > application will redirect the user to a welcome page. It's very simple,
> > and
> > works totally fine on my localhost machine, which is installed with
> > Windows
> > XP with SP2. But after I moved this application to my company's web
> > server,
> > on which I can use the www.mycompany.com type url to browser the logon
> > page,
> > the page's Click button is no longer working. I checked all the possible
> > reasons I can think about, such as virtual directory, user access control,
> > all the possible IIS and server security settings, still can't find why it
> > doesn't work on the web server, which is installed with Windows 2003
> > Server.
> > Anyone can help?
>
>
>
Author
19 Aug 2005 9:54 PM
Joseph Bittman MCSD
August 19, 2005

  I think I have seen that behavior before. I believe it was caused by some
IE setting or script error on the page that caused everything to break. One
other thing that comes to my mind is whether your button was an HTML button
that you right clicked and selected Run At Server. Then if it uses
javascript or something to call the event on the server and the production
server has that disabled, then that could be a problem? or maybe if the
client has it disabled?... is this the case about an HTML button? You might
also look in the HTML generated and see if there is some problem there. Hope
this helps!

--
                 Joseph Bittman
Microsoft Certified Solution Developer

Web Site: http://71.39.42.23/
Static IP





Show quoteHide quote
"Sword" <Sw***@discussions.microsoft.com> wrote in message
news:D16FABFE-D874-4CBF-A0B9-00851076885F@microsoft.com...
> All my authentication codes are on the Click button's click event. When I
> click it on the web server, nothing happened. No any error messages, no
> any
> prompts. Just like no running codes for the event. It seems the server
> doesn't run the codes at all.
>
> "Joseph Bittman MCSD" wrote:
>
>> August 18, 2005
>>
>>    I'm not sure what exactly you are running into? Are you getting a
>> SecurityException or? On XP, ASP.Net uses the ASPNET account; on Windows
>> Server 2003, ASP.Net uses the Network Service account.
>>
>> --
>>                  Joseph Bittman
>> Microsoft Certified Solution Developer
>>
>> Web Site: http://71.39.42.23/
>> Static IP
>>
>>
>>
>>
>>
>> "Sword" <Sw***@discussions.microsoft.com> wrote in message
>> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
>> >I have an ASP.NET application that using form-based authentication. I
>> >have
>> >a
>> > logon page, the user can enter his user name and password - which
>> > stored
>> > on a
>> > remote SQL server, after click the Logon button, if both are correct,
>> > the
>> > application will redirect the user to a welcome page. It's very simple,
>> > and
>> > works totally fine on my localhost machine, which is installed with
>> > Windows
>> > XP with SP2. But after I moved this application to my company's web
>> > server,
>> > on which I can use the www.mycompany.com type url to browser the logon
>> > page,
>> > the page's Click button is no longer working. I checked all the
>> > possible
>> > reasons I can think about, such as virtual directory, user access
>> > control,
>> > all the possible IIS and server security settings, still can't find why
>> > it
>> > doesn't work on the web server, which is installed with Windows 2003
>> > Server.
>> > Anyone can help?
>>
>>
>>
Author
20 Aug 2005 7:09 AM
Dominick Baier [DevelopMentor]
Hello Sword,

install a tool like Fiddler (www.fiddlertool.com) and trace the traffic.
maybe this give your more information.

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

Show quoteHide quote
> All my authentication codes are on the Click button's click event.
> When I click it on the web server, nothing happened. No any error
> messages, no any prompts. Just like no running codes for the event. It
> seems the server doesn't run the codes at all.
>
> "Joseph Bittman MCSD" wrote:
>
>> August 18, 2005
>>
>> I'm not sure what exactly you are running into? Are you getting a
>> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
>> Windows Server 2003, ASP.Net uses the Network Service account.
>>
>> --
>> Joseph Bittman
>> Microsoft Certified Solution Developer
>> Web Site: http://71.39.42.23/
>> Static IP
>> "Sword" <Sw***@discussions.microsoft.com> wrote in message
>> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
>>
>>> I have an ASP.NET application that using form-based authentication.
>>> I have
>>> a
>>> logon page, the user can enter his user name and password - which
>>> stored
>>> on a
>>> remote SQL server, after click the Logon button, if both are
>>> correct, the
>>> application will redirect the user to a welcome page. It's very
>>> simple,
>>> and
>>> works totally fine on my localhost machine, which is installed with
>>> Windows
>>> XP with SP2. But after I moved this application to my company's web
>>> server,
>>> on which I can use the www.mycompany.com type url to browser the
>>> logon
>>> page,
>>> the page's Click button is no longer working. I checked all the
>>> possible
>>> reasons I can think about, such as virtual directory, user access
>>> control,
>>> all the possible IIS and server security settings, still can't find
>>> why it
>>> doesn't work on the web server, which is installed with Windows 2003
>>> Server.
>>> Anyone can help?
Author
22 Aug 2005 3:16 PM
Sword
Hi, Guys,

Thanks to provide me such useful ideas. I used Fiddler to trace the HTTP
contents, but still can’t find where the problem is. And all the javascript
settings are fine on both server and client sides.

The following is the HTML page source codes, can you help me check if there
are any problems?

HTTP/1.1 200 OK
Date: Mon, 22 Aug 2005 14:41:43 GMT
Server: Microsoft-IIS/6.0
MicrosoftSharePointTeamServices: 6.0.2.5530
X-Powered-By: ASP.NET
X-AspNet-Version: 1.1.4322
Set-Cookie: ASP.NET_SessionId=tzbku3fzc5f4qxbe5trauwas; path=/
Cache-Control: private
Content-Type: text/html; charset=utf-8
Content-Length: 3483


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
    <HEAD>
        <title>WebForm1</title>
        <meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
        <meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
        <meta name="vs_defaultClientScript" content="JavaScript">
        <meta name="vs_targetSchema"
content="http://schemas.microsoft.com/intellisense/ie5">
    </HEAD>
    <body>
        <form name="Form1" method="post" action="Login.aspx" language="javascript"
onsubmit="if (!ValidatorOnSubmit()) return false;" id="Form1">
<input type="hidden" name="__VIEWSTATE"
value="dDwtMTA0NDYzMTY2Mjs7bDxjaGtMb2c7Pj7Cqwwna1FAYtogb4vN8QNB1TjRqg==" />

<script language="javascript" type="text/javascript"
src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>


            <P>Log In To Your Account</P>
            <P>
                <span id="myMsg"></span></P>
            <P>Email:      
                <input name="txtEmail" type="text" id="txtEmail" /><BR>

                <span id="RequiredFieldValidator1" controltovalidate="txtEmail"
errormessage="Email must not be left blank"
evaluationfunction="RequiredFieldValidatorEvaluateIsValid" initialvalue=""
style="color:Red;width:168px;visibility:hidden;">Email must not be left
blank</span><BR>

                <span id="RegularExpressionValidator1" controltovalidate="txtEmail"
errormessage="Please enter a valid email address"
evaluationfunction="RegularExpressionValidatorEvaluateIsValid"
validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
style="color:Red;visibility:hidden;">Please enter a valid email
address</span></P>
            <P>Password:
                <input name="txtPassword" type="password" id="txtPassword" /><BR>

                <span id="RequiredFieldValidator2" controltovalidate="txtPassword"
errormessage="Password must not be left blank"
evaluationfunction="RequiredFieldValidatorEvaluateIsValid" initialvalue=""
style="color:Red;visibility:hidden;">Password must not be left
blank</span></P>
            <P>              
                <input id="chkLog" type="checkbox" name="chkLog" /><label
for="chkLog">Remeber My User Name</label></P>
            <P>
                <input type="submit" name="cmdLogin" value="Login" onclick="if
(typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); "
language="javascript" id="cmdLogin" style="width:80px;" /></P>
            <P> </P>

<script language="javascript" type="text/javascript">
<!--
    var Page_Validators =  new Array(document.all["RequiredFieldValidator1"],
document.all["RegularExpressionValidator1"],
document.all["RequiredFieldValidator2"]);
        // -->
</script>


<script language="javascript" type="text/javascript">
<!--
var Page_ValidationActive = false;
if (typeof(clientInformation) != "undefined" &&
clientInformation.appName.indexOf("Explorer") != -1) {
    if ((typeof(Page_ValidationVer) != "undefined") && (Page_ValidationVer
== "125"))
        ValidatorOnLoad();
}

function ValidatorOnSubmit() {
    if (Page_ValidationActive) {
        return ValidatorCommonOnSubmit();
    }
    return true;
}
// -->
</script>


        </form>
    </body>
</HTML>

Show quoteHide quote
"Dominick Baier [DevelopMentor]" wrote:

> Hello Sword,
>
> install a tool like Fiddler (www.fiddlertool.com) and trace the traffic.
> maybe this give your more information.
>
> ---------------------------------------
> Dominick Baier - DevelopMentor
> http://www.leastprivilege.com
>
> > All my authentication codes are on the Click button's click event.
> > When I click it on the web server, nothing happened. No any error
> > messages, no any prompts. Just like no running codes for the event. It
> > seems the server doesn't run the codes at all.
> >
> > "Joseph Bittman MCSD" wrote:
> >
> >> August 18, 2005
> >>
> >> I'm not sure what exactly you are running into? Are you getting a
> >> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
> >> Windows Server 2003, ASP.Net uses the Network Service account.
> >>
> >> --
> >> Joseph Bittman
> >> Microsoft Certified Solution Developer
> >> Web Site: http://71.39.42.23/
> >> Static IP
> >> "Sword" <Sw***@discussions.microsoft.com> wrote in message
> >> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
> >>
> >>> I have an ASP.NET application that using form-based authentication.
> >>> I have
> >>> a
> >>> logon page, the user can enter his user name and password - which
> >>> stored
> >>> on a
> >>> remote SQL server, after click the Logon button, if both are
> >>> correct, the
> >>> application will redirect the user to a welcome page. It's very
> >>> simple,
> >>> and
> >>> works totally fine on my localhost machine, which is installed with
> >>> Windows
> >>> XP with SP2. But after I moved this application to my company's web
> >>> server,
> >>> on which I can use the www.mycompany.com type url to browser the
> >>> logon
> >>> page,
> >>> the page's Click button is no longer working. I checked all the
> >>> possible
> >>> reasons I can think about, such as virtual directory, user access
> >>> control,
> >>> all the possible IIS and server security settings, still can't find
> >>> why it
> >>> doesn't work on the web server, which is installed with Windows 2003
> >>> Server.
> >>> Anyone can help?
>
>
>
>
Author
22 Aug 2005 4:43 PM
Dominick Baier [DevelopMentor]
Hello Sword,

more interesting would be the request/response header _after_ you clicked
the login button

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

Show quoteHide quote
> Hi, Guys,
>
> Thanks to provide me such useful ideas. I used Fiddler to trace the
> HTTP contents, but still can't find where the problem is. And all the
> javascript settings are fine on both server and client sides.
>
> The following is the HTML page source codes, can you help me check if
> there are any problems?
>
> HTTP/1.1 200 OK
> Date: Mon, 22 Aug 2005 14:41:43 GMT
> Server: Microsoft-IIS/6.0
> MicrosoftSharePointTeamServices: 6.0.2.5530
> X-Powered-By: ASP.NET
> X-AspNet-Version: 1.1.4322
> Set-Cookie: ASP.NET_SessionId=tzbku3fzc5f4qxbe5trauwas; path=/
> Cache-Control: private
> Content-Type: text/html; charset=utf-8
> Content-Length: 3483
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> <HTML>
> <HEAD>
> <title>WebForm1</title>
> <meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
> <meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
> <meta name="vs_defaultClientScript" content="JavaScript">
> <meta name="vs_targetSchema"
> content="http://schemas.microsoft.com/intellisense/ie5">
> </HEAD>
> <body>
> <form name="Form1" method="post" action="Login.aspx"
> language="javascript"
> onsubmit="if (!ValidatorOnSubmit()) return false;" id="Form1">
> <input type="hidden" name="__VIEWSTATE"
> value="dDwtMTA0NDYzMTY2Mjs7bDxjaGtMb2c7Pj7Cqwwna1FAYtogb4vN8QNB1TjRqg=
> =" />
>
> <script language="javascript" type="text/javascript"
> src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>
>
> <P>Log In To Your Account</P>
> <P>
> <span id="myMsg"></span></P>
> <P>Email:
> <input name="txtEmail" type="text" id="txtEmail" /><BR>
> <span id="RequiredFieldValidator1" controltovalidate="txtEmail"
> errormessage="Email must not be left blank"
> evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> initialvalue="" style="color:Red;width:168px;visibility:hidden;">Email
> must not be left blank</span><BR>
>
> <span id="RegularExpressionValidator1"
> controltovalidate="txtEmail"
> errormessage="Please enter a valid email address"
> evaluationfunction="RegularExpressionValidatorEvaluateIsValid"
> validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
> style="color:Red;visibility:hidden;">Please enter a valid email
> address</span></P>
> <P>Password:
> <input name="txtPassword" type="password" id="txtPassword" /><BR>
> <span id="RequiredFieldValidator2" controltovalidate="txtPassword"
> errormessage="Password must not be left blank"
> evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> initialvalue=""
> style="color:Red;visibility:hidden;">Password must not be left
> blank</span></P>
> <P>
> <input id="chkLog" type="checkbox" name="chkLog" /><label
> for="chkLog">Remeber My User Name</label></P>
> <P>
> <input type="submit" name="cmdLogin" value="Login" onclick="if
> (typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); "
> language="javascript" id="cmdLogin" style="width:80px;" /></P>
> <P> </P>
> <script language="javascript" type="text/javascript">
> <!--
> var Page_Validators =  new
> Array(document.all["RequiredFieldValidator1"],
> document.all["RegularExpressionValidator1"],
> document.all["RequiredFieldValidator2"]);
> // -->
> </script>
> <script language="javascript" type="text/javascript">
> <!--
> var Page_ValidationActive = false;
> if (typeof(clientInformation) != "undefined" &&
> clientInformation.appName.indexOf("Explorer") != -1) {
> if ((typeof(Page_ValidationVer) != "undefined") &&
> (Page_ValidationVer
> == "125"))
> ValidatorOnLoad();
> }
> function ValidatorOnSubmit() {
> if (Page_ValidationActive) {
> return ValidatorCommonOnSubmit();
> }
> return true;
> }
> // -->
> </script>
> </form>
> </body>
> </HTML>
> "Dominick Baier [DevelopMentor]" wrote:
>
>> Hello Sword,
>>
>> install a tool like Fiddler (www.fiddlertool.com) and trace the
>> traffic. maybe this give your more information.
>>
>> ---------------------------------------
>> Dominick Baier - DevelopMentor
>> http://www.leastprivilege.com
>>> All my authentication codes are on the Click button's click event.
>>> When I click it on the web server, nothing happened. No any error
>>> messages, no any prompts. Just like no running codes for the event.
>>> It seems the server doesn't run the codes at all.
>>>
>>> "Joseph Bittman MCSD" wrote:
>>>
>>>> August 18, 2005
>>>>
>>>> I'm not sure what exactly you are running into? Are you getting a
>>>> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
>>>> Windows Server 2003, ASP.Net uses the Network Service account.
>>>>
>>>> --
>>>> Joseph Bittman
>>>> Microsoft Certified Solution Developer
>>>> Web Site: http://71.39.42.23/
>>>> Static IP
>>>> "Sword" <Sw***@discussions.microsoft.com> wrote in message
>>>> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
>>>>> I have an ASP.NET application that using form-based
>>>>> authentication.
>>>>> I have
>>>>> a
>>>>> logon page, the user can enter his user name and password - which
>>>>> stored
>>>>> on a
>>>>> remote SQL server, after click the Logon button, if both are
>>>>> correct, the
>>>>> application will redirect the user to a welcome page. It's very
>>>>> simple,
>>>>> and
>>>>> works totally fine on my localhost machine, which is installed
>>>>> with
>>>>> Windows
>>>>> XP with SP2. But after I moved this application to my company's
>>>>> web
>>>>> server,
>>>>> on which I can use the www.mycompany.com type url to browser the
>>>>> logon
>>>>> page,
>>>>> the page's Click button is no longer working. I checked all the
>>>>> possible
>>>>> reasons I can think about, such as virtual directory, user access
>>>>> control,
>>>>> all the possible IIS and server security settings, still can't
>>>>> find
>>>>> why it
>>>>> doesn't work on the web server, which is installed with Windows
>>>>> 2003
>>>>> Server.
>>>>> Anyone can help?
Author
22 Aug 2005 5:08 PM
Sword
Request Header:
GET /Login.aspx HTTP/1.1
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
application/x-shockwave-flash, application/vnd.ms-excel,
application/vnd.ms-powerpoint, application/msword, */*
Accept-Language: en-us
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR
1.1.4322)
Host: www.com
Proxy-Connection: Keep-Alive

Response Header:
HTTP/1.1 200 OK
Date: Mon, 22 Aug 2005 16:55:58 GMT
Server: Microsoft-IIS/6.0
MicrosoftSharePointTeamServices: 6.0.2.5530
X-Powered-By: ASP.NET
X-AspNet-Version: 1.1.4322
Set-Cookie: ASP.NET_SessionId=sfutrirokm33fy45dyr5zm45; path=/
Cache-Control: private
Content-Type: text/html; charset=utf-8
Content-Length: 3483

Show quoteHide quote
"Dominick Baier [DevelopMentor]" wrote:

> Hello Sword,
>
> more interesting would be the request/response header _after_ you clicked
> the login button
>
> ---------------------------------------
> Dominick Baier - DevelopMentor
> http://www.leastprivilege.com
>
> > Hi, Guys,
> >
> > Thanks to provide me such useful ideas. I used Fiddler to trace the
> > HTTP contents, but still can't find where the problem is. And all the
> > javascript settings are fine on both server and client sides.
> >
> > The following is the HTML page source codes, can you help me check if
> > there are any problems?
> >
> > HTTP/1.1 200 OK
> > Date: Mon, 22 Aug 2005 14:41:43 GMT
> > Server: Microsoft-IIS/6.0
> > MicrosoftSharePointTeamServices: 6.0.2.5530
> > X-Powered-By: ASP.NET
> > X-AspNet-Version: 1.1.4322
> > Set-Cookie: ASP.NET_SessionId=tzbku3fzc5f4qxbe5trauwas; path=/
> > Cache-Control: private
> > Content-Type: text/html; charset=utf-8
> > Content-Length: 3483
> > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> > <HTML>
> > <HEAD>
> > <title>WebForm1</title>
> > <meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
> > <meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
> > <meta name="vs_defaultClientScript" content="JavaScript">
> > <meta name="vs_targetSchema"
> > content="http://schemas.microsoft.com/intellisense/ie5">
> > </HEAD>
> > <body>
> > <form name="Form1" method="post" action="Login.aspx"
> > language="javascript"
> > onsubmit="if (!ValidatorOnSubmit()) return false;" id="Form1">
> > <input type="hidden" name="__VIEWSTATE"
> > value="dDwtMTA0NDYzMTY2Mjs7bDxjaGtMb2c7Pj7Cqwwna1FAYtogb4vN8QNB1TjRqg=
> > =" />
> >
> > <script language="javascript" type="text/javascript"
> > src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>
> >
> > <P>Log In To Your Account</P>
> > <P>
> > <span id="myMsg"></span></P>
> > <P>Email:
> > <input name="txtEmail" type="text" id="txtEmail" /><BR>
> > <span id="RequiredFieldValidator1" controltovalidate="txtEmail"
> > errormessage="Email must not be left blank"
> > evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> > initialvalue="" style="color:Red;width:168px;visibility:hidden;">Email
> > must not be left blank</span><BR>
> >
> > <span id="RegularExpressionValidator1"
> > controltovalidate="txtEmail"
> > errormessage="Please enter a valid email address"
> > evaluationfunction="RegularExpressionValidatorEvaluateIsValid"
> > validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
> > style="color:Red;visibility:hidden;">Please enter a valid email
> > address</span></P>
> > <P>Password:
> > <input name="txtPassword" type="password" id="txtPassword" /><BR>
> > <span id="RequiredFieldValidator2" controltovalidate="txtPassword"
> > errormessage="Password must not be left blank"
> > evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> > initialvalue=""
> > style="color:Red;visibility:hidden;">Password must not be left
> > blank</span></P>
> > <P>
> > <input id="chkLog" type="checkbox" name="chkLog" /><label
> > for="chkLog">Remeber My User Name</label></P>
> > <P>
> > <input type="submit" name="cmdLogin" value="Login" onclick="if
> > (typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); "
> > language="javascript" id="cmdLogin" style="width:80px;" /></P>
> > <P> </P>
> > <script language="javascript" type="text/javascript">
> > <!--
> > var Page_Validators =  new
> > Array(document.all["RequiredFieldValidator1"],
> > document.all["RegularExpressionValidator1"],
> > document.all["RequiredFieldValidator2"]);
> > // -->
> > </script>
> > <script language="javascript" type="text/javascript">
> > <!--
> > var Page_ValidationActive = false;
> > if (typeof(clientInformation) != "undefined" &&
> > clientInformation.appName.indexOf("Explorer") != -1) {
> > if ((typeof(Page_ValidationVer) != "undefined") &&
> > (Page_ValidationVer
> > == "125"))
> > ValidatorOnLoad();
> > }
> > function ValidatorOnSubmit() {
> > if (Page_ValidationActive) {
> > return ValidatorCommonOnSubmit();
> > }
> > return true;
> > }
> > // -->
> > </script>
> > </form>
> > </body>
> > </HTML>
> > "Dominick Baier [DevelopMentor]" wrote:
> >
> >> Hello Sword,
> >>
> >> install a tool like Fiddler (www.fiddlertool.com) and trace the
> >> traffic. maybe this give your more information.
> >>
> >> ---------------------------------------
> >> Dominick Baier - DevelopMentor
> >> http://www.leastprivilege.com
> >>> All my authentication codes are on the Click button's click event.
> >>> When I click it on the web server, nothing happened. No any error
> >>> messages, no any prompts. Just like no running codes for the event.
> >>> It seems the server doesn't run the codes at all.
> >>>
> >>> "Joseph Bittman MCSD" wrote:
> >>>
> >>>> August 18, 2005
> >>>>
> >>>> I'm not sure what exactly you are running into? Are you getting a
> >>>> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
> >>>> Windows Server 2003, ASP.Net uses the Network Service account.
> >>>>
> >>>> --
> >>>> Joseph Bittman
> >>>> Microsoft Certified Solution Developer
> >>>> Web Site: http://71.39.42.23/
> >>>> Static IP
> >>>> "Sword" <Sw***@discussions.microsoft.com> wrote in message
> >>>> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
> >>>>> I have an ASP.NET application that using form-based
> >>>>> authentication.
> >>>>> I have
> >>>>> a
> >>>>> logon page, the user can enter his user name and password - which
> >>>>> stored
> >>>>> on a
> >>>>> remote SQL server, after click the Logon button, if both are
> >>>>> correct, the
> >>>>> application will redirect the user to a welcome page. It's very
> >>>>> simple,
> >>>>> and
> >>>>> works totally fine on my localhost machine, which is installed
> >>>>> with
> >>>>> Windows
> >>>>> XP with SP2. But after I moved this application to my company's
> >>>>> web
> >>>>> server,
> >>>>> on which I can use the www.mycompany.com type url to browser the
> >>>>> logon
> >>>>> page,
> >>>>> the page's Click button is no longer working. I checked all the
> >>>>> possible
> >>>>> reasons I can think about, such as virtual directory, user access
> >>>>> control,
> >>>>> all the possible IIS and server security settings, still can't
> >>>>> find
> >>>>> why it
> >>>>> doesn't work on the web server, which is installed with Windows
> >>>>> 2003
> >>>>> Server.
> >>>>> Anyone can help?
>
>
>
>
Author
22 Aug 2005 7:56 PM
Sword
I just found another problem. Only the computers login to our domain by using
my account can pass through, if I change to another user’s account, the
button still doesn’t working. Is there any other settings need to be done? I
checked all the security and iis settings, just can’t figure it out. Still
need help.

Show quoteHide quote
"Dominick Baier [DevelopMentor]" wrote:

> Hello Sword,
>
> more interesting would be the request/response header _after_ you clicked
> the login button
>
> ---------------------------------------
> Dominick Baier - DevelopMentor
> http://www.leastprivilege.com
>
> > Hi, Guys,
> >
> > Thanks to provide me such useful ideas. I used Fiddler to trace the
> > HTTP contents, but still can't find where the problem is. And all the
> > javascript settings are fine on both server and client sides.
> >
> > The following is the HTML page source codes, can you help me check if
> > there are any problems?
> >
> > HTTP/1.1 200 OK
> > Date: Mon, 22 Aug 2005 14:41:43 GMT
> > Server: Microsoft-IIS/6.0
> > MicrosoftSharePointTeamServices: 6.0.2.5530
> > X-Powered-By: ASP.NET
> > X-AspNet-Version: 1.1.4322
> > Set-Cookie: ASP.NET_SessionId=tzbku3fzc5f4qxbe5trauwas; path=/
> > Cache-Control: private
> > Content-Type: text/html; charset=utf-8
> > Content-Length: 3483
> > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> > <HTML>
> > <HEAD>
> > <title>WebForm1</title>
> > <meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
> > <meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
> > <meta name="vs_defaultClientScript" content="JavaScript">
> > <meta name="vs_targetSchema"
> > content="http://schemas.microsoft.com/intellisense/ie5">
> > </HEAD>
> > <body>
> > <form name="Form1" method="post" action="Login.aspx"
> > language="javascript"
> > onsubmit="if (!ValidatorOnSubmit()) return false;" id="Form1">
> > <input type="hidden" name="__VIEWSTATE"
> > value="dDwtMTA0NDYzMTY2Mjs7bDxjaGtMb2c7Pj7Cqwwna1FAYtogb4vN8QNB1TjRqg=
> > =" />
> >
> > <script language="javascript" type="text/javascript"
> > src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>
> >
> > <P>Log In To Your Account</P>
> > <P>
> > <span id="myMsg"></span></P>
> > <P>Email:
> > <input name="txtEmail" type="text" id="txtEmail" /><BR>
> > <span id="RequiredFieldValidator1" controltovalidate="txtEmail"
> > errormessage="Email must not be left blank"
> > evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> > initialvalue="" style="color:Red;width:168px;visibility:hidden;">Email
> > must not be left blank</span><BR>
> >
> > <span id="RegularExpressionValidator1"
> > controltovalidate="txtEmail"
> > errormessage="Please enter a valid email address"
> > evaluationfunction="RegularExpressionValidatorEvaluateIsValid"
> > validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
> > style="color:Red;visibility:hidden;">Please enter a valid email
> > address</span></P>
> > <P>Password:
> > <input name="txtPassword" type="password" id="txtPassword" /><BR>
> > <span id="RequiredFieldValidator2" controltovalidate="txtPassword"
> > errormessage="Password must not be left blank"
> > evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> > initialvalue=""
> > style="color:Red;visibility:hidden;">Password must not be left
> > blank</span></P>
> > <P>
> > <input id="chkLog" type="checkbox" name="chkLog" /><label
> > for="chkLog">Remeber My User Name</label></P>
> > <P>
> > <input type="submit" name="cmdLogin" value="Login" onclick="if
> > (typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); "
> > language="javascript" id="cmdLogin" style="width:80px;" /></P>
> > <P> </P>
> > <script language="javascript" type="text/javascript">
> > <!--
> > var Page_Validators =  new
> > Array(document.all["RequiredFieldValidator1"],
> > document.all["RegularExpressionValidator1"],
> > document.all["RequiredFieldValidator2"]);
> > // -->
> > </script>
> > <script language="javascript" type="text/javascript">
> > <!--
> > var Page_ValidationActive = false;
> > if (typeof(clientInformation) != "undefined" &&
> > clientInformation.appName.indexOf("Explorer") != -1) {
> > if ((typeof(Page_ValidationVer) != "undefined") &&
> > (Page_ValidationVer
> > == "125"))
> > ValidatorOnLoad();
> > }
> > function ValidatorOnSubmit() {
> > if (Page_ValidationActive) {
> > return ValidatorCommonOnSubmit();
> > }
> > return true;
> > }
> > // -->
> > </script>
> > </form>
> > </body>
> > </HTML>
> > "Dominick Baier [DevelopMentor]" wrote:
> >
> >> Hello Sword,
> >>
> >> install a tool like Fiddler (www.fiddlertool.com) and trace the
> >> traffic. maybe this give your more information.
> >>
> >> ---------------------------------------
> >> Dominick Baier - DevelopMentor
> >> http://www.leastprivilege.com
> >>> All my authentication codes are on the Click button's click event.
> >>> When I click it on the web server, nothing happened. No any error
> >>> messages, no any prompts. Just like no running codes for the event.
> >>> It seems the server doesn't run the codes at all.
> >>>
> >>> "Joseph Bittman MCSD" wrote:
> >>>
> >>>> August 18, 2005
> >>>>
> >>>> I'm not sure what exactly you are running into? Are you getting a
> >>>> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
> >>>> Windows Server 2003, ASP.Net uses the Network Service account.
> >>>>
> >>>> --
> >>>> Joseph Bittman
> >>>> Microsoft Certified Solution Developer
> >>>> Web Site: http://71.39.42.23/
> >>>> Static IP
> >>>> "Sword" <Sw***@discussions.microsoft.com> wrote in message
> >>>> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
> >>>>> I have an ASP.NET application that using form-based
> >>>>> authentication.
> >>>>> I have
> >>>>> a
> >>>>> logon page, the user can enter his user name and password - which
> >>>>> stored
> >>>>> on a
> >>>>> remote SQL server, after click the Logon button, if both are
> >>>>> correct, the
> >>>>> application will redirect the user to a welcome page. It's very
> >>>>> simple,
> >>>>> and
> >>>>> works totally fine on my localhost machine, which is installed
> >>>>> with
> >>>>> Windows
> >>>>> XP with SP2. But after I moved this application to my company's
> >>>>> web
> >>>>> server,
> >>>>> on which I can use the www.mycompany.com type url to browser the
> >>>>> logon
> >>>>> page,
> >>>>> the page's Click button is no longer working. I checked all the
> >>>>> possible
> >>>>> reasons I can think about, such as virtual directory, user access
> >>>>> control,
> >>>>> all the possible IIS and server security settings, still can't
> >>>>> find
> >>>>> why it
> >>>>> doesn't work on the web server, which is installed with Windows
> >>>>> 2003
> >>>>> Server.
> >>>>> Anyone can help?
>
>
>
>
Author
22 Aug 2005 4:46 PM
Sword
I debugged the codes, it seems ValidatorOnSubmit() function doesn’t pass. I
know it’s form authentication related, but how this happens?

Show quoteHide quote
"Sword" wrote:

> Hi, Guys,
>
> Thanks to provide me such useful ideas. I used Fiddler to trace the HTTP
> contents, but still can’t find where the problem is. And all the javascript
> settings are fine on both server and client sides.
>
> The following is the HTML page source codes, can you help me check if there
> are any problems?
>
> HTTP/1.1 200 OK
> Date: Mon, 22 Aug 2005 14:41:43 GMT
> Server: Microsoft-IIS/6.0
> MicrosoftSharePointTeamServices: 6.0.2.5530
> X-Powered-By: ASP.NET
> X-AspNet-Version: 1.1.4322
> Set-Cookie: ASP.NET_SessionId=tzbku3fzc5f4qxbe5trauwas; path=/
> Cache-Control: private
> Content-Type: text/html; charset=utf-8
> Content-Length: 3483
>
>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> <HTML>
>     <HEAD>
>         <title>WebForm1</title>
>         <meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
>         <meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
>         <meta name="vs_defaultClientScript" content="JavaScript">
>         <meta name="vs_targetSchema"
> content="http://schemas.microsoft.com/intellisense/ie5">
>     </HEAD>
>     <body>
>         <form name="Form1" method="post" action="Login.aspx" language="javascript"
> onsubmit="if (!ValidatorOnSubmit()) return false;" id="Form1">
> <input type="hidden" name="__VIEWSTATE"
> value="dDwtMTA0NDYzMTY2Mjs7bDxjaGtMb2c7Pj7Cqwwna1FAYtogb4vN8QNB1TjRqg==" />
>    
> <script language="javascript" type="text/javascript"
> src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>
>
>
>             <P>Log In To Your Account</P>
>             <P>
>                 <span id="myMsg"></span></P>
>             <P>Email:      
>                 <input name="txtEmail" type="text" id="txtEmail" /><BR>
>                                
>                 <span id="RequiredFieldValidator1" controltovalidate="txtEmail"
> errormessage="Email must not be left blank"
> evaluationfunction="RequiredFieldValidatorEvaluateIsValid" initialvalue=""
> style="color:Red;width:168px;visibility:hidden;">Email must not be left
> blank</span><BR>
>                                
>                 <span id="RegularExpressionValidator1" controltovalidate="txtEmail"
> errormessage="Please enter a valid email address"
> evaluationfunction="RegularExpressionValidatorEvaluateIsValid"
> validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
> style="color:Red;visibility:hidden;">Please enter a valid email
> address</span></P>
>             <P>Password:
>                 <input name="txtPassword" type="password" id="txtPassword" /><BR>
>                                
>                 <span id="RequiredFieldValidator2" controltovalidate="txtPassword"
> errormessage="Password must not be left blank"
> evaluationfunction="RequiredFieldValidatorEvaluateIsValid" initialvalue=""
> style="color:Red;visibility:hidden;">Password must not be left
> blank</span></P>
>             <P>              
>                 <input id="chkLog" type="checkbox" name="chkLog" /><label
> for="chkLog">Remeber My User Name</label></P>
>             <P>
>                 <input type="submit" name="cmdLogin" value="Login" onclick="if
> (typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); "
> language="javascript" id="cmdLogin" style="width:80px;" /></P>
>             <P> </P>
>        
> <script language="javascript" type="text/javascript">
> <!--
>     var Page_Validators =  new Array(document.all["RequiredFieldValidator1"],
> document.all["RegularExpressionValidator1"],
> document.all["RequiredFieldValidator2"]);
>         // -->
> </script>
>
>            
> <script language="javascript" type="text/javascript">
> <!--
> var Page_ValidationActive = false;
> if (typeof(clientInformation) != "undefined" &&
> clientInformation.appName.indexOf("Explorer") != -1) {
>     if ((typeof(Page_ValidationVer) != "undefined") && (Page_ValidationVer
> == "125"))
>         ValidatorOnLoad();
> }
>
> function ValidatorOnSubmit() {
>     if (Page_ValidationActive) {
>         return ValidatorCommonOnSubmit();
>     }
>     return true;
> }
> // -->
> </script>
>        
>
>         </form>
>     </body>
> </HTML>
>
> "Dominick Baier [DevelopMentor]" wrote:
>
> > Hello Sword,
> >
> > install a tool like Fiddler (www.fiddlertool.com) and trace the traffic.
> > maybe this give your more information.
> >
> > ---------------------------------------
> > Dominick Baier - DevelopMentor
> > http://www.leastprivilege.com
> >
> > > All my authentication codes are on the Click button's click event.
> > > When I click it on the web server, nothing happened. No any error
> > > messages, no any prompts. Just like no running codes for the event. It
> > > seems the server doesn't run the codes at all.
> > >
> > > "Joseph Bittman MCSD" wrote:
> > >
> > >> August 18, 2005
> > >>
> > >> I'm not sure what exactly you are running into? Are you getting a
> > >> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
> > >> Windows Server 2003, ASP.Net uses the Network Service account.
> > >>
> > >> --
> > >> Joseph Bittman
> > >> Microsoft Certified Solution Developer
> > >> Web Site: http://71.39.42.23/
> > >> Static IP
> > >> "Sword" <Sw***@discussions.microsoft.com> wrote in message
> > >> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
> > >>
> > >>> I have an ASP.NET application that using form-based authentication.
> > >>> I have
> > >>> a
> > >>> logon page, the user can enter his user name and password - which
> > >>> stored
> > >>> on a
> > >>> remote SQL server, after click the Logon button, if both are
> > >>> correct, the
> > >>> application will redirect the user to a welcome page. It's very
> > >>> simple,
> > >>> and
> > >>> works totally fine on my localhost machine, which is installed with
> > >>> Windows
> > >>> XP with SP2. But after I moved this application to my company's web
> > >>> server,
> > >>> on which I can use the www.mycompany.com type url to browser the
> > >>> logon
> > >>> page,
> > >>> the page's Click button is no longer working. I checked all the
> > >>> possible
> > >>> reasons I can think about, such as virtual directory, user access
> > >>> control,
> > >>> all the possible IIS and server security settings, still can't find
> > >>> why it
> > >>> doesn't work on the web server, which is installed with Windows 2003
> > >>> Server.
> > >>> Anyone can help?
> >
> >
> >
> >
Author
22 Aug 2005 5:09 PM
Dominick Baier [DevelopMentor]
Hello Sword,

aah,

this usually happens if you dont have the /aspnet_client directory in the
root of your website. this can easily happen if you move wwwroot around...

---------------------------------------
Dominick Baier - DevelopMentor
http://www.leastprivilege.com

Show quoteHide quote
> I debugged the codes, it seems ValidatorOnSubmit() function doesn't
> pass. I know it's form authentication related, but how this happens?
>
> "Sword" wrote:
>
>> Hi, Guys,
>>
>> Thanks to provide me such useful ideas. I used Fiddler to trace the
>> HTTP contents, but still can't find where the problem is. And all the
>> javascript settings are fine on both server and client sides.
>>
>> The following is the HTML page source codes, can you help me check if
>> there are any problems?
>>
>> HTTP/1.1 200 OK
>> Date: Mon, 22 Aug 2005 14:41:43 GMT
>> Server: Microsoft-IIS/6.0
>> MicrosoftSharePointTeamServices: 6.0.2.5530
>> X-Powered-By: ASP.NET
>> X-AspNet-Version: 1.1.4322
>> Set-Cookie: ASP.NET_SessionId=tzbku3fzc5f4qxbe5trauwas; path=/
>> Cache-Control: private
>> Content-Type: text/html; charset=utf-8
>> Content-Length: 3483
>> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
>> <HTML>
>> <HEAD>
>> <title>WebForm1</title>
>> <meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
>> <meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
>> <meta name="vs_defaultClientScript" content="JavaScript">
>> <meta name="vs_targetSchema"
>> content="http://schemas.microsoft.com/intellisense/ie5">
>> </HEAD>
>> <body>
>> <form name="Form1" method="post" action="Login.aspx"
>> language="javascript"
>> onsubmit="if (!ValidatorOnSubmit()) return false;" id="Form1">
>> <input type="hidden" name="__VIEWSTATE"
>> value="dDwtMTA0NDYzMTY2Mjs7bDxjaGtMb2c7Pj7Cqwwna1FAYtogb4vN8QNB1TjRqg
>> ==" />
>> <script language="javascript" type="text/javascript"
>> src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>
>>
>> <P>Log In To Your Account</P>
>> <P>
>> <span id="myMsg"></span></P>
>> <P>Email:
>> <input name="txtEmail" type="text" id="txtEmail" /><BR>
>> <span id="RequiredFieldValidator1" controltovalidate="txtEmail"
>> errormessage="Email must not be left blank"
>> evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
>> initialvalue=""
>> style="color:Red;width:168px;visibility:hidden;">Email must not be
>> left blank</span><BR>
>>
>> <span id="RegularExpressionValidator1" controltovalidate="txtEmail"
>> errormessage="Please enter a valid email address"
>> evaluationfunction="RegularExpressionValidatorEvaluateIsValid"
>> validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
>> style="color:Red;visibility:hidden;">Please enter a valid email
>> address</span></P>
>> <P>Password:
>> <input name="txtPassword" type="password" id="txtPassword" /><BR>
>> <span id="RequiredFieldValidator2" controltovalidate="txtPassword"
>> errormessage="Password must not be left blank"
>> evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
>> initialvalue=""
>> style="color:Red;visibility:hidden;">Password must not be left
>> blank</span></P>
>> <P>
>> <input id="chkLog" type="checkbox" name="chkLog" /><label
>> for="chkLog">Remeber My User Name</label></P>
>> <P>
>> <input type="submit" name="cmdLogin" value="Login" onclick="if
>> (typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); "
>> language="javascript" id="cmdLogin" style="width:80px;" /></P>
>> <P> </P>
>> <script language="javascript" type="text/javascript">
>> <!--
>> var Page_Validators =  new
>> Array(document.all["RequiredFieldValidator1"],
>> document.all["RegularExpressionValidator1"],
>> document.all["RequiredFieldValidator2"]);
>> // -->
>> </script>
>> <script language="javascript" type="text/javascript">
>> <!--
>> var Page_ValidationActive = false;
>> if (typeof(clientInformation) != "undefined" &&
>> clientInformation.appName.indexOf("Explorer") != -1) {
>> if ((typeof(Page_ValidationVer) != "undefined") &&
>> (Page_ValidationVer
>> == "125"))
>> ValidatorOnLoad();
>> }
>> function ValidatorOnSubmit() {
>> if (Page_ValidationActive) {
>> return ValidatorCommonOnSubmit();
>> }
>> return true;
>> }
>> // -->
>> </script>
>> </form>
>> </body>
>> </HTML>
>> "Dominick Baier [DevelopMentor]" wrote:
>>
>>> Hello Sword,
>>>
>>> install a tool like Fiddler (www.fiddlertool.com) and trace the
>>> traffic. maybe this give your more information.
>>>
>>> ---------------------------------------
>>> Dominick Baier - DevelopMentor
>>> http://www.leastprivilege.com
>>>> All my authentication codes are on the Click button's click event.
>>>> When I click it on the web server, nothing happened. No any error
>>>> messages, no any prompts. Just like no running codes for the event.
>>>> It seems the server doesn't run the codes at all.
>>>>
>>>> "Joseph Bittman MCSD" wrote:
>>>>
>>>>> August 18, 2005
>>>>>
>>>>> I'm not sure what exactly you are running into? Are you getting a
>>>>> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
>>>>> Windows Server 2003, ASP.Net uses the Network Service account.
>>>>>
>>>>> --
>>>>> Joseph Bittman
>>>>> Microsoft Certified Solution Developer
>>>>> Web Site: http://71.39.42.23/
>>>>> Static IP
>>>>> "Sword" <Sw***@discussions.microsoft.com> wrote in message
>>>>> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
>>>>>> I have an ASP.NET application that using form-based
>>>>>> authentication.
>>>>>> I have
>>>>>> a
>>>>>> logon page, the user can enter his user name and password - which
>>>>>> stored
>>>>>> on a
>>>>>> remote SQL server, after click the Logon button, if both are
>>>>>> correct, the
>>>>>> application will redirect the user to a welcome page. It's very
>>>>>> simple,
>>>>>> and
>>>>>> works totally fine on my localhost machine, which is installed
>>>>>> with
>>>>>> Windows
>>>>>> XP with SP2. But after I moved this application to my company's
>>>>>> web
>>>>>> server,
>>>>>> on which I can use the www.mycompany.com type url to browser the
>>>>>> logon
>>>>>> page,
>>>>>> the page's Click button is no longer working. I checked all the
>>>>>> possible
>>>>>> reasons I can think about, such as virtual directory, user access
>>>>>> control,
>>>>>> all the possible IIS and server security settings, still can't
>>>>>> find
>>>>>> why it
>>>>>> doesn't work on the web server, which is installed with Windows
>>>>>> 2003
>>>>>> Server.
>>>>>> Anyone can help?
Author
22 Aug 2005 6:31 PM
Sword
Yes, you are right, Dominick. After I copy the /aspnet_client directory to my
own wwwroot directory, problem solved.

Thanks again, you are so wonderful.

Show quoteHide quote
"Dominick Baier [DevelopMentor]" wrote:

> Hello Sword,
>
> aah,
>
> this usually happens if you dont have the /aspnet_client directory in the
> root of your website. this can easily happen if you move wwwroot around...
>
> ---------------------------------------
> Dominick Baier - DevelopMentor
> http://www.leastprivilege.com
>
> > I debugged the codes, it seems ValidatorOnSubmit() function doesn't
> > pass. I know it's form authentication related, but how this happens?
> >
> > "Sword" wrote:
> >
> >> Hi, Guys,
> >>
> >> Thanks to provide me such useful ideas. I used Fiddler to trace the
> >> HTTP contents, but still can't find where the problem is. And all the
> >> javascript settings are fine on both server and client sides.
> >>
> >> The following is the HTML page source codes, can you help me check if
> >> there are any problems?
> >>
> >> HTTP/1.1 200 OK
> >> Date: Mon, 22 Aug 2005 14:41:43 GMT
> >> Server: Microsoft-IIS/6.0
> >> MicrosoftSharePointTeamServices: 6.0.2.5530
> >> X-Powered-By: ASP.NET
> >> X-AspNet-Version: 1.1.4322
> >> Set-Cookie: ASP.NET_SessionId=tzbku3fzc5f4qxbe5trauwas; path=/
> >> Cache-Control: private
> >> Content-Type: text/html; charset=utf-8
> >> Content-Length: 3483
> >> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> >> <HTML>
> >> <HEAD>
> >> <title>WebForm1</title>
> >> <meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
> >> <meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
> >> <meta name="vs_defaultClientScript" content="JavaScript">
> >> <meta name="vs_targetSchema"
> >> content="http://schemas.microsoft.com/intellisense/ie5">
> >> </HEAD>
> >> <body>
> >> <form name="Form1" method="post" action="Login.aspx"
> >> language="javascript"
> >> onsubmit="if (!ValidatorOnSubmit()) return false;" id="Form1">
> >> <input type="hidden" name="__VIEWSTATE"
> >> value="dDwtMTA0NDYzMTY2Mjs7bDxjaGtMb2c7Pj7Cqwwna1FAYtogb4vN8QNB1TjRqg
> >> ==" />
> >> <script language="javascript" type="text/javascript"
> >> src="/aspnet_client/system_web/1_1_4322/WebUIValidation.js"></script>
> >>
> >> <P>Log In To Your Account</P>
> >> <P>
> >> <span id="myMsg"></span></P>
> >> <P>Email:
> >> <input name="txtEmail" type="text" id="txtEmail" /><BR>
> >> <span id="RequiredFieldValidator1" controltovalidate="txtEmail"
> >> errormessage="Email must not be left blank"
> >> evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> >> initialvalue=""
> >> style="color:Red;width:168px;visibility:hidden;">Email must not be
> >> left blank</span><BR>
> >>
> >> <span id="RegularExpressionValidator1" controltovalidate="txtEmail"
> >> errormessage="Please enter a valid email address"
> >> evaluationfunction="RegularExpressionValidatorEvaluateIsValid"
> >> validationexpression="\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
> >> style="color:Red;visibility:hidden;">Please enter a valid email
> >> address</span></P>
> >> <P>Password:
> >> <input name="txtPassword" type="password" id="txtPassword" /><BR>
> >> <span id="RequiredFieldValidator2" controltovalidate="txtPassword"
> >> errormessage="Password must not be left blank"
> >> evaluationfunction="RequiredFieldValidatorEvaluateIsValid"
> >> initialvalue=""
> >> style="color:Red;visibility:hidden;">Password must not be left
> >> blank</span></P>
> >> <P>
> >> <input id="chkLog" type="checkbox" name="chkLog" /><label
> >> for="chkLog">Remeber My User Name</label></P>
> >> <P>
> >> <input type="submit" name="cmdLogin" value="Login" onclick="if
> >> (typeof(Page_ClientValidate) == 'function') Page_ClientValidate(); "
> >> language="javascript" id="cmdLogin" style="width:80px;" /></P>
> >> <P> </P>
> >> <script language="javascript" type="text/javascript">
> >> <!--
> >> var Page_Validators =  new
> >> Array(document.all["RequiredFieldValidator1"],
> >> document.all["RegularExpressionValidator1"],
> >> document.all["RequiredFieldValidator2"]);
> >> // -->
> >> </script>
> >> <script language="javascript" type="text/javascript">
> >> <!--
> >> var Page_ValidationActive = false;
> >> if (typeof(clientInformation) != "undefined" &&
> >> clientInformation.appName.indexOf("Explorer") != -1) {
> >> if ((typeof(Page_ValidationVer) != "undefined") &&
> >> (Page_ValidationVer
> >> == "125"))
> >> ValidatorOnLoad();
> >> }
> >> function ValidatorOnSubmit() {
> >> if (Page_ValidationActive) {
> >> return ValidatorCommonOnSubmit();
> >> }
> >> return true;
> >> }
> >> // -->
> >> </script>
> >> </form>
> >> </body>
> >> </HTML>
> >> "Dominick Baier [DevelopMentor]" wrote:
> >>
> >>> Hello Sword,
> >>>
> >>> install a tool like Fiddler (www.fiddlertool.com) and trace the
> >>> traffic. maybe this give your more information.
> >>>
> >>> ---------------------------------------
> >>> Dominick Baier - DevelopMentor
> >>> http://www.leastprivilege.com
> >>>> All my authentication codes are on the Click button's click event.
> >>>> When I click it on the web server, nothing happened. No any error
> >>>> messages, no any prompts. Just like no running codes for the event.
> >>>> It seems the server doesn't run the codes at all.
> >>>>
> >>>> "Joseph Bittman MCSD" wrote:
> >>>>
> >>>>> August 18, 2005
> >>>>>
> >>>>> I'm not sure what exactly you are running into? Are you getting a
> >>>>> SecurityException or? On XP, ASP.Net uses the ASPNET account; on
> >>>>> Windows Server 2003, ASP.Net uses the Network Service account.
> >>>>>
> >>>>> --
> >>>>> Joseph Bittman
> >>>>> Microsoft Certified Solution Developer
> >>>>> Web Site: http://71.39.42.23/
> >>>>> Static IP
> >>>>> "Sword" <Sw***@discussions.microsoft.com> wrote in message
> >>>>> news:85AA77F9-2BE9-405C-A645-D372078B48B6@microsoft.com...
> >>>>>> I have an ASP.NET application that using form-based
> >>>>>> authentication.
> >>>>>> I have
> >>>>>> a
> >>>>>> logon page, the user can enter his user name and password - which
> >>>>>> stored
> >>>>>> on a
> >>>>>> remote SQL server, after click the Logon button, if both are
> >>>>>> correct, the
> >>>>>> application will redirect the user to a welcome page. It's very
> >>>>>> simple,
> >>>>>> and
> >>>>>> works totally fine on my localhost machine, which is installed
> >>>>>> with
> >>>>>> Windows
> >>>>>> XP with SP2. But after I moved this application to my company's
> >>>>>> web
> >>>>>> server,
> >>>>>> on which I can use the www.mycompany.com type url to browser the
> >>>>>> logon
> >>>>>> page,
> >>>>>> the page's Click button is no longer working. I checked all the
> >>>>>> possible
> >>>>>> reasons I can think about, such as virtual directory, user access
> >>>>>> control,
> >>>>>> all the possible IIS and server security settings, still can't
> >>>>>> find
> >>>>>> why it
> >>>>>> doesn't work on the web server, which is installed with Windows
> >>>>>> 2003
> >>>>>> Server.
> >>>>>> Anyone can help?
>
>
>
>