Dev Sec Ops
Dev Sec Ops
• Keyword: automation
• Speed-up feedback between teams
• The app will be delivered to the customers easily and successfully.
• DevOps pipeline: flow of information
• New functionality in the app.
• New library, New attack surface, SQLi?
Dev Dev
Qua.
IT Op
Assur Qua.
Assu
r
Why DevSecOps
Companies implementing DevSecOps address vulnerabilities faster
than others
Higher speed and agility: security teams
Implement, Educate & Follow best practices for secure coding and
infrastructure provisioning/ deployment / configuration.
DevSecOps: Securing CI/CD
MEASURE, MONITOR,
REPORT AND ACTION
https://cloudsecurityalliance.org/press-releases/2020/07/07/cloud-security-alliance-publishes-new-paper-the-six-pillars-of-
devsecops-automation/
Why do we need DevSecOps
Static Application Security Testing (SAST) Dynamic Application Security Testing (DAST)
Push
Jenkins: Pipeline Creation
Source Code Security (GitHub)
• Browsing security vulnerability in the GitHub
Advisory DB
• https://github.com/advisories : It allows you to
browse or search for vulnerabilities which affect
open source projects on GitHub
• Below sources are used for vulnerabilities by
GitHub
• The National Vulnerability Database
• A combination of machine learning and human
review to detect vulnerabilities in public commits on
GitHub
• Security advisories on GitHub
• FriendsOfPHP
• Security alerts for vulnerable dependencies
• Automated security updates
• Update vulnerable dependencies in repository
• Managing alerts for vulnerable dependencies
in your organization
Example Web Application: DevSecOps
https://github.com/ocatak/devsecops-tutorial
GitHub repository for the lecture at University of Stavanger
Pipeline
SAST DAST
Dynamic application Container Deployment
Development Static application
Security
security testing security testing
Push
DevSecOps: SAST - SonarQube
It is an open-source tool used for continuous inspection of code quality, static analysis of code to
detect bugs, code smells and security vulnerabilities on 20+ programming languages.
It provides reports on duplicated lines of code, coding standards, unit tests, coverage, code
complexity, comments, bugs etc.
Reduces risks in software development within a short span of time, detects bugs in the code and automatically alerts
developers.
Receives all files as input , stores them in a database, analyses them with barriers and displays it in a dashboard.
Benefits of SonarQube It increases the productivity of Dev team by detecting duplicated & redundant code.
Dev Team receive regular feedback on quality issues and it helps them increase their programming skills.
Code quality becomes part of CI/CD & Development team.
Security flaws detection & remediation.
DevSecOps: SAST - SonarQube
1. git clone https://github.com/ocatak/SonarQube.git
2. sudo npm install sonarqube-scanner
3. Run SonarQube Docker image: docker-compose up –d
4. GitHub: sonar-project.js
DevSecOps: SAST - SonarQube
Push
DevSecOps: DAST - ARACHNI
Push
DevSecOps: Container Security - Anchore
• Anchore allows us to perform detailed
analysis on container images, run
queries, produce reports. Also we can
define our own policies that can be used
with CI/CD pipelines
DevSecOps: Container Security - Anchore
Example Web Application: DevSecOps
https://github.com/ocatak/devsecops-tutorial
GitHub repository for the lecture at University of Stavanger
Pipeline
SAST DAST
Dynamic application Container Deployment
Development Static application
Security
security testing security testing
Push
What We Learned?
• Paradigm-shifting from time consuming Penetration testing Activities
to DevSecOps
• PenTesters use same/similar tools (Kali, Sqlmap, Arachni, Nmap,
Metasplot etc) to perform a security testing to find the vulnerabilities
• We can integrate them into our CI/CD Pipelines
• Speed-Up security checks
Future Challenges
• Complex Tool Integrations
• come from various vendors.
• Adding security tools makes things even more complex.
• time-consuming, labor-intensive approach is incompatible with DevOps’ high-
speed,
• Shifting security left in the SDLC
• Security principles apply to overall organization and not just to security
engineering teams.
• End-of-cycle security testing results in delays and vulnerabilities left in
production
Thank You
F. Ozgur Catak
f.ozgur.catak@gmail.com
https://www.ozgurcatak.org