crashappsec / crashappsec/chalk

Tool Integration with CoGuard

Open
#23 2 comments 0 reactions 0 assignees View on GitHub
enhancement P3
Dominant language
Nim
Stars
436
Forks
25
PR merge metrics
No merged PRs in 30d

Description

Hi! Love your project!

As I outlined to Mark, I would love to support the tool with our scanning capabilities on infrastructure related files.

We cloned your project and did a scan (find the output attached).

Highlights:
- Generally, ensure that the user running the `ENTRYPOINT` or `CMD` instruction is not root. This is especially interesting for the `./server/Dockerfile`.
- Whenever you install packages via `apt`, `pip`, etc., ensure that you also fix the version. Otherwise, you are always pulling "latest", and future builds of the same Dockerfile may produce different images, which potentially crash (more often than not).
- The same holds for `FROM` instructions inside Dockerfiles. Also a major cause of build fails that we have seen.
- Add `HEALTHCHECK` instructions for longer-running services, so that other containers which may use it can start up when the state is `healthy` or just are able to monitor the health of their environment.

Apart from that, we noticed that you are pulling an unmaintained image (coleifer/sqlite-web, last update 3 years ago). Generally, one should only work with maintained images.

In order to keep track of any future infra-related file (such as Kubernetes, any database configuration), you can add our tool CoGuard for free to your CI/CD pipeline and ensure that future builds always follow best practices in terms of security and scalability. [Here are the instructions from the marketplace](https://github.com/marketplace/actions/coguard-scan-action).:

```yaml
name: Including CoGuard into your GitHub Action
on: [push]
jobs:
create-image-and-run-coguard:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Run the CoGuard CLI Action
uses: coguardio/coguard-scan-action@v0.2.2
with:
username: ${{ secrets.CoGuardUserName }}
password: ${{ secrets.CoGuardPassword }}
```

That can go directly into your `.github/workflows` folder.

Cheers
[coguard_chalk_output.txt](https://github.com/crashappsec/chalk/files/12785159/coguard_chalk_output.txt)

Contributor guide

No contributing guide indexed for this repository

Research direction

Review ./server/Dockerfile, the attached CoGuard scan output, and the .github/workflows location mentioned in the issue. First determine which recommendations are in scope and whether the proposed GitHub Actions integration is wanted; done should be an agreed, testable set of infrastructure changes or a documented decision on the integration.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, github-actions
Domain
ci-cd, devops, infrastructure, security
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.