28
Putting the Sec in DevSecOps Automating cloud security as an enabler

Putting the Sec in DevSecOps

  • Upload
    others

  • View
    10

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Putting the Sec in DevSecOps

Putting the Secin DevSecOps

Automating cloud security as an enabler

Page 2: Putting the Sec in DevSecOps

Agenda

● Intro to infrastructure as code (IaC)

● Problems facing DevOps & security teams

● Sources of misconfigurations and cloud risk

● Tools to help with IaC security challenges and education

● Addressing cloud security throughout the DevOps lifecycle

● Strategy to implement a DevSecOps strategy

Page 3: Putting the Sec in DevSecOps

Cloud-native technology (and security) is evolving

Infrastructure as code makes DevSecOps possible for cloud

infrastructure

Page 4: Putting the Sec in DevSecOps

$ aws ec2 create-security-group --group-name my-sg --description "My security group"

$ aws ec2 authorize-security-group-ingress --group-id sg-903004f8 --protocol tcp --port 22 --cidr 0.0.0.0/0

$ aws ec2 run-instances --image-id ami-xxxxxxxx --count 1 --instance-type t2.micro --key-name MyKeyPair --security-group-ids sg-903004f8 --subnet-id subnet-6e7f829e

What about ● Readability?● Debugging?● Reusability?● Collaboration?● Versioning?● Security?

Page 5: Putting the Sec in DevSecOps

resource "aws_security_group" "my-sg" { name = "my-sg" ingress { from_port = 22 to_port = 2 protocol = "tcp" cidr_blocks = ["0.0.0.0/0"] }}

resource "aws_instance" "web-server" { ami = "ami-0885b1f6bd170450c" instance_type = "t2.micro" vpc_security_group_ids = [aws_security_group.my-sg.id]}

Page 6: Putting the Sec in DevSecOps

Better, but we’re still missing security

Page 7: Putting the Sec in DevSecOps
Page 8: Putting the Sec in DevSecOps

What are some examples of misconfigurations?

Unencrypted databases

Insecure protocols

Disabled logging

Page 9: Putting the Sec in DevSecOps

Security isn’t happy

1 insecure IaC template

100s of insecure resources

1,000s of alerts

...

~9 Devs : 1 Sec

... ...

Not a real serviceHad real job postings

Page 10: Putting the Sec in DevSecOps

Waterfall

Requirements

Design

Implementation

Testing (incl. Security)

Maintenance

SecurityAnalyze Define Design Test Deploy

SecurityAnalyze Define Design Test Deploy

SecurityAnalyze Define Design Test Deploy

SecurityAnalyze Define Design Test Deploy

SecurityAnalyze Define Design Test Deploy

Agile

Engineering isn’t happy

Page 11: Putting the Sec in DevSecOps

263 Pagesof just text

Page 12: Putting the Sec in DevSecOps

Responsibilities are at odds and shifting

DevOps moves faster and is more agile

Traditional security lags and doesn’t

scale

Shifting security left is hard and

risky

Page 13: Putting the Sec in DevSecOps

The key to developer-first security

AutomatedCodified Integrated

Page 14: Putting the Sec in DevSecOps

Tools that can help

...and tools that can help us learn!

Page 15: Putting the Sec in DevSecOps
Page 16: Putting the Sec in DevSecOps
Page 17: Putting the Sec in DevSecOps

github.com/bridgecrewio/checkov

Page 18: Putting the Sec in DevSecOps

Learn by doing

BUILD

IDENTIFY MISTAKES

CORRECT AND

IMPROVE

Page 19: Putting the Sec in DevSecOps
Page 20: Putting the Sec in DevSecOps

What does embedded security mean?

Every step of the SDLC

Page 21: Putting the Sec in DevSecOps

Security in the whole DevOps lifecycle

RuntimeCI/CDPull requestPre-commitIDE

Available information, representation of actual resource

Complexity, time, risk of finding and fixing errors

Page 22: Putting the Sec in DevSecOps

Pull request

Security in the whole DevOps lifecycle

RuntimeCI/CDPre-commitIDE

Available information, representation of actual resource

Complexity, time, risk of finding and fixing errors

Page 23: Putting the Sec in DevSecOps

Pre-commitIDE

Security in the whole DevOps lifecycle

RuntimeCI/CDPull request

Available information, representation of actual resource

Complexity, time, risk of finding and fixing errors

Page 24: Putting the Sec in DevSecOps

Pull requestPre-commitIDE

Security in the whole DevOps lifecycle

RuntimeCI/CD

Available information, representation of actual resource

Complexity, time, risk of finding and fixing errors

Page 25: Putting the Sec in DevSecOps

Security in the whole DevOps lifecycle

RuntimeCI/CDPull requestPre-commitIDE

Available information, representation of actual resource

Complexity, time, risk of finding and fixing errors

Page 26: Putting the Sec in DevSecOps

Implementing a cloud DevSecOps strategy

Crawl, walk, run

Page 27: Putting the Sec in DevSecOps

How to roll out your IaC governance program

Govern

● Audit results with all stakeholders

● Implement tagging strategy

● Get code to cloud visibility

● Regulate non- compliance usage using VCS

Scale

● Orchestrate scans with build jobs

● Tweak and customize policies

● Evaluate results against known compliance benchmarks

Test

● Schedule scans on repositories

● Audit configuration methods and adjust scanners

● Track errors and manage SLAs for addressing them

Experiment

● Scan individual folders and repos

● Use open source containerized scanners

● Explore various output types and their effectiveness

Page 28: Putting the Sec in DevSecOps

Thank you!Meet me in the chat lounge for questions