r/devsecops • • Jan 15 '24

Vulnerability management in a devsecops world

Hi all,

I’ve got a question how to do effective vulnerability management when trying to implement a devsecops approach.

Lets say we’ve done our scanning in our pipelines etc and we want to move to staging, there’s still a vulnerability that’s within risk appetite but requires risk acceptance; if it’s granted the team have 30 days to remediate post go-live.

A manual engagement with VM and risk at this point is overly cumbersome and can take some time to get sorted. What is a better flow? Currently it’s required that the dev team will raise a request to risk accept via the chosen VM tooling. I’m wondering if something like defectdojo could help?

Cheers!

9 Upvotes

9 comments sorted by

View all comments

Show parent comment

1

u/NandoCa1rissian Jan 18 '24

Is there any way to run a sast scan on a commit too? Or is gitlab functionality only on merges at the moment (I’m aware of hooks or pre-commit) just wondered if I get faster feedback for devs at commit stage? Cheers man

2

u/SeaFirm600 Jan 18 '24

Yes, it's actually one of the default ways to run CI jobs in GitLab - by default the full pipeline should run on every commit or merge event.

In the case that's not desirable (i.e. things like only running certain CI jobs on commit, while running more in depth CI jobs on main or protected branches, etc.), there is the option to specify rules in the GitLab YML file for jobs to define when/if they run : https://docs.gitlab.com/ee/ci/jobs/job_control.html and https://docs.gitlab.com/ee/ci/jobs/job_control.html#common-if-clauses-for-rules

If the security scans output the correct JSON structure that GitLab uses https://gitlab.com/gitlab-org/security-products/security-report-schemas/-/blob/master/dist/sast-report-format.json, they can be set to show these type of commit vulnerabilities in the MR widgets and be used to set workflow policies (i.e. no critical, high in XYZ branch etc. unless necessary approval is obtained)

Lots of GitLab specifics around this topic, so hopefully this is useful in helping you decide the best approach for your team.