SeamFramework.orgCommunity Documentation

Chapter 1. Security - Introduction

1.1. Overview
1.1.1. Authentication
1.1.2. Identity Management
1.1.3. External Authentication
1.1.4. Authorization
1.2. Configuration
1.2.1. Maven Dependencies
1.2.2. Enabling the Security Interceptor
1.2.3. Third Party Dependencies

The Seam Security module provides a number of useful features for securing your Java EE application, which are briefly summarised in the following sections. The rest of the chapters contained in this documentation each focus on one major aspect of each of the following features.

The Maven artifacts for all Seam modules are hosted within the JBoss Maven repository. Please refer to the Maven Getting Started Guide for information about configuring your Maven installation to use the JBoss repository.

To use Seam Security within your Maven-based project, it is advised that you import the Seam BOM (Bill of Materials) which declares the versions for all Seam modules. First declare a property value for ${seam.version} as follows:


<properties>
  <seam.version>3.0.0.Final</seam.version>
</properties>

You can check the JBoss Maven Repository directly to determine the latest version of the Seam BOM to use.

Now add the following lines to the list of dependencies within the dependencyManagement section of your project's pom.xml file:


<dependency>
  <groupId>org.jboss.seam</groupId>
  <artifactId>seam-bom</artifactId>
  <version>${seam.version}</version>
  <type>pom</type>
  <scope>import</scope>
</dependency>

Once that is done, add the following dependency (no version is required as it comes from seam-bom):


<dependency>
  <groupId>org.jboss.seam.security</groupId>
  <artifactId>seam-security</artifactId>
</dependency>

It is also possible to import the security module as separate API and implementation modules, for situations where you may not want to use the default implementation (such as testing environments where you may wish to substitute mock objects instead of the actual implementation). To do this, the following dependencies may be declared instead:


<dependency>
  <groupId>org.jboss.seam.security</groupId>
  <artifactId>seam-security-api</artifactId>
</dependency>

<dependency>
  <groupId>org.jboss.seam.security</groupId>
  <artifactId>seam-security-impl</artifactId>
</dependency>

If you wish to use the external authentication module in your application to allow authentication using OpenID or SAML, then add the following dependency also:


<dependency>
  <groupId>org.jboss.seam.security</groupId>
  <artifactId>seam-security-external</artifactId>
</dependency>