pathans
Posts: 46
|
Posted: 12/10/2012, 10:12 AM |
|
for our internal sites we use AD authentication.
is it possible to somehow use that in codecharge to capture user login and use
for example.
when i go to our intranet it uses my AD login and log me in to the site.
I want to use that in codecharge so when i am visiting a codecharge page.
right now i am forcing users to login and then use their user id that way.
|
|
|
MichaelMcDonald
Posts: 640
|
Posted: 12/11/2012, 5:29 AM |
|
LDAP?
_________________
Central Coast, NSW, Australia.
|
|
|
pathans
Posts: 46
|
Posted: 12/11/2012, 9:34 AM |
|
do you have an example of LDAP working with codecharge. I will search the forum as well.
but that still prompt you for login and password. I want to use the authenticated user info from browser and let them login. kinda like sharepoint.
|
|
|
DataDoIT
|
Posted: 12/11/2012, 10:22 AM |
|
http://adldap.sourceforge.net/
|
|
|
MichaelMcDonald
Posts: 640
|
Posted: 12/11/2012, 2:08 PM |
|
If you are using IIS you will be able to use Windows integrated login with PHP & LDAP.
_________________
Central Coast, NSW, Australia.
|
|
|
pathans
Posts: 46
|
Posted: 12/12/2012, 2:26 PM |
|
isn't there a way i can use authenticated user value in php and call that some how as username?
on the server phpinfo shows authenticated user as my user name?
btw my server is
windows 2008 with IIS and/or XAMMP.
with mysql installed locally
|
|
|
norbi771
Posts: 3
|
Posted: 12/13/2012, 11:31 AM |
|
You can do that but with Internet Explorer and IIS web server only.
If the above is applicable to your scenario you can check $_SERVER["Logon_User"] or very similar variable, just print_r($_SERVER) and you will see that.
As far as I remember you also have to turn off anonymous user on the IIS web site you want NTLM auth to be turned on.
You can also use ldap_auth. Request for username and password in your form and then in your php script issue ldap_auth.
$ldap = ldap_connect("ldap.example.com")
if($bind = ldap_bind($ldap, $_POST['username'], $_POST['password'])) {
// log them in!
} else {
// error message
}
instead of $_POST ... you can use Control->GetValue() or similar ... (I ended up using codecharge studio 3 and I don't remember this by heart)
Brgs
Norbert
|
|
|