From 92cab2b678bac4881b5ad78168f26e5467edb9ce Mon Sep 17 00:00:00 2001 From: Harsh4902 Date: Wed, 12 Jun 2024 11:41:08 +0530 Subject: [PATCH 1/2] Add 'Required Dependencies' section in ldap.adoc file Closes gh-14699 --- .../authentication/passwords/ldap.adoc | 35 +++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc b/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc index f045329781..ba52240a30 100644 --- a/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc +++ b/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc @@ -10,6 +10,41 @@ However, despite leveraging a username/password for authentication it does not i There are many different scenarios for how an LDAP server may be configured so Spring Security's LDAP provider is fully configurable. It uses separate strategy interfaces for authentication and role retrieval and provides default implementations which can be configured to handle a wide range of situations. +[[servlet-authentication-ldap-required-dependencies]] +== Required Dependencies + +To enable LDAP with Spring Security you have to add following dependencies: + +[tabs] +====== +Maven:: ++ +[source,xml,role="primary",subs="verbatim,attributes"] +---- + + org.springframework.boot + spring-boot-starter-data-ldap + {spring-boot-starter-data-ldap-version} + + + + org.springframework.security + spring-security-ldap + {spring-security-ldap-version} + +---- + +Gradle:: ++ +[source,groovy,role="secondary",subs="verbatim,attributes"] +---- +depenendencies { + implementation "org.springframework.boot:spring-boot-starter-data-ldap:{spring-boot-starter-data-ldap-version}" + implementation "org.springframework.security:spring-security-ldap:{spring-security-ldap-version}" +} +---- +====== + [[servlet-authentication-ldap-prerequisites]] == Prerequisites From f622d8e2e22fbf39800a9c0d083b78c0e75760b7 Mon Sep 17 00:00:00 2001 From: Steve Riesenberg <5248162+sjohnr@users.noreply.github.com> Date: Thu, 13 Jun 2024 15:52:55 -0500 Subject: [PATCH 2/2] Polish gh-15235 --- .../servlet/authentication/passwords/ldap.adoc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc b/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc index ba52240a30..9364dbc8cd 100644 --- a/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc +++ b/docs/modules/ROOT/pages/servlet/authentication/passwords/ldap.adoc @@ -13,34 +13,34 @@ It uses separate strategy interfaces for authentication and role retrieval and p [[servlet-authentication-ldap-required-dependencies]] == Required Dependencies -To enable LDAP with Spring Security you have to add following dependencies: +To get started, add the `spring-security-ldap` dependency to your project. +When using Spring Boot, add the following dependencies: +.Spring Security LDAP Dependencies [tabs] ====== Maven:: + -[source,xml,role="primary",subs="verbatim,attributes"] +[source,xml,role="primary"] ---- org.springframework.boot spring-boot-starter-data-ldap - {spring-boot-starter-data-ldap-version} org.springframework.security spring-security-ldap - {spring-security-ldap-version} ---- Gradle:: + -[source,groovy,role="secondary",subs="verbatim,attributes"] +[source,groovy,role="secondary"] ---- depenendencies { - implementation "org.springframework.boot:spring-boot-starter-data-ldap:{spring-boot-starter-data-ldap-version}" - implementation "org.springframework.security:spring-security-ldap:{spring-security-ldap-version}" + implementation "org.springframework.boot:spring-boot-starter-data-ldap" + implementation "org.springframework.security:spring-security-ldap" } ---- ======