Correction de l'UID des utilisateurs si une adresse mail est passée en paramètre

tags/0.2.20
Daniel Berteaud 12 years ago
parent d160f9de45
commit 229febd1e0
  1. 1
      root/usr/share/mozilla-mcd/firefox.php
  2. 1
      root/usr/share/mozilla-mcd/thunderbird.php

@ -20,6 +20,7 @@ if(isset($_SERVER['QUERY_STRING']) && preg_match('/^.+@' . DOMAIN . '$/', $_SERV
// Search for the mail address
$result = ldap_search($link, USER_BASE, "mail=" . $_SERVER['QUERY_STRING']);
$user = ldap_get_entries($link, $result);
$uid = $user[0]['uid'][0];
if($user['count'] != 1) {
// user not found or multiple result found
exit;

@ -19,6 +19,7 @@ if(isset($_SERVER['QUERY_STRING']) && preg_match('/^.+@' . DOMAIN . '$/', $_SERV
// Search for the mail address
$result = ldap_search($link, USER_BASE, "mail=" . $_SERVER['QUERY_STRING']);
$user = ldap_get_entries($link, $result);
$uid = $user[0]['uid'][0];
if($user['count'] != 1) {
// user not found or multiple result found
exit;

Loading…
Cancel
Save