experimental: try to get user data

This commit is contained in:
Marc Wäckerlin
2017-02-28 19:13:21 +00:00
parent 68781d4ce4
commit 916e7aa16a
4 changed files with 14 additions and 1 deletions

View File

@@ -23,6 +23,9 @@ if (!isset($_SERVER['PHP_AUTH_USER'])) {
ldap_start_tls($ldapconn)
or error_die($ldapconn, "cannot start LDAP TLS");
if ($ldapbind = @ldap_bind($ldapconn, $checkuser.'='.$tstusername.','.$ldapbase, $password)) {
ldap_bind($ldap, 'username', 'password');
$search = ldap_search($ldapconn, 'base_dn', 'search_filter', array('mail', 'cn'));
$data = ldap_get_entries($ldap, $search);
ldap_close($ldapconn);
$username = $tstusername;
} else {

View File

@@ -4,4 +4,8 @@ $thumbpath = "/var/tmp/sharing-gallery/thumbnails/";
$max_validity_days = "30";
$font = "DejaVu-Sans";
$preview_num = "5";
$default_mail_subject = "Sharing Gallery: See my Fotos";
$default_mail_text = "Fotos from my gallery:\n\npassword = PASSWORD\n\nlink: LINK\n\nRegards\nUSERNAME";
$default_mailto = "";
$fallback_mail_replyto = "";
?>