Skip to content

OpenLDAP

Johnson Fu edited this page Jul 20, 2019 · 25 revisions

Quick Start

Vagrant LDAP VM

https://github.com/fivetanley/vagrant-ldap-vm

LDAP Query

ldapsearch -x uid=test1 -b dc=localhost -H ldap://192.168.1.188
ldapsearch -xLLL uid=test1 -b dc=localhost -H ldap://192.168.1.188 dn uid gecos memberOf gidNumber homeDirectory loginShell

Lightweight LDAP Browser

https://www.ldapadministrator.com/download.htm

Use LDAP admin to change password

ldappasswd -H ldap://ipaddress -x -D "uid=root,cn=users,dc=localhost" -W -S "uid=test2,cn=users,dc=localhost"

Change LDAP user password by providing the previous password

ldappasswd -H ldap://ipadderss -x -D "uid=test2,cn=users,dc=localhost" -W -S "uid=test2,cn=users,dc=localhost"

List the groups in which the user belongs to

ldapsearch -h ipaddress -x -b "dc=localhost" "(&(cn=*)(memberUid=test2))" dn

slapcat這個指令可以將目前slapd資料庫有的資料輸出,產生出LDIF檔案。LDIF檔案可以再透過slapadd指令來輸入至slapd資料庫中。*

sudo slapcat
sudo slapcat -a "entryDN:dnSubtreeMatch:=cn=admin,dc=monk,dc=org"

Resources

LDAP Administration

我花了一个五一终于搞懂了OpenLDAP

https://segmentfault.com/a/1190000014683418

LDAP 安裝、設定、管理

https://blog.xuite.net/towns/hc/81677540-LDAP+%E5%AE%89%E8%A3%9D%E3%80%81%E8%A8%AD%E5%AE%9A%E3%80%81%E7%AE%A1%E7%90%86+

Apache Directory

https://directory.apache.org/studio/download/download-windows.html

使用Ubuntu Server架設LDAP伺服器

https://magiclen.org/ubuntu-server-ldap/

Using LDAP on Synology

https://blogging.dragon.org.uk/using-ldap-on-synology/

Synology tutorial

https://www.synology.com/zh-tw/knowledgebase/DSM/help/DirectoryServer/ldap_server

How To Change Account Passwords on an OpenLDAP Server

https://www.digitalocean.com/community/tutorials/how-to-change-account-passwords-on-an-openldap-server

Spring Boot

Spring Boot中使用LDAP来统一管理用户信息

http://blog.didispace.com/spring-boot-ldap-user/

Spring Boot集成LDAP实现登录

https://juejin.im/entry/5ab304ad6fb9a028b547c7d3

LDAP Authentication with Spring Boot

https://medium.com/@lejinkr/ldap-authentication-with-spring-boot-7b2d3fd08277

Password Encoder

https://dzone.com/articles/password-encoder-migration-with-spring-security-5

Guide to Spring Data LDAP

https://www.baeldung.com/spring-data-ldap

OpenLDAP使用疑惑解答及使用Java完成LDAP身份认证

https://www.cnblogs.com/lanxuezaipiao/p/3664676.html

How to configure LDAP Authentication using Spring Boot

https://www.opencodez.com/java/configure-ldap-authentication-using-spring-boot.htm

How to use Spring Security to authenticate users with Microsoft Active Directory

https://medium.com/@viraj.rajaguru/how-to-use-spring-security-to-authenticate-with-microsoft-active-directory-1caff11c57f2

trust ssl certificate

http://roufid.com/java-ldap-ssl-authentication/

  • freemarker
  • thymeleaf
  • JMX (jconsole)
  • ZeroMQ
  • microk8s
  • multipass
  • pwsh (powershell)

Clone this wiki locally