7 strategies for scaling product security QCon 2018 New York City - - PowerPoint PPT Presentation

7 strategies for scaling
SMART_READER_LITE
LIVE PREVIEW

7 strategies for scaling product security QCon 2018 New York City - - PowerPoint PPT Presentation

7 strategies for scaling product security QCon 2018 New York City Angelo Prado, Senior Director Jet.com | Walmart about me 12+ years of experience in software development and Leading Product Security teams at Jet.com, Salesforce and


slide-1
SLIDE 1

7 strategies for scaling product security

QCon 2018 – New York City Angelo Prado, Senior Director Jet.com | Walmart

slide-2
SLIDE 2

about me

12+ years of experience in software development and Leading Product Security teams at Jet.com, Salesforce and Microsoft 4 times Black Hat Speaker, co-author of 10+ CVEs including the BREACH attack (SSL Side Channel) Currently leading a product security team across two continents, assistant professor in Spain at Comillas University, advising security startups and non-profits

slide-3
SLIDE 3

earlier career attempts…

slide-4
SLIDE 4

what is product security

slide-5
SLIDE 5

Product Security teams are the guardians of customer data, fixing and preventing security vulnerabilities. Inclusive of much more than just code. Product Security covers the full service and how your customers use and interact with it securely. It goes beyond securing the underlying software and includes operational responsibilities.

slide-6
SLIDE 6

why do we need

Product Security?

slide-7
SLIDE 7

core mission

prevent vulnerabilities build effective automation perform security reviews harden the product

slide-8
SLIDE 8

product security?

who needs

slide-9
SLIDE 9

you do.

slide-10
SLIDE 10

we do.

slide-11
SLIDE 11

Security is reflected in how products are built and operated. Product Security should be engaged with customers and partners. Engineering teams must have a consistent interpretation of the security posture and secure development lifecycle.

slide-12
SLIDE 12

7 strategies to scale

Building Product Security from the ground up

slide-13
SLIDE 13

prioritize relationships and establish a non- blocking function

slide-14
SLIDE 14

SERVICE CATALOG

design reviews automation services security testing vulnerability management training & research

slide-15
SLIDE 15

Product Security should be a lean, effective, non- blocking technical assessment function

slide-16
SLIDE 16

rules of engagement

prioritize relationships over bugs

The number of teams and individuals you interact with will keep growing – In connecting with other human beings, align priorities and exercise empathy

be thoughtful about prioritization and risk

Security isn’t always #1 - If you want to build a relationship with someone, you need to know their priorities. Develop a narrative that resonates with them

be pragmatic and solicit feedback

Security should not block shipping, and it shouldn’t be reactive. We triage vulnerabilities based on severity, but not all bugs are considered equal. Listen to the teams you support and proactively seek improvement importunities In collaboration with Tom Maher

slide-17
SLIDE 17

Even the most professional, security- conscious developers take it personally

  • ccasionally. It's not their fault. A regular

drumbeat of "you're doing it wrong" will discourage anyone. Developers usually want to do the right thing - Promote thoughtful solutions that scale and balance technical capabilities with product usability

slide-18
SLIDE 18

the hacker mindset

aptitude

  • pen source contributions,

research, publications and bug bounty recognitions

breaker mindset

substantial knowledge of application-level attacks and flaws

builder mindset

strong knowledge of software development, browsers, cloud services, network, crypto and defense strategies

soft skills

effective communication skills and the ability to influence and communicate with engineers

slide-19
SLIDE 19

Run security like a business: Sorry, Mr. Hacker, this just isn't working out...

slide-20
SLIDE 20

invest in vulnerability management, metrics and reporting

slide-21
SLIDE 21

vuln management

the fix is validated in an staging environment, including different variants

verify fix

the fix is released to production and required comms are handled

ship it!

the engineering team works out a fix, assisted by the security contact

work on a fix

a vulnerability is found, an issue is created and assigned to the team backlog

deliver bug

slide-22
SLIDE 22

agile workflows

security owner

each product security engineer

  • wns a portfolio of applications

proactive signoff

product teams are notified of any security issues and provided with hardening recommendations

design review

security owners are responsible for attending design reviews

continuous testing

security owners deploy automation and perform gray-box testing

threat modeling

security owners identify weaknesses and mitigations

slide-23
SLIDE 23

vulnerability notifications

the priority, description of the vulnerability, and the remediation target date should be emphasized

usability is a key

there should be a clear call to action on any vulnerability, indicating proposed remediation

make it actionable

ensure the right engineering team and security

  • wner receive notifications for their products

make it relevant

slide-24
SLIDE 24

prioritize responsibly

P1 P2 P0

Critical Priority (P0) – 7 days SLA Medium Priority (P1) – 30 days SLA Low Priority (P2) – 60 days SLA

slide-25
SLIDE 25

SLA process

starts on delivery

  • nly after the right product team has been identified

and their engineers notified

resets if misrouted

teams should not be penalized for incorrect delivery

requires exception workflow

engineering manager and security manager approval is required if a security issue cannot be remediated within the agreed SLA

slide-26
SLIDE 26

vulnerability management

01 02 03 04 05 06 07

01 – deliver bug 02 – work on a fix 03 – SLA is due 07 – fixed! 05 – manager approves 04 – exception requested 06 – security approves

slide-27
SLIDE 27

track release progress

30 24 43

these are bugs where no action has been taken

  • pen bugs

bugs actively worked on

in progress

fixed & verified

resolved

slide-28
SLIDE 28

intake time / time to resolution

4.3 2.5 3.5 4.5 2.4 4.4 1.8 2.8 2 2 3 5

2 4 6 8 10 12 14 team 4 team 3 team 9 team 7

New In Progress Fixed

slide-29
SLIDE 29

vulnerability lifetime in production

20d 15d 18d 22d

Q1 Q2 Q3 Q4 measures time since a team starts working on a bug until a fix is deployed

>

starts when a vulnerability is introduced in production, at deployment – this metric measures the effectiveness of your product security program.

>

cross-referenced with pull request size, it can help understand complexity and exposure

>

slide-30
SLIDE 30

SLA adherence benchmarks

team a team b team c team d team d team f team g team h

highlights teams requiring assistance recognizes teams that prioritize security

slide-31
SLIDE 31

SLA trends

  • ver time

Q2 17 Q3 17 Q4 17 Q1 18 Q2 18 Q3 18

critical issues all issues low priority

slide-32
SLIDE 32

Benchmark by vulnerability type

XSS 66% Session Management 83% Authorization 91% SQL Injection 44% Information Disclosure 59%

slide-33
SLIDE 33

developers received

security training

90%

slide-34
SLIDE 34

teams have automated coverage SCA | RTA | DAST

73%

slide-35
SLIDE 35

automate all the things

slide-36
SLIDE 36

Complexity is the enemy of security: Secure by default or die not actually trying

slide-37
SLIDE 37

scaling source code reviews

98%

we cannot review

  • f check-

ins

slide-38
SLIDE 38
  • f security vulnerabilities

can be automatically detected

40%+

slide-39
SLIDE 39

vulnerability demographics

low- hanging fruit

testing required

manual

discovery possible

auto

slide-40
SLIDE 40

vuln sources

penetration testing

20%

automation and tooling

35%

bug bounty programs

40%

regressions

5%

slide-41
SLIDE 41

CI/CD integration

analyzes check-ins automatically log issues manual validation

slide-42
SLIDE 42

types of automation

static code analysis

analyzes source code flows and incremental check-ins with known rules

dynamic analysis

capable of testing web service and application endpoints in production

runtime self-protection

understands when an application’s normal flow is being exercised by a malicious actor

actual vulnerability

slide-43
SLIDE 43
  • pen source

software

A solid third-party library program is required to review exploitable vulnerabilities and dependencies. Monitor CVEs and public exploits.

Vulnerabilities in Third-Party Libraries

slide-44
SLIDE 44

successful automation

not actual vulnerabilities

false positives

things that are technically valid but we are willing to live with due to mitigating controls or exploitability

acceptable risk

Important, exploitable vulnerabilities

issues we care about

slide-45
SLIDE 45

Invest in product hardening

slide-46
SLIDE 46

awkwardness

That period with an API after you know what you can do but before you know what you should do

The Kaminsky Dictionary

slide-47
SLIDE 47

nailing the fundamentals

01

HSTS & CSP

HTTP Strict Transport Security and Content Security Policy

03

Secret Management

Storing secrets securely

02

Device Fingerprinting

Stopping account take-over attempts and using second-factor Auth smartly

04

Proactive Controls

Providing users and admins with management controls and visibility

slide-48
SLIDE 48

reducing the attack surface

HSTS, CSP & Expect-CT

Ensuring that all requests are done with strict transport security and that rogue certificates are not being used (certificate transparency). Content Security Policy enables us to filter out insecure content, avoid referrer leakage and in general block malicious JavaScript from executing

slide-49
SLIDE 49

secret management

identify secrets

use rules & regular expressions implement automatic validation

store securely

key management system (key vault with HSM)

rotate secrets

automatically perform key rotation

slide-50
SLIDE 50

session management

www.nsa.gov

Login History Device & Location Apps / oAuth Active Sessions

slide-51
SLIDE 51

device fingerprinting

Proper device fingerprinting combined with behavioral and geolocation analytics enables you to perform contextual two-factor authentication via SMS or one- time links / tokens via email, reducing false negatives and false positives

smart and effective implementation

fingerprints are stored over time and attached to a given user identity

linked to the user

prioritize features with a higher weight, more specific to your users

unique

understand that certain capabilities for the user-agent can change

adaptive

slide-52
SLIDE 52

controls proactive

Define Security Requirements Leverage Security Frameworks Secure Database Access Validate Inputs & Escape Data Enforce Access Controls Protect Data at Rest & in Transit Implement Secure Logging Handle Errors & Exceptions

slide-53
SLIDE 53

create a mature education & awareness program

slide-54
SLIDE 54

threat modeling

Learn to think like a hacker and identify threats and security objectives. Identify flows, mitigations and make informed decisions about residual risk.

slide-55
SLIDE 55

self-guided training

deliver secure coding guidelines that are relevant to the our organization’s languages and frameworks at a minimum, common attack patterns, secure storage, cloud security and secure feature design should be covered

slide-56
SLIDE 56

▪ Clear secure coding guidelines ▪ Real-life libraries & frameworks ▪ Previous vulnerability examples ▪ Actionable code snippets Keep it relevant! i.e. NodeJS developers don’t need to know about XML injection and heap overflow exploitation

classroom training

slide-57
SLIDE 57

security champions

shared accountability programs like this help you scale as engineering

  • rganizations outnumber

security engineers Recognize and reward good behavior across all roles

slide-58
SLIDE 58

leverage the collective skills of the research community

slide-59
SLIDE 59

why do I need a Bug Bounty Program

slide-60
SLIDE 60

Everything fails. Even things that make everything fail.

Dan Kaminsky

slide-61
SLIDE 61

launching a bounty program

scope

what to include as your targets and how to frame it

rewards

how to reward competitively

recruiting

who to invite to your program and when how to maintain hackers interested over time

engagement

slide-62
SLIDE 62

a global community

20%

20%

30%

10% 20%

slide-63
SLIDE 63

Over 170,000 hackers participating Over 70,000 vulnerabilities found Over $30 million paid in bounties

Data as of June 2018

Source: HackerOne

slide-64
SLIDE 64

engage your top researchers

Fly them to Vegas and keep them

  • hydrated. Be transparent and
  • vercommunicate. Keep them happy. Fly

them to your HQ. Recruit them if

  • necessary. Be prompt, reasonable

and technical. Run recurring

promotions and challenges.

slide-65
SLIDE 65

Private programs enable you to increase

signal to noise ratio. VIP programs drive

  • retention. Consider researcher circles for

knowledge sharing. Recruit from active

  • programs. Reward competitively. Defuse

escalations / disclosure. Resource your program.

slide-66
SLIDE 66

deploy a solid SDL and maturity model

slide-67
SLIDE 67

six steps for a good SDL

design

Threat Modeling Design Reviews

build

Static Code Analysis Code Reviews

learn and refine

Retrospective Planning

verify

Penetration Testing

  • wnership

Patch Management Remediation Pen-testing

release

Dynamic Testing Bug Bounty

slide-68
SLIDE 68

maturity model

evidence-based framework for evaluating the overall security stance of a business unit or new acquisition. Provides an authoritative and consistent roadmap for the advancement of a the organization’s overall product security posture. Should be meaningful and objective.

slide-69
SLIDE 69

Another day, another layer of abstraction

slide-70
SLIDE 70

maturity model

level 1 – initial

Application Login/Admin Interface Inventory – Continuous Dynamic Application Scanning – Customer Data Inventory – HTTPS By Default – Legacy Source Code Review & Remediation – Product Security 3rd Party Assessment – Strong Password Hashing

1

Q1 Y1 Q3 Y1 Q1 Y2 Q2 Y2 Y3+

slide-71
SLIDE 71

maturity model

level 2 – defined

Basic Logging for Security Events – Client Software is Signed – Encryption keys not stored in source control – Security Requirements for New Features and Designs – NGWAF deployed for Web + API endpoints – In-House Manual Testing of Codebase / App – No "Roll-your-own" Cryptography – Security Tools Run Against Codebase / App On Release – Strong Session Management (AuthN/AuthZ) – Strong Encryption Standards

2

Q1 Y1 Q3 Y1 Q1 Y2 Q2 Y2 Y3+

slide-72
SLIDE 72

3

Q1 Y1 Q3 Y1 Q1 Y2 Q2 Y2 Y3+

maturity model

Level 3 – managed

Enhanced Application Logging – HTTPS-Only (HSTS) – Inventory of open source – SLA + Signoff

  • r Equivalent Control (90% > Adherence) – Source

Code Check-in Monitoring – Strong Multitenancy Controls – Multi-factor Authentication – Strong Secrets Storage – Strong Session Authentication/Authorization – Threat Modeling of New Features – Role-Based Access Control

slide-73
SLIDE 73

maturity model

4

Q1 Y1 Q3 Y1 Q1 Y2 Q2 Y2 Y3+ level 4 – mature and automated

Static Code Analysis at Check-in time – Runtime and Dynamic Analysis – APIs must support multi-scope tokens – Bug Bounty Program Coverage – Code Signing – Continuous External App Scanning – Field-level Authenticated Encryption – Integrated Automated Security – Testing with QA Process – Device Fingerprinting – Test Key/Credential Rotation

slide-74
SLIDE 74

5

Q1 Y1 Q3 Y1 Q1 Y2 Q2 Y2 Y3+

maturity model

Built-In Honeypot / Indicators Automated OSS Coverage HSM and Device Fingerprinting

level 5 – optimizing

Behavioral Anomaly Detection Usage of App Containers

slide-75
SLIDE 75

sample scorecard

security control initial defined mature

  • ptimizing

HTTPs by default Strong Session Management Multi-Factor Authentication Bug Bounty Program Credential Rotation

slide-76
SLIDE 76

the last 0day is in captivity – the galaxy is at peace

slide-77
SLIDE 77

thank you !

* you guys were great

slide-78
SLIDE 78

angelpm@gmail.com PradoAngelo LinkedIn.com/in/angeloprado

contact

Check out my SSL Research: BreachAttack.com