Skip to content
Snippets Groups Projects
Commit 4c3c1731 authored by Thibault Debatty's avatar Thibault Debatty
Browse files

updated readme and build for all push

parent 51fe6cb4
No related branches found
No related tags found
No related merge requests found
Pipeline #10284 failed
build:
image: docker:20.10.16
# run on a gitlab-runner that is configured with docker-in-docker
tags:
- dind
stage: build
services:
- docker:20.10.16-dind
variables:
# use TLS https://docs.gitlab.com/ee/ci/docker/using_docker_build.html#tls-enabled
# mounts /certs directory for the service and build container
# needed for the Docker client to use the certificates
DOCKER_TLS_CERTDIR: "/certs"
before_script:
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
script:
# use previous image as a cache to speedup build process
- docker pull $CI_REGISTRY_IMAGE:latest || true
- docker build --cache-from $CI_REGISTRY_IMAGE:latest --tag $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG --tag $CI_REGISTRY_IMAGE:latest .
release:
image: docker:20.10.16
# run on a gitlab-runner that is configured with docker-in-docker
tags:
- dind
# only for git tags
only:
- tags
services:
- docker:20.10.16-dind
variables:
# use TLS https://docs.gitlab.com/ee/ci/docker/using_docker_build.html#tls-enabled
# mounts /certs directory for the service and build container
# needed for the Docker client to use the certificates
DOCKER_TLS_CERTDIR: "/certs"
before_script:
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
script:
# use previous image as a cache to speedup build process
- docker pull $CI_REGISTRY_IMAGE:latest || true
# use git tag to tag the image
- docker build --cache-from $CI_REGISTRY_IMAGE:latest --tag $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG --tag $CI_REGISTRY_IMAGE:latest .
- docker push $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG
- docker push $CI_REGISTRY_IMAGE:latest
......
# SQLite Injection
[![pipeline status](https://gitlab.cylab.be/cylab/play/sqlite-injection/badges/main/pipeline.svg)](https://gitlab.cylab.be/cylab/play/sqlite-injection/-/commits/main)
![SQLite Injection](sqlite-injection.png)
An example web application that can be hacked using SQL injection attack. The web app uses a SQLite database.
* it has a search page
......@@ -13,12 +17,20 @@ Simply use this search query (for example):
' union select null, username, password from users where username like '%
```
## Running with Docker
```bash
docker run -p 8000:80 gitlab.cylab.be:8081/cylab/play/sqlite-injection
```
## Testing locally
You can use PHP built-in webserver to test locally:
```
cd public
```bash
git clone https://gitlab.cylab.be/cylab/play/sqlite-injection.git
cd sqlite-injection/public
php -S localhost:8000
```
sqlite-injection.png

106 KiB

0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment