cd example/gke
terraform init
terraform apply
pipenv run config
# Move config.env to casval/rem
pipenv run freeze
pipenv run deploy
docker run -e MYSQL_DATABASE=casval -e MYSQL_ROOT_PASSWORD=Passw0rd! -d -p 3306:3306 mysql:5.7 --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci
docker run -e PUBLIC_HOSTNAME=localhost -d -p 443:443 -p 9390:9390 mikesplain/openvas:9
pipenv shell
pipenv install -d
pipenv run server
Variable Name | Default Value | Description | Note |
---|---|---|---|
ADMIN_PASSWORD | admin-password | Password for entering CASVAL ORIGIN | app.yaml for GCP environment |
CONFIG_ENV_FILE_PATH | config.env | Relative file path of configuration file from the application root directory of CASVAL REM | app.yaml |
DB_ENDPOINT | 127.0.0.1 | MySQL server endpoint | |
DB_PORT | 3306 | MySQL server port | |
DB_INSTANCE_NAME | - | Google Cloud SQL instance name | |
DB_NAME | casval | MySQL database name | |
DB_USER | root | MySQL user account name | |
DB_PASSWORD | Passw0rd! | MySQL database password | |
GCP_PROJECT_NAME | - | GCP project name that deploys CASVAL REM | |
GCP_REPORT_STORAGE_NAME | - | GCS bucket name that stores raw scan report file | |
KUBERNETES_MASTER_SERVER | - | Kubernetes master endpoint of the REM's cluster | |
KUBERNETES_NAMESPACE | default | Kuberenates namespace name | app.yaml |
OPENVAS_OMP_ENDPOINT | 127.0.0.1 | OpenVAS OMP server endpoint | |
OPENVAS_OMP_PORT | 9390 | OpenVAS OMP server port | app.yaml for GCP environment |
OPENVAS_OMP_USERNAME | admin | OpenVAS server login user name | app.yaml for GCP environment |
OPENVAS_OMP_PASSWORD | admin | OpenVAS server login password | app.yaml for GCP environment |
OPENVAS_SCAN_ENDPOINT | 127.0.0.1 | OpenVAS scan source endpoint | |
OPENVAS_ALIVE_TEST | Consider Alive | OpenVAS option specifies the method to check if a target is reachable | app.yaml for GCP environment |
OPENVAS_PROFILE | Full and very deep | OpenVAS scan configuration profile | app.yaml for GCP environment |
PASSWORD_SALT | password-salt | Salt string for password hash | app.yaml for GCP environment |
CORS_PERMITTED_ORIGINS | * | Origins that allow to send cross origin requests, that value is set to Access-Control-Allow-Origin response header |
app.yaml for GCP environment |
PERMITTED_SOURCE_IP_RANGES | - | Comma separated source IP address ranges that allows to call restricted APIs | app.yaml for GCP environment |
SCAN_MAX_PARALLEL_SESSION | 1 | Max parallel scan session count | app.yaml for GCP environment |
JWT_SECRET_KEY | super-secret | Secret key used for signing JWT credentials | app.yaml for GCP environment |
pipenv run format
CASVAL internally uses openvas_lib for communicating with remote OpenVAS server(s) through OMP protocol. This library is useful but it doesn't support Python 3.x, so we convert their code with 2to3 to make them Python 3.x compatible and include them into the root openvas_lib
directory. If you'd like to update the library with upstream changes, try to do follows. Note that our confirmed revision is the commit bd650702 only.
export CASVAL_ROOT = {YOUR CASVAL REM ROOT DIR}
cd /tmp
git clone https://github.com/golismero/openvas_lib
cd openvas_lib
2to3 -w .
cp openvas_lib/* $CASVAL_ROOT/openvas_lib