Logging off Windows 2000 from IIS

F

Fox

I will be traveling and I will need to show someone a
secure folder in an IIS website and I will be on a public
computer. When we are done, I will need to be able to log
off so no one else using that computer will find
their way into that part of the website. The security is
Windows authentitication using Clear Text.

Can ASP log me off. If so I will need to code this before
I leave. Can anyone point me to where I can get some
examples of code to do this ?

Thanks
Fox
 
F

Fox

Will it suffice to just end the session ?
How should I go about doing that.
I have never used code to end a session ?

Fox
 
R

Ray at

The only way to do this is to close the browser, because even if you kill
the session, IE will be "nice" and re-send your credentials if you were just
logged in. Okay, there is one other ~possible~ solution, and that is to
disable the account at the end of the session. This would require something
like, eh,


logout.asp:

<%

sUser = Request.ServerVariables("LOGON_USER")
Session.Abandon()
Response.Redirect "someAnonymousPath/page.asp?u=" & sUser

%>

And then in someAnonymousPath/page.asp:

<%
Dim sUser, oShell
sUser = Request.Querystring("u")
Set oShell = Server.CreateObject("WScript.Shell")
oShell.Run "cmd.exe /c net user " & sUser & " /active:n"
Set oShell = Nothing
Response.Redirect "somewhereelse.asp"
%>

This would require your IUSR account to have admin rights. This whole
suggest is unorthodox, but maybe you'd be cool with it if you just need
something setup temporarily.

Ray at work
 
F

Fox

That's an interesting solution.
But the Admin rights, is a bit more than I can handle (G)
If closing the browser will do it, then I guess that is fine.
I've never tested that remotely. I was thinking that on my
network, it lives beyond closing a browser, but now
that I think of it, I was remembering wrongly. For me its
probably been that I have too many browser windows open
at once.

thanks,
Fox
 

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,139
Messages
2,570,804
Members
47,351
Latest member
LolaD32479

Latest Threads

Top