Skip to content
Open

Demo #229

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file

version: 2
updates:
- package-ecosystem: "pip" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "daily"
5 changes: 3 additions & 2 deletions .github/workflows/gke.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ jobs:
pcc_console_url: ${{ secrets.PCC_CONSOLE_URL }}
pcc_user: ${{ secrets.PCC_USER }}
pcc_pass: ${{ secrets.PCC_PASS }}
image_name: gcr.io/${{ secrets.GKE_PROJECT }}/${{ secrets.IMAGE }}:${{ github.sha }}
image_name: gcr.io/${{ secrets.GKE_PROJECT }}/${{ secrets.IMAGE }}:${{ github.sha }}
project: "GKE Demo"
# Push the Docker image to Google Container Registry
- name: Publish
run: |-
Expand All @@ -68,4 +69,4 @@ jobs:
cat kustomization.yaml
kustomize build . | kubectl apply -f -
kubectl get pods -o wide


20 changes: 13 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
FROM ubuntu:latest
COPY wild.py /
# Pull the minimal Ubuntu image
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LOW  A user for the container has not been created
    Resource: /Dockerfile. | Checkov ID: CKV_DOCKER_3

Description

The policy's primary purpose is to verify that a dedicated user has been explicitly created for running the container. This is essential to avoid running the container with root privileges, which could introduce significant security risks in case of a compromise. Running containers as a non-root user reduces the potential impact of a security breach.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LOW  Healthcheck instructions have not been added to container images
    Resource: /Dockerfile. | Checkov ID: CKV_DOCKER_2

Description

We recommend that you add the HEALTHCHECK instruction to your Docker container images to ensure that health checks are executed against running containers.
An important security control is that of availability.
Adding the HEALTHCHECK instruction to your container image ensures that the Docker engine periodically checks the running container instances against that instruction to ensure that containers are still operational.
Based on the results of the health check, the Docker engine could terminate containers which are not responding correctly, and instantiate new ones.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nghttp2 1.30.0-1ubuntu1 / Dockerfile.FROM

Total vulnerabilities: 1

Critical: 0 High: 1 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2023-44487 HIGH HIGH 7.5 - Open

FROM us-central1-docker.pkg.dev/panw-utd-public-cloud/utd-demo-images/utd-cnsp/ubuntu:malware

# Nginx already present in base image. Just copy the Nginx config
COPY default /etc/nginx/sites-available/default

# Install a vulnerable package
RUN apt update -y
RUN apt install python3-pip git curl wget node-hawk node-minimist -y
RUN pip3 --no-cache-dir install --upgrade awscli boto3
RUN pip3 install gitpython azure-identity azure-storage-blob
RUN curl -sL https://aka.ms/InstallAzureCLIDeb | bash
EXPOSE 8080
ENTRYPOINT [ "python3", "wild.py"]

# Expose the port for access
EXPOSE 80/tcp

# Run the Nginx server
CMD /opt/entrypoint.sh && /usr/sbin/nginx -g daemon off
12 changes: 12 additions & 0 deletions default
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
server {
listen 80 default_server;
listen [::]:80 default_server;

root /usr/share/nginx/html;
index index.html index.htm;

server_name _;
location / {
try_files $uri $uri/ =404;
}
}
2 changes: 1 addition & 1 deletion host/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@ six==1.15.0
supervisor==4.2.2
toml==0.10.2
urllib3==1.26.4
virtualenv==20.4.3
virtualenv==20.29.3
visitor==0.1.3
Werkzeug==1.0.1
57 changes: 29 additions & 28 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,28 +1,29 @@
backports-abc==0.5
certifi==2017.4.17
chardet==3.0.4
click==6.7
Faker==0.7.17
Flask==0.12.2
Flask-SQLAlchemy==2.2
gevent==1.2.2
greenlet==0.4.12
grequests==0.3.0
idna==2.5
ipaddress==1.0.18
itsdangerous==0.24
Jinja2==2.9.6
lxml==4.2.1
MarkupSafe==1.0
MySQL-python==1.2.5
PyJWT==1.5.2
python-dateutil==2.6.0
python-docx==0.8.5
PyYAML==3.12
requests==2.18.1
singledispatch==3.4.0.3
six==1.10.0
SQLAlchemy==1.1.11
tornado==4.5.1
urllib3==1.21.1
Werkzeug==0.14.1

backports-abc==0.5
certifi==2017.4.17
Copy link
Copy Markdown
Contributor

@prisma-cloud-devsecops prisma-cloud-devsecops Bot Sep 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

certifi 2017.4.17 / requirements.txt

Total vulnerabilities: 1

Critical: 1 High: 0 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2023-37920 CRITICAL CRITICAL 9.8 2023.07.22 Open
Vulnerabilities scan results were updated by commit f3bd8c8

chardet==3.0.4
click==6.7
Faker==0.7.17
Flask==0.12.2
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

flask 0.12.2 / requirements.txt

Total vulnerabilities: 3

Critical: 0 High: 3 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2019-1010083 HIGH HIGH 7.5 1.0 Open
CVE-2018-1000656 HIGH HIGH 7.5 0.12.3 Open
CVE-2023-30861 HIGH HIGH 7.5 2.2.5 Open

Flask-SQLAlchemy==2.2
gevent==1.2.2
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gevent 1.2.2 / requirements.txt

Total vulnerabilities: 1

Critical: 1 High: 0 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2023-41419 CRITICAL CRITICAL 9.8 23.9.0 Open

greenlet==0.4.12
grequests==0.3.0
idna==2.5
ipaddress==1.0.18
itsdangerous==0.24
Jinja2==2.9.6
Copy link
Copy Markdown
Contributor

@prisma-cloud-devsecops prisma-cloud-devsecops Bot Sep 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

jinja2 2.9.6 / requirements.txt

Total vulnerabilities: 1

Critical: 0 High: 1 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2019-10906 HIGH HIGH 8.6 2.10.1 Open
Vulnerabilities scan results were updated by commit f3bd8c8

lxml==4.2.1
Copy link
Copy Markdown
Contributor

@prisma-cloud-devsecops prisma-cloud-devsecops Bot Sep 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lxml 4.2.1 / requirements.txt

Total vulnerabilities: 2

Critical: 0 High: 2 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2021-43818 HIGH HIGH 7.1 4.6.5 Open
CVE-2022-2309 HIGH HIGH 7.5 4.9.1 Open
Vulnerabilities scan results were updated by commit f3bd8c8

MarkupSafe==1.0
MySQL-python==1.2.5
PyJWT==1.5.2
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pyjwt 1.5.2 / requirements.txt

Total vulnerabilities: 1

Critical: 0 High: 1 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2022-29217 HIGH HIGH 7.5 2.4.0 Open

python-dateutil==2.6.0
python-docx==0.8.5
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

python-docx 0.8.5 / requirements.txt

Total vulnerabilities: 1

Critical: 0 High: 1 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2016-5851 HIGH HIGH 8.8 0.8.6 Open

PyYAML==3.12
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pyyaml 3.12 / requirements.txt

Total vulnerabilities: 1

Critical: 1 High: 0 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2017-18342 CRITICAL CRITICAL 9.8 5.1 Open

requests==2.18.1
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

requests 2.18.1 / requirements.txt

Total vulnerabilities: 1

Critical: 0 High: 1 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2018-18074 HIGH HIGH 7.5 2.20.0 Open

singledispatch==3.4.0.3
six==1.10.0
SQLAlchemy==1.1.11
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sqlalchemy 1.1.11 / requirements.txt

Total vulnerabilities: 1

Critical: 1 High: 0 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2019-7164 CRITICAL CRITICAL 9.8 1.2.18 Open

tornado==4.5.1
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tornado 4.5.1 / requirements.txt

Total vulnerabilities: 1

Critical: 0 High: 1 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2024-52804 HIGH HIGH 7.5 6.4.2 Open

urllib3==1.21.1
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

urllib3 1.21.1 / requirements.txt

Total vulnerabilities: 3

Critical: 1 High: 2 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
CVE-2018-20060 CRITICAL CRITICAL 9.8 1.23 Open
CVE-2019-11324 HIGH HIGH 7.5 1.24.2 Open
CVE-2023-43804 HIGH HIGH 8.1 1.26.17 Open

Werkzeug==0.14.1
Copy link
Copy Markdown
Contributor

@prisma-cloud-devsecops prisma-cloud-devsecops Bot Sep 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

werkzeug 0.14.1 / requirements.txt

Total vulnerabilities: 7

Critical: 0 High: 7 Medium: 0 Low: 0
Vulnerability IDSeverityCVSSFixed inStatus
PRISMA-2023-0035 HIGH HIGH 7.5 2.3.0 Open
CVE-2024-34069 HIGH HIGH 7.5 3.0.3 Open
CVE-2019-14806 HIGH HIGH 7.5 0.15.3 Open
CVE-2023-25577 HIGH HIGH 7.5 2.2.3 Open
CVE-2023-46136 HIGH HIGH 7.5 2.3.8 Open
CVE-2024-49767 HIGH HIGH 7.5 3.0.6 Open
CVE-2019-14322 HIGH HIGH 7.5 0.15.5 Open
Vulnerabilities scan results were updated by commit f3bd8c8