Active Directory

Write here everything about development of SLiMS' additional features or plugins or add-ons from member of SLiMS users communities.

Moderators: wynerst, buitenzorg812, purwoko, sutriadi, ido, Dicarve, ridorido

Post Reply
dfrEak
Posts: 72
Joined: 16 Dec 2013, 11:13
Location: Tokyo, Japan

Active Directory

Post by dfrEak » 13 Jan 2014, 15:59

Saya ingin bertanya, saya ada masalah untuk active directory
itu tinggal di edit di sysconfig.inc.php

di bagian native jadi LDAP kan?

Code: Select all

/**
 * User and member login method
 */
$sysconf['auth']['user']['method'] = 'native'; // method can be 'native' or 'LDAP'
$sysconf['auth']['member']['method'] = 'native'; // for library member, method can be 'native' or 'LDAP'
/**
 * LDAP Specific setting for User
 */
if (($sysconf['auth']['user']['method'] === 'LDAP') OR ($sysconf['auth']['member']['method'] === 'LDAP')) {
  $sysconf['auth']['user']['ldap_server'] = '127.0.0.1'; // LDAP server
  $sysconf['auth']['user']['ldap_base_dn'] = 'ou=slims,dc=diknas,dc=go,dc=id'; // LDAP base DN
  $sysconf['auth']['user']['ldap_suffix'] = ''; // LDAP user suffix
  $sysconf['auth']['user']['ldap_bind_dn'] = 'uid=#loginUserName,'.$sysconf['auth']['user']['ldap_base_dn']; // Binding DN
  $sysconf['auth']['user']['ldap_port'] = null; // optional LDAP server connection port, use null or false for default
  $sysconf['auth']['user']['ldap_options'] = array(
      array(LDAP_OPT_PROTOCOL_VERSION, 3),
      array(LDAP_OPT_REFERRALS, 0)
      ); // optional LDAP server options
  $sysconf['auth']['user']['ldap_search_filter'] = '(|(uid=#loginUserName)(cn=#loginUserName*))'; // LDAP search filter, #loginUserName will be replaced by the real login name
  $sysconf['auth']['user']['userid_field'] = 'uid'; // LDAP field for username
  $sysconf['auth']['user']['fullname_field'] = 'cn'; // LDAP field for full name
  $sysconf['auth']['user']['mail_field'] = 'mail'; // LDAP field for e-mail
  /**
   * LDAP Specific setting for member
   * By default same as User
   */
  $sysconf['auth']['member']['ldap_server'] = &$sysconf['auth']['user']['ldap_server']; // LDAP server
  $sysconf['auth']['member']['ldap_base_dn'] = &$sysconf['auth']['user']['ldap_base_dn']; // LDAP base DN
  $sysconf['auth']['member']['ldap_suffix'] = &$sysconf['auth']['user']['ldap_suffix']; // LDAP user suffix
  $sysconf['auth']['member']['ldap_bind_dn'] = &$sysconf['auth']['user']['ldap_bind_dn']; // Binding DN
  $sysconf['auth']['member']['ldap_port'] = &$sysconf['auth']['user']['ldap_port']; // optional LDAP server connection port, use null or false for default
  $sysconf['auth']['member']['ldap_options'] = &$sysconf['auth']['user']['ldap_options']; // optional LDAP server options
  $sysconf['auth']['member']['ldap_search_filter'] = &$sysconf['auth']['user']['ldap_search_filter']; // LDAP search filter, #loginUserName will be replaced by the real login name
  $sysconf['auth']['member']['userid_field'] = &$sysconf['auth']['user']['userid_field']; // LDAP field for username
  $sysconf['auth']['member']['fullname_field'] = &$sysconf['auth']['user']['fullname_field']; // LDAP field for full name
  $sysconf['auth']['member']['mail_field'] = &$sysconf['auth']['user']['mail_field']; // LDAP field for e-mail
}
atau ada settingan yg lainnya di SLIMS
setelah dicek di active directorynya ga ada request koneksi

User avatar
wynerst
Posts: 13
Joined: 02 Oct 2011, 13:16

Re: Active Directory

Post by wynerst » 09 Mar 2014, 23:15

Setting LDAP sangat tergantung konfigurasi server LDAP yang ada.
Untuk setting SLiMS yang sudah dibuktikan adalah menggunakan OpenLDAP server.
Kasusnya akan sangat spesifik untuk setiap server yang digunakan. Debug perbaris dari setting juga harus dilakukan dengan syarat menguasai dengan baik "how to" koneksi LDAP server yang dipakai.

Salam.

dfrEak
Posts: 72
Joined: 16 Dec 2013, 11:13
Location: Tokyo, Japan

Re: Active Directory

Post by dfrEak » 10 Mar 2014, 13:52

disini saya memakai active directory
bkannya LDAP itu protocol autentifikasi yang digunakan yak

apakah ada perbedaan antara openLDAP dan active directory?

dfrEak
Posts: 72
Joined: 16 Dec 2013, 11:13
Location: Tokyo, Japan

Re: Active Directory

Post by dfrEak » 04 Jun 2014, 10:24

disini saya masih belum bisa terkoneksi dengan ldap

saya mendapatkan error seperti ini
hal ini kemungkinan disebabkan karena tidak mengenali LDAP_OPT_PROTOCOL_VERSION dan LDAP_OPT_REFERRALS
oh iya saya memakai slims 7

Code: Select all

[Wed Jun 04 10:17:41 2014] [error] [client 10.150.4.3] PHP Notice:  Use of undefined constant LDAP_OPT_PROTOCOL_VERSION - assumed 'LDAP_OPT_PROTOCOL_VERSION' in /var/www/slims/sysconfig.local.inc.php on line 59, referer: http://10.150.9.94/slims/index.php?p=member
[Wed Jun 04 10:17:41 2014] [error] [client 10.150.4.3] PHP Notice:  Use of undefined constant LDAP_OPT_REFERRALS - assumed 'LDAP_OPT_REFERRALS' in /var/www/slims/sysconfig.local.inc.php on line 60, referer: http://10.150.9.94/slims/index.php?p=member
terima kasih

aditya123
Posts: 1
Joined: 06 Nov 2017, 21:11

Re: Active Directory

Post by aditya123 » 09 Nov 2017, 10:44

Mohon Infonya untuk SLIMS connect ke Active Directory ?
step yang sudah saya lakukan :
- enable ldap di php
- config ldap di sysconfig.inc.php

tapi ketika login pakai user AD, selalu ada message "Nama Pengguna atau Kata Sandi Salah. AKSES DITOLAK"
apakah sudah ada yg berhasil melakukan hal ini ?

terima kasih

Post Reply