#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    3
    Rep Power
    0

    ldap_mod_replace with AD and PHP


    I am trying to modify an attribute in Active Directory useing LDAP and PHP. I can connect, bind and view the data from Active Directory I just can't seem to modify it. I am using the ldap_mod_replace within php and I even get no errors when it runs and it shows that it was successfully. But when I review the attribute that is to be changed, in this case the telephoneNumber. It is still the same as it was before. If anyone has any ideas I would appreciate it. I am currrently using PHP 5.0.1 on a windows 2003 server running active directory and IIS
  2. #2
  3. Psycho Canadian
    Devshed Demi-God (4500 - 4999 posts)

    Join Date
    Jan 2001
    Location
    Canada
    Posts
    4,846
    Rep Power
    635
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Location
    Stuttgart
    Posts
    50
    Rep Power
    11
    don't use ldap_mod_replace

    use $r = ldap_modify($ldapConn, $dn , $info);

    for attribute-value modification


    http://ldap.caspro.de
  6. #4
  7. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    3
    Rep Power
    0
    Got it. It really helps when you use the full dn when identifing the object you what to modify. Now I just need to get the connection to the server to work on port 636 so I can change passwords. Thanks.
  8. #5
  9. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Location
    Stuttgart
    Posts
    50
    Rep Power
    11
    if you can't establish the ssl - connection (and i bet you can't)

    visit www.ldaphelp.com
  10. #6
  11. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2004
    Posts
    3
    Rep Power
    0
    I tried the suggestions on the web site that you directed to. But I still have the issue. If I put ldaps:// it connects on port 389 (unsecure) and I get unwilling to perform. If I put in the <ip address>, 636 to force the secure port I get unable to bind. If you have any other thoughts I would appreciate them.

IMN logo majestic logo threadwatch logo seochat tools logo