agile and secure – can we be both? innotech austin october ...€¦ · 11/10/2007  · background...

37
Agile and Secure – Can We Be Both? InnoTech Austin October 11 th , 2007

Upload: others

Post on 23-Aug-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Agile and Secure – Can We Be Both?

InnoTech Austin

October 11th, 2007

Page 2: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Agenda

• Background• Evolution of Software Development Methodologiesp g• Benefits of Agile Development• Requirements for Secure Development

A il d S• Agile and Secure• Questions

1

Page 3: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Background

• Programmer by background– Both .NET and JEE: MCSD and Java 2 Certified Programmer

Developer focused on security not a security professional looking at development– Developer focused on security, not a security professional looking at development

• Denim Group– Software Development: .NET and JEE– Software / Application Security

• Vulnerability Assessments, Penetration Testing, Training, Mentoring

• Basis for this presentation:p– Work with our customers doing SDLC security and mentoring– Challenges facing our own development teams

• Deliver projects in an economically-responsible manner• Uphold security goals

2

Page 4: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Evolution of Software Development Methodologiesp g• Ad Hoc• Waterfall• Agile

3

Page 5: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Ad Hoc Software Development

• Early days of computing– Focus was on hardware– Software was secondary

• No structure – “cowboy coding”• Became unacceptable as software systems became larger and

more critical

4

Page 6: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Waterfall Software Development

• Treat software engineering as a structured engineering process• House building metaphor

5

Page 7: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Waterfall Software Development

Requirements Architecture Design Coding Integration Testing Deployment

6

Page 8: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Problems with Waterfall Model

• Creating software is different than creating bridges or buildings– Creativity required throughout the process – not just at the outset

• Very documentation heavy• Changes are expensive

– Must go back up the waterfall for impact analysis

• Business requirements change over time– By the time you finish a system, the target has moved

7

Page 9: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Enter Agile Methods

• Be more responsive to business concerns• Increase the frequency of stable releases• Decrease the time it takes to deploy new features• Do not waste time on “superfluous” documentation and planning

8

Page 10: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Notable Agile Methods

• eXtreme Programming (XP)• Feature Driven Development (FDD)• SCRUM• MSF for Agile Software Development• Agile Unified Process (AUP)Agile Unified Process (AUP)• Crystal

9

Page 11: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Manifesto for Agile Software Developmentp

Individuals and interactions over processes and tools

Working software over comprehensive documentation

Customer collaboration over contract negotiation

Responding to change over following a plan

10

Source: http://www.agilemanifesto.org/

Page 12: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Agile’s Core ValuesAgile’s Core Values

C i ti• Communication

• Simplicity

• Feedback

• Courage

11

Page 13: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Principles of Agile DevelopmentPrinciples of Agile Development• Rapid Feedback

• The system is appropriate f th i t d d di• Simple Design

• Incremental Change

for the intended audience.

• The code passes all the • Incremental Change

• Embracing Change

ptests.

• The code communicates

• Quality Work

• The code communicates everything it needs to.

Th d h th ll t• The code has the smallest number of classes and methods.

12

Page 14: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Agile PracticesAgile Practices• The Planning Game

• Customer: scope, priorities and release dates

• Developer: estimates

• The Driving Metaphor

• Developer: estimates, consequences and detailed scheduling

• Shared Vision

• On-Site Customer

• Small Releases • Development iterations or cycles that last 1-4 weeks.

• Release iterations as soon as possible (weekly, monthly, quarterly).

13

Page 15: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

More Agile PracticesMore Agile Practices• Collective Ownership

• Test Driven

• Continuous Integration

• Coding Standardsg

• Pair Programming

14

Page 16: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

The Agile Practitioner’s Dilemma The Agile Practitioner s Dilemma Agile Forces:

More responsive to Secure Forces:

Comply with more pbusiness concernsIncreasing the frequency of stable

p yaggressive regulatory environmentfrequency of stable

releasesDecrease the time

environmentFocus on need for security

it takes to deploy new featuresD t t ti

Traditional approaches to security requireDo not waste time

on “superfluous” documentation and

security require additional documentation and l ( ’Oh )

15

planning planning (D’Oh!)

Page 17: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Definition of Secure

A secure product is one that protects the confidentiality, p p y,integrity, and availability of the customers’ information, and the integrity and availability of processing resources under control of the s stem’s o ner or administratorthe system’s owner or administrator.

Source: Writing Secure Code (Microsoft com)-- Source: Writing Secure Code (Microsoft.com)

16

Page 18: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

A Secure Development Process…

• Strives To Be A Repeatable Process

• Requires Team Member Education

• Tracks Metrics and Maintains Accountability

Sources:“Writing Secure Code” 2nd Ed., Howard & LeBlanc

“The Trustworthy Computing Security Development Lifecycle”by Lipner & Howard

17

y p

Page 19: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Secure Development Principles

• SD3: Secure by Design, Secure by Default, and in Deployment• Learn From Mistakes• Minimize Your Attack Surface• Assume External Systems Are Insecure• Plan On FailurePlan On Failure • Never Depend on Security Through Obscurity Alone• Fix Security Issues Correctly

18

Page 20: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Secure Development Practices

• Threat Modeling / Architectural Risk Assessment

• Education, Education, Education

• Secure Coding Techniques– Via standards, practitioner knowledge and tools

• Security ReviewsA hit t– Architecture

– Design– Code

19

• Security Testing (Penetration Testing)

Page 21: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Microsoft’s Secure Development Lifecycle (SDL)Microsoft s Secure Development Lifecycle (SDL)

• Requirements • DesignDesign• Implementation• Verification• Release• (Waterfall!)

20

Page 22: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Observations of the SDL in Practice• Threat Modeling is the Highest-Priority Component• Penetration Testing Alone is Not the Answer• Tools Should be Complementary

21

Page 23: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Threat ModelingThreat Modeling• STRIDE – classify threats

– Spoofing Identity– Spoofing Identity– Tampering with Data– Repudiation

Information Disclosure– Information Disclosure– Denial of Service– Elevation of Privilege

• DREAD – rank vulnerabilities– Damage Potential– Reproducibility– Exploitability– Affected Users

22

– Discoverability

Page 24: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Dr Dobb’s says Agile Methods Are Catching OnDr. Dobb’s says Agile Methods Are Catching On41% of organizations have adopted an agile

methodologymethodology

Of the 2,611 respondents doing agile…p g g

• 37% using eXtreme Programming• 19% using Feature Driven Development (FDD)• 16% using SCRUM

7% i MSF f A il S ft D l t• 7% using MSF for Agile Software Development

23

Source: http://www.ddj.com/dept/architect/191800169

Page 25: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Agile Teams are “Quality Infected”• 60% reported increased productivity

• 66% reported improved quality

• 58% improved stakeholder satisfaction58% improved stakeholder satisfaction

24

Page 26: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Adoption Rate for Agile Practices

Of the respondents using an agile method…

• 36% have active customer participation

• 61% have adopted common coding guidelines61% have adopted common coding guidelines

• 53% perform code regression testing

• 37% utilize pair programming

25

Page 27: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

An Integrated Process

Making Agile Trustworthy

26

Page 28: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Project Roles

• Product Manager / Customer• Program Manager / Coach• Architect• Developer• TesterTester• Security Adviser

27

Page 29: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Organization Setup

• Education & Training (include Security)– Developers– Testers– Customers

• User Stories / Use Case Driven Process• Enterprise Architecture Decisions• Organizational Adoption of Threat Modeling

28

Page 30: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Project / Release PlanningProject / Release Planning• User Stories / Use Cases Drive…

– Acceptance Test ScenariosAcceptance Test Scenarios– Estimations may affect priorities and thus the composition of the

release– Inputs for Threat Modelingp g– Security Testing Scenarios– Determine the qualitative “risk budget”

• Keep the customer involved in making risk tradeoffsp g

• Finalize Architecture & Development Guidelines– Common Coding Standards (include security)

• Crucial for collective code ownershipp– Data Classification standards– Conduct Initial Threat Modeling (assets & threats)

• Agree on STRIDE and DREAD classifications

29

– Designer’s Security Checklist

Page 31: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Iteration PlanningIteration Planning• 1-4 Weeks in Length (2 weeks is very common)

B i ith It ti Pl i M ti• Begins with an Iteration Planning Meeting – User Stories are broken down into Development Tasks– Developers estimate their own tasksp– Document the Attack Surface (Story Level)– Model the threats alongside the user story documentation

• Crucial in documentation-light processesCrucial in documentation light processes• Capture these and keep them

– Code will tell you what decision was made, threat models will tell you why decisions were made

– Crucial for “refactoring” in the face of changing security priorities

• Never Slip the Date– Add or Remove Stories As Necessary

30

Add or Remove Stories As Necessary

Page 32: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Executing an IterationExecuting an Iteration• Daily Stand-ups

• Continuous Integration– Code Scanning ToolsCode Scanning Tools– Security Testing Tools

• Adherence to Common Coding Standards and Security Guidelines– Crucial for communal code ownershipCrucial for communal code ownership

• Developer’s Checklist

31

Page 33: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Closing an Iteration

• Automation of Customer Acceptance Tests– Include negative testing for identified threats

• Security Code Review– Some may have happened informally during pair programming

32

Page 34: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Stabilizing a Release

• Schedule Defects & Vulnerabilities– Prioritize vulnerabilities with client input based on agreed-upon STRIDE and

DREAD t d dDREAD standards

• Security Push– Include traditional penetration testing

33

Page 35: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Compromises We’ve Made

• Security Compromises:– Short term, iterative focus removes some “top down” control– Focus on individual features can blind the process to cross-feature security

issues

• Agile Compromises:More documentation than is required in pure Agile development– More documentation than is required in pure Agile development

• Security coding standards• Data classification standards• Project-specific STRIDE and DREAD standards• User story threat models

– Additional tasks increase development time– Forces customers to accept security (isn’t this a good thing?)

34

Page 36: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Values of an Agile and Secure Process

C i ti• Communication• Simplicity• Feedback• Courage• Trustworthy

35

Page 37: Agile and Secure – Can We Be Both? InnoTech Austin October ...€¦ · 11/10/2007  · Background • Programmer by background – Both .NET and JEE: MCSD and Java 2 Certified Programmer

Questions

Dan [email protected](210) 572-4400

Website: www denimgroup comWebsite: www.denimgroup.comBlog 1: www.agileandsecure.comBlog 2: denimgroup.typepad.com

36