SlideShare a Scribd company logo
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Use Amazon EC2 Systems Manager to
Perform Automated Resilience
Testing in Your CI/CD Pipeline
AWS re:INVENT
D a v e B a k s h a n i
S e n i o r S o f t w a r e E n g i n e e r @ E x p e d i a
W i l l i e W h e e l e r
P r i n c i p a l A p p l i c a t i o n s E n g i n e e r @ E x p e d i a
N o v e m b e r 2 9 , 2 0 1 7
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
In 2016, Expedia, Inc., was
the 11th largest internet
company by revenue at
$8.77B.
THE PRICE OF DOWNTIME—A BACK-OF-THE-
ENVELOPE CALCULATION
Source: https://en.wikipedia.org/wiki/List_of_largest_Internet_companies
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Uptime Downtime
Potential lost
revenue
99% 3.65d $87.7M
99.9% 8.76h $8.77M
99.99% 52.56m $877K
THE PRICE OF DOWNTIME—A BACK-OF-THE-
ENVELOPE CALCULATION
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Keeping our site up protects
tens of millions of dollars per year
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
OUR TALK
• [Overview] Resilience engineering
• [Overview] Amazon EC2 Systems Manager
• [Demo] Attack your app with Amazon EC2 Systems
Manager
• [Demo] Run resilience tests in a CI/CD pipeline
• Implementing other attacks
• Q&A
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
RESILIENCE ENGINEERING
O V E R V I E W O F
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
RESILIENCE ENGINEERING GOALS
Keep the site up
Even when components fail
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
STORAGE MEMORY POWER
TRAFFIC CPU NETWORK
WHAT GOES WRONG (A PARTIAL LIST)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Overprovisioning and
redundancy
Auto-scaling Load-shedding
CAPACITY STRATEGIES
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Fallback/failover Fail silent Fail fast
FAULT-TOLERANCE STRATEGIES
Circuit breaker Circuit breakerCircuit breaker
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
ANATOMY OF A RESILIENCE EXPERIMENT
Attack
system
Identify
desired
response
Verify
response
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
P R O D : R A N D O M I Z E DT E S T : C O N T R O L L E D
RESILIENCE EXPERIMENTS BY ENVIRONMENT
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
RECAP
 Goal: Keep the site up
 Many strategies available
 Run experiments in test and
prod
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AMAZON EC2 SYSTEMS MANAGER
O V E R V I E W O F
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
• Automation
• Inventory
• Maintenance windows
• Parameter store
• Patch management
• State management
• Run command
WHAT I S AMAZON EC 2 SYST EMS MANAGER ?
Capabilities:
Systems Manager is a service to help manage your
Amazon Elastic Compute Cloud (Amazon EC2) and
on-premises instances
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SYSTEMS MANAGER OVERVIEW
Systems Manager Service
EC2
Instance
Systems
Manager Agent
EC2
Instance
On-Prem
Instance
Systems
Manager Agent
Systems
Manager Agent
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Step 1:
Create an IAM role with the
AmazonEC2RoleforSSM
policy
Step 2:
Attach the IAM role to your
EC2 instances
Step 3:
Install the Systems Manager
agent (if it’s not already
there)
SYSTEMS MANAGER SETUP
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SYSTEMS MANAGER IN A NUTSHELL
• Systems Manager documents
• Run command
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
{
"schemaVersion": "2.0",
"description": "Install or uninstall the latest version or specified version of an AWS package.",
"parameters": {
"action": {
"description": "(Required) Specify whether or not to install or uninstall the package.",
"type": "String",
"allowedValues": [ "Install", "Uninstall" ]
},
... other parameters ...
},
"mainSteps": [{
"action": "aws:configurePackage",
"name": "configurePackage",
"inputs": {
"action": "{{ action }}",
"name": "{{ name }}",
"version": "{{ version }}"
}
}]
}
SYSTEMS MANAGER DOCUMENTS
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SYSTEMS MANAGER RUN COMMAND
Supports remote management of instance configuration
Choose
Command
Document
Choose
target
instances
Specify
document
params
Execute
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
RECAP
We learned about:
 Systems Manager capabilities, architecture, and setup
 Systems Manager documents and Run command
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Now the fun stuff
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
ATTACK YOUR APP WITH
AMAZON EC2 SYSTEMS MANAGER
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
ATTACKING SYSTEMS WITH SYSTEMS
MANAGER
Create
Command
Document
for attack
Execute
Run
Command
Systems
Manager
Agent runs
command
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
{
"schemaVersion": "2.0",
"description": "Blackhole an outbound port on an instance",
"parameters": {
"port": {
"type": "String",
"description": "(Required) Specify an outbound port to blackhole."
}
},
"mainSteps": [{
"action": "aws:runShellScript",
"name": "runShellScript",
"inputs": {
"runCommand": [
"iptables -A OUTPUT -p tcp --destination-port {{ port }} -j DROP"
]
}
}]
}
A SYSTEMS MANAGER ATTACK DOCUMENT
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
[DEMO]
ATTACKING YOUR APP WITH SYSTEMS
MANAGER
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SAMPLE APPLICATION: WEATHER REPORT
Weather Report UI
Weather Report API
Weather
Report DB
OpenWeatherMap
API
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Two versions of the app:
• Non-resilient
• Resilient (has breakers)
SAMPLE APPLICATION: WEATHER REPORT
Weather Report UI
Weather Report API
Weather
Report DB
OpenWeatherMap
API
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Two versions of the app:
• Non-resilient
• Resilient (has breakers)
What we’ll cover:
SAMPLE APPLICATION: WEATHER REPORT
Weather Report UI
Weather Report API
Weather
Report DB
OpenWeatherMap
API
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Two versions of the app:
• Non-resilient
• Resilient (has breakers)
What we’ll cover:
• Blackhole attack against DB
SAMPLE APP: WEATHER REPORT
Weather Report UI
Weather Report API
Weather
Report DB
OpenWeatherMap
API
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
[DEMO]
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
 We learned how to use
Systems Manager to
execute an attack
 We saw both
non-resilient and
resilient responses
RECAP
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
RUN RESILIENCE TESTS IN A CI/CD
PIPELINE
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Use CI/CD pipeline for
ongoing verification
RESILIENCE TESTING
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
RESILIENCE TESTING IN A CI/CD PIPELINE
build
deploy
to test
security
scan
perf
tests
release
to test
deploy
to prod
release
to prod
resilience
tests
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
[DEMO]
RESILIENCE TESTING IN A CI/CD PIPELINE
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
WHAT WE’LL COVER
• Build pipeline with three resilience tests:
• Pre-test (happy path)
• Blackhole attack & fallback test
• Post-test (recovery)
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
[DEMO]
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
RECAP
 We embedded our resilience test in a CI/CD pipeline
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
IMPLEMENTING OTHER ATTACKS
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
• Burn CPU
• Burn I/O
• Fail DNS
• Fail Amazon
DynamoDB
• Fail EC2
• Fail S3
• Fill disk
• Kill processes
• Network corruption
• Network latency
• Network loss
• Null route
SIMIAN ARMY ATTACKS
Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Attack scripts are straightforward to implement
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
#!/bin/bash
cat << EOF > /tmp/infiniteburn.sh
#!/bin/bash
while true;
do openssl speed;
done
EOF
for i in {1..`nproc --all`}
do
nohup /bin/bash /tmp/infiniteburn.sh &
done
BURN CPU
Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
#!/bin/bash
cat << EOF > /tmp/loopburnio.sh
#!/bin/bash
while true;
do
dd if=/dev/urandom of=/burn bs=1M count=1024 iflag=fullblock
done
EOF
nohup /bin/bash /tmp/loopburnio.sh &
BURN I/O
Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
#!/bin/bash
# Block all traffic on port 53
iptables -A INPUT -p tcp -m tcp --dport 53 -j DROP
iptables -A INPUT -p udp -m udp --dport 53 -j DROP
FAIL DNS
Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
 We learned how
Systems Manager helps
keep your site up
 Start testing and
enhancing your site
resilience today
WRAPPING UP
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
thankYou([
{
name: "Kuldeep Chowhan",
reasons: [
"Original concept"
]
}, {
name: "Jay Spang",
reasons: [
"Initial implementation in our resilience testing framework",
"Wrote the proposal that led to this presentation"
]
}
])
ACKNOWLEDGMENTS
© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Thank you!
F o r m o r e i n f o r m a t i o n :
h t t p s : / / t e c h b l o g . e x p e d i a . c o m / 2 0 1 7 / 1 1 / 2 1 / r e i n v e n t - 2 0 1 7 - u s e -
e c 2 - s y s t e m s - m a n a g e r - t o - p e r f o r m - a u t o m a t e d - r e s i l i e n c y -
t e s t i n g - i n - y o u r - c i c d - p i p e l i n e /

More Related Content

What's hot

SID301_Using AWS Lambda as a Security Team
SID301_Using AWS Lambda as a Security TeamSID301_Using AWS Lambda as a Security Team
SID301_Using AWS Lambda as a Security Team
Amazon Web Services
 
Application Performance Management on AWS
Application Performance Management on AWSApplication Performance Management on AWS
Application Performance Management on AWS
Amazon Web Services
 
NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...
NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...
NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...
Amazon Web Services
 
SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...
SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...
SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...
Amazon Web Services
 
Five New Security Automation Improvements You Can Make by Using Amazon CloudW...
Five New Security Automation Improvements You Can Make by Using Amazon CloudW...Five New Security Automation Improvements You Can Make by Using Amazon CloudW...
Five New Security Automation Improvements You Can Make by Using Amazon CloudW...
Amazon Web Services
 
MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...
MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...
MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...
Amazon Web Services
 
DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...
DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...
DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...
Amazon Web Services
 
SRV312_Taking Serverless to the Edge
SRV312_Taking Serverless to the EdgeSRV312_Taking Serverless to the Edge
SRV312_Taking Serverless to the Edge
Amazon Web Services
 
Launch Applications the Amazon Way - AWS Online Tech Talks
Launch Applications the Amazon Way - AWS Online Tech TalksLaunch Applications the Amazon Way - AWS Online Tech Talks
Launch Applications the Amazon Way - AWS Online Tech Talks
Amazon Web Services
 
ARC325_Managing Multiple AWS Accounts at Scale
ARC325_Managing Multiple AWS Accounts at ScaleARC325_Managing Multiple AWS Accounts at Scale
ARC325_Managing Multiple AWS Accounts at Scale
Amazon Web Services
 
MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...
MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...
MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...
Amazon Web Services
 
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech TalksAWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
Amazon Web Services
 
Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...
Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...
Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...
Amazon Web Services
 
GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...
GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...
GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...
Amazon Web Services
 
Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...
Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...
Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...
Amazon Web Services
 
How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...
How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...
How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...
Amazon Web Services
 
CON209_Interstella 8888 Learn How to Use Docker on AWS
CON209_Interstella 8888 Learn How to Use Docker on AWSCON209_Interstella 8888 Learn How to Use Docker on AWS
CON209_Interstella 8888 Learn How to Use Docker on AWS
Amazon Web Services
 
GPSTEC306-Continuous Compliance for Healthcare and Life Sciences
GPSTEC306-Continuous Compliance for Healthcare and Life SciencesGPSTEC306-Continuous Compliance for Healthcare and Life Sciences
GPSTEC306-Continuous Compliance for Healthcare and Life Sciences
Amazon Web Services
 
Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...
Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...
Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...
Amazon Web Services
 
Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...
Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...
Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...
Amazon Web Services
 

What's hot (20)

SID301_Using AWS Lambda as a Security Team
SID301_Using AWS Lambda as a Security TeamSID301_Using AWS Lambda as a Security Team
SID301_Using AWS Lambda as a Security Team
 
Application Performance Management on AWS
Application Performance Management on AWSApplication Performance Management on AWS
Application Performance Management on AWS
 
NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...
NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...
NEW LAUNCH! Gain Operational Insights and Take Action on AWS Resources with A...
 
SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...
SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...
SecOps 2021 Today: Using AWS Services to Deliver SecOps - SID304 - re:Invent ...
 
Five New Security Automation Improvements You Can Make by Using Amazon CloudW...
Five New Security Automation Improvements You Can Make by Using Amazon CloudW...Five New Security Automation Improvements You Can Make by Using Amazon CloudW...
Five New Security Automation Improvements You Can Make by Using Amazon CloudW...
 
MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...
MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...
MBL309_User Engagement, Messaging, and Analytics Using Amazon Pinpoint from A...
 
DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...
DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...
DEV328_DevOps Lessons from Courser a Site Performance, Reliability, and Devel...
 
SRV312_Taking Serverless to the Edge
SRV312_Taking Serverless to the EdgeSRV312_Taking Serverless to the Edge
SRV312_Taking Serverless to the Edge
 
Launch Applications the Amazon Way - AWS Online Tech Talks
Launch Applications the Amazon Way - AWS Online Tech TalksLaunch Applications the Amazon Way - AWS Online Tech Talks
Launch Applications the Amazon Way - AWS Online Tech Talks
 
ARC325_Managing Multiple AWS Accounts at Scale
ARC325_Managing Multiple AWS Accounts at ScaleARC325_Managing Multiple AWS Accounts at Scale
ARC325_Managing Multiple AWS Accounts at Scale
 
MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...
MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...
MBL209_Learn How MicroStrategy on AWS is Helping Vivint Solar Deliver Clean E...
 
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech TalksAWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
AWS X-Ray: Debugging Applications at Scale - AWS Online Tech Talks
 
Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...
Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...
Advanced Patterns in Microservices Implementation with Amazon ECS - CON402 - ...
 
GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...
GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...
GPSTEC319-Build Once Deploy Many Architecting and Building Automated Reusable...
 
Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...
Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...
Operation Monitoring and Alerting at Scale in GE Transportation - ENT340 - re...
 
How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...
How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...
How to Assess Your Organization's Readiness to Migrate at Scale to AWS - ENT2...
 
CON209_Interstella 8888 Learn How to Use Docker on AWS
CON209_Interstella 8888 Learn How to Use Docker on AWSCON209_Interstella 8888 Learn How to Use Docker on AWS
CON209_Interstella 8888 Learn How to Use Docker on AWS
 
GPSTEC306-Continuous Compliance for Healthcare and Life Sciences
GPSTEC306-Continuous Compliance for Healthcare and Life SciencesGPSTEC306-Continuous Compliance for Healthcare and Life Sciences
GPSTEC306-Continuous Compliance for Healthcare and Life Sciences
 
Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...
Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...
Protect Your Web Applications from Common Attack Vectors Using AWS WAF - SID3...
 
Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...
Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...
Building end-to-end IT Lifecycle Mgmt & Workflows with AWS Service Catalog - ...
 

Similar to Use Amazon EC2 Systems Manager to Perform Automated Resilience Testing in Your CI/CD Pipeline - DEV338 - re:Invent 2017

DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...
DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...
DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...
Amazon Web Services
 
NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017
NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017
NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017
Amazon Web Services
 
CON203_Driving Innovation with Containers
CON203_Driving Innovation with ContainersCON203_Driving Innovation with Containers
CON203_Driving Innovation with Containers
Amazon Web Services
 
Driving Innovation with Containers - CON203 - re:Invent 2017
Driving Innovation with Containers - CON203 - re:Invent 2017Driving Innovation with Containers - CON203 - re:Invent 2017
Driving Innovation with Containers - CON203 - re:Invent 2017
Amazon Web Services
 
Introducing Amazon Fargate
Introducing Amazon FargateIntroducing Amazon Fargate
Introducing Amazon Fargate
Amazon Web Services
 
DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...
DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...
DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...
New Relic
 
CON309_Containerized Machine Learning on AWS
CON309_Containerized Machine Learning on AWSCON309_Containerized Machine Learning on AWS
CON309_Containerized Machine Learning on AWS
Amazon Web Services
 
How to Determine If You Are Well Architected for Resiliency (or How I Learned...
How to Determine If You Are Well Architected for Resiliency (or How I Learned...How to Determine If You Are Well Architected for Resiliency (or How I Learned...
How to Determine If You Are Well Architected for Resiliency (or How I Learned...
Amazon Web Services
 
Containers on AWS
Containers on AWSContainers on AWS
Containers on AWS
Amazon Web Services
 
Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global TablesBuilding Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
Amazon Web Services
 
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
AWS Germany
 
Building a Multi-Region, Active-Active Serverless Backends.
Building a Multi-Region, Active-Active Serverless Backends.Building a Multi-Region, Active-Active Serverless Backends.
Building a Multi-Region, Active-Active Serverless Backends.
Adrian Hornsby
 
10 Lessons from 10 Years of AWS
10 Lessons from 10 Years of AWS10 Lessons from 10 Years of AWS
10 Lessons from 10 Years of AWS
Adrian Hornsby
 
CON319_Interstella GTC CICD for Containers on AWS
CON319_Interstella GTC CICD for Containers on AWSCON319_Interstella GTC CICD for Containers on AWS
CON319_Interstella GTC CICD for Containers on AWS
Amazon Web Services
 
Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017
Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017
Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017
Amazon Web Services
 
AWS 容器服務入門實務
AWS 容器服務入門實務AWS 容器服務入門實務
AWS 容器服務入門實務
Amazon Web Services
 
Introduction to AWS Fargate & Amazon Elastic Container Service for Kubernetes
Introduction to AWS Fargate & Amazon Elastic Container Service for KubernetesIntroduction to AWS Fargate & Amazon Elastic Container Service for Kubernetes
Introduction to AWS Fargate & Amazon Elastic Container Service for Kubernetes
Amazon Web Services
 
CON208_Building Microservices on AWS
CON208_Building Microservices on AWSCON208_Building Microservices on AWS
CON208_Building Microservices on AWS
Amazon Web Services
 
SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...
SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...
SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...
Amazon Web Services
 
Building with Containers on AWS
Building with Containers on AWSBuilding with Containers on AWS
Building with Containers on AWS
Amazon Web Services
 

Similar to Use Amazon EC2 Systems Manager to Perform Automated Resilience Testing in Your CI/CD Pipeline - DEV338 - re:Invent 2017 (20)

DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...
DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...
DEV325_Application Deployment Techniques for Amazon EC2 Workloads with AWS Co...
 
NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017
NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017
NEW LAUNCH! Introducing AWS Fargate - CON214 - re:Invent 2017
 
CON203_Driving Innovation with Containers
CON203_Driving Innovation with ContainersCON203_Driving Innovation with Containers
CON203_Driving Innovation with Containers
 
Driving Innovation with Containers - CON203 - re:Invent 2017
Driving Innovation with Containers - CON203 - re:Invent 2017Driving Innovation with Containers - CON203 - re:Invent 2017
Driving Innovation with Containers - CON203 - re:Invent 2017
 
Introducing Amazon Fargate
Introducing Amazon FargateIntroducing Amazon Fargate
Introducing Amazon Fargate
 
DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...
DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...
DEV209 A Field Guide to Monitoring in the Cloud: From Lift and Shift to AWS L...
 
CON309_Containerized Machine Learning on AWS
CON309_Containerized Machine Learning on AWSCON309_Containerized Machine Learning on AWS
CON309_Containerized Machine Learning on AWS
 
How to Determine If You Are Well Architected for Resiliency (or How I Learned...
How to Determine If You Are Well Architected for Resiliency (or How I Learned...How to Determine If You Are Well Architected for Resiliency (or How I Learned...
How to Determine If You Are Well Architected for Resiliency (or How I Learned...
 
Containers on AWS
Containers on AWSContainers on AWS
Containers on AWS
 
Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global TablesBuilding Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
 
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
 
Building a Multi-Region, Active-Active Serverless Backends.
Building a Multi-Region, Active-Active Serverless Backends.Building a Multi-Region, Active-Active Serverless Backends.
Building a Multi-Region, Active-Active Serverless Backends.
 
10 Lessons from 10 Years of AWS
10 Lessons from 10 Years of AWS10 Lessons from 10 Years of AWS
10 Lessons from 10 Years of AWS
 
CON319_Interstella GTC CICD for Containers on AWS
CON319_Interstella GTC CICD for Containers on AWSCON319_Interstella GTC CICD for Containers on AWS
CON319_Interstella GTC CICD for Containers on AWS
 
Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017
Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017
Interstella 8888: CICD for Containers on AWS - CON319 - re:Invent 2017
 
AWS 容器服務入門實務
AWS 容器服務入門實務AWS 容器服務入門實務
AWS 容器服務入門實務
 
Introduction to AWS Fargate & Amazon Elastic Container Service for Kubernetes
Introduction to AWS Fargate & Amazon Elastic Container Service for KubernetesIntroduction to AWS Fargate & Amazon Elastic Container Service for Kubernetes
Introduction to AWS Fargate & Amazon Elastic Container Service for Kubernetes
 
CON208_Building Microservices on AWS
CON208_Building Microservices on AWSCON208_Building Microservices on AWS
CON208_Building Microservices on AWS
 
SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...
SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...
SRV331_Build a Multi-Region Serverless Application for Resilience and High Av...
 
Building with Containers on AWS
Building with Containers on AWSBuilding with Containers on AWS
Building with Containers on AWS
 

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 Fargate
Amazon Web Services
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
Amazon 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
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
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 Workloads
Amazon Web Services
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
Amazon 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 sfatare
Amazon 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 NodeJS
Amazon 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 web
Amazon 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 sfatare
Amazon 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 AWS
Amazon 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 Deck
Amazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
Amazon Web Services
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
Amazon 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 Service
Amazon 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
 

Use Amazon EC2 Systems Manager to Perform Automated Resilience Testing in Your CI/CD Pipeline - DEV338 - re:Invent 2017

  • 1. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Use Amazon EC2 Systems Manager to Perform Automated Resilience Testing in Your CI/CD Pipeline AWS re:INVENT D a v e B a k s h a n i S e n i o r S o f t w a r e E n g i n e e r @ E x p e d i a W i l l i e W h e e l e r P r i n c i p a l A p p l i c a t i o n s E n g i n e e r @ E x p e d i a N o v e m b e r 2 9 , 2 0 1 7
  • 2. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. In 2016, Expedia, Inc., was the 11th largest internet company by revenue at $8.77B. THE PRICE OF DOWNTIME—A BACK-OF-THE- ENVELOPE CALCULATION Source: https://en.wikipedia.org/wiki/List_of_largest_Internet_companies
  • 3. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Uptime Downtime Potential lost revenue 99% 3.65d $87.7M 99.9% 8.76h $8.77M 99.99% 52.56m $877K THE PRICE OF DOWNTIME—A BACK-OF-THE- ENVELOPE CALCULATION
  • 4. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Keeping our site up protects tens of millions of dollars per year
  • 5. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. OUR TALK • [Overview] Resilience engineering • [Overview] Amazon EC2 Systems Manager • [Demo] Attack your app with Amazon EC2 Systems Manager • [Demo] Run resilience tests in a CI/CD pipeline • Implementing other attacks • Q&A
  • 6. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. RESILIENCE ENGINEERING O V E R V I E W O F
  • 7. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. RESILIENCE ENGINEERING GOALS Keep the site up Even when components fail
  • 8. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. STORAGE MEMORY POWER TRAFFIC CPU NETWORK WHAT GOES WRONG (A PARTIAL LIST)
  • 9. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Overprovisioning and redundancy Auto-scaling Load-shedding CAPACITY STRATEGIES
  • 10. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Fallback/failover Fail silent Fail fast FAULT-TOLERANCE STRATEGIES Circuit breaker Circuit breakerCircuit breaker
  • 11. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. ANATOMY OF A RESILIENCE EXPERIMENT Attack system Identify desired response Verify response
  • 12. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. P R O D : R A N D O M I Z E DT E S T : C O N T R O L L E D RESILIENCE EXPERIMENTS BY ENVIRONMENT
  • 13. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. RECAP  Goal: Keep the site up  Many strategies available  Run experiments in test and prod
  • 14. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AMAZON EC2 SYSTEMS MANAGER O V E R V I E W O F
  • 15. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. • Automation • Inventory • Maintenance windows • Parameter store • Patch management • State management • Run command WHAT I S AMAZON EC 2 SYST EMS MANAGER ? Capabilities: Systems Manager is a service to help manage your Amazon Elastic Compute Cloud (Amazon EC2) and on-premises instances
  • 16. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SYSTEMS MANAGER OVERVIEW Systems Manager Service EC2 Instance Systems Manager Agent EC2 Instance On-Prem Instance Systems Manager Agent Systems Manager Agent
  • 17. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Step 1: Create an IAM role with the AmazonEC2RoleforSSM policy Step 2: Attach the IAM role to your EC2 instances Step 3: Install the Systems Manager agent (if it’s not already there) SYSTEMS MANAGER SETUP
  • 18. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SYSTEMS MANAGER IN A NUTSHELL • Systems Manager documents • Run command
  • 19. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. { "schemaVersion": "2.0", "description": "Install or uninstall the latest version or specified version of an AWS package.", "parameters": { "action": { "description": "(Required) Specify whether or not to install or uninstall the package.", "type": "String", "allowedValues": [ "Install", "Uninstall" ] }, ... other parameters ... }, "mainSteps": [{ "action": "aws:configurePackage", "name": "configurePackage", "inputs": { "action": "{{ action }}", "name": "{{ name }}", "version": "{{ version }}" } }] } SYSTEMS MANAGER DOCUMENTS
  • 20. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SYSTEMS MANAGER RUN COMMAND Supports remote management of instance configuration Choose Command Document Choose target instances Specify document params Execute
  • 21. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. RECAP We learned about:  Systems Manager capabilities, architecture, and setup  Systems Manager documents and Run command
  • 22. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Now the fun stuff
  • 23. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. ATTACK YOUR APP WITH AMAZON EC2 SYSTEMS MANAGER
  • 24. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. ATTACKING SYSTEMS WITH SYSTEMS MANAGER Create Command Document for attack Execute Run Command Systems Manager Agent runs command
  • 25. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. { "schemaVersion": "2.0", "description": "Blackhole an outbound port on an instance", "parameters": { "port": { "type": "String", "description": "(Required) Specify an outbound port to blackhole." } }, "mainSteps": [{ "action": "aws:runShellScript", "name": "runShellScript", "inputs": { "runCommand": [ "iptables -A OUTPUT -p tcp --destination-port {{ port }} -j DROP" ] } }] } A SYSTEMS MANAGER ATTACK DOCUMENT
  • 26. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. [DEMO] ATTACKING YOUR APP WITH SYSTEMS MANAGER
  • 27. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SAMPLE APPLICATION: WEATHER REPORT Weather Report UI Weather Report API Weather Report DB OpenWeatherMap API
  • 28. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Two versions of the app: • Non-resilient • Resilient (has breakers) SAMPLE APPLICATION: WEATHER REPORT Weather Report UI Weather Report API Weather Report DB OpenWeatherMap API
  • 29. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Two versions of the app: • Non-resilient • Resilient (has breakers) What we’ll cover: SAMPLE APPLICATION: WEATHER REPORT Weather Report UI Weather Report API Weather Report DB OpenWeatherMap API
  • 30. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Two versions of the app: • Non-resilient • Resilient (has breakers) What we’ll cover: • Blackhole attack against DB SAMPLE APP: WEATHER REPORT Weather Report UI Weather Report API Weather Report DB OpenWeatherMap API
  • 31. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. [DEMO]
  • 32. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.  We learned how to use Systems Manager to execute an attack  We saw both non-resilient and resilient responses RECAP
  • 33. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. RUN RESILIENCE TESTS IN A CI/CD PIPELINE
  • 34. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Use CI/CD pipeline for ongoing verification RESILIENCE TESTING
  • 35. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. RESILIENCE TESTING IN A CI/CD PIPELINE build deploy to test security scan perf tests release to test deploy to prod release to prod resilience tests
  • 36. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. [DEMO] RESILIENCE TESTING IN A CI/CD PIPELINE
  • 37. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. WHAT WE’LL COVER • Build pipeline with three resilience tests: • Pre-test (happy path) • Blackhole attack & fallback test • Post-test (recovery)
  • 38. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. [DEMO]
  • 39. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. RECAP  We embedded our resilience test in a CI/CD pipeline
  • 40. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. IMPLEMENTING OTHER ATTACKS
  • 41. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. • Burn CPU • Burn I/O • Fail DNS • Fail Amazon DynamoDB • Fail EC2 • Fail S3 • Fill disk • Kill processes • Network corruption • Network latency • Network loss • Null route SIMIAN ARMY ATTACKS Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
  • 42. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Attack scripts are straightforward to implement
  • 43. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. #!/bin/bash cat << EOF > /tmp/infiniteburn.sh #!/bin/bash while true; do openssl speed; done EOF for i in {1..`nproc --all`} do nohup /bin/bash /tmp/infiniteburn.sh & done BURN CPU Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
  • 44. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. #!/bin/bash cat << EOF > /tmp/loopburnio.sh #!/bin/bash while true; do dd if=/dev/urandom of=/burn bs=1M count=1024 iflag=fullblock done EOF nohup /bin/bash /tmp/loopburnio.sh & BURN I/O Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
  • 45. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. #!/bin/bash # Block all traffic on port 53 iptables -A INPUT -p tcp -m tcp --dport 53 -j DROP iptables -A INPUT -p udp -m udp --dport 53 -j DROP FAIL DNS Source: https://github.com/Netflix/SimianArmy/tree/master/src/main/resources/scripts
  • 46. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved.  We learned how Systems Manager helps keep your site up  Start testing and enhancing your site resilience today WRAPPING UP
  • 47. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. thankYou([ { name: "Kuldeep Chowhan", reasons: [ "Original concept" ] }, { name: "Jay Spang", reasons: [ "Initial implementation in our resilience testing framework", "Wrote the proposal that led to this presentation" ] } ]) ACKNOWLEDGMENTS
  • 48. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Thank you! F o r m o r e i n f o r m a t i o n : h t t p s : / / t e c h b l o g . e x p e d i a . c o m / 2 0 1 7 / 1 1 / 2 1 / r e i n v e n t - 2 0 1 7 - u s e - e c 2 - s y s t e m s - m a n a g e r - t o - p e r f o r m - a u t o m a t e d - r e s i l i e n c y - t e s t i n g - i n - y o u r - c i c d - p i p e l i n e /