Warning: strtotime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/libraries/joomla/utilities/date.php on line 56

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/libraries/joomla/utilities/date.php on line 198

Ldap com Mysql

E-mail Imprimir PDF

Link genérico:
http://www.ldap.org.br/
http://www.openldap.org/
Tutorials:
http://www.flatmtn.com/article/setting-ldap-back-sql#LdapGeneral-5
http://www.yolinux.com/TUTORIALS/LinuxTutorialLDAP-SLAPD-LDIF-V2-config.html
http://www.openldap.org/faq/data/cache/978.html
http://www.vivaolinux.com.br/artigo/Implementando-servidor-LDAP-no-Ubuntu/
https://www.wideopen.com/docs/manuals/linux/RHL-9-Manual/ref-guide/s1-ldap-quickstart.html
http://www.howtoforge.com/openldap-samba-domain-controller-ubuntu7.10
http://www.ldap.org.br/modules/ldap/files/files///samba+openLDAP+qmail.pdf

Como fazer a instalação:

apt-get install slapd ldap-utils

Edite o arquivo /etc/ldap/slapd.conf e troque todos os dc para o dc que você quiser.
Por exemplo: dc=casa,dc=lan

Descomente a instrução:
rootdn "cn=admin,dc=casa,dc=lan"

E acrescente uma linha de senha que é gerada pelo comando:
slappasswd

Por ex:
rootpw {SSHA}vv2y+i6V6esazrIv70xSSnNAJE18bb2u

Reinicie o ldap server:
invoke-rc.d slapd restart

Ferramentas GUI:
apt-get install apache2 libapache2-mod-php5 php5 php5-cgi php5-ldap
apt-get install phpldapadmin

Talvez seja necessário aumentar a meméria disponível para o php5 no arquivo:
/etc/php5/apache2/php.ini
e reiniciar o apache com:
/etc/init.d/apache2 restart

Edit o arquivo /etc/ldap/ldap.conf

Ports for the Firewall
LDAP runs on port 389/tcp by default and LDAP over SSL is 636/tcp.

Para reindexar utilize os comandos:
invoke-rc.d slapd stop
slapindex -v
chown openldap /etc/ldap/*.conf
invoke-rc.d slapd start

Para acertar o log edite o arquivo /etc/syslog.conf e coloque no final:
local4.* /var/log/ldap.log

Reinicie o log:
invoke-rc.d sysklogd restart

Instale agora a ferramenta de gerenciamento da base via shell:
apt-get install ldapscripts
Se dermos um "ldapsearch -x" ele nos mostra a base inteira LDAP.

Pode ser usado em conjunto com samba:
Modify you smb.conf file to call the scripts :
# [...]
add machine script = /usr/bin/ldapaddmachine ‘%u’ sambamachines
add user script = /usr/bin/ldapadduser ‘%u’ sambausers
add group script = /usr/bin/ldapaddgroup ‘%g’
add user to group script = /usr/bin/ldapaddusertogroup ‘%u’ ‘%g’
delete user script = /usr/bin/ldapdeleteuser ‘%u’
delete group script = /usr/bin/ldapdeletegroup ‘%g’
delete user from group script = /usr/bin/ldapdeleteuserfromgroup ‘%u’ ‘%g’
set primary group script = /usr/bin/ldapsetprimarygroup ‘%u’ ‘%g’
rename user script = /usr/bin/ldaprenameuser ‘%uold’ ‘%unew’
# [...]

Instalando o libnss-ldap (muitas vezes isso é instalado no momento da instalação do ldapscripts):
# aptitude install libnss-ldap
Respostas:
host address: IP da máquina
destinguished name ou dn: dc=vivaolinux,dc=com,dc=br
ldap version: 3
login database: no
readable/writable: no
OK

Instalando o libpam-ldap (muitas vezes isso é instalado no momento da instalação do ldapscripts):
# aptitude install libpam-ldap
Make local root database admin: yes
Database requires logging in: no
root login account: cn=admin,dc=vivaolinux,dc=com,dc=br
root passwd: senha do admin
local crypt to use when changing passwords: crypt

Editar o arquivo /etc/nsswitch.conf:
passwd: compat ldap
group: compat ldap
shadow: compat ldap

O restante permanece a mesma coisa.

Agora iremos fazer com que o sistema busque os usuários na base LDAP.
Editar arquivo /etc/pam.d/common-account:
account sufficient pam_ldap.so
account required pam_unix.so
session required /lib/security/pam_mkhomedir.so skel=/etc/skel/ umask=0022
Editar o arquivo /etc/pam.d/common-auth:
auth sufficient pam_ldap.so
auth required pam_unix.so nullok_secure try_first_pass
Editar o arquivo /etc/common-password:
password sufficient pam_unix.so nullok obscure min=4 max=8 md5
password required pam_ldap.so try_first_pass
Editar o arquivo /etc/common-session:
session sufficient pam_ldap.so
session required pam_unix.so

Pronto! Sua base está autenticando no LDAP.

Coloque o schema samba disponível:
cp /usr/share/doc/samba-doc/examples/LDAP/samba.schema.gz /etc/ldap/schema/
gzip -d /etc/ldap/schema/samba.schema.gz

E adicione:
include /etc/ldap/schema/samba.schema
include /etc/ldap/schema/misc.schema

Altere a linha:
access to attrs=userPassword,shadowLastChange
para:
access to attrs=userPassword,shadowLastChange,sambaNTPassword,sambaLMPassword
 

Warning: strftime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/libraries/joomla/utilities/date.php on line 250
Banner

Identificação

Visitantes


Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/modules/mod_vvisit_counter/helper.php on line 56

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/modules/mod_vvisit_counter/helper.php on line 57

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/modules/mod_vvisit_counter/helper.php on line 58

Warning: mktime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/modules/mod_vvisit_counter/helper.php on line 59

Warning: mktime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/modules/mod_vvisit_counter/helper.php on line 60

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/modules/mod_vvisit_counter/helper.php on line 63
mod_vvisit_countermod_vvisit_countermod_vvisit_countermod_vvisit_countermod_vvisit_countermod_vvisit_countermod_vvisit_counter
mod_vvisit_counterHoje41
mod_vvisit_counterOntem80
mod_vvisit_counterEsta semana290
mod_vvisit_counterEste mês1342
mod_vvisit_counterTodos505518

Últimas Notícias


Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/libraries/joomla/utilities/date.php on line 198

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_latestnews/helper.php on line 109

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_latestnews/helper.php on line 109

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_latestnews/helper.php on line 109

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_latestnews/helper.php on line 109

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_latestnews/helper.php on line 109

Mais Vistos


Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/libraries/joomla/utilities/date.php on line 198

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_mostread/helper.php on line 79

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_mostread/helper.php on line 79

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_mostread/helper.php on line 79

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_mostread/helper.php on line 79

Warning: Creating default object from empty value in /home/edifast0/public_html/corp/modules/mod_mostread/helper.php on line 79

Itens Relacionados


Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/libraries/joomla/utilities/date.php on line 198

Newsflash


Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/edifast0/public_html/corp/libraries/joomla/utilities/date.php on line 198
SERVER NOT FOUND or TIME OUT