Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

session("userid") equivalent 2

Status
Not open for further replies.

G00GLER

Instructor
May 17, 2005
57
US
is there an easy way to find out who on the network is visiting a webform (.net) like in ASP.

thanks.
 
Using Windows Authentication with my intranet applications, I can use User.Identity.Name to identify user names.


--
Not until I became a Network Administrator did the error message "See your Network Administrator for assistance" become petrifying.
 
What did you use in ASP to set session("userid")? I ask as this is just a session wide variable and unless you set it, it wouldn't exist and certainly wouldn't return the name of the current user.

--------------------------------------------------------------------------------------------------------------------------------------------

Need help finding an answer?

Try the search facility ( or read FAQ222-2244 on how to get better results.
 
ca8msm good point, session("userid") was created in an include done many years ago. thanks for pointing that out.
 
Mike555 do i need to have network configure IIS.. disabling anonymous access in IIS and enable IWA, Digest or Basic. Have you done
that?

will this screw up any of my asp intranet applications?
 
I was just wondering how you actually populated that variable, as it may be that you could do it the same way (unless of course you can utilise the solution from Mike555).

--------------------------------------------------------------------------------------------------------------------------------------------

Need help finding an answer?

Try the search facility ( or read FAQ222-2244 on how to get better results.
 
It shouldn't mess up your other applications (if they are running on the same web server) as you can define the security for each application.

You will have to go into IIS and select the properties of the ASP.NET application, select the Directory Security and set up Windows Authentication there.

--------------------------------------------------------------------------------------------------------------------------------------------

Need help finding an answer?

Try the search facility ( or read FAQ222-2244 on how to get better results.
 
ca8msm can correct me (I'm sure) If I'm wrong, but I think...

If you have anonymous access enabled, only anonymous users (whom the application cannot outright identify) would show in User.Identity.Name. Having anonymous access enabled would not automatically make user's unidentifiable via User.Identity.Name. IIS Virtual Directory accesses may be configured on a Virtual Directory-by-Virtual Directory basis and therefore modifying the settings of one Virtual Directory will not screw-up other Virtual directories.


--
Not until I became a Network Administrator did the error message "See your Network Administrator for assistance" become petrifying.
 
CORRECTION -

If you have anonymous access enabled, only anonymous users (whom the application cannot outright identify) would NOT show in User.Identity.Name. Having anonymous access enabled would not automatically make user's unidentifiable via User.Identity.Name. IIS Virtual Directory accesses may be configured on a Virtual Directory-by-Virtual Directory basis and therefore modifying the settings of one Virtual Directory will not screw-up other Virtual directories.


--
Not until I became a Network Administrator did the error message "See your Network Administrator for assistance" become petrifying.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top