Try Devtron Enterprise!
Start Free Trial
LogoLogo
WebsiteDevtron demoGithub RepoJoin Discord
v0.7
v0.7
  • Introduction
  • Getting Started
  • Install Devtron
    • Install Devtron with CI/CD
    • Install Devtron with CI/CD and GitOps (Argo CD)
    • Install Devtron without Integrations
    • Install Devtron on Minikube, Microk8s, K3s, Kind, Cloud VMs
    • Install Devtron on Airgapped Environment
    • Demo on Popular Cloud Providers
    • Backup for Disaster Recovery
    • Uninstall Devtron
    • FAQs
  • Install Devtron Enterprise Trial
  • Devtron Kubernetes Client
  • Configurations
    • Installation Configurations
    • Override Configurations
    • Ingress Setup
  • Global Configurations
    • Host URL
    • GitOps
    • Projects
    • Clusters & Environments
    • Git Accounts
    • Container/OCI Registry
    • Chart Repositories
    • Deployment Charts
    • Authorization
      • SSO Login Services
        • Google
        • GitHub
        • GitLab
        • Microsoft
        • LDAP
        • OIDC
          • Keycloak
          • Okta
        • OpenShift
      • User Permissions
      • Permission Groups
      • API Tokens
    • Notifications
    • Deployment Window
    • Approval Policy
    • External Links
    • Catalog Framework
    • Scoped Variables
    • Plugin Policy
    • Pull Image Digest
    • Tags Policy
    • Filter Condition
    • Lock Deployment Configuration
    • Image Promotion Policy
    • Build Infra
  • Devtron Upgrade
    • Update Devtron from Devtron UI
    • Upgrade to 1.5.0
    • 0.6.x-0.7.x
    • 0.5.x-0.6.x
    • 0.4.x-0.5.x
    • 0.4.x-0.4.x
    • 0.3.x-0.4.x
    • 0.3.x-0.3.x
    • 0.2.x-0.3.x
  • Usage
    • Applications
      • Create a New Application
      • Clone an Existing Application
      • Deploy a Sample Application
      • App Configuration
        • Git Repository
        • Build Configuration
        • Base Deployment Template
          • Deployment
          • Rollout Deployment
          • Job and Cronjob
          • StatefulSets
        • GitOps Configuration
        • Workflow Editor
          • CI Pipeline
            • Pre-Build/Post-Build Stages
            • Override Build Configuration
          • CD Pipeline
        • ConfigMaps
        • Secrets
          • External Secret Operator (ESO)
            • AWS Secrets Manager
            • Google Secrets Manager
            • HashiCorp Vault
        • Environment Overrides
        • Deleting Application
      • Build and Deploy
        • Triggering CI
        • Triggering CD
        • Rollback Deployment
        • Applying Labels to Images
      • App Details
        • Debugging Deployment And Monitoring
        • Using Ephemeral Containers
        • Application Metrics
      • Application Overview
    • Jobs
      • Create a new job
      • Configurations
      • Workflow Editor
      • Trigger Job
      • Overview
    • Application Groups
    • Software Distribution Hub
      • Tenants
      • Release Hub
    • Resource Browser
    • Resource Watcher
    • Charts
      • Charts Overview
      • Deploy & Observe
      • Examples
        • Deploying Mysql Helm Chart
        • Deploying MongoDB Helm Chart
      • Chart Group
    • Security
      • Security Scans
      • Security Policies
    • Bulk Edit
    • Integrations
      • Build and Deploy (CI/CD)
      • GitOps (Argo CD)
      • Vulnerability Scanning (Clair)
      • Notifications
      • Monitoring (Grafana)
    • Pipeline Plugins
      • Create Your Plugin
      • Our Plugins
        • Ansible Runner
        • Bitbucket Runner Trigger
        • Codacy
        • Code-Scan
        • Copacetic
        • Container Image Exporter
        • Copy Container Image
        • Cosign
        • CraneCopy
        • Dependency track - Maven & Gradle
        • Dependency track - NodeJS
        • Dependency track - Python
        • Devtron CD Trigger
        • Devtron CI Trigger
        • Devtron Job Trigger
        • DockerSlim
        • EKS Create Cluster
        • GCS Create Bucket
        • GitHub Pull Request Updater
        • GKE Provisioner
        • GoLang-migrate
        • Jenkins
        • Jira Issue Validator
        • Jira Issue Updater
        • K6 Load Testing
        • Pull images from container repository
        • Semgrep
        • SonarQube
        • SonarQube v1.1.0
        • Terraform CLI
        • Vulnerability Scanning
  • Resources
    • Glossary
    • Troubleshooting
    • Use Cases
      • Devtron Generic Helm Chart To Run CronJob Or One Time Job
      • Connect SpringBoot with Mysql Database
      • Connect Expressjs With Mongodb Database
      • Connect Django With Mysql Database
      • Pull Helm Charts from OCI Registry
    • Telemetry Overview
    • Devtron on Graviton
    • Release Notes
Powered by GitBook
On this page
  • Introduction
  • Where to Initiate the Scan
  • Before Building Artifact
  • After Building Container Image
  • Before Triggering Deployment
  • During Helm App Deployment
  • Extras
  • Scans and Policies

Was this helpful?

Export as PDF
  1. Usage

Security

PreviousChart GroupNextSecurity Scans

Last updated 1 month ago

Was this helpful?

Introduction

Devtron provides capabilities across your software development life cycle for both: the default CI/CD solution by Devtron as well as your existing CI/CD Tools.

One of the key components of DevSecOps is the detection of security risks. Currently, Devtron supports the following types of scanning:

  • Image Scan

  • Code Scan

  • Kubernetes Manifest Scan

Figure 1: Security Scan Results

You can integrate a scanning tool of your choice. By default, Devtron integrates with Trivy using which you can scan for the following issues:

  • Vulnerability

  • License Risks

  • Misconfigurations

  • Exposed Secrets


Where to Initiate the Scan

Before Building Artifact

  1. In your application, go to App Configuration → Workflow Editor.

  2. Click the CI pipeline of your preferred workflow.

  3. Go to the Pre-build stage (tab).

  4. Click + Add Task.

  5. Choose Vulnerability_Scanner v1.0.0 plugin from the list.

  6. Click Update Pipeline.

Based on the results of the scanner, you can also decide whether your CI should proceed further or not. This is possible through Pass/Failure Condition setting in the plugin. In the below example, we are allowing image build only if the no. of high vulnerability is zero.

Results of Pre-CI scan will be visible under Code Scan in the App Details page as shown below.

After Building Container Image

Once a container image is ready, you can scan its base image libraries, stale files, compromised licenses, and many more.

There are 2 options available:

  • Comprehensive scan in Post-Build stage

This section contains the steps for comprehensive scan.

  1. Go to the Post-build stage (tab) of your CI pipeline.

  2. Click + Add Task and choose Vulnerability_Scanner v1.0.0.

  3. Click Update Pipeline.

Results of Post-CI scan will be visible under Image Scan in the App Details page as shown below.

Before Triggering Deployment

There can be a loophole where the original image built in the CI stage gets compromised later (say, in publicly accessible repository). Therefore, you can scan the image and catch issues before deploying it. On top of that, you can also scan manifests to detect misconfigurations and exposed secrets.

  1. Go to the Pre-Deployment stage (tab) of your CD pipeline.

  2. Click + Add Task and choose Vulnerability_Scanner v1.0.0.

  3. Click Update Pipeline.

Results of Pre-CD scan will be visible under Image Scan and Kubernetes Manifest in the App Details page as shown below.

Results of helm app scan will be visible under Image Scan and Kubernetes Manifest in the App Details page as shown below.

Extras

You can also check for vulnerabilities within a specific workload such as job, pod, deployment, etc. There are two ways to perform it:

From App Details

  • Go to App Details (Devtron App/Helm App) → Workloads (under K8 Resources tab).

  • Click a workload, e.g., Pod.

  • On the right-hand side, click the kebab menu (3 vertical dots).

  • Click Check Vulnerabilities.

From Resource Browser

  • Go to Resource Browser.

  • Select a cluster.

  • Click a workload within the Workloads dropdown.

  • Access the Check Vulnerabilities option from the kebab menu present to your selected workload.


Scans and Policies

Who Can Perform This Action?

Users need to have super-admin permission to enable vulnerability scanning and to define security policies in Devtron.

Devtron's Security feature has two primary sections:

When you commit the code, it's essential to scan it before building a . By scanning early, you can catch and fix problems before they become expensive or time-consuming to remediate later.

Figure 2: Scanning in Pre-CI Stage
Figure 3: Setting a Condition
Figure 4: Pre-CI Code Scan Results

Image scan in the Build stage (refer )

Figure 5: Scanning in Post-CI Stage
Figure 6: Post-CI Image Scan Results
Figure 7: Scanning in Pre-CD Stage
Figure 8: Pre-CD Scan Results

During Helm App Deployment

When you , Devtron will scan the image associated with that helm chart and also the manifests, but unlike Devtron Apps, there is no code scan involved.

Figure 9: Helm App Scan Results
Figure 10: Scanning Workloads - App Details Page
Figure 11: Scanning Workloads - Resource Browser

- You can view the vulnerabilities detected across your applications.

- This allows you to define guardrails to block or allow the deployment of container images depending on the vulnerabilities detected.

Security Scans
deploy a helm chart
Security Scans
Security Policies
DevSecOps
container image