SlideShare une entreprise Scribd logo
1  sur  35
Télécharger pour lire hors ligne
Why Software Teams
Struggle with API Security Testing
and How to Make it Easier
Hint: None of the reasons are “Developers Don’t Care about Security”
$ whoami
Scott Gerlach
● CSO/Co-Founder StackHawk, Inc
● CISO @SendGrid - 3 years
● Sr. Security Arch @GoDaddy - 9 years
● Husband, Dad, Brewer, Golfer, tinkerer
● @sgerlach
● linkedin.com/in/scott-gerlach-kaakaww
API Security Problem Overview
API Security : How can I to go to there?
Static Code Analysis
● Noisy, often lacks Application Context
● Language Dependant (Don’t get me started on IDE support)
Dynamic Code Analysis
● Better at actual app and context, but still somewhat noisy
● Hard to use and many don’t support RestAPI, GraphQL
RASP, IAST, WAF
● Wait until someone/something else finds it… in Prod, and hopefully block it
Problem One:
Working Agreements Aren’t
Clear
Hey! I broke the crap out of your thing. Cool huh!
working agreement | [wur-king ə-ˈgrē-mənt ]
Definition Time
1. The purpose of a working agreement is to ensure the Agile Team shares
responsibility in defining expectations for how they will function together
and enhance their self-organization process
2. Working agreements can apply to services, and can even be documented.
3. You can certainly make a working agreement with the Security Team…
just saying
Functional Agreements:
● Rate Limiting?
● Standardized Errors?
Data Input:
● Validation?
● Encoding?
● Escaping?
Data Output:
● Validation?
● Encoding?
● Escaping?
● Paging?
Data Working Agreement
Functional Agreements:
● Back off routines?
Data Input:
● Validation?
● Encoding?
● Escaping?
Data Output:
● Validation?
● Encoding?
● Escaping?
Backend Team (API Team) Front End Team
Functional Agreements:
● Rate Limiting
● Standardized Errors
Data Input:
● Validation
● Encoding
● Escaping
Data Output:
● Validation
● Encoding
● Escaping
● Paging
Data Working Agreement
Functional Agreements:
● Back off routines
Data Input:
● Validation
● Encoding
● Escaping
Data Output:
● Validation
● Encoding
● Escaping
Backend Team (API Team) Front End Team
YES, THAT!
Problem Two:
Security Tools are Built for the
Security Team
Hey! I broke the crap out of your thing. Cool huh!
FIX ALL THE THINGS!
I think we’ve got a
SQL Injection here
Security Websters
CSRF: Cross Site Request Forgery
XSRF: Cross Site Request Forgery
Cross-Site Request Forgery (CSRF) is an attack that forces an end user to execute unwanted
actions on a web application in which they’re currently authenticated. With a little help of
social engineering (such as sending a link via email or chat), an attacker may trick the users of
a web application into executing actions of the attacker’s choosing. If the victim is a normal
user, a successful CSRF attack can force the user to perform state changing requests like
transferring funds, changing their email address, and so forth.
We couldn’t decide which one to use, so we use both interchangeably. Isn’t that cool? Anyway, I
hope some of this text helps you understand what this means because we wrote a lot of it.
Let’s Teach Them AppSec
If they know how attackers think, they’ll be able to test like an attacker - Hack Yourself!
● Here’s 11ty Billion new Acronyms to learn
● Also, let’s talk about risk
● But wait before that, do you know the Internet is a bad
place?
● If you have sent any of your Devs to a Security Training
program, who usually gets selected?
“We Need to Model Out a Price Increase”
Have you ever seen the FP&A team teach the basics of accounting to the Exec Team
Lastly, and worst of all,
they suffer from….
Problem Three:
The Production Bias
Examining the Production-Bias: People
Primary Value: These groups are very focused on the “finding” of vulnerabilities/security bugs. MOAR
findings = MOAR better.
The Security Team Pen Tester
Production is where they know the app the best Production is their only point of access
Repercussions…
● More focused on the numbers of things found, than finding and fixing the right things
● Inefficient — the “finders” are not the “fixers”
● Reinforces an adversarial relationship — “Hey look, I broke your stuff”
*Assuming you have a security team
PLAN
M
ONITOR
CODE
BUILD
T
E
S
T
RELEASE
DEPLOY
OPERATE
Security is either
a blocker
or “playing catch up”
DEV OPS
Examining the Production-Bias: Timing
Example RestAPI - Pants`R’ Us
GET /rest/api/v1/listPants
Returns list of pantIds
GET /rest/api/v1/{pantId}/details
Returns details about a pair of pants, size, color, stock
Example RestAPI - Pants`R’ Us
GET /rest/api/v1/listPants
Returns list of pantIds
GET /rest/api/v1/{pantId}/details
Returns details about a pair of pants, size, color, stock
HUNDREDS OF STYLES AND SIZES WAITING FOR YOU!
Example RestAPI - Pants`R’ Us
SO MANY PANTS!
Also, there’s a major problem with appsec tools that
favor running in production…
THE BUGS ARE
IN PRODUCTION.
Illustration by Stories by Freepik
I wouldn’t want a Junior Developer
making security decisions
Trust Issues
I wouldn’t want to put a new hire
Developer in the position of
making an uninformed risk
decision
Trust and Support
-Scott Gerlach
The Chase to Perfection
● Find 11ty Billion issues -> We have to fix all of these!
● Why? What is the actual risk in the context of the business?
● What if your QA filled 1,000 tickets for bugs that are
unlikely to degrade user experience?
“I’ve never had a satisfying conversation on
why a security issue is ever more important
than a feature. Ever.” - Product VP
If You Don’t Have a Security Team
● Where do I start?
● OMG, forget it. I have other stuff to do.
● Wait, maybe the DevOps team can handle it
There are Good AppSec Dev Tools Out There
Developer native tools (in context, how they work)
● Snyk
● Fossa
● npm audit
● GitHub (package inspection, PR Bot)
● OWASP Dependency Check
Context of the Code is lacking
Inefficient
Time Consuming
Expensive
Context of the App and how it works
Context of Business Risk
Examining the Production-Bias: Context
Wrong Team Wrong Time
Wrong Context
Getting Started:
The Right Way
How Test-Driven
Security
Should Work
When a team writes code, they know the syntax
is wrong when it won’t compile.
When a team merges code they know there is a
problem when it doesn’t merge.
When a team runs unit tests, they know the
code is wrong when it fails the unit test.
When a team runs integration tests, they
know the code is wrong when it doesn’t work as
designed.
When a team introduces a
vulnerability, they know when it
fails a security test.
PLAN
M
ONITOR
CODE
BUILD
T
E
S
T
RELEASE
DEPLOY
OPERATE
DEV OPS
Right Time: Pre-Production
Security Tests
Security Tests
Instrumenting Security Tests into CI/CD
gives engineers immediate feedback.
Adding the ability to test locally allows for
quick iteration in the fix-test loop if a new
bug is identified.
Local Dev & CI/CD
● Set up working agreements across
teams/apps/departments
● Create Standards documentation automatically
(OpenAPI/Introspection)
● Seed the database! Test in Pre-Prod!
● Understand these two things deeply
○ Object Level Authorization (Tenancy Filtering)
○ Function Level Authorization
Cover Your Bases
● Engage a project team and their pipeline
● Choose AN app or service to start
● Choose a technology (SCA, DAST)
● Iterate and expand
Just Start!
Thanks!
scott.gerlach@stackhawk.com @sgerlach https://stackhawk.com

Contenu connexe

Tendances

I Love APIs 2015: Create Design-driven APIs with Node.js and Swagger
I Love APIs 2015: Create Design-driven APIs with Node.js and SwaggerI Love APIs 2015: Create Design-driven APIs with Node.js and Swagger
I Love APIs 2015: Create Design-driven APIs with Node.js and Swagger
Apigee | Google Cloud
 

Tendances (20)

apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflixapidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
apidays LIVE Hong Kong 2021 - Less Data is More by Damir Svrtan, Netflix
 
Beyond the basic Swagger UI: Adyen API Explorer
Beyond the basic Swagger UI: Adyen API ExplorerBeyond the basic Swagger UI: Adyen API Explorer
Beyond the basic Swagger UI: Adyen API Explorer
 
apidays LIVE Hong Kong 2021 - Automating the API Product Lifecycle by Jeremy ...
apidays LIVE Hong Kong 2021 - Automating the API Product Lifecycle by Jeremy ...apidays LIVE Hong Kong 2021 - Automating the API Product Lifecycle by Jeremy ...
apidays LIVE Hong Kong 2021 - Automating the API Product Lifecycle by Jeremy ...
 
apidays LIVE Australia 2021 - From apps to APIs: how no-code is transforming ...
apidays LIVE Australia 2021 - From apps to APIs: how no-code is transforming ...apidays LIVE Australia 2021 - From apps to APIs: how no-code is transforming ...
apidays LIVE Australia 2021 - From apps to APIs: how no-code is transforming ...
 
Past, Present, Future of APIS
Past, Present, Future of APISPast, Present, Future of APIS
Past, Present, Future of APIS
 
apidays LIVE LONDON - OpenAPI-driven API development lifecycle at Adyen by Al...
apidays LIVE LONDON - OpenAPI-driven API development lifecycle at Adyen by Al...apidays LIVE LONDON - OpenAPI-driven API development lifecycle at Adyen by Al...
apidays LIVE LONDON - OpenAPI-driven API development lifecycle at Adyen by Al...
 
Outpost24 webinar - Api security
Outpost24 webinar - Api securityOutpost24 webinar - Api security
Outpost24 webinar - Api security
 
INTERFACE, by apidays - Low code APIs that don't break by Zdenek Nemec, Supe...
INTERFACE, by apidays  - Low code APIs that don't break by Zdenek Nemec, Supe...INTERFACE, by apidays  - Low code APIs that don't break by Zdenek Nemec, Supe...
INTERFACE, by apidays - Low code APIs that don't break by Zdenek Nemec, Supe...
 
apidays LIVE Australia 2021 - Designing APIs: Just Enough is Perfect! by Dami...
apidays LIVE Australia 2021 - Designing APIs: Just Enough is Perfect! by Dami...apidays LIVE Australia 2021 - Designing APIs: Just Enough is Perfect! by Dami...
apidays LIVE Australia 2021 - Designing APIs: Just Enough is Perfect! by Dami...
 
apidays LIVE New York - API Code First vs Design First by Phil Sturgeon
apidays LIVE New York - API Code First vs Design First by Phil Sturgeonapidays LIVE New York - API Code First vs Design First by Phil Sturgeon
apidays LIVE New York - API Code First vs Design First by Phil Sturgeon
 
Operational API design anti-patterns (Jason Harmon)
Operational API design anti-patterns (Jason Harmon)Operational API design anti-patterns (Jason Harmon)
Operational API design anti-patterns (Jason Harmon)
 
apidays LIVE Paris 2021 - Privacy Engineering by Ian Oliver, Nokia Bell Labs
apidays LIVE Paris 2021 - Privacy Engineering by Ian Oliver, Nokia Bell Labsapidays LIVE Paris 2021 - Privacy Engineering by Ian Oliver, Nokia Bell Labs
apidays LIVE Paris 2021 - Privacy Engineering by Ian Oliver, Nokia Bell Labs
 
I Love APIs 2015: Create Design-driven APIs with Node.js and Swagger
I Love APIs 2015: Create Design-driven APIs with Node.js and SwaggerI Love APIs 2015: Create Design-driven APIs with Node.js and Swagger
I Love APIs 2015: Create Design-driven APIs with Node.js and Swagger
 
apidays LIVE London 2021 - API Horror Stories from an Unnamed Coworking Compa...
apidays LIVE London 2021 - API Horror Stories from an Unnamed Coworking Compa...apidays LIVE London 2021 - API Horror Stories from an Unnamed Coworking Compa...
apidays LIVE London 2021 - API Horror Stories from an Unnamed Coworking Compa...
 
Api Design
Api DesignApi Design
Api Design
 
apidays LIVE London 2021 - API Security challenges and solutions by Wadii Tah...
apidays LIVE London 2021 - API Security challenges and solutions by Wadii Tah...apidays LIVE London 2021 - API Security challenges and solutions by Wadii Tah...
apidays LIVE London 2021 - API Security challenges and solutions by Wadii Tah...
 
Pain Points In API Development? They’re Everywhere
Pain Points In API Development? They’re EverywherePain Points In API Development? They’re Everywhere
Pain Points In API Development? They’re Everywhere
 
API Developer Experience: Why it Matters, and How Documenting Your API with S...
API Developer Experience: Why it Matters, and How Documenting Your API with S...API Developer Experience: Why it Matters, and How Documenting Your API with S...
API Developer Experience: Why it Matters, and How Documenting Your API with S...
 
Leaping Forward: Finding The Future of Your API Docs
Leaping Forward: Finding The Future of Your API DocsLeaping Forward: Finding The Future of Your API Docs
Leaping Forward: Finding The Future of Your API Docs
 
apidays LIVE Paris 2021 - Test developer experience, not code by Kathrine Osa...
apidays LIVE Paris 2021 - Test developer experience, not code by Kathrine Osa...apidays LIVE Paris 2021 - Test developer experience, not code by Kathrine Osa...
apidays LIVE Paris 2021 - Test developer experience, not code by Kathrine Osa...
 

Similaire à apidays LIVE New York 2021 - Why Software Teams Struggle with API Security Testing by Scott Gerlach, StackHawk

Security engineering 101 when good design & security work together
Security engineering 101  when good design & security work togetherSecurity engineering 101  when good design & security work together
Security engineering 101 when good design & security work together
Wendy Knox Everette
 
Intro to-ssdl--lone-star-php-2013
Intro to-ssdl--lone-star-php-2013Intro to-ssdl--lone-star-php-2013
Intro to-ssdl--lone-star-php-2013
nanderoo
 
Code Review Looking for a vulnerable code. Vlad Savitsky.
Code Review Looking for a vulnerable code. Vlad Savitsky.Code Review Looking for a vulnerable code. Vlad Savitsky.
Code Review Looking for a vulnerable code. Vlad Savitsky.
DrupalCampDN
 
BSides Columbus - Lend me your IR's!
BSides Columbus - Lend me your IR's!BSides Columbus - Lend me your IR's!
BSides Columbus - Lend me your IR's!
ThreatReel Podcast
 
Testingfor Sw Security
Testingfor Sw SecurityTestingfor Sw Security
Testingfor Sw Security
ankitmehta21
 
4.Security Assessment And Testing
4.Security Assessment And Testing4.Security Assessment And Testing
4.Security Assessment And Testing
phanleson
 

Similaire à apidays LIVE New York 2021 - Why Software Teams Struggle with API Security Testing by Scott Gerlach, StackHawk (20)

2022 APIsecure_API Security Testing: The Next Step in Modernizing AppSec
2022 APIsecure_API Security Testing: The Next Step in Modernizing AppSec2022 APIsecure_API Security Testing: The Next Step in Modernizing AppSec
2022 APIsecure_API Security Testing: The Next Step in Modernizing AppSec
 
Year Zero
Year ZeroYear Zero
Year Zero
 
Security engineering 101 when good design & security work together
Security engineering 101  when good design & security work togetherSecurity engineering 101  when good design & security work together
Security engineering 101 when good design & security work together
 
Cinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patternsCinci ug-january2011-anti-patterns
Cinci ug-january2011-anti-patterns
 
Гірка правда про безпеку програмного забезпечення, Володимир Стиран
Гірка правда про безпеку програмного забезпечення, Володимир СтиранГірка правда про безпеку програмного забезпечення, Володимир Стиран
Гірка правда про безпеку програмного забезпечення, Володимир Стиран
 
Sigma Open Tech Week: Bitter Truth About Software Security
Sigma Open Tech Week: Bitter Truth About Software SecuritySigma Open Tech Week: Bitter Truth About Software Security
Sigma Open Tech Week: Bitter Truth About Software Security
 
Identifying a Compromised WordPress Site
Identifying a Compromised WordPress SiteIdentifying a Compromised WordPress Site
Identifying a Compromised WordPress Site
 
Intro to-ssdl--lone-star-php-2013
Intro to-ssdl--lone-star-php-2013Intro to-ssdl--lone-star-php-2013
Intro to-ssdl--lone-star-php-2013
 
So you wanna be a pentester - free webinar to show you how
So you wanna be a pentester - free webinar to show you howSo you wanna be a pentester - free webinar to show you how
So you wanna be a pentester - free webinar to show you how
 
Code Review Looking for a vulnerable code. Vlad Savitsky.
Code Review Looking for a vulnerable code. Vlad Savitsky.Code Review Looking for a vulnerable code. Vlad Savitsky.
Code Review Looking for a vulnerable code. Vlad Savitsky.
 
RSA 2015 Blending the Automated and the Manual: Making Application Vulnerabil...
RSA 2015 Blending the Automated and the Manual: Making Application Vulnerabil...RSA 2015 Blending the Automated and the Manual: Making Application Vulnerabil...
RSA 2015 Blending the Automated and the Manual: Making Application Vulnerabil...
 
5 things i wish i knew about sast (DSO-LG July 2021)
5 things i wish i knew about sast (DSO-LG July 2021)5 things i wish i knew about sast (DSO-LG July 2021)
5 things i wish i knew about sast (DSO-LG July 2021)
 
BSidesDC 2016 Beyond Automated Testing
BSidesDC 2016 Beyond Automated TestingBSidesDC 2016 Beyond Automated Testing
BSidesDC 2016 Beyond Automated Testing
 
A Strategic Path from Secure Code Reviews to Threat Modeling (101)
A Strategic Path from Secure Code Reviews to Threat Modeling (101)A Strategic Path from Secure Code Reviews to Threat Modeling (101)
A Strategic Path from Secure Code Reviews to Threat Modeling (101)
 
Continuous security testing - sharing responsibility
Continuous security testing - sharing responsibilityContinuous security testing - sharing responsibility
Continuous security testing - sharing responsibility
 
Appsec Agility: A Brief Tour
Appsec Agility: A Brief TourAppsec Agility: A Brief Tour
Appsec Agility: A Brief Tour
 
Survey Presentation About Application Security
Survey Presentation About Application SecuritySurvey Presentation About Application Security
Survey Presentation About Application Security
 
BSides Columbus - Lend me your IR's!
BSides Columbus - Lend me your IR's!BSides Columbus - Lend me your IR's!
BSides Columbus - Lend me your IR's!
 
Testingfor Sw Security
Testingfor Sw SecurityTestingfor Sw Security
Testingfor Sw Security
 
4.Security Assessment And Testing
4.Security Assessment And Testing4.Security Assessment And Testing
4.Security Assessment And Testing
 

Plus de apidays

Plus de apidays (20)

Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...
Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...
Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...
Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...
Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...
 
Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...
Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...
Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...
 
Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...
Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...
Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...
 
Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...
Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...
Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...
 
Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...
Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...
Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...
 
Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...
Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...
Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...
 
Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...
Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...
Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...
 
Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...
Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...
Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...
Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...
Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...
 
Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...
Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...
Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...
Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...
Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...
 

Dernier

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 

Dernier (20)

Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 

apidays LIVE New York 2021 - Why Software Teams Struggle with API Security Testing by Scott Gerlach, StackHawk

  • 1. Why Software Teams Struggle with API Security Testing and How to Make it Easier Hint: None of the reasons are “Developers Don’t Care about Security”
  • 2. $ whoami Scott Gerlach ● CSO/Co-Founder StackHawk, Inc ● CISO @SendGrid - 3 years ● Sr. Security Arch @GoDaddy - 9 years ● Husband, Dad, Brewer, Golfer, tinkerer ● @sgerlach ● linkedin.com/in/scott-gerlach-kaakaww
  • 3. API Security Problem Overview API Security : How can I to go to there? Static Code Analysis ● Noisy, often lacks Application Context ● Language Dependant (Don’t get me started on IDE support) Dynamic Code Analysis ● Better at actual app and context, but still somewhat noisy ● Hard to use and many don’t support RestAPI, GraphQL RASP, IAST, WAF ● Wait until someone/something else finds it… in Prod, and hopefully block it
  • 5. Hey! I broke the crap out of your thing. Cool huh!
  • 6. working agreement | [wur-king ə-ˈgrē-mənt ] Definition Time 1. The purpose of a working agreement is to ensure the Agile Team shares responsibility in defining expectations for how they will function together and enhance their self-organization process 2. Working agreements can apply to services, and can even be documented. 3. You can certainly make a working agreement with the Security Team… just saying
  • 7. Functional Agreements: ● Rate Limiting? ● Standardized Errors? Data Input: ● Validation? ● Encoding? ● Escaping? Data Output: ● Validation? ● Encoding? ● Escaping? ● Paging? Data Working Agreement Functional Agreements: ● Back off routines? Data Input: ● Validation? ● Encoding? ● Escaping? Data Output: ● Validation? ● Encoding? ● Escaping? Backend Team (API Team) Front End Team
  • 8. Functional Agreements: ● Rate Limiting ● Standardized Errors Data Input: ● Validation ● Encoding ● Escaping Data Output: ● Validation ● Encoding ● Escaping ● Paging Data Working Agreement Functional Agreements: ● Back off routines Data Input: ● Validation ● Encoding ● Escaping Data Output: ● Validation ● Encoding ● Escaping Backend Team (API Team) Front End Team YES, THAT!
  • 9. Problem Two: Security Tools are Built for the Security Team
  • 10. Hey! I broke the crap out of your thing. Cool huh! FIX ALL THE THINGS! I think we’ve got a SQL Injection here
  • 11. Security Websters CSRF: Cross Site Request Forgery XSRF: Cross Site Request Forgery Cross-Site Request Forgery (CSRF) is an attack that forces an end user to execute unwanted actions on a web application in which they’re currently authenticated. With a little help of social engineering (such as sending a link via email or chat), an attacker may trick the users of a web application into executing actions of the attacker’s choosing. If the victim is a normal user, a successful CSRF attack can force the user to perform state changing requests like transferring funds, changing their email address, and so forth. We couldn’t decide which one to use, so we use both interchangeably. Isn’t that cool? Anyway, I hope some of this text helps you understand what this means because we wrote a lot of it.
  • 12. Let’s Teach Them AppSec If they know how attackers think, they’ll be able to test like an attacker - Hack Yourself! ● Here’s 11ty Billion new Acronyms to learn ● Also, let’s talk about risk ● But wait before that, do you know the Internet is a bad place? ● If you have sent any of your Devs to a Security Training program, who usually gets selected?
  • 13. “We Need to Model Out a Price Increase” Have you ever seen the FP&A team teach the basics of accounting to the Exec Team
  • 14. Lastly, and worst of all, they suffer from….
  • 16. Examining the Production-Bias: People Primary Value: These groups are very focused on the “finding” of vulnerabilities/security bugs. MOAR findings = MOAR better. The Security Team Pen Tester Production is where they know the app the best Production is their only point of access Repercussions… ● More focused on the numbers of things found, than finding and fixing the right things ● Inefficient — the “finders” are not the “fixers” ● Reinforces an adversarial relationship — “Hey look, I broke your stuff” *Assuming you have a security team
  • 17. PLAN M ONITOR CODE BUILD T E S T RELEASE DEPLOY OPERATE Security is either a blocker or “playing catch up” DEV OPS Examining the Production-Bias: Timing
  • 18. Example RestAPI - Pants`R’ Us GET /rest/api/v1/listPants Returns list of pantIds GET /rest/api/v1/{pantId}/details Returns details about a pair of pants, size, color, stock
  • 19. Example RestAPI - Pants`R’ Us GET /rest/api/v1/listPants Returns list of pantIds GET /rest/api/v1/{pantId}/details Returns details about a pair of pants, size, color, stock HUNDREDS OF STYLES AND SIZES WAITING FOR YOU!
  • 20. Example RestAPI - Pants`R’ Us SO MANY PANTS!
  • 21. Also, there’s a major problem with appsec tools that favor running in production… THE BUGS ARE IN PRODUCTION. Illustration by Stories by Freepik
  • 22. I wouldn’t want a Junior Developer making security decisions Trust Issues
  • 23. I wouldn’t want to put a new hire Developer in the position of making an uninformed risk decision Trust and Support -Scott Gerlach
  • 24. The Chase to Perfection ● Find 11ty Billion issues -> We have to fix all of these! ● Why? What is the actual risk in the context of the business? ● What if your QA filled 1,000 tickets for bugs that are unlikely to degrade user experience? “I’ve never had a satisfying conversation on why a security issue is ever more important than a feature. Ever.” - Product VP
  • 25. If You Don’t Have a Security Team ● Where do I start? ● OMG, forget it. I have other stuff to do. ● Wait, maybe the DevOps team can handle it
  • 26. There are Good AppSec Dev Tools Out There Developer native tools (in context, how they work) ● Snyk ● Fossa ● npm audit ● GitHub (package inspection, PR Bot) ● OWASP Dependency Check
  • 27. Context of the Code is lacking Inefficient Time Consuming Expensive Context of the App and how it works Context of Business Risk Examining the Production-Bias: Context
  • 28. Wrong Team Wrong Time Wrong Context
  • 30. How Test-Driven Security Should Work When a team writes code, they know the syntax is wrong when it won’t compile. When a team merges code they know there is a problem when it doesn’t merge. When a team runs unit tests, they know the code is wrong when it fails the unit test. When a team runs integration tests, they know the code is wrong when it doesn’t work as designed. When a team introduces a vulnerability, they know when it fails a security test.
  • 31. PLAN M ONITOR CODE BUILD T E S T RELEASE DEPLOY OPERATE DEV OPS Right Time: Pre-Production Security Tests Security Tests Instrumenting Security Tests into CI/CD gives engineers immediate feedback. Adding the ability to test locally allows for quick iteration in the fix-test loop if a new bug is identified. Local Dev & CI/CD
  • 32. ● Set up working agreements across teams/apps/departments ● Create Standards documentation automatically (OpenAPI/Introspection) ● Seed the database! Test in Pre-Prod! ● Understand these two things deeply ○ Object Level Authorization (Tenancy Filtering) ○ Function Level Authorization Cover Your Bases
  • 33.
  • 34. ● Engage a project team and their pipeline ● Choose AN app or service to start ● Choose a technology (SCA, DAST) ● Iterate and expand Just Start!