Link to home
Start Free TrialLog in
Avatar of alexisbr
alexisbr

asked on

Server Variables LOGON_USER returns no value from ASP

HI!  When I run the code below, I see "You are" and not the logon name.  Does anyone know why?
<HTML>
<BODY>
      You are <%=Request.ServerVariables("LOGON_USER")%>
</BODY>
</HTML>
I have read posts on this subject for the last hour and can't figure out what I'm doing wrong.   In IIS, Enable Anonymous Access is checked and the logon name is IUSR_OURMACHINENAME.  Integrated Windows authentication is checked.  We are running Windows 2003 server, ASP Classic and SQL Server 2005.  I am trying to get the AD group of the user so I can display a menu on the intranet (not external site) based on their group without the users having to ask users to log in via a login form.  Any ideas?  I have seen so many posts from people doing the same thing but they were able to see the results of the Server Variables.  When I looked at WIndows Firewall as one of the posts I reviewed suggested, I got a message saying the WIndows Firewall Service wasn't even started.
Thanks,
Alexis
ASKER CERTIFIED SOLUTION
Avatar of hongjun
hongjun
Flag of Singapore image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of alexisbr
alexisbr

ASKER

Thanks, Hongiun.  How will unchecking Anonymous Access affect existing users?  We have hundreds of users on this intranet and I don't want to mess up their access.  Integrated Windows Authentication is already checked.

Alexis
We unchecked Anonymous Access.  However, it caused login problems for some users so we had to check it again.  Do you have any suggestions?  Is there another way to tie Active Directory users to SQL Server logins so I can restrict datasets based on the logins?  I already set up the users in SQL Server based on their AD group but now I need to tie that to that to the ASP pages.
Thanks,
Alexis
We decided to go another route because just unchecking anonymous access caused other problems.  I didn't hear back on any other solutions so we are going to have to set up our own login logic and force the users to log in instead of using Active Directory setup.