SlideShare a Scribd company logo
1 of 35
Download to read offline
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Integrating security testing into your
container build pipeline
Aditya Patel
Security Architect
AWS
S D D 3 0 8
Avik Mukherjee
Senior Consultant
AWS
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Goals
• Learn about container security using DevSecOps
• Learn about open-source container security tools and standards
• Learn about AWS development tools and DevOps services
• Have fun while you’re at it!
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Why is container security different?
Server
Host OS
Hypervisor
Guest OS Guest OS
Bins/libs Bins/libs
Cats
application
Dogs
application
Virtual machines
Server
Host OS
Container engine
Bins/libs
Cats
application
Cats
application
Bins/libs
Dogs
application
Dogs
application
Containers
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Containers on AWS
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
AWS shared responsibility model
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Amazon ECS: AWS shared responsibility model
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
AWS Fargate: AWS shared responsibility model
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Automated pipelines: DevSecOps
Speaking of automation, you should automate everything, including
• Code and container builds
• Infrastructure via infrastructure as code patterns
• Deployments
• Process of making things self-healing
• Security!
Make it fast and easy for your team to do the right thing!
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Container security threats
• Host security
• Image security
• Denial of service
• Credentials and secrets
• Container breakouts
• Runtime security
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Container security threats
• Host security
• Image security
• Denial of service
• Credentials and secrets
• Container breakouts
• Runtime security
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Security best practices
for container images
• Less is more (secure)
• No secrets in them
• One service per container
• Minimize container footprint
• Include only what is needed at
runtime
Bootfs
Kernel
Base image
Image
Image
Container
References
parent
image
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Security best practices
for container images
• Use known and trusted base
images
• Scan the image for CVEs
• Specify USER in Dockerfile
(otherwise it’s a root)
• Use unique and informative
image tags
• Be able to tell which commit
at a glance
Bootfs
Kernel
Base image
Image
Image
Container
References
parent
image
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Image security
• Docker linting: Validation of Docker configuration (PCI DSS v3.2.1
Req 2.2)
• hadolint
• dockerfile_lint
• Secrets scanning in images (PCI DSS v3.2.1 Req 6.3.1)
• truffleHog
• git-secrets
• Vulnerability scanning of images in your build pipeline (PCI DSS v3.2.1 Req 6.1)
• Anchore Open-Source Engine
• CoreOS Clair
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
DevSecOps container pipeline
AWS CodeBuild
AWS CodeCommit
Task definition
Dockerfile
FROM centos:centos7
MAINTAINER cb@demo.com
RUN yum -y update
RUN yum -y install openssh-server
U
SER sshduser
EXPOSE 5432
ENTRYPOINT sshd
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
DevSecOps container pipeline
Developers Security engineers Ops engineers
AWS CodeBuild
AWS CodeCommit
Task definition
Dockerfile
FROM centos:centos7
MAINTAINER cb@demo.com
RUN yum -y update
RUN yum -y install openssh-server
U
SER sshduser
EXPOSE 5432
ENTRYPOINT sshd
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
DevSecOps container pipeline
Docker image
Validate configuration > Merge >
Scan for secrets > Merge >
Developers Security engineers Ops engineers
AWS CodeBuild
AWS CodeCommit
Task definition
Dockerfile
FROM centos:centos7
MAINTAINER cb@demo.com
RUN yum -y update
RUN yum -y install openssh-server
U
SER sshduser
EXPOSE 5432
ENTRYPOINT sshd
➢ python ./check_dockerfile.py
./examples/Dockerfile-demo
|jq ".warnings.warnings[].message"
"yum clean all is not used"
"installing SSH in a container is not recommended"
"No 'USER' instruction"
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
DevSecOps container pipeline
Developers Security engineers Ops engineers
AWS CodeBuild
AWS CodeCommit
Task definition
Dockerfile
FROM centos:centos7
MAINTAINER cb@demo.com
RUN yum -y update
RUN yum -y install openssh-server
U
SER sshduser
EXPOSE 5432
ENTRYPOINT sshd
Docker image
Validate configuration > Merge >
Scan for secrets > Merge >
➢ python ./check_dockerfile.py
./examples/Dockerfile-demo
|jq ".warnings.warnings[].message"
"yum clean all is not used"
"installing SSH in a container is not recommended"
"No 'USER' instruction"
Amazon EC2
container
registry
Scan Docker image > Publish >
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Credentials and secrets
AWS has Parameter Store and AWS
Secrets Manager to store your secrets
They are integrated into Amazon ECS,
but you need to call them within the
pod on Kubernetes via AWS CLI or
SDK
Assigning an IAM role to an instance,
task, or function means that the right
AWS access key and secret to call the
AWS CLI or SDK are transparently
obtained and rotated
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
AWS CodePipeline
AWS CodeCommit
(application repo)
Developer Amazon CloudWatch
event rule
Pull
request
AWS Lambda
function
Dockerfile
linting
Secrets
scanning
Vulnerability
scanning
Image
build
6. Triggers AWS
Lambda function
AWS CodeBuild AWS CodeBuild AWS CodeBuild AWS CodeBuild
Configs
Development
AWS Cloud9
AWS Security Hub
1. Pull request
2. Triggers AWS
CodePipeline
3. Pushes vulnerabilities to
AWS Security Hub
Amazon ECR
4. Builds and
pushes imageto
Amazon ECR
5. AWS CodeBuild
success/failure
triggers rule
7. Adds feedback
to pull request
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Integrating security testing into your container build
pipeline: Workshop prerequisites
• Start with https://container-devsecops.awssecworkshops.com
• Module 0: Environment Setup (15 min.)
• Use AWS Event Engine Option (first option)
• Use your Hash to login to your AWS account
Use
“us-east-2”
Use
“AWS Event
Engine”
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Integrating security testing into your container build
pipeline: Module 1
• Start with https://container-devsecops.awssecworkshops.com
• Module 1: Dockerfile linting (15 mins)
• Create buildspec file
• Add hadolint configuration
• Module 2: Secrets scanning
• Module 3: Vulnerability scanning
• Module 4: Pipeline testing
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Integrating security testing into your container build
pipeline: Module 2
• Start with https://container-devsecops.awssecworkshops.com
• Module 1: Dockerfile linting
• Module 2: Secrets scanning (15 mins)
• Create buildspec file
• Add truffleHog RegEx configuration
• Module 3: Vulnerability scanning
• Module 4: Pipeline testing
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Integrating security testing into your container build
pipeline: Module 3
• Start with https://container-devsecops.awssecworkshops.com
• Module 1: Dockerfile linting
• Module 2: Secrets scanning
• Module 3: Vulnerability scanning (15 mins)
• Create buildspec file
• Add command to run Anchore
• Module 4: Pipeline testing
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Integrating security testing into your container build
pipeline: Module 4
• Start with https://container-devsecops.awssecworkshops.com
• Module 1: Dockerfile linting
• Module 2: Secrets scanning
• Module 3: Vulnerability scanning
• Module 4: Pipeline testing (15 mins)
• Make a commit
• View feedback loop
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
AWS CodeCommit (application
repo)
Branches
Development
Master
Developer
1. Commit
2. Pull
request
AWS CodeCommit
(config repo)
ConfigsPull request
Dev → master
= Manual
= Automated
AWS Cloud9
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
AWS CodePipeline
Amazon
CloudWatch
event rule
3. Triggers rule
4. Triggers
AWS CodePipeline
Pull
request
Dockerfilelinting
AWS CodeBuild
Configs
Development
5
AWS CodeCommit (application
repo)
Branches
Development
Master
Developer
1. Commit
2. Pull
request
AWS CodeCommit
(config repo)
ConfigsPull request
Dev → master
= Manual
= Automated
AWS Cloud9
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Secrets
scanning
AWS CodeBuild
6
AWS CodePipeline
Amazon
CloudWatch
event rule
3. Triggers rule
4. Triggers
AWS CodePipeline
Pull
request
Dockerfile linting
AWS CodeBuild
Configs
Development
5
AWS CodeCommit (application
repo)
Branches
Development
Master
Developer
1. Commit
2. Pull
request
AWS CodeCommit
(config repo)
ConfigsPull request
Dev → master
= Manual
= Automated
AWS Cloud9
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Vulnerability
scanning
AWS CodeBuild
7
Secrets
scanning
AWS CodeBuild
6
AWS CodePipeline
Amazon
CloudWatch
event rule
3. Triggers rule
4. Triggers
AWS CodePipeline
Pull
request
Dockerfile linting
AWS CodeBuild
Configs
Development
5
AWS CodeCommit (application
repo)
Branches
Development
Master
Developer
1. Commit
2. Pull
request
AWS CodeCommit
(config repo)
ConfigsPull request
Dev → master
= Manual
= Automated
AWS Cloud9
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
AWS Security Hub
Amazon
VPC
AWS Fargate
(running Anchore)
8. Scan image for
vulnerabilities
9. Send findingsto AWS
Security Hub
Vulnerability
scanning
AWS CodeBuild
7
Secrets
scanning
AWS CodeBuild
6
AWS CodePipeline
Amazon
CloudWatch
event rule
3. Triggers rule
4. Triggers
AWS CodePipeline
Pull
request
Dockerfile linting
AWS CodeBuild
Configs
Development
5
AWS CodeCommit (application
repo)
Branches
Development
Master
Developer
1. Commit
2. Pull
request
AWS CodeCommit
(config repo)
ConfigsPull request
Dev → master
= Manual
= Automated
AWS Cloud9
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Image
build
Amazon ECR
AWS CodeBuild
10
11. Build image
and push to
Amazon ECR
AWS Security Hub
Amazon
VPC
AWS Fargate
(running Anchore)
8. Scan image for
vulnerabilities
9. Send findingsto AWS
Security Hub
Vulnerability
scanning
AWS CodeBuild
7
Secrets
scanning
AWS CodeBuild
6
AWS CodePipeline
Amazon
CloudWatch
event rule
3. Triggers rule
4. Triggers
AWS CodePipeline
Pull
request
Dockerfile linting
AWS CodeBuild
Configs
Development
5
AWS CodeCommit (application
repo)
Branches
Development
Master
Developer
1. Commit
2. Pull
request
AWS CodeCommit
(config repo)
ConfigsPull request
Dev → master
= Manual
= Automated
AWS Cloud9
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
Amazon
CloudWatch
event rule
AWS Lambda
function
14. Adds
feedback to
pull request
13. Triggers AWS
Lambda function
12. AWS CodeBuild success/failure triggers rule
Image
build
Amazon ECR
AWS CodeBuild
10
11. Build image
and push to
Amazon ECR
AWS Security Hub
Amazon
VPC
AWS Fargate
(running Anchore)
8. Scan image for
vulnerabilities
9. Send findingsto AWS
Security Hub
Vulnerability
scanning
AWS CodeBuild
7
Secrets
scanning
AWS CodeBuild
6
AWS CodePipeline
Amazon
CloudWatch
event rule
3. Triggers rule
4. Triggers
AWS CodePipeline
Pull
request
Dockerfile linting
AWS CodeBuild
Configs
Development
5
AWS CodeCommit (application
repo)
Branches
Development
Master
Developer
1. Commit
2. Pull
request
AWS CodeCommit
(config repo)
ConfigsPull request
Dev → master
= Manual
= Automated
AWS Cloud9
Thank you!
Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.

More Related Content

What's hot

Ensure the integrity of your code for fast and secure deployments - SDD319 - ...
Ensure the integrity of your code for fast and secure deployments - SDD319 - ...Ensure the integrity of your code for fast and secure deployments - SDD319 - ...
Ensure the integrity of your code for fast and secure deployments - SDD319 - ...Amazon Web Services
 
Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...
Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...
Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...Amazon Web Services
 
An open-source adventure in the cloud, containers, and incident response - SE...
An open-source adventure in the cloud, containers, and incident response - SE...An open-source adventure in the cloud, containers, and incident response - SE...
An open-source adventure in the cloud, containers, and incident response - SE...Amazon Web Services
 
Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019
Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019 Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019
Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019 Amazon Web Services
 
Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019
Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019 Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019
Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019 Amazon Web Services
 
The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019
The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019 The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019
The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019 Amazon Web Services
 
Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...
Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...
Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...Amazon Web Services
 
Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019
Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019 Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019
Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019 Amazon Web Services
 
Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...
Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...
Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...Amazon Web Services
 
Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019
Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019 Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019
Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019 Amazon Web Services
 
Architecting security and governance through policy guardrails in Amazon EKS ...
Architecting security and governance through policy guardrails in Amazon EKS ...Architecting security and governance through policy guardrails in Amazon EKS ...
Architecting security and governance through policy guardrails in Amazon EKS ...Amazon Web Services
 
How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...
How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...
How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...Amazon Web Services
 
Evolving perimeters with guardrails, not gates: Improving developer agility -...
Evolving perimeters with guardrails, not gates: Improving developer agility -...Evolving perimeters with guardrails, not gates: Improving developer agility -...
Evolving perimeters with guardrails, not gates: Improving developer agility -...Amazon Web Services
 
DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019
DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019 DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019
DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019 Amazon Web Services
 
AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019
AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019 AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019
AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019 Amazon Web Services
 
New ways to automate compliance verification on AWS using provable security -...
New ways to automate compliance verification on AWS using provable security -...New ways to automate compliance verification on AWS using provable security -...
New ways to automate compliance verification on AWS using provable security -...Amazon Web Services
 
Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019
 Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019  Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019
Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019 Amazon Web Services
 
Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019
Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019 Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019
Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019 Amazon Web Services
 
Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...
Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...
Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...Amazon Web Services
 
Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019
Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019 Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019
Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019 Amazon Web Services
 

What's hot (20)

Ensure the integrity of your code for fast and secure deployments - SDD319 - ...
Ensure the integrity of your code for fast and secure deployments - SDD319 - ...Ensure the integrity of your code for fast and secure deployments - SDD319 - ...
Ensure the integrity of your code for fast and secure deployments - SDD319 - ...
 
Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...
Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...
Build a PCI SAQ A-EP-compliant serverless service to manage credit card payme...
 
An open-source adventure in the cloud, containers, and incident response - SE...
An open-source adventure in the cloud, containers, and incident response - SE...An open-source adventure in the cloud, containers, and incident response - SE...
An open-source adventure in the cloud, containers, and incident response - SE...
 
Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019
Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019 Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019
Security best practices the well-architected way - SDD318 - AWS re:Inforce 2019
 
Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019
Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019 Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019
Build security into your golden AMI pipeline - DEM08 - AWS reInforce 2019
 
The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019
The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019 The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019
The fundamentals of AWS cloud security - FND209-R - AWS re:Inforce 2019
 
Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...
Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...
Root CA hierarchies for AWS Certificate Manager (ACM) Private CA - FND320 - A...
 
Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019
Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019 Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019
Data encryption concepts in AWS - FND302 - AWS re:Inforce 2019
 
Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...
Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...
Build end-to-end IT lifecycle management on AWS - FND301-R - AWS re:Inforce 2...
 
Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019
Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019 Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019
Balancing cloud innovation and security - GRC317 - AWS re:Inforce 2019
 
Architecting security and governance through policy guardrails in Amazon EKS ...
Architecting security and governance through policy guardrails in Amazon EKS ...Architecting security and governance through policy guardrails in Amazon EKS ...
Architecting security and governance through policy guardrails in Amazon EKS ...
 
How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...
How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...
How to secure your Active Directory deployment on AWS - FND306-R - AWS re:Inf...
 
Evolving perimeters with guardrails, not gates: Improving developer agility -...
Evolving perimeters with guardrails, not gates: Improving developer agility -...Evolving perimeters with guardrails, not gates: Improving developer agility -...
Evolving perimeters with guardrails, not gates: Improving developer agility -...
 
DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019
DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019 DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019
DevSecOps: Integrating security into pipelines - SDD310 - AWS re:Inforce 2019
 
AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019
AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019 AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019
AWS Executive Security Simulation - FND201-R - AWS re:Inforce 2019
 
New ways to automate compliance verification on AWS using provable security -...
New ways to automate compliance verification on AWS using provable security -...New ways to automate compliance verification on AWS using provable security -...
New ways to automate compliance verification on AWS using provable security -...
 
Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019
 Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019  Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019
Your first compliance-as-code - GRC305-R - AWS re:Inforce 2019
 
Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019
Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019 Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019
Using analytics to set access controls in AWS - SDD204 - AWS re:Inforce 2019
 
Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...
Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...
Architect proper segmentation for PCI DSS workloads on AWS - GRC306 - AWS re:...
 
Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019
Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019 Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019
Establishing AWS as a trusted partner - GRC325 - AWS re:Inforce 2019
 

Similar to Integrating security testing into your container build pipeline - SDD308 - AWS re:Inforce 2019

End-to-End CI/CD at scale with Infrastructure-as-Code on AWS
End-to-End CI/CD at scale with Infrastructure-as-Code on AWSEnd-to-End CI/CD at scale with Infrastructure-as-Code on AWS
End-to-End CI/CD at scale with Infrastructure-as-Code on AWSBhuvaneswari Subramani
 
From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019AWS Summits
 
From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019Amazon Web Services
 
AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...
AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...
AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...Amazon Web Services
 
CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019
CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019
CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019Bhuvaneswari Subramani
 
GPSTEC304_Shipping With PorpoiseA K8s Story
GPSTEC304_Shipping With PorpoiseA K8s StoryGPSTEC304_Shipping With PorpoiseA K8s Story
GPSTEC304_Shipping With PorpoiseA K8s StoryAmazon Web Services
 
AWS CodeDeploy: Manage Deployment Complexity
AWS CodeDeploy: Manage Deployment ComplexityAWS CodeDeploy: Manage Deployment Complexity
AWS CodeDeploy: Manage Deployment ComplexityAmazon Web Services
 
DevOps Spain 2019. Pedro Mendoza-AWS
DevOps Spain 2019. Pedro Mendoza-AWSDevOps Spain 2019. Pedro Mendoza-AWS
DevOps Spain 2019. Pedro Mendoza-AWSatSistemas
 
Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집
Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집
Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집Amazon Web Services Korea
 
Transforming Software Development
Transforming Software DevelopmentTransforming Software Development
Transforming Software DevelopmentAmazon Web Services
 
Aws container webinar day 2
Aws container webinar day 2Aws container webinar day 2
Aws container webinar day 2HoseokSeo7
 
CI/CD pipelines on AWS - Builders Day Israel
CI/CD pipelines on AWS - Builders Day IsraelCI/CD pipelines on AWS - Builders Day Israel
CI/CD pipelines on AWS - Builders Day IsraelAmazon Web Services
 
A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools
A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer ToolsA Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools
A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer ToolsAmazon Web Services
 
Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...
Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...
Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...Amazon Web Services
 
ACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer ToolsACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer ToolsAWS User Group Kochi
 
DEV326_DevOps Essentials An Introductory Workshop on CICD Practices
DEV326_DevOps Essentials An Introductory Workshop on CICD PracticesDEV326_DevOps Essentials An Introductory Workshop on CICD Practices
DEV326_DevOps Essentials An Introductory Workshop on CICD PracticesAmazon Web Services
 
Continuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web ServicesContinuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web ServicesJulien SIMON
 
Automate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeployAutomate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeployAmazon Web Services
 
Transforming Software Development
Transforming Software DevelopmentTransforming Software Development
Transforming Software DevelopmentAmazon Web Services
 

Similar to Integrating security testing into your container build pipeline - SDD308 - AWS re:Inforce 2019 (20)

End-to-End CI/CD at scale with Infrastructure-as-Code on AWS
End-to-End CI/CD at scale with Infrastructure-as-Code on AWSEnd-to-End CI/CD at scale with Infrastructure-as-Code on AWS
End-to-End CI/CD at scale with Infrastructure-as-Code on AWS
 
From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019
 
From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019
 
AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...
AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...
AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Practices (DEV3...
 
CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019
CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019
CI CD using AWS Developer Tools @ AWS Community Day Chennai 2019
 
GPSTEC304_Shipping With PorpoiseA K8s Story
GPSTEC304_Shipping With PorpoiseA K8s StoryGPSTEC304_Shipping With PorpoiseA K8s Story
GPSTEC304_Shipping With PorpoiseA K8s Story
 
AWS CodeDeploy: Manage Deployment Complexity
AWS CodeDeploy: Manage Deployment ComplexityAWS CodeDeploy: Manage Deployment Complexity
AWS CodeDeploy: Manage Deployment Complexity
 
DevOps Spain 2019. Pedro Mendoza-AWS
DevOps Spain 2019. Pedro Mendoza-AWSDevOps Spain 2019. Pedro Mendoza-AWS
DevOps Spain 2019. Pedro Mendoza-AWS
 
Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집
Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집
Amazon Container 환경의 보안 – 최인영, AWS 솔루션즈 아키텍트:: AWS 온라인 이벤트 – 클라우드 보안 특집
 
Transforming Software Development
Transforming Software DevelopmentTransforming Software Development
Transforming Software Development
 
Aws container webinar day 2
Aws container webinar day 2Aws container webinar day 2
Aws container webinar day 2
 
CI/CD pipelines on AWS - Builders Day Israel
CI/CD pipelines on AWS - Builders Day IsraelCI/CD pipelines on AWS - Builders Day Israel
CI/CD pipelines on AWS - Builders Day Israel
 
A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools
A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer ToolsA Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools
A Tale of Two Pizzas: Accelerating Software Delivery with AWS Developer Tools
 
Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...
Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...
Workshop: AWS DevOps Essentials: An Introductory Workshop on CI/CD Best Pract...
 
ACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer ToolsACDKOCHI19 - CI / CD using AWS Developer Tools
ACDKOCHI19 - CI / CD using AWS Developer Tools
 
DEV326_DevOps Essentials An Introductory Workshop on CICD Practices
DEV326_DevOps Essentials An Introductory Workshop on CICD PracticesDEV326_DevOps Essentials An Introductory Workshop on CICD Practices
DEV326_DevOps Essentials An Introductory Workshop on CICD Practices
 
Continuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web ServicesContinuous Deployment with Amazon Web Services
Continuous Deployment with Amazon Web Services
 
Automate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeployAutomate Software Deployments on EC2 with AWS CodeDeploy
Automate Software Deployments on EC2 with AWS CodeDeploy
 
Transforming Software Development
Transforming Software DevelopmentTransforming Software Development
Transforming Software Development
 
AWS Code Services
AWS Code ServicesAWS Code Services
AWS Code Services
 

More from Amazon Web Services

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Amazon Web Services
 
Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...
Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...
Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...Amazon Web Services
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateAmazon Web Services
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSAmazon Web Services
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Amazon Web Services
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Amazon Web Services
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...Amazon Web Services
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsAmazon Web Services
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareAmazon Web Services
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSAmazon Web Services
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAmazon Web Services
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareAmazon Web Services
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWSAmazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckAmazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without serversAmazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...Amazon Web Services
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceAmazon Web Services
 

More from Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...
Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...
Big Data per le Startup: come creare applicazioni Big Data in modalitĂ  Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

Integrating security testing into your container build pipeline - SDD308 - AWS re:Inforce 2019

  • 1. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Integrating security testing into your container build pipeline Aditya Patel Security Architect AWS S D D 3 0 8 Avik Mukherjee Senior Consultant AWS
  • 2. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Goals • Learn about container security using DevSecOps • Learn about open-source container security tools and standards • Learn about AWS development tools and DevOps services • Have fun while you’re at it!
  • 3. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Why is container security different? Server Host OS Hypervisor Guest OS Guest OS Bins/libs Bins/libs Cats application Dogs application Virtual machines Server Host OS Container engine Bins/libs Cats application Cats application Bins/libs Dogs application Dogs application Containers
  • 4. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Containers on AWS
  • 5. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. AWS shared responsibility model
  • 6. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Amazon ECS: AWS shared responsibility model
  • 7. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. AWS Fargate: AWS shared responsibility model
  • 8. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Automated pipelines: DevSecOps Speaking of automation, you should automate everything, including • Code and container builds • Infrastructure via infrastructure as code patterns • Deployments • Process of making things self-healing • Security! Make it fast and easy for your team to do the right thing!
  • 9. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Container security threats • Host security • Image security • Denial of service • Credentials and secrets • Container breakouts • Runtime security
  • 10. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Container security threats • Host security • Image security • Denial of service • Credentials and secrets • Container breakouts • Runtime security
  • 11. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Security best practices for container images • Less is more (secure) • No secrets in them • One service per container • Minimize container footprint • Include only what is needed at runtime Bootfs Kernel Base image Image Image Container References parent image
  • 12. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Security best practices for container images • Use known and trusted base images • Scan the image for CVEs • Specify USER in Dockerfile (otherwise it’s a root) • Use unique and informative image tags • Be able to tell which commit at a glance Bootfs Kernel Base image Image Image Container References parent image
  • 13. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Image security • Docker linting: Validation of Docker configuration (PCI DSS v3.2.1 Req 2.2) • hadolint • dockerfile_lint • Secrets scanning in images (PCI DSS v3.2.1 Req 6.3.1) • truffleHog • git-secrets • Vulnerability scanning of images in your build pipeline (PCI DSS v3.2.1 Req 6.1) • Anchore Open-Source Engine • CoreOS Clair
  • 14. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. DevSecOps container pipeline AWS CodeBuild AWS CodeCommit Task definition Dockerfile FROM centos:centos7 MAINTAINER cb@demo.com RUN yum -y update RUN yum -y install openssh-server U SER sshduser EXPOSE 5432 ENTRYPOINT sshd
  • 15. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. DevSecOps container pipeline Developers Security engineers Ops engineers AWS CodeBuild AWS CodeCommit Task definition Dockerfile FROM centos:centos7 MAINTAINER cb@demo.com RUN yum -y update RUN yum -y install openssh-server U SER sshduser EXPOSE 5432 ENTRYPOINT sshd
  • 16. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. DevSecOps container pipeline Docker image Validate configuration > Merge > Scan for secrets > Merge > Developers Security engineers Ops engineers AWS CodeBuild AWS CodeCommit Task definition Dockerfile FROM centos:centos7 MAINTAINER cb@demo.com RUN yum -y update RUN yum -y install openssh-server U SER sshduser EXPOSE 5432 ENTRYPOINT sshd ➢ python ./check_dockerfile.py ./examples/Dockerfile-demo |jq ".warnings.warnings[].message" "yum clean all is not used" "installing SSH in a container is not recommended" "No 'USER' instruction"
  • 17. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. DevSecOps container pipeline Developers Security engineers Ops engineers AWS CodeBuild AWS CodeCommit Task definition Dockerfile FROM centos:centos7 MAINTAINER cb@demo.com RUN yum -y update RUN yum -y install openssh-server U SER sshduser EXPOSE 5432 ENTRYPOINT sshd Docker image Validate configuration > Merge > Scan for secrets > Merge > ➢ python ./check_dockerfile.py ./examples/Dockerfile-demo |jq ".warnings.warnings[].message" "yum clean all is not used" "installing SSH in a container is not recommended" "No 'USER' instruction" Amazon EC2 container registry Scan Docker image > Publish >
  • 18. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Credentials and secrets AWS has Parameter Store and AWS Secrets Manager to store your secrets They are integrated into Amazon ECS, but you need to call them within the pod on Kubernetes via AWS CLI or SDK Assigning an IAM role to an instance, task, or function means that the right AWS access key and secret to call the AWS CLI or SDK are transparently obtained and rotated
  • 19. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
  • 20. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. AWS CodePipeline AWS CodeCommit (application repo) Developer Amazon CloudWatch event rule Pull request AWS Lambda function Dockerfile linting Secrets scanning Vulnerability scanning Image build 6. Triggers AWS Lambda function AWS CodeBuild AWS CodeBuild AWS CodeBuild AWS CodeBuild Configs Development AWS Cloud9 AWS Security Hub 1. Pull request 2. Triggers AWS CodePipeline 3. Pushes vulnerabilities to AWS Security Hub Amazon ECR 4. Builds and pushes imageto Amazon ECR 5. AWS CodeBuild success/failure triggers rule 7. Adds feedback to pull request
  • 21. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
  • 22. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Integrating security testing into your container build pipeline: Workshop prerequisites • Start with https://container-devsecops.awssecworkshops.com • Module 0: Environment Setup (15 min.) • Use AWS Event Engine Option (first option) • Use your Hash to login to your AWS account Use “us-east-2” Use “AWS Event Engine”
  • 23. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Integrating security testing into your container build pipeline: Module 1 • Start with https://container-devsecops.awssecworkshops.com • Module 1: Dockerfile linting (15 mins) • Create buildspec file • Add hadolint configuration • Module 2: Secrets scanning • Module 3: Vulnerability scanning • Module 4: Pipeline testing
  • 24. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Integrating security testing into your container build pipeline: Module 2 • Start with https://container-devsecops.awssecworkshops.com • Module 1: Dockerfile linting • Module 2: Secrets scanning (15 mins) • Create buildspec file • Add truffleHog RegEx configuration • Module 3: Vulnerability scanning • Module 4: Pipeline testing
  • 25. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Integrating security testing into your container build pipeline: Module 3 • Start with https://container-devsecops.awssecworkshops.com • Module 1: Dockerfile linting • Module 2: Secrets scanning • Module 3: Vulnerability scanning (15 mins) • Create buildspec file • Add command to run Anchore • Module 4: Pipeline testing
  • 26. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Integrating security testing into your container build pipeline: Module 4 • Start with https://container-devsecops.awssecworkshops.com • Module 1: Dockerfile linting • Module 2: Secrets scanning • Module 3: Vulnerability scanning • Module 4: Pipeline testing (15 mins) • Make a commit • View feedback loop
  • 27. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.
  • 28. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. AWS CodeCommit (application repo) Branches Development Master Developer 1. Commit 2. Pull request AWS CodeCommit (config repo) ConfigsPull request Dev → master = Manual = Automated AWS Cloud9
  • 29. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. AWS CodePipeline Amazon CloudWatch event rule 3. Triggers rule 4. Triggers AWS CodePipeline Pull request Dockerfilelinting AWS CodeBuild Configs Development 5 AWS CodeCommit (application repo) Branches Development Master Developer 1. Commit 2. Pull request AWS CodeCommit (config repo) ConfigsPull request Dev → master = Manual = Automated AWS Cloud9
  • 30. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Secrets scanning AWS CodeBuild 6 AWS CodePipeline Amazon CloudWatch event rule 3. Triggers rule 4. Triggers AWS CodePipeline Pull request Dockerfile linting AWS CodeBuild Configs Development 5 AWS CodeCommit (application repo) Branches Development Master Developer 1. Commit 2. Pull request AWS CodeCommit (config repo) ConfigsPull request Dev → master = Manual = Automated AWS Cloud9
  • 31. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Vulnerability scanning AWS CodeBuild 7 Secrets scanning AWS CodeBuild 6 AWS CodePipeline Amazon CloudWatch event rule 3. Triggers rule 4. Triggers AWS CodePipeline Pull request Dockerfile linting AWS CodeBuild Configs Development 5 AWS CodeCommit (application repo) Branches Development Master Developer 1. Commit 2. Pull request AWS CodeCommit (config repo) ConfigsPull request Dev → master = Manual = Automated AWS Cloud9
  • 32. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. AWS Security Hub Amazon VPC AWS Fargate (running Anchore) 8. Scan image for vulnerabilities 9. Send findingsto AWS Security Hub Vulnerability scanning AWS CodeBuild 7 Secrets scanning AWS CodeBuild 6 AWS CodePipeline Amazon CloudWatch event rule 3. Triggers rule 4. Triggers AWS CodePipeline Pull request Dockerfile linting AWS CodeBuild Configs Development 5 AWS CodeCommit (application repo) Branches Development Master Developer 1. Commit 2. Pull request AWS CodeCommit (config repo) ConfigsPull request Dev → master = Manual = Automated AWS Cloud9
  • 33. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Image build Amazon ECR AWS CodeBuild 10 11. Build image and push to Amazon ECR AWS Security Hub Amazon VPC AWS Fargate (running Anchore) 8. Scan image for vulnerabilities 9. Send findingsto AWS Security Hub Vulnerability scanning AWS CodeBuild 7 Secrets scanning AWS CodeBuild 6 AWS CodePipeline Amazon CloudWatch event rule 3. Triggers rule 4. Triggers AWS CodePipeline Pull request Dockerfile linting AWS CodeBuild Configs Development 5 AWS CodeCommit (application repo) Branches Development Master Developer 1. Commit 2. Pull request AWS CodeCommit (config repo) ConfigsPull request Dev → master = Manual = Automated AWS Cloud9
  • 34. Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved. Amazon CloudWatch event rule AWS Lambda function 14. Adds feedback to pull request 13. Triggers AWS Lambda function 12. AWS CodeBuild success/failure triggers rule Image build Amazon ECR AWS CodeBuild 10 11. Build image and push to Amazon ECR AWS Security Hub Amazon VPC AWS Fargate (running Anchore) 8. Scan image for vulnerabilities 9. Send findingsto AWS Security Hub Vulnerability scanning AWS CodeBuild 7 Secrets scanning AWS CodeBuild 6 AWS CodePipeline Amazon CloudWatch event rule 3. Triggers rule 4. Triggers AWS CodePipeline Pull request Dockerfile linting AWS CodeBuild Configs Development 5 AWS CodeCommit (application repo) Branches Development Master Developer 1. Commit 2. Pull request AWS CodeCommit (config repo) ConfigsPull request Dev → master = Manual = Automated AWS Cloud9
  • 35. Thank you! Š 2019, Amazon Web Services, Inc. or its affiliates. Allrights reserved.