Solved

login & password

Posted on 1997-07-24
6
230 Views
Last Modified: 2013-12-25
I use Microsoft Information Server 3.0 (Windows NT4.0+NTFS).
I have some folders not for everyone. So when I get access to this restricted folders I need to enter login & password.
In one of my web pages in this folder I have a form which has CGI as an action. The question is: Can I use this login & password in my CGI script? How can I do it? I use Borland C++ 5.0. I suppose that I can get login from "REMOTE_USER"
environment variable. But what about password?
0
Comment
Question by:sto072097
6 Comments
 
LVL 5

Expert Comment

by:icd
ID: 1829375
I don't have the answer to this question, but I have seen several queries similar to yours.

UNIX uses the .htaccess method which does not map over onto NT, as I understand it any equivalent method on NT requires an NT type login account. The REMOTE_USER does not work on NT as it does on UNIX.

0
 
LVL 2

Expert Comment

by:Philippe
ID: 1829376

Remote user doesn't work with most browsers.

 Philippe

0
 
LVL 2

Expert Comment

by:n3mtr
ID: 1829377
For Philippe: that's not right Remote_user will be available on most unix hosts after the user logs in(as required by .htaccess). You are prabably thinking of http_from which was designed to give the users email address.(don't worry most browsers don't use this)
for sto: Why would you need the password?  They have already been authenticated by the system.  If they are accessing your script, they have access, and you can use remote_user to see who it is(if you have more than one user).  If you don't have more than one user don't bother checking it at all.
I don't know about NT; icd might be right about remote_user not working.  There may be some other way to find out who has logged in.
0
Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

 

Author Comment

by:sto072097
ID: 1829378
For n3mtr: My script works with Interbase database so I need password for Interbase authentication.
0
 
LVL 1

Expert Comment

by:buemoh
ID: 1829379
sto - that's only a small idea:

Have a look at the WindowsNT IIS helpfiles, because some w3 servers need special naming of the cgi. (WebSite do so, a cgi, which should get the username and password have to start with a "$").

If WindowsNT and IIS doesn't gave you any possibility to get the password, generate one with the username and a string stored in the cgi. - I do this on my WindowsNT IIS 3.0 machine, because I didn't find out how to get the password.

By the way, I'm programmin with Borland Delphi 2.x and I wrote a component supporting the CGI interface - it's free.

0
 

Accepted Solution

by:
ernst earned 100 total points
ID: 1829380
you can't get the password, because the password is encrypted
in one direction.  You need to store the password somewhere
that you can retrieve it based on the userid, which you can get
from the REMOTE_USER environment variable.  The REMOTE_USER
variable is available on all browsers that can go to a page with authentication.  In otherwords, if you can't get the REMOTE_USER variable, they can't see your page, so it doesn't matter.  I use
a database table with the user and password stored in it.  
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

If you get a (Blue Screen of Death), your system writes a small file called a minidump. Your first step is to make certain your computer is setup to record memory dumps. Right click My Computer, choose properties. Click on the advanced tab, an…
In this tutorial I will show you how to make a simple HTML bar chart with the usage of WhizBase, If you want more information about WhizBase please read my previous articles at http://www.experts-exchange.com/ARTH_5123186.html (http://www.experts-ex…
Learn the basics of lists in Python. Lists, as their name suggests, are a means for ordering and storing values. : Lists are declared using brackets; for example: t = [1, 2, 3]: Lists may contain a mix of data types; for example: t = ['string', 1, T…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question