Ask a Question related to ASP.NET Security, Design and Development.
-
NWx #1
User details in authenticated page
Hi,
I implement forms authentication, and once authenticated, I want to display
user name in a control.
I created a user control, placed on header of every page, and it contains a
label control I want to use to display username of currently logged user.
Do I have this info available in every page? How?
Thank you.
NWx Guest
-
accesing AD from an ASP.NET app when user has been authenticated via AD cert. mapping
hello forum! I am developing an ASP.NET web application which interacts with AD. Client/User authentication must be via AD certificate mapping,... -
How to allow authenticated user to impersonate
If you are running under W2000, you must add the "Act as part of the operating system" privilege to the account that will try to impersonate. On XP... -
Can I force 401 error when user not authenticated?
Currently I have succesfully implemented role-based folder security using roles and web.config in each folder. This works great - if a user is not... -
impersonating windows authenticated user?
I have a asp.net web application that i wrote for internal use in my company. The problem i'm having is being able to test the application as other... -
Terminating a authenticated user
Hi, 1. How can I "terminate" an authenticated user? (I would like the server to redirect the user to the login page again. I'm using "forms... -
Joe Kaplan \(MVP - ADSI\) #2
Re: User details in authenticated page
If your forms authentication is designed properly, then the HttpContext.User
property contains an IPrincipal object with an Identity property whose Name
property should be the name of the user. Thus you should be able to do:
Page.User.Identity.Name or Context.User.Identity.Name to get the user's name
from wherever in your code.
Joe K.
"NWx" <test@test.com> wrote in message
news:u3KHyaK8DHA.2760@TK2MSFTNGP09.phx.gbl...display> Hi,
>
> I implement forms authentication, and once authenticated, I want toa> user name in a control.
> I created a user control, placed on header of every page, and it contains> label control I want to use to display username of currently logged user.
> Do I have this info available in every page? How?
>
> Thank you.
>
>
Joe Kaplan \(MVP - ADSI\) Guest



Reply With Quote

