473,320 Members | 1,916 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Windows authentication with Signout

I have a web application which uses Windows Authentication for user
authorization.
I would like to give the user a way of logging out, instead of just
closing the browser. Basically I want a Signout option, as used with
Forms Authentication and FormsAuthentication.Signout();

But how would I do that?

I have attempted the following:

GenericIdentity ident = new GenericIdentity("", "");
GenericPrincipal prin = new GenericPrincipal(ident, new string[]{});
HttpContext.Current.User = prin;

Session.Abandon();
Response.Cookies["ASP.NET_SessionID"].Value = null;
Response.Redirect("default.aspx");

Without luck.
What am I doing wrong?
Is what I want possible?
If yes, how?

--
Thomas Due
Posted with XanaNews version 1.16.4.6

"Supreme excellence consists in breaking the enemy's resistance without
fighting."
-- Sun-Tzu
Nov 18 '05 #1
0 1141

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Rob | last post by:
I have an ASP.NET application that uses forms-based authentication. A user wishes to be able to run multiple sessions of this application simultaneously from the user's client machine. The...
2
by: Angel | last post by:
I have a problem when I signout of FormsAuthentication. When I signout I would like to go o a certain page not the login page. I have the following code Session.Abandon( Response.Cookies.Clear(...
1
by: Andy Fish | last post by:
Hi, I have an asp.net web app whereby I authenticate the user with Forms Authentication and store details about him in the session. I want to be able to catch an event when the users...
5
by: oakleyx | last post by:
Hi, I'm using asp.net form authentication. The problem i'm having is when my cookie expires it redirects me to the login page, so I log in again and it brings me to the page that I was on last...
10
by: Will Gillen | last post by:
I have an ASP.NET application that is using Windows Integrated Authentication (IIS) (as opposed to Forms Authentication). When the user first logs into the application, IIS prompts the user for...
18
by: Rippo | last post by:
Hi I am using role base forms authentication in asp.net and have come across a problem that I would like advice on. On a successful login a session variable is set to identify a user. This is...
3
by: JMUApache | last post by:
Hi: I have got a problem with FromsAuthentication for many days. I use "Forms" Authentication in my ASP.NET Web Froms, and I find that I can't singout.... Some Code Here: //In my...
4
by: mkhawley | last post by:
hello everyone, I am trying to make session out when I click logoff button using windows authentication. Could anyone help me out with this issue, please? Thanks in advance!
1
by: gnewsgroup | last post by:
I am using forms authentication for a web application. Like many other member web application, my web application prints out Welcome! John Doe (Logout) on the top right corner of each...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.