Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    PHP


SuperbHosting.net have generously sponsored dedicated servers to ensure a reliable and scalable dedicated hosting solution for BigResource.com.





Authenticate Windows


I posted a question in ASP forum but I really want to know your opinion in PHP because I'm more familiar with PHP than ASP. I have a windows 2003 stand alone server. In this server I have some windows accounts and they all have passwords.

Now I have to create an intranet website on this server (IIS) My question is how can I use accounts/password on the server to authenticate user through an PHP page? Users have to enter their identity and the webpage log username and the time they login.




View Complete Forum Thread with Replies

Related Forum Messages:
Is It Possible To Authenticate Users Running Apache On MacOS X (with PHP 4) And An Active Directory On Windows 2000 Or Windows XP?
From a PHP webpage, is it possible to authenticate users running Apache on MacOS X (with PHP 4) and an active directory on Windows 2000 or Windows XP?

View Replies !
Intranet - Authenticate Using Windows Credentials?
I've just about finished an intranet app that allows users to sign in and out, track their time, show a calendar view of time worked, vacation days used, calculates overtime, etc. My backend is mysql and I'm currently authenticating against a users table that I threw together. The problem with that is another set of u/p's for users. I can import a list of everyone's windows login info, but then it's in two places and I have potential sync issues and maintenance that I'd like to avoid.

My question is this: are there any environment variables that capture the windows login info in PHP (the server will be running on windows, not *nix)? For example, if I login into my workstation as djf / password1, rather than having that information also stored in a mysql table, is there any way to access those values without the user typing them in again? I'm not that familiar with windows environments, but based on the research I've done, using LDAP and Active Directory might be a possibility? I have no idea how to do either.

View Replies !
Use PHP To Authenticate To AD
We use Windows 2000 AD for everything. However, we are also running
XAMPP (basically Apache, MySQL, PHP for windows) on a Windows box for
our Intranet. I have a few applications that need to authenticate via
AD from PHP and every example I see uses the LDAP functions built into
PHP.

I cannot query our AD server via LDAP. If I type
ldap://domaincontroller it fails, so of course, when I try to use the
LDAP function in PHP they fail.

How do I get LDAP running on AD? I'm sure I'm missing something simple,
but I'm very frustrated.

BTW, I've started coding another app that queries AD using ASP and it
is soooo easy it hurts.

View Replies !
Authenticate
Ive started recoding my login/authenticate pages for my game engine, because they were simple.

Upon testing what I have so far I have noticed something that confuses me.

Say these are my login details.

User - Me
Pass- letmein

Now it will log me in when i enter them exactly like that. BUT when i log in using the user me ( no capitol M), it gives me a blank screen and does nothing The incorrect password or incorrect user name works, it seems to break with case sensitivity issues.

any ideas? Code:

View Replies !
Use WWW-Authenticate:
I would like to learn how to use

header('WWW-Authenticate: Negotiate');
header('WWW-Authenticate: NTLM', true);

How are variables passed? Which are the variables? How do I name them? If anyone can give me some info to get started with that.

View Replies !
How To Authenticate When Using SimpleXML
I've got an RSS feed I'd like to consume from our Sharepoint server.
When I try:

$xml = simplexml_load_file($url);

I get

failed to open stream: HTTP request failed! HTTP/1.1 401 Unauthorized

This is understandable as I need to specify a username and password to
access the RSS. How can I do this with SimpleXML, or, should I first
call the URL with cURL and work with the stream locally?

I thought there may be some global params I could set for the stream
handling library of PHP.

View Replies !
How To Authenticate Remotely
There is an html form on a remote site with the fields: Username, password. I can visit the website, and login successfully. However, I'm wondering if it's possible to login without visiting the website.

In other words, can I create a similar form on a remote server, and do a remote POST? I've tried the following code, but it doesn't log me in. It simply returns to the login form. Code:

View Replies !
Authenticate Google Accounts Pro
Did any of you ever tried to authenticate Google Accounts pro
grammatically? What I mean is that there are many google services
available which needs to authenticate user accounts first to fetch
data remotely. Now is there any of you who authenticated using PHP?

View Replies !
Use Sessions To Authenticate My Pages
Im trying to use sessions to authenticate my pages - usernames/password being stored in a database, here's my code:

View Replies !
Authenticate The SOAP Server
Is there anybody who knows to authenticate the SOAP server. so that, only registered user can have access to the SOAP server?


View Replies !
How To Authenticate Users With Htaccess?
Can I use PHP and htaccess to authenticate users?

My service provider lets me password protect directories on my web site -
using htaccess. If a user tries to access a page within a password
protected directory, a dialog is received requesting username and password.

But I want to provide a login page that users go to first, and then are
directed to the page/directory that they are allowed to see based on their
username/password. Code:

View Replies !
Http-Authenticate Problems
I am using an include on the pages I want to protect but it just brings up the login box over and over again even with the correct user and pass. Is there a specific type of formatting to use in the database fields? Code:

View Replies !
Http Authenticate Entire Site
we are validating users in several different sections (each section is in it's own directory..ex. the download section is in /downloads) using http authentication. when a user authenticates in one section they can roam freely in that directory without having to authenticate again.

for some reason however, when i change to a different directory and then run a phpinfo(), both $PHP_AUTH_USER and $PHP_AUTH_PW are gone, meaning the user will have to authenticate again.

the user can go back to the first directory again and they are still authenticated within that directory. i would like the users to only have to authenticate once for the entire site, but scince there are areas of the site that do not require validation i don't want to make them authenticate until they have to.

View Replies !
Http Authenticate Auto Login?
you know the apache built in authenticate boxes? username+password. is it possible to run a php script that can log into that? do I send the username/pass as a post?
is this possible? I've searched everywhere and only found info on making one.

I don't want to make one, I want to log into one via  a php script. reason: dreamhost uses that for the login for the stats page, I want to read the data from the page in a php script, but first I need to log in.

View Replies !
Authenticate Into An .htpasswd-protected Area
how I would authenticate a user using PHP to allow them access into a .htaccess + .htpasswd protected area?

The configuration I currently have is a collection of directories under /protected, such /protected/sales/, /protected/adverts/, etc. Each of these directories has it's own .htaccess and .htpasswd. I would like to create a login form that would accept a user's name and password, then authenticate them to allow them to access the directories.

View Replies !
Authenticate Portal Users (php) In Active Directory
I would like to authenticate portal users (php) in Active Directory (Win
Server 2003). (right now php authenticates them on radius). If somebody has
codes or articles about php + AD .

View Replies !
PHP::Auth Requiring Valid Email Address To Authenticate
I am about to implement an authentication system on the site I am
building. I don't care much what users choose for their username and
password, but I want to verify that users have given a valid email
address before allowing them access to restricted content. Will Auth
facilitate the email validation process, or does it only deal with
usernames and passwords?

I don't need to be told in detail how to do all this, but I'd like to
know early if I'm barking up the wrong tree by trying to use Auth with
this intention in mind. If so, is there a better package to use for
authentication that requires a valid email address?

View Replies !
WWW-Authenticate: How To Force Password Login At Every Page Refresh ?
<!--
The following sample should authorize the user to log on the site.
This works once but after refreshing the browser, it does not prompt
again for login until all browser (IE 6) windows are closed and the
same page is opened.
I turned off all caching but still it does cache (as a refresh doen
not promt again).

How can I force the page to prompt for a password at every refresh

-->

<html>
<head>
<META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE">
<META HTTP-EQUIV="CACHE-CONTROL" CONTENT="NO-CACHE">
<?php

$showall = false;
error_reporting (E_ERROR);

if (($PHP_AUTH_USER != "myname") || ($PHP_AUTH_PW != "mypass"))
{
header('WWW-Authenticate: Basic realm="Secure Login"');
header('HTTP/1.0 401 Unauthorized');
$showall = false;
}
else
{
error_reporting (E_ALL ^ E_NOTICE);
$showall = true;
}

if (!showall) {
echo "access denied";
} else {
?>

................

</head>
<body>

.................

<? } ?>

</body>
</html>

View Replies !
Mail() Won't Work; Server Says "Unable To Authenticate User..."
I am working on a sendmail script using the PHP mail() function.

If I click on the HTML form page from within my hosting control panel (while I'm logged into my hosting account), fill out the form, and then click on the "submit" button the mail sends just fine.

However, if I log out of my control panel and approach the form page, just like a visitor or stranger would do, the PHP mail() function will not send the mail.

If I look inside the "./tmp/mailError.log" file there is the following message:

"Unable to authenticate user. Message not sent."

It appears that the server will not send the mail because there is not any identification for the outgoing mail. I have tried inserting a fourth variable in the PHP mail() function a couple of different ways like so:

View Replies !
Header('WWW-Authenticate: Basic Realm="Private"');
What am I doing wrong here:

if ($_SERVER['PHP_AUTH_USER'] !== 'username' || $_SERVER['PHP_AUTH_PW'] !== 'password')
{
header('WWW-Authenticate: Basic realm="Private"');
header('HTTP/1.0 401 Unauthorized');
die('Authorization Required.');
}

I don;t use this much, so I don;t know....This is what's happening with this code...I am prompted with the log in box....When I type in the wrong or right login info, I am simply prompted again to input my login info....if I press cancel, I receive the message: Code:

View Replies !
Authenticate A User Using Same Password As Linux Password
We're working on an intranet site where we will require user's to only
be able to access their own page in some instances. Rather than
introducing another password to the mix, we were thinking about seeing
if we could use the same credentials (username and password) as their
linux credentials. The web site will be running off of the same machine
that we want to access the credentials on.

View Replies !
Authenticate The User With The Login.html, Login.php.
I am setting up a registration/login for my website with PHP and MYSQL. I have a register.html, register.php & a login.html, login.php.

I can successfully register a user (using register.html, register.php) into my database. Now, I am trying to authenticate the user with the login.html, login.php.

When I try to do so, however, I always recieve my error message "failed." It will not authenticate (despite several attempts of logging in with the same username and password of that which is in my database.) Code:

View Replies !
CLI And Windows
The portion of the PHP manual entitled "Using PHP from the command
line"
states that "The CGI SAPI supports the CLI SAPI behaviour by means of
the -C switch when run from the command line.":

http://us2.php.net/features.commandline

However, "php -h" says of the -C switch, "Do not chdir to the script's
directory".

Further, running php -Cr "echo 'test'" results in an error saying
that
the -r switch doesn't exist, even though it should if it were acting
like the CLI version.

This, coupled with the fact that the Windows installer doesn't seem to
install a seperate CLI exe means that, unless I'm missing something,
CLI isn't something that can be used on Windows, contrary to what the
docs say.

View Replies !
Php On Windows
I try to install PHP on Win 95 platform using Windows PHP installer,
but it does't work. When running php.exe, I got error message "php.exe
file is linked to missing export kernel32.dll: cancello." Where is
wrong? Is it due to php not support win 95?

View Replies !
Pop-up Windows
I have a form coded as: <form action="test.php" method="post"> the form has two buttons: Preview and Submit

if ($Preview) {// perform action 1}
else {// perform action2}

My question: If Preview is clicked, I would like to open a new pop-up window without closing the original one. I would like the results of action 1 to be displayed on this new pop-up window.

Is there a way to do that without using javascript?
If no, then how would you do that with javascript?

i cannot use target=_blank in the form tag because i would like to have the pop-up window only if Preview is selected. But maybe there is a better way to code everything!

View Replies !
PHP On Windows XP Using IIS
I am trying to request form elements from a form from a page that
looks like this:

<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
</head>

<body>
<form action="result.php" method="post">
Name: <input type="text" name="username" value="brenda"><br />
Email: <input type="text" name="email" value="hipples"><br />
<input type="submit" name="submit" value="Submit me!">
</form>
</body>
</html>

Here is the results page, using multiple methods of variable retreival
and it will not work locally but up on the web server it works
fine....

<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
</head>

<body>
<?php

// Available since PHP 4.1.0

echo $_POST['username'];
echo $_REQUEST['username'];

import_request_variables('p', 'p_');
echo $p_username;

// Available since PHP 3. As of PHP 5.0.0, these long predefined
// variables can be disabled with the register_long_arrays directive.

echo $HTTP_POST_VARS['username'];

// Available if the PHP directive register_globals = on. As of
// PHP 4.2.0 the default value of register_globals = off.
// Using/relying on this method is not preferred.

echo $username;
?>
</body>
</html>

When I view the source of the result.php page, the opening <HTML> is
never there, leading me to beleive that there is a header issue of
some sort.

View Replies !
PHP And Windows CMD.exe ?
I'd like to somehow manage to get php sending things to windows cmd.exe.  Is thier any possible way for example.

I have to run a program to register a user, and I need to knwo if php is even capable of speaking with it.

C:Documents and SettingsUSERDesktopSOMEFOLDER
eleasesystem>addlicense.exe -a42790
8484 -psomepassword -ysomeuser -zsomepassword -l4 -b0

this is an example of what Im sending.

View Replies !
PHP Under Windows
I read somewhere that you need to install a virtual server (or something like that) if you want to run PHP scripts on a PC. The background is that I'd like to make the pages of my site dynamic, but would like to be able to view the site offline on my computer.

Is there such a piece of software, possibly easy to install? I'm not too familiar with servers.

View Replies !
Windows API
Is it possible to open a named pipe from a php script on Windows? More specifically, I have a Windows service that receives commands through a named pipe, and I'd like to open the client end of the pipe directly from php rather than creating an intermediate process.

View Replies !
Windows CE
I try to interact with my php/MySQL data-input website via my PocketPC. Usually, no problem (other than having to do a lot of scrolling on pages never meant to fit in a 240 X 290 window).

I recently built a fairly complex input form page that works just fine with a regular computer/browser. but when I submit (POST) form data using the PocketPC (using Pocket Internet Explorer) the data does not seem to post. nothing is saved and the script that receives it looks like it never saw any data arrive.

View Replies !
On Windows
Are there any disadvantages to running PHP on a Windows server as a CGI executable as opposed to running it on a Linux server?

View Replies !
PHP 5 And Windows XP
I have downloaded the binary zip file onto my desktop and am attempting to install it. I have created a folder in my Program Files called PHP into which I want to extract the files. From this point on I appear to be stuck as the files do not appear to want to extract to c:Program FilesPHP. Can anyone help me?

View Replies !
PHP, IIS On Windows
I installed IIS 5.1 and PHP 4.3.9 (windows installer version), apparently configures itself for use with IIS if the option is selected. Now when I drop a PHP file in C:Inetpubwwwroot and open in browser nothing happens just a blank page, it seems the PHP is not being intepreted. Does anyone have a quick list of settings for PHP and IIS on Windpows XP or any known issues so I can check through and hopefully sort it out cos it's driving me crazy!

View Replies !
PHP On Windows And Mysql
Is it possible to run php scripts on windows XP Professional with IIS? How? If yes, is it possible to access mysql database on windows by PHP? Is there any different between on windows and on linux?

View Replies !
Sockets On Windows
Hey all. I was going through the sockets tutorial and I am painstakingly trying to make windows xp allow me to play around with them but it wont let me.

On my Linux box everything works fine, but windows is denying my socket connections except at the usual telnet port (23).

Does anyone know how to configure port permissions, etc on windows xp?

View Replies !
Windows Sockets (yes I Know Its Old)
sorry to dig back into all this stuff but im having problems with sockets in a win98 env. my PHP is the installer version and i just added the .dll from the .zip after. what is happening is that im following the tutorial and have taken the server.php script at the end of part two and run it i then fire up telnet then connect to 127.0.0.1 (which i specified in the server.php file). then as soon as i type in a key i get a message "connection to host lost" and then in the DOS window where i am running PHP, it quits bqck to the DOS command prompt. any ideas guys?

View Replies !
Printing Under Windows
I'm wondering whether anyone knows of a good tutorial on how to use the PHP Printer Functions under Windows.

I've been dabbling in it a little, but the PHP Manual is kinda flakey on the subject.

I want to be able to print a report, generated in PHP, on the printer connected to the web-server (it's for an Intranet app).

View Replies !
Can't Get Variables Under Windows!!
I used PHP alot under linux but that's my first time to programme PHP under windows. However, I'm experiencing the weird case here. My php scripts can't get any variables from HTML form. not even by http://blahblah.com/phpscript.php?var1=hello.

View Replies !
PHP On Windows Server
I have been working with PHP in Linux for a while now and I have just been asked about PHP in the windows environment. Where should I go for the best info on what versions work the best with what windows server platforms?
Does mysql work on windows and can I use the same php files written for Linux on Windows?

View Replies !
ClibPDF + Php 4.3.3 +windows XP
Anyone knows where I could find a binary distribution of the ClibPDF
extension for PHP 4.3.3 and windows XP?

View Replies !
Windows Service
I need to stop (sometimes start) a Windows seevice (in XP / Vista). Does
anyone know how to do such a thing in php?

View Replies !
Request_uri For Windows IIS 5
the request_uri is not working for windows IIS How can i get it work? is there any other code? i just want the url right after the domain name;
http://www.domain.com/blahblah/blah.htm

View Replies !
Ssh2 Using Windows
i'm using Windows to access an ssh server. everything works perfect
until i try executing files (ssh2_exec) and sending/receiving files
(ssh2_scp_send/ssh2_scp_recv)... in the function manual at php.net it
has the following example to execute a command:

ssh2_exec($connection, '/usr/local/bin/php -i');

i'm assuming this is for linux/unix machines, so on a Windows machine,
should it be possible to do the following?

ssh2_exec($connection, 'c:/php/php.exe c:/a.php');
.......

View Replies !
PHP And Windows NT Authentication
Can PHP check a user to see if they are logged into an NT domain, and get their username?
If so, where should I start?

View Replies !
Authentication On Windows
Hi, I have for some time Apache running on windows. I am interested in authentication, but... If I call the following 'authenticate' example from the manual, I get the 500 internal server error. PHP Code:

View Replies !
PHP Upload In Windows
I have php and apache running in Windows XP. I am trying to use various file upload scripts but none of them work. When I try to use ones that use a copy function I get the following error:

Warning: copy(C:serverxitamiwebpageshivangPhotoGallery empimg3e710f87bf1ed.jpg) [function.copy]: failed to create stream: No such file or directory in C:serverxitamiwebpagesshivangPhotoGallery est.php on line 46
File could not be stored.

Anther script I tried does the following:
// Open the uploaded file
$file = fopen($img1, "r");
// Read in the uploaded file
$fileContents = fread($file, filesize($img1));
// Escape special characters in the file
$fileContents = AddSlashes($fileContents);

The above script fileContents only has half the image. I have the upload_tmp_dir set to c:serverupload and file_uploads to yes.

View Replies !
CHMOD In Windows?
I need to change the attributes of a file from 700 to 777. But Windows no likee CHMOD (UNIX command).

View Replies !
Windows Size
Can someone tell me if it is possible to control the size of the window using php because i want to have a script run in a window the following size: Height = 250 Width = 250

View Replies !
Editor For Windows?
I couldn't find a good program. I like Kate Editor but this program only working in the linux..

View Replies !
Exec() On Windows
this is my problem: I need to "exec" the following command:

C:ProgrammiSoftsoft.exe -v -d C:dati$nomefile
C:datipdf$filename

and i tried to execute it in php with (one of) the following lines....

exec("C:ProgrammiSoftsoft.exe -v -d C:dati.$nomefile
C:datipdf.$filename");
exec("C:ProgrammiSoftsoft.exe" -v -d "C:dati".$nomefile
"C:datipdf".$filename);
exec("C:ProgrammiSoftsoft.exe -v -d C:dati.$nomefile
C:datipdf.$filename");
exec("C:/Programmi/Soft/soft.exe -v -d C:/dati/.$nomefile
C:/dati/pdf/.$filename");
exec("C:/Programmi/Soft/soft.exe" -v -d "C:/dati/".$nomefile
"C:/dati/pdf/".$filename);

but there is something wrong and that i.. do not understand...
Is there anyone so kind to show me the correct line and a couple of
comments on how to built it? I tried to search for it (manual,
newsgroups...) but i haven't found it (and my mistakes are the result
:-P)

View Replies !
PHP And LDAP On Windows
Anyone have recommendations as to the easiest LDAP libraries to install
on Windows for PHP? Building them from source on Windows is not an
option and we can't locate anything pre-built from UMich or OpenLDAP -
someone suggested the Novell and Mozilla SDKs but I have no idea where
to put the DLLs ..

PHP 5.0.4 under Windows XP

View Replies !
How To Set Up Apache And Php On Windows XP.
Just wonder if there are any sites with a guide on how to set up apache and
php on windows XP. Would like to test my php-pages locally.


View Replies !

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