I assume you are using Basic AUTH here, right? Then send the username/password combo like this..


http://myusername:[EMAIL PROTECTED]/

Obviously, this kind of puts the username/password combo out there is clear text for all to see. However, that happens even with normal Basic AUTH. Base64 encoding isn't encryption. If this is a concern, then use SSL with Basic AUTH.

Jake

At 08:58 PM 7/10/2003 -0700, you wrote:
Hi,
In client side i wrote a php script trying to invoke a cgi script in web server


$fp = fsockopen (http://webserver, 80, $errno, $errstr, 30);
if (!$fp) {
echo "$errstr ($errno)<br>\n";
} else {
fputs ($fp, "GET /bintest.cgi?" HTTP/1.0\r\nHost:http://webserver\r\n\r\n";);
}


The web server will chanllenge me to supply user name and password.
How can I write the username and password into my php script in order to invoke the cgi script .
Any help will be really appreciated.
bin






---------------------------------
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to