Skip to content

Commit f055a50

Browse files
committed
Added context for Tomcat
1 parent fb8a1a4 commit f055a50

2 files changed

Lines changed: 12 additions & 2 deletions

File tree

Ch06_SQLInjection/pom.xml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
<artifactId>javax.servlet-api</artifactId>
1919
</dependency>
2020
<dependency>
21-
<groupId>org.hsqldb</groupId>
22-
<artifactId>hsqldb</artifactId>
21+
<groupId>com.h2database</groupId>
22+
<artifactId>h2</artifactId>
2323
</dependency>
2424
<dependency>
2525
<groupId>org.owasp.esapi</groupId>
@@ -54,6 +54,9 @@
5454
<plugin>
5555
<groupId>org.apache.tomcat.maven</groupId>
5656
<artifactId>tomcat7-maven-plugin</artifactId>
57+
<configuration>
58+
<contextFile>${project.basedir}/src/main/resources/context.xml</contextFile>
59+
</configuration>
5760
</plugin>
5861
<plugin>
5962
<groupId>org.apache.maven.plugins</groupId>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?xml version='1.0' encoding='utf-8'?>
2+
<Context useHttpOnly="false">
3+
<Resource name="sqliDS" auth="Container" type="javax.sql.DataSource"
4+
maxActive="100" maxIdle="30" maxWait="10000"
5+
username="sa" password="sa" driverClassName="org.h2.Driver"
6+
url="jdbc:h2:mem:sqli"/>
7+
</Context>

0 commit comments

Comments
 (0)