Adding jasypt to your Maven 2 or Maven 3 project is very easy, you just need to add the corresponding dependency to your pom.xml:
<dependency> <groupId>org.jasypt</groupId> <artifactId>jasypt</artifactId> <version>{version}</version> <scope>compile</scope> </dependency>
Alternatively, by specifying a classifier you can use the lite artifact, which contains only the essentials in a much smaller .jar file. [More Info].
<dependency> <groupId>org.jasypt</groupId> <artifactId>jasypt</artifactId> <version>{version}</version> <classifier>lite</classifier> <scope>compile</scope> </dependency>
If you are goint to use any integration modules, just add them in the same way:
<dependency> <groupId>org.jasypt</groupId> <artifactId>jasypt-spring31</artifactId> <version>{version}</version> <scope>compile</scope> </dependency>
Adding jasypt to your Maven 1.x project is as easy as it is for Maven 2. Maven 1.x does not support transitive dependencies, but anyway jasypt has none (except icu4j if you're using Java 5 or older):
<dependency> <groupId>org.jasypt</groupId> <artifactId>jasypt</artifactId> <version>{version}</version> </dependency> <!-- ICU4J is not needed if you are using Java 6 or higher, but it will be used if it is present in classpath. --> <dependency> <groupId>com.ibm.icu</groupId> <artifactId>icu4j</artifactId> <version>3.4.4</version> </dependency>