modules.adoc 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342
  1. // FIXME: This might make sense in Getting Spring Security along with the artifact information
  2. [[modules]]
  3. = Project Modules and Dependencies
  4. In Spring Security 3.0, the codebase was sub-divided into separate jars which more clearly separate different functionality areas and third-party dependencies.
  5. If you use Maven to build your project, these are the modules you should add to your `pom.xml`.
  6. Even if you do not use Maven, we recommend that you consult the `pom.xml` files to get an idea of third-party dependencies and versions.
  7. Another good idea is to examine the libraries that are included in the sample applications.
  8. This section provides a reference of the modules in Spring Security and the additional dependencies that they require in order to function in a running application.
  9. We don't include dependencies that are only used when building or testing Spring Security itself.
  10. Nor do we include transitive dependencies which are required by external dependencies.
  11. The version of Spring required is listed on the project website, so the specific versions are omitted for Spring dependencies below.
  12. Note that some of the dependencies listed as "optional" below may still be required for other non-security functionality in a Spring application.
  13. Also dependencies listed as "optional" may not actually be marked as such in the project's Maven POM files if they are used in most applications.
  14. They are "optional" only in the sense that you don't need them unless you are using the specified functionality.
  15. Where a module depends on another Spring Security module, the non-optional dependencies of the module it depends on are also assumed to be required and are not listed separately.
  16. [[spring-security-core]]
  17. == Core -- `spring-security-core.jar`
  18. This module contains core authentication and access-control classes and interfaces, remoting support, and basic provisioning APIs.
  19. It is required by any application that uses Spring Security.
  20. It supports standalone applications, remote clients, method (service layer) security, and JDBC user provisioning.
  21. It contains the following top-level packages:
  22. * `org.springframework.security.core`
  23. * `org.springframework.security.access`
  24. * `org.springframework.security.authentication`
  25. * `org.springframework.security.provisioning`
  26. .Core Dependencies
  27. |===
  28. | Dependency | Version | Description
  29. | ehcache
  30. | 1.6.2
  31. | Required if the Ehcache-based user cache implementation is used (optional).
  32. | spring-aop
  33. |
  34. | Method security is based on Spring AOP
  35. | spring-beans
  36. |
  37. | Required for Spring configuration
  38. | spring-expression
  39. |
  40. | Required for expression-based method security (optional)
  41. | spring-jdbc
  42. |
  43. | Required if using a database to store user data (optional).
  44. | spring-tx
  45. |
  46. | Required if using a database to store user data (optional).
  47. | aspectjrt
  48. | 1.6.10
  49. | Required if using AspectJ support (optional).
  50. | jsr250-api
  51. | 1.0
  52. | Required if you are using JSR-250 method-security annotations (optional).
  53. |===
  54. [[spring-security-remoting]]
  55. == Remoting -- `spring-security-remoting.jar`
  56. This module provides integration with Spring Remoting.
  57. You do not need this unless you are writing a remote client that uses Spring Remoting.
  58. The main package is `org.springframework.security.remoting`.
  59. .Remoting Dependencies
  60. |===
  61. | Dependency | Version | Description
  62. | spring-security-core
  63. |
  64. |
  65. | spring-web
  66. |
  67. | Required for clients which use HTTP remoting support.
  68. |===
  69. [[spring-security-web]]
  70. == Web -- `spring-security-web.jar`
  71. This module contains filters and related web-security infrastructure code.
  72. It contains anything with a servlet API dependency.
  73. You need it if you require Spring Security web authentication services and URL-based access-control.
  74. The main package is `org.springframework.security.web`.
  75. .Web Dependencies
  76. |===
  77. | Dependency | Version | Description
  78. | spring-security-core
  79. |
  80. |
  81. | spring-web
  82. |
  83. | Spring web support classes are used extensively.
  84. | spring-jdbc
  85. |
  86. | Required for JDBC-based persistent remember-me token repository (optional).
  87. | spring-tx
  88. |
  89. | Required by remember-me persistent token repository implementations (optional).
  90. |===
  91. [[spring-security-config]]
  92. == Config -- `spring-security-config.jar`
  93. This module contains the security namespace parsing code and Java configuration code.
  94. You need it if you use the Spring Security XML namespace for configuration or Spring Security's Java Configuration support.
  95. The main package is `org.springframework.security.config`.
  96. None of the classes are intended for direct use in an application.
  97. .Config Dependencies
  98. |===
  99. | Dependency | Version | Description
  100. | spring-security-core
  101. |
  102. |
  103. | spring-security-web
  104. |
  105. | Required if you are using any web-related namespace configuration (optional).
  106. | spring-security-ldap
  107. |
  108. | Required if you are using the LDAP namespace options (optional).
  109. | spring-security-openid
  110. |
  111. | Required if you are using OpenID authentication (optional).
  112. | aspectjweaver
  113. | 1.6.10
  114. | Required if using the protect-pointcut namespace syntax (optional).
  115. |===
  116. [[spring-security-ldap]]
  117. == LDAP -- `spring-security-ldap.jar`
  118. This module provides LDAP authentication and provisioning code.
  119. It is required if you need to use LDAP authentication or manage LDAP user entries.
  120. The top-level package is `org.springframework.security.ldap`.
  121. .LDAP Dependencies
  122. |===
  123. | Dependency | Version | Description
  124. | spring-security-core
  125. |
  126. |
  127. | spring-ldap-core
  128. | 1.3.0
  129. | LDAP support is based on Spring LDAP.
  130. | spring-tx
  131. |
  132. | Data exception classes are required.
  133. | apache-ds footnote:[The modules `apacheds-core`, `apacheds-core-entry`, `apacheds-protocol-shared`, `apacheds-protocol-ldap` and `apacheds-server-jndi` are required.
  134. ]
  135. | 1.5.5
  136. | Required if you are using an embedded LDAP server (optional).
  137. | shared-ldap
  138. | 0.9.15
  139. | Required if you are using an embedded LDAP server (optional).
  140. | ldapsdk
  141. | 4.1
  142. | Mozilla LdapSDK.
  143. Used for decoding LDAP password policy controls if you are using password-policy functionality with OpenLDAP, for example.
  144. |===
  145. [[spring-security-oauth2-core]]
  146. == OAuth 2.0 Core -- `spring-security-oauth2-core.jar`
  147. `spring-security-oauth2-core.jar` contains core classes and interfaces that provide support for the OAuth 2.0 Authorization Framework and for OpenID Connect Core 1.0.
  148. It is required by applications that use OAuth 2.0 or OpenID Connect Core 1.0, such as client, resource server, and authorization server.
  149. The top-level package is `org.springframework.security.oauth2.core`.
  150. [[spring-security-oauth2-client]]
  151. == OAuth 2.0 Client -- `spring-security-oauth2-client.jar`
  152. `spring-security-oauth2-client.jar` contains Spring Security's client support for OAuth 2.0 Authorization Framework and OpenID Connect Core 1.0.
  153. It is required by applications that use OAuth 2.0 Login or OAuth Client support.
  154. The top-level package is `org.springframework.security.oauth2.client`.
  155. [[spring-security-oauth2-jose]]
  156. == OAuth 2.0 JOSE -- `spring-security-oauth2-jose.jar`
  157. `spring-security-oauth2-jose.jar` contains Spring Security's support for the JOSE (Javascript Object Signing and Encryption) framework.
  158. The JOSE framework is intended to provide a method to securely transfer claims between parties.
  159. It is built from a collection of specifications:
  160. * JSON Web Token (JWT)
  161. * JSON Web Signature (JWS)
  162. * JSON Web Encryption (JWE)
  163. * JSON Web Key (JWK)
  164. It contains the following top-level packages:
  165. * `org.springframework.security.oauth2.jwt`
  166. * `org.springframework.security.oauth2.jose`
  167. [[spring-security-oauth2-resource-server]]
  168. == OAuth 2.0 Resource Server -- `spring-security-oauth2-resource-server.jar`
  169. `spring-security-oauth2-resource-server.jar` contains Spring Security's support for OAuth 2.0 Resource Servers.
  170. It is used to protect APIs via OAuth 2.0 Bearer Tokens.
  171. The top-level package is `org.springframework.security.oauth2.server.resource`.
  172. [[spring-security-acl]]
  173. == ACL -- `spring-security-acl.jar`
  174. This module contains a specialized domain object ACL implementation.
  175. It is used to apply security to specific domain object instances within your application.
  176. The top-level package is `org.springframework.security.acls`.
  177. .ACL Dependencies
  178. |===
  179. | Dependency | Version | Description
  180. | spring-security-core
  181. |
  182. |
  183. | ehcache
  184. | 1.6.2
  185. | Required if the Ehcache-based ACL cache implementation is used (optional if you are using your own implementation).
  186. | spring-jdbc
  187. |
  188. | Required if you are using the default JDBC-based AclService (optional if you implement your own).
  189. | spring-tx
  190. |
  191. | Required if you are using the default JDBC-based AclService (optional if you implement your own).
  192. |===
  193. [[spring-security-cas]]
  194. == CAS -- `spring-security-cas.jar`
  195. This module contains Spring Security's CAS client integration.
  196. You should use it if you want to use Spring Security web authentication with a CAS single sign-on server.
  197. The top-level package is `org.springframework.security.cas`.
  198. .CAS Dependencies
  199. |===
  200. | Dependency | Version | Description
  201. | spring-security-core
  202. |
  203. |
  204. | spring-security-web
  205. |
  206. |
  207. | cas-client-core
  208. | 3.1.12
  209. | The JA-SIG CAS Client.
  210. This is the basis of the Spring Security integration.
  211. | ehcache
  212. | 1.6.2
  213. | Required if you are using the Ehcache-based ticket cache (optional).
  214. |===
  215. [[spring-security-openid]]
  216. == OpenID -- `spring-security-openid.jar`
  217. [NOTE]
  218. The OpenID 1.0 and 2.0 protocols have been deprecated and users are encouraged to migrate to OpenID Connect, which is supported by spring-security-oauth2.
  219. This module contains OpenID web authentication support.
  220. It is used to authenticate users against an external OpenID server.
  221. The top-level package is `org.springframework.security.openid`.
  222. It requires OpenID4Java.
  223. .OpenID Dependencies
  224. |===
  225. | Dependency | Version | Description
  226. | spring-security-core
  227. |
  228. |
  229. | spring-security-web
  230. |
  231. |
  232. | openid4java-nodeps
  233. | 0.9.6
  234. | Spring Security's OpenID integration uses OpenID4Java.
  235. | httpclient
  236. | 4.1.1
  237. | openid4java-nodeps depends on HttpClient 4.
  238. | guice
  239. | 2.0
  240. | openid4java-nodeps depends on Guice 2.
  241. |===
  242. [[spring-security-test]]
  243. == Test -- `spring-security-test.jar`
  244. This module contains support for testing with Spring Security.
  245. [[spring-security-taglibs]]
  246. == Taglibs -- `spring-security-taglibs.jar`
  247. Provides Spring Security's JSP tag implementations.
  248. .Taglib Dependencies
  249. |===
  250. | Dependency | Version | Description
  251. | spring-security-core
  252. |
  253. |
  254. | spring-security-web
  255. |
  256. |
  257. | spring-security-acl
  258. |
  259. | Required if you are using the `accesscontrollist` tag or `hasPermission()` expressions with ACLs (optional).
  260. | spring-expression
  261. |
  262. | Required if you are using SPEL expressions in your tag access constraints.
  263. |===