Skip to content

Add rwavsep XXE tests #63

Add rwavsep XXE tests

Add rwavsep XXE tests #63

Workflow file for this run

name: CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
cache: maven
- name: Build with Maven
run: mvn clean package
- name: Test wavsep
run: |
# Run wavsep, mapping the logs
mkdir logs
# Pre create the logfile we need access to
LOG_FILE=localhost.$(date +%F).log
touch logs/$LOG_FILE
chmod -R a+r logs
docker run --rm -v $(pwd)/logs:/opt/tomcat/logs/:rw -v $(pwd)/target/wavsep.war:/opt/tomcat/webapps/wavsep.war:rw -p 8080:8080 -p 3306:3306 zaproxy/wavsep &
sleep 5
docker run --rm -v $(pwd):/zap/wrk/:rw --network host ghcr.io/zaproxy/zaproxy:nightly zap.sh -cmd -port 9090 -silent -autorun /zap/wrk/test/zap-spider.yaml
sleep 5
echo List logs dir
ls -l logs
cat logs/$LOG_FILE
grep "Unable to compile class" logs/$LOG_FILE >> grepout || true
if [ -s grepout ]; then
echo "Compilation failed"
exit 1
else
echo "Compilation passed"
exit 0
fi