|
Home > Archive > IIS Server Security > August 2004 > ASP scripts not running
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]
| Author |
ASP scripts not running
|
|
| Phil Taylor 2004-08-25, 5:58 pm |
| Hi All,
Help!!
We have installed the System Update Service on our server in order to
distribute Windows updates to the 60 pc's on the LAN. Now we have
problems with our intranet applications.
The SUS program and associated files were uninstalled and the IIS
lockdown wizard used to restore out original settings. Most of the
apps now work but the ASP programs fail to run. It seems to be a
session error as the script debugger displays a session mismatch box
and highlights the following text
[vbcol=seagreen]
<%
session("OpenAdmin") = False
session("Notify") = False
session("AdminEmail") = ""
session("AdminPass") = ""
Dim strConnect
strConnect = "Driver={Microsoft Access Driver (*.MDB)}; DBQ="&
Server.MapPath("Tracking.mdb")
set objRec = server.CreateObject("ADODB.Recordset")
if request.Item("txtUsername") <> "Please Select" then
if request.item("txtPassword") <> "" then
strSQL = "SELECT * FROM Logon WHERE Username='" &
request.Item("txtUsername") & "'"
objRec.open strSQL, strConnect
if request.Item("txtPassword") = objRec("Password") then
session("AdminPass") = objRec("FullName")
session("AdminEmail") = objRec("Email")
if objRec("Notify") = True then session("Notify") = True
if objRec("Admin") = True then session("OpenAdmin") = True
end if
objRec.close
if session("AdminPass") <> "" then response.redirect ("Tracking.asp")
if session("") = "" then strPassword = "<font
color=red><strong>Password incorrect. Please try
again.</strong></FONT>"
end if
end if
strSQL = "SELECT * FROM Logon ORDER BY Username"
objRec.open strSQL, strConnect
Dim strUsername
do until objRec.EOF = true
strUsername = strUsername & "<option>" & objRec("Username")
objrec.MoveNext
loop
objrec.Close
%>
My knowledge of ASP ans IIS is limited, please help....
TIA
Phil
| |
| Ken Schaefer 2004-08-25, 5:58 pm |
| In IIS Manager, right-click on the website or web application root in
question and choose Properties
On the Home Directory (or Directory) tab, click the "Configuration" button
On the "Options" tab, ensure "enable session state" is checked
Hope this helps.
Cheers
Ken
"Phil Taylor" <ptaylor404@gmail.com> wrote in message
news:b39a7776.0408250237.336ec501@posting.google.com...
> Hi All,
>
> Help!!
>
> We have installed the System Update Service on our server in order to
> distribute Windows updates to the 60 pc's on the LAN. Now we have
> problems with our intranet applications.
>
> The SUS program and associated files were uninstalled and the IIS
> lockdown wizard used to restore out original settings. Most of the
> apps now work but the ASP programs fail to run. It seems to be a
> session error as the script debugger displays a session mismatch box
> and highlights the following text
>
>
> <%
>
> session("OpenAdmin") = False
> session("Notify") = False
> session("AdminEmail") = ""
> session("AdminPass") = ""
>
> Dim strConnect
>
> strConnect = "Driver={Microsoft Access Driver (*.MDB)}; DBQ="&
> Server.MapPath("Tracking.mdb")
> set objRec = server.CreateObject("ADODB.Recordset")
>
> if request.Item("txtUsername") <> "Please Select" then
>
> if request.item("txtPassword") <> "" then
>
> strSQL = "SELECT * FROM Logon WHERE Username='" &
> request.Item("txtUsername") & "'"
>
> objRec.open strSQL, strConnect
>
> if request.Item("txtPassword") = objRec("Password") then
> session("AdminPass") = objRec("FullName")
> session("AdminEmail") = objRec("Email")
> if objRec("Notify") = True then session("Notify") = True
> if objRec("Admin") = True then session("OpenAdmin") = True
> end if
>
> objRec.close
>
> if session("AdminPass") <> "" then response.redirect ("Tracking.asp")
> if session("") = "" then strPassword = "<font
> color=red><strong>Password incorrect. Please try
> again.</strong></FONT>"
> end if
>
> end if
>
> strSQL = "SELECT * FROM Logon ORDER BY Username"
>
> objRec.open strSQL, strConnect
>
> Dim strUsername
> do until objRec.EOF = true
> strUsername = strUsername & "<option>" & objRec("Username")
> objrec.MoveNext
> loop
>
> objrec.Close
>
>
> %>
>
> My knowledge of ASP ans IIS is limited, please help....
>
> TIA
>
> Phil
| |
| Phil Taylor 2004-08-25, 5:58 pm |
| Thanks Ken.
Everything is up and running fine now. I seem to have learned a lot
about asp, cookies and iis today..... ;-)
Phil
"Ken Schaefer" <kenREMOVE@THISadOpenStatic.com> wrote in message news:<u5sNFFpiEHA.3476@tk2msftngp13.phx.gbl>...[vbcol=seagreen]
> In IIS Manager, right-click on the website or web application root in
> question and choose Properties
>
> On the Home Directory (or Directory) tab, click the "Configuration" button
>
> On the "Options" tab, ensure "enable session state" is checked
>
> Hope this helps.
>
> Cheers
> Ken
>
> "Phil Taylor" <ptaylor404@gmail.com> wrote in message
> news:b39a7776.0408250237.336ec501@posting.google.com...
|
|
|
|
|