Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    ASP




ASP Effective User ID


I've been looking for information on how to figure out
which active user ID a ASP script runs as.
The normal Request.ServerVariables dont do the trick.
For example if the anonymous browsing is set to the user "test". I would like to know how to retrieve that the user is actually "test".




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Effective Search Result
we have a MSAccess database of products with titles, short descriptions, long descriotions, bulletpoints etc contained for each product. we currently search the database looking for the target keyphrase within the fields, but this doesnt give any accurate results as for example a product that is compativle with "widget 1" is shown before "widget 1" . anyone know of a process that will give us better, more relevant search results?

ADSI - Trying To Enable A User - The User Add Works Very Well
I have written an ASP.NET 2.0 application that uses Active Directory or ADAM
to manage account users - the site has a page that allows people to create an
account (much like any site). The page populates the AD with all the
information and the user account but I am unable to enable the account.
Microsoft has information on how to do that here -->
http://msdn.microsoft.com/library/d...ting_a_user.asp
(the sample is for Visual Basic) - and I am unable to complete the bottom
portion of the script. Can some one point me in the right direction - or can
you tell me how I can add a snippet of VBscript code to an ASP.NET page.

I am using the Active DS Type library - not sure why there are multiple ones
(System.DirectoryServices) but it is rather confusing - I seem to accomplish
one thing with one and another with the other (they did have trouble
co-existing however). Anyway my script works very well but I am not able to
access the properties required to enable the account.

Here is a simple version (no error checking) of the code.....

Mail User Info To User
how to go about setting up an asp script or flash action script to take the input from a user of his/her username and password then send an email to the user with the information. I am able to do all of this but the problem is that the users pc is the one sending the email. I want the server to send the email instead.

Can't Get User's NT Log-in
I'm having a real tough time getting a User's NT login after they
submit a form.

I have Anon. Login disabled. I'm using Digest Authentication (although
I've tried everything).

Every time I run the page, I get a blank string instead of the
requested information.

The information is in a hidden field, with the value set to:
<%=Request.ServerVariables("LOGON_USER")%>

The icing on the cake is that when I run this on my PWS, I can pull the
information and it shows up in the SQL DB I'm sending it too. But, when
put on our live box, it doesn't show up. The setting on each box are
exactly the same.

User Ado.net
I have a classic ASP program running on a server in the DMZ. I need to consume a web service so that I can consume data from that web service. However I am not able to call the web service from the DMZ since the server can not send messages out on the
internet.

Thus, I need to send the call to another server running within the internal
area of the company's internet. I need to send this message to an IIS server
and then from the IIS server call the web service. I was thinking that I need
to call the service on the IIS server with an ADO.NET connection. This
ADO.NET connection object would be generated just long enough to call the web
service, get a response from the web serice, and return the message to the
server running in the DMZ.

Let me know if you think this would be a good solution and tell me how you
would setup this interface. (Should C#.NET or Visual Basic.NET be used or
some other lanaguge.)

Also after this solution works, I will need to implement this similar type
of solution to call other web services.

User NAME
does anyone know a way to show a users USER name instead of just there login name
its for a school intranet currently we retrieve a lot of data based on the login name by using this script:

[code] <%=Request.ServerVariables("LOGON_USER")%>

it would be a lot more functional if i could pull the full name, we are using Active Directory 2003 and iis6, and all the logins have the full username inputted in the AD?

ASP.NET User In AD
It seems that the ASP.NET user in AD has been deleted. How can I get it
back?

ASP Add User
I'm developing an ASP form registeration system. The details of the form must be added to a text file not the tradional database.
Each time a new user adds a record it should be added to the list at the bottom to the previos adder.
Does anyone have a script sniplet of how i could do this.
Remember details from the form i.e. name, firstname should be added to a text file...

User ID
How can I get the user information of the user as which the ASP script is being run?

Get User Name With WIA
I am new to .NET and I am trying to get the user name from a kerberos ticket and I have no idea how to do that. There seems to be some ability to do it using WSE 2.0 but I cant really see why there is not an easier way. how to do this?

User
I have a admin-page wich is username and password protection and Microsoft Access database with table called "member" and fields "username and "password" in it. I wan't to have a welcome message when user is successfully logged in so he/her can see for example "Welcome Chris". How to I do this?

Create New User Using IIS/ASP
I'm running IIS5 on a Win2K server, and I want to have an ASP page that
creates new users. I have some simple code to test this, but am getting
a "500" error when I run it. The ASP looks like:

<%

strDomain ="Foo.com"
strUser ="Foo1"

' Create new user with password
Set oDomain = GetObject("WinNT://" & strDomain)
Set oUser = oDomain.Create ("User", strUser)
oUser.SetPassword = "password"
oUser.SetInfo
%>

Just for this testing, I've added IUSR_machinename to the Administrators
group, but am still getting the 500 error.

Limit User
How can i limit the number of users on my .ASP page, i want only one user to
be using the page at a time,

The query i have on my page is big and takes a lot of my system resources.

One User One Page
I have a login page. and more users. Let's call them users A, users B and Users C. Users A can only access page A, users B page B, ... All the pages uses the same DB, but different tables (table A, table B, table C).

User Regisitration
I surveyed 1000 people and 884 of them said that they prefer forms that are filled out in sections (multiple pages) instead of one long form. I am trying to do that with my site. Currently the way I was planning it was:

register.asp - sets up username >>
stage1.asp - checks for unique username >>
stage2.asp - personal info >>
stage3.asp - more personal info >>
stage4.asp - even more personal info >>
stage5.asp - yet more personal inf >>
stage6.asp - employer info >>
stage7.asp - Finished

When users go to register, I want to:
select a user name and password, then make sure the user name isnt taken, make sure the passwords match, collect personal info over a few pages, then finish.

I would like to do all this only utilizing the register.asp and possibly a process page. Anyone have any links or tutorials on creating pages like this.

User Variable
Do you know how to get windows login variables (i.e. the LOGON_USER server
variable) from ASP without having to fill in the challenge response message
box that automatically appears when you configure IIS to Integrated Windows
Security for a particular site? I don't want users to have to log in again
to the site as they have already logged in to windows but I want to use
their username on the back end to verify permissions. Is it possible?

NT User Authentication - Is It Possible?
I'm facing a situation where my team leader wants me to create some ASP code that will pull the user's ID (which is no problem - request the LOGON_USER server variable) and THEN pull that user's NT Permissions to determine what kind of permissions the user will have when he/she comes onto the website. There is to be no logon screen at all. The permissions cannot be determined via a database or through cookies. Only NT Authentication can be used.

I have a small hunch that the HTTP_AUTHORIZATION server variable might provide a clue, but the value of that variable is a bunch of (encrypted?) gibberish that means nothing to me, except probably the NTLM part at the beginning. Is there a way to decode the value of that variable into something coherent that I can use in my code?

How Can I Allow A User To Logout And...
I have a button that would allow a user to logout of the program, how can this be done? Also, how can I allow the program to logout and terminate if not used after so many minutes?

User Logs
I have five forms in my website, what I'm trying to accomplish is to track the users history. For an example if the user save their information on the first page and exit the system; Whenever that user logs back in I want them to be where they left off. I hope I'm clear on what I need help with. Does anyone know how to accomplish this task?
P.s I'm using Deamweaver to create my page.

User Management
What I am trying to do is to develop a dhtml based chat system.
So far everything is working as planned, took me over 6 hours to get it
working, but I am pleased with the results, it is comparable to java
chat. With no page refresh.
My problem is
How do we manage which users are online on chat and which are not.
I do not wish to use any application variables nor do i wish to use
session variables. i am trying to avoid the 2
Either the user may simply close the chat window, or he might just go
and browse another site. Either way I do not get to write the even to
the database.

Redirect The User
I want to redirect the user to the page that they came from?could someone give me the code

User On Form
I have created a form with simple fields such as address and phone number. I would like to, in real time, take the value a person puts in for name (ex. John Smith), check a database to see if he is there, then to populate his address fields and phone number to save the user the trouble of typing it in repeatedly.
Any ideas how to go about this? I created a button for the user to "look up" to see if his info is saved but cant seem to get the syntax write. I have written similar code for the information to be put in the database, and it works, just need to retreive it while the user is on the form.

Adding New User
How can I add a new user on my server using ASP?
User example: myserver/user1

Active User IP's
I just made a simple thing on my page that says Active Users: and the number by adding 1 to session_onstart in global.asa. It seems to work.
Is there a way I can have this store IP's of the active user, etc without using a database to store the stuff in?

User Registration
Previously I have canvassed a few way to get a registration code from one server to another - checking the results of the search and returning a function in a string tro be executed at the end. Well that worked until one of my beta testers decided that he would fiffle and get around the syste mmm...

Get User Details
I'm trying to get a very simple task to work. Using the users login name
(gained from IE) I want to get their full name from AD (Win 2k and 2003 AD
domain).I'm using this ASP code on the IIS server:

usr=mid(request.ServerVariables("LOGON_USER"),8)
Set User = GetObject("WinNT://domainname/" & usr & ",user")
response.write "Name is " & User.Fullname
set usr=nothing

This code works fine when run on the server direct using wscript, but when
served by the web server I get the error:

Active Directory (0x80070005)
General access denied error


Prompting To The User
i was asked to
"
Write an ASP page that prompts a user to enter the value for the radius of a
circle then calculates its area (Area = &#8719; * (radius)2) and another ASP page that
also prompts the user to enter the radius and then calculates the circumference
(circumference= 2 * &#8719; * radius ). Both pages should access the value of &#8719; (&#8719; =
3.142) stored in the application state."

*** my problem is in prompting to the user i cant prompt a window in the asp script and if i prompt the window from the javascript i don't know how to send the value to the asp script.

Get User Info
My web site is windows authenticated.
When someone connect to my site, I get his SID with a small active X object
which uses OpenProcessToken and GetTokenInformation (token user etc ...

But now, I also need the SID list from AD user object SIDHistory. (when a
user is moved across domain).

User Other Than IUSR
I'm writing a script to do a simple directory listing and parse, and that is all working fine. However I run into a problem when I try to create a text file to write it into.
Specifically:

Microsoft VBScript runtime error '800a0046'
Permission denied
(PATH)/indexer.asp, line 15

Where line 15 is the line where I'm trying to create the text file.
This is probably because the IUSR_ account permissions aren't set to allow writing. I'm also running this on a server where I do not have the rights needed to change the However, I do have an account with full permissions that I use for accessing the website from Frontpage.Is there a way I can use my other account to run the script, or at least that part of it?

Disallowed User
how can I disallowed or disable user to
used the back button or option in their browser for security reason

Retrieving User From Db
i have a checkout page which lists the user and what they have puchased. however, theres a problem with this page as I cant retrieve the user from both tables in my db, Customer & Corporate. The error message that I received is:

Microsoft VBScript compilation (0x800A03F4)
Expected 'If'
/shop/check_out.asp, line 412, column 3
End
--^

which refers to the red line in the code below: Code:

User Input
I'm using the following code and if someone enters something in the "instructions" field with characters -"', - it causes the SQL statement to change using those characters.

Dim strSQLadd
strSQLadd = "INSERT INTO orders" &_
"(form_number, orig_number, order_loannum, order_date, order_time, order_address, order_city, order_zip," &_
"order_contact, order_lockbox, order_agent, order_homephone, order_workphone, order_cellphone," &_
"order_legal, order_instructions, order_deliver, order_pay, order_altmail, order_appraiser) " &_
"VALUES (" & FormNum & "," & OrigNum & ",'" & CaseNum & "','" & OrderDate & "','" & OrderTime & "','" & pave & "','" & City & "','" &_
Zip & "','" & Owner & "','" & LockBox & "','" & Agents & "','" & BorHmP & "','" & BorWrkP & "','" &_
BorCellP & "','" & Legal & "','" & Instruct & "','" & DeliverType & "','" & Payment & "','" & AltMailType & "','" & AppName &"');"
objconn.Execute (strSQLadd)

Impersonating User
I have a asp.net application, which control virtual directory, we want any
user to access and we do not want to use windows authentication(we do not
want windows authentication dialog) or forms authentication(as we do not
want any login page). However we want to impersonate the user.

Impersonating A User
I am trying to log on to SQL sever in an asp.net application.
My problem is this: I want to use a specific windows log in for SQL server,
In order to do this I use windows integrated security.
Currently the user that is being logged into SQL server is the currently logged on
windows user. I need to know if there is a way to tell IIS to impersonate a user
programmatically.

New User In DB Default
If a new user is added to the database through a webform, and they would usually have immediate access to member only services, is there a way to make them nonactive in a MS access db until an admin activates them?

User Inserted
I have a form where people from around the world will enter their address. As you know, addresses from around the globe vary so darn much. I thought that instead of a form with text boxes for such things as city, zip, street 1, street 2, etc., I could use a text-area. That being said, if someone entered in an address in a text box such as this:

Joe User
121 E 209th
Euclid Ohio
44123
United States

Could I take that and on the insertion into a database insert a <br /> where appropriate?

USER DSN Not Working
I am connecting MS Access Database from my ASP Page and trying all possible options. The DSN-less way works fine, even the System DSN and File DSN works fine, but the problem arises when I try to use the USER DSN. It just doesn't work. The error message I got is "Data Source Name not found and no default driver specified" It seems its looking for the system DSN only when I use the following code :

SET Conn = Server.Createobject("ADODB.Connection")
Conn.open "DSN=myUserDSN"

I have created the user DSN called "myUserDSN" successfully under the USER DSN tab of ODBC drivers. So why it doesn't work?

User Registration
I know this question in general has been asked before and various answers have been given, however is my case, none of the answers I found really apply.
This is the scenario - I have written a very small commercial program. This product will be available for payment and download electronically.
I generate a registration code at the time the program is paid for. And that registration code is stored in an access database on my web (external ISP) which is in a directory with read write modify permissions having been set. At the time the registration code is supplied, I log the IP address the user came from.
Now my question is this - when the user sets up the program (an asp application) the registration code is entered and stored in the users database. Now when the code is accessed, I would like the code on the users machine to access my database, and check the user registration details are the same - if they are not the same then the program becomes limited in its use. So what I am asking is how do I programatically allow external access to my database from another machine to achieve this ?

ASP User-friendly IDE
can anyone tell me a user-friendly IDE for ASP? (not
asp.net). Is interdev has intellisense in it?

Time User
is it possible to time how long a user has spent on a page and when the user exists the page an new entry is added to a database.

User Details
I have a working members code now where members can sign up, login to a protected page and log out. I now want to personalise each members login so when a member logs in it says welcome [username] etc and then when the use logs out it says 'thanks [username] you have logged out'. I tried to query my database but it doesnt work.

Best Way To Remember Where User Came From?
I am not sure if there is a technical name for this method or process.

I am working on a project in ASP and MS Access. I would like to add Favorites feature to the site. User clicks on 'Add to Favorite' link, an ASP script is processed, if user is not logged in in takes them to a login page which redirects to the default home page.

I want to be able to send the user to the same page they came from after they have logged in and their item saved in Favorites, in this case would be a details page which resulted after a search.

User Login
I have fields on a datebase called user_info with fields name, acctid, pw and blah blah blah. On the website I asked the visitors to input 0000 if they were not a client. I don't
really understand how if...then, if...else works. How can I get it to validate the name, pw, acctid

and if it equals 0000 to i guess (request.redirect "/client.bronzefactory/")?

The next thing is... the client page, for them to sign up if they haven't yet. On the database their acctid is going to be listed but nothing else. I'm guessing I have to use the update syntax right?

How would that work? I enter aa123456 and it does a = seach and redirect to a page where they fill it out and sumbits a update right? Is the statement something like this "UPDATE user_info SET name, pw= '" & name &'", '" & pw &'" where acctid= '?' <---how do i get the acctid there?

How Do I Emulate A User?
I need to write an ASP app to upload files to a separate, non IIS, server. All users will have read-only access except a service account. I need my ASP app to emulate this service account in order to allow the uploads to be written the the directory.

Count By User
Here is my SQL code in my asp page that calls the number od downloads made from tbldownload, but I want to get specfic with the number of downloads by user from tbluser

Download count sql
Set rsDownloadAdmin = Server.CreateObject("ADODB.Recordset")
strSQL = "SELECT downloadid, downloadtitle, downloadcount FROM tbldownload ORDER BY DownloadID"
rsDownloadAdmin.Open strSQL, adoCon

This works fine , I just want to add the statment and syntax that will show downloads by spefic user or user id

Log On A User Via ASP Script?
I would like to protect a file so that only certain users could download it
from my website. It would be very easy for me to simply use IIS Admin to
remove anonymous access to that file and to create a new account on the web
server and give those account credentials to my users. That would prohibit
people from directly accessing the file unless they knew the username and
password.

My question is this: Is there a way for me to write an ASP page that
"embeds" these logon credentials into a hyperlink to a page, or that
automatically logs a user on with hard-coded credentials?

What I'm thinking is that I can authenticate my users against my own app's
database, and then if successful I could perform a behind-the-scenes basic
Windows logon (with all users using the same Windows account) to actually
provide the file to the users. (In my case, my user accounts are stored in
SQL--they are not windows accounts.) Code:

User Name And Password
Is it possible to create a blog on Asp?how can i create a page where you can't access unless log in by user name and password. Link to tutorial works just fine for me!

User Logout
I want to have a logout page that gives members the option to logout.
Is it just a case of doing a simple session.end, or how do I go about it

User Online
I have a login script and everything, I just have one problem. The thing is, is that I want to check how many users are online. It is very simple to do that, but is there a way to check when their user-session ends, or something? In the database all it is is a simple yes or no under "online" and if they are logged in it goes to "yes" and if they access a page while logged out, there is no way to check if they are online or not.
How should I go about doing this?

And if you give me a code, can you please tell me how it works so I can easily modify it(It's just that it'd take a lot less time with you explaining it, than me figuring it out All I need is a simple wording


Copyright © 2005-08 www.BigResource.com, All rights reserved