Skip to content

Commit c45f64c

Browse files
committed
Refactored the package name.
1 parent c346e24 commit c45f64c

30 files changed

Lines changed: 114 additions & 49 deletions

operator/internal/telemetry/telemetry.go

Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,26 +20,24 @@ var telemetryInterval = 24 * time.Hour
2020
// officialScanTypes contains the list of official secureCodeBox Scan Types.
2121
// Unofficial Scan Types should be reported as "other" to avoid leakage of confidential data via the scan-types name
2222
var officialScanTypes map[string]bool = map[string]bool{
23-
"amass": true,
24-
"angularjs-csti-scanner": true,
25-
"git-repo-scanner": true,
26-
"gitleaks": true,
27-
"kube-hunter": true,
28-
"kubeaudit": true,
29-
"ncrack": true,
30-
"nikto": true,
31-
"nmap": true,
32-
"screenshooter": true,
33-
"ssh-scan": true,
34-
"sslyze": true,
35-
"trivy": true,
36-
"wpscan": true,
37-
"zap-baseline-scan": true,
38-
"zap-api-scan": true,
39-
"zap-full-scan": true,
40-
"zap-extended-baseline-scan": true,
41-
"zap-extended-api-scan": true,
42-
"zap-extended-full-scan": true,
23+
"amass": true,
24+
"angularjs-csti-scanner": true,
25+
"git-repo-scanner": true,
26+
"gitleaks": true,
27+
"kube-hunter": true,
28+
"kubeaudit": true,
29+
"ncrack": true,
30+
"nikto": true,
31+
"nmap": true,
32+
"screenshooter": true,
33+
"ssh-scan": true,
34+
"sslyze": true,
35+
"trivy": true,
36+
"wpscan": true,
37+
"zap-baseline-scan": true,
38+
"zap-api-scan": true,
39+
"zap-full-scan": true,
40+
"zap-extended-scan": true,
4341
}
4442

4543
// telemetryData submitted by operator

scanners/zap-extended/.helmignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
parser/
44
scanner/*.*
5-
scanner/scbzapv2/
5+
scanner/zapclient/
66
scanner/tests/
77
examples/
88

scanners/zap-extended/examples/secureCodeBox.io-scan/scan.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
apiVersion: "execution.securecodebox.io/v1"
33
kind: Scan
44
metadata:
5-
name: "zap-extended-baseline-securecodebox"
5+
name: "zap-extended-scan-securecodebox"
66
labels:
77
organization: "OWASP"
88
spec:
Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
FROM python:3.9.0-alpine
2-
COPY . /zap-extended/
3-
RUN pip3 install -r /zap-extended/requirements.txt
4-
RUN addgroup --system --gid 1001 zap-extended && adduser zap-extended --system --uid 1001 --ingroup zap-extended
2+
COPY . /zap-client/
3+
RUN pip3 install -r /zap-client/requirements.txt
4+
RUN addgroup --system --gid 1001 zap-client && adduser zap-client --system --uid 1001 --ingroup zap-client
55
USER 1001
66
CMD ["/bin/sh"]
7-
WORKDIR /zap-extended
8-
ENTRYPOINT ["python3", "-m", "scbzapv2"]
7+
WORKDIR /zap-client
8+
ENTRYPOINT ["python3", "-m", "zapclient"]

scanners/zap-extended/scanner/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ unit-test:
1818

1919
docker-test:
2020
@echo "Running local Integrations Tests based on docker-compose..."
21-
pytest ./tests/test_integration_docker_local.py --log-cli-level "INFO"
21+
pytest ./tests/test_integration_docker_local.py --log-cli-level "DEBUG"
2222

2323
local-test:
2424
@echo "Running local Integrations Tests based on local ZAP + docker-compose..."
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
version: "3"
2+
services:
3+
bodgeit:
4+
image: docker.io/psiinon/bodgeit:latest
5+
deploy:
6+
replicas: 1
7+
restart_policy:
8+
condition: any
9+
ports:
10+
- "8080:8080"
11+
healthcheck:
12+
interval: 1m
13+
retries: 3
14+
test:
15+
- CMD
16+
- curl
17+
- -f
18+
- http://bodgeit:8080/bodgeit/
19+
timeout: 10s
20+
juiceshop:
21+
image: docker.io/bkimminich/juice-shop:latest
22+
deploy:
23+
replicas: 1
24+
restart_policy:
25+
condition: any
26+
ports:
27+
- "3000:3000"
28+
healthcheck:
29+
interval: 1m
30+
retries: 3
31+
test:
32+
- CMD
33+
- wget
34+
- --spider
35+
- http://juiceshop:3000/#/
36+
timeout: 10s
37+
petstore:
38+
image: docker.io/swaggerapi/petstore
39+
deploy:
40+
replicas: 1
41+
restart_policy:
42+
condition: any
43+
ports:
44+
- "8000:8080"
45+
environment:
46+
- SWAGGER_BASE_PATH=/v2
47+
- SWAGGER_HOST=http://localhost:8000
48+
- SWAGGER_URL=http://localhost:8000
49+
# healthcheck:
50+
# interval: 1m
51+
# retries: 3
52+
# test:
53+
# - CMD
54+
# - wget
55+
# - --spider
56+
# - http://petstore/
57+
# timeout: 10s

scanners/zap-extended/scanner/docker-compose.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ services:
124124
- ./tests/mocks/scan-full-petstore-docker/:/home/securecodebox/configs/
125125
- ./tests/results/:/home/securecodebox/results/
126126
entrypoint: ['python3',
127-
'-m', 'scbzapv2',
127+
'-m', 'zapclient',
128128
'--report-type', 'XML',
129129
'--zap-url', 'zap:8090',
130130
'--output-folder',

scanners/zap-extended/scanner/tests/test_integration_docker_local.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
from zapv2 import ZAPv2
1111
from requests.exceptions import ConnectionError
1212

13-
from scbzapv2.zap_extended import ZapExtended
13+
from zapclient.zap_extended import ZapExtended
1414

1515
def is_responsive(url):
1616
try:

scanners/zap-extended/scanner/tests/test_integration_zap_local.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
from zapv2 import ZAPv2
88
from requests.exceptions import ConnectionError
99

10-
from scbzapv2.zap_extended import ZapExtended
10+
from zapclient.zap_extended import ZapExtended
1111

1212
def is_responsive(url):
1313
try:

scanners/zap-extended/scanner/tests/test_zap_configuration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
from unittest.mock import MagicMock, Mock
44
from unittest import TestCase
55

6-
from scbzapv2.zap_configuration import ZapConfiguration
6+
from zapclient.zap_configuration import ZapConfiguration
77

88
class ZapConfigurationTests(TestCase):
99

0 commit comments

Comments
 (0)