The AppSec How-To: 10 Steps to Secure Agile Development



Similar documents
How We Implemented Security in Agile for 20 SCRUMs- and Lived to Tell

The AppSec How-To: Achieving Security in DevOps

Software Quality Testing Course Material

The Web AppSec How-to: The Defenders Toolbox

Adobe Systems Incorporated

Passing PCI Compliance How to Address the Application Security Mandates

Interactive Application Security Testing (IAST)

Security and Vulnerability Testing How critical it is?

Managing Vulnerabilities for PCI Compliance White Paper. Christopher S. Harper Managing Director, Agio Security Services

elearning for Secure Application Development

Seven Practical Steps to Delivering More Secure Software. January 2011

Secure Code Development

IBM Rational AppScan: Application security and risk management

Kentico CMS security facts

How to Avoid an Attack - Security Testing as Part of Your Software Testing Process

Application security testing: Protecting your application and data

How to achieve PCI DSS Compliance with Checkmarx Source Code Analysis

How To Protect Your Data From Attack

How to start a software security initiative within your organization: a maturity based and metrics driven approach OWASP

Kenna Platform Security. A technical overview of the comprehensive security measures Kenna uses to protect your data

Integrating Application Security into the Mobile Software Development Lifecycle. WhiteHat Security Paper

Vulnerability Management in an Application Security World. AppSec DC November 12 th, The OWASP Foundation

Testing Solutions to Tackle Application Security Checkpoint Technologies SQGNE. Jimmie Parson Checkpoint Technologies

APPLICATION SECURITY: ONE SIZE DOESN T FIT ALL

Secure Development Lifecycle. Eoin Keary & Jim Manico

Information Supplement: Requirement 6.6 Code Reviews and Application Firewalls Clarified

Application Code Development Standards

HP Application Security Center

A Strategic Approach to Web Application Security The importance of a secure software development lifecycle

Production Security and the SDLC. Mark Kraynak Sr. Dir. Strategic Marketing Imperva

Smarter Balanced Assessment Consortium. Recommendation

DISA's Application Security and Development STIG: How OWASP Can Help You. AppSec DC November 12, The OWASP Foundation

Turning the Battleship: How to Build Secure Software in Large Organizations. Dan Cornell May 11 th, 2006

Black Box versus White Box: Different App Testing Strategies John B. Dickson, CISSP

2015 Vulnerability Statistics Report

Automating Security Testing. Mark Fallon Senior Release Manager Oracle

Application Security Center overview

ASV Scan Report Attestation of Scan Compliance

IBM Innovate AppScan: Introducin g Security, a first. Bobby Walters Consultant, ATSC bwalters@atsc.com Application Security & Compliance

! Resident of Kauai, Hawaii

White Paper. Automating Your Code Review: Moving to a SaaS Model for Application Security

ENJOYING OPEN SOURCE WITHOUT COMPROMISING BUSINESS. Dr. Ron Rymon Founder, White Source Software

Development. Resilient Software. Secure and. Mark S. Merkow Lakshmikanth Raghavan. CRC Press. Taylor& Francis Croup. Taylor St Francis Group,

OWASP Top Ten Tools and Tactics

CSUSB Web Application Security Standard CSUSB, Information Security & Emerging Technologies Office

Building Assurance Into Software Development Life- Cycle (SDLC)

Implementation of Web Application Security Solution using Open Source Gaurav Gupta 1, B. K. Murthy 2, P. N. Barwal 3

Starting your Software Security Assurance Program. May 21, 2015 ITARC, Stockholm, Sweden

8070.S000 Application Security

WhiteHat Security White Paper. Evaluating the Total Cost of Ownership for Protecting Web Applications

Agile Security Successful Application Security Testing for Agile Development

WHITE PAPER. FortiWeb and the OWASP Top 10 Mitigating the most dangerous application security threats

Learning objectives for today s session

How To Protect A Web Application From Attack From A Trusted Environment

Still Aren't Doing. Frank Kim

Security Information & Policies

From the Bottom to the Top: The Evolution of Application Monitoring

Enterprise Application Security Program

Integrating Security Testing into Quality Control

The purpose of this report is to educate our prospective clients about capabilities of Hackers Locked.

SD Elements: A Tool for Secure Application Development Management

Building & Measuring Security in Web Applications. Fabio Cerullo Cycubix Limited 30 May Belfast

The Top Web Application Attacks: Are you vulnerable?

A Strategic Approach to Web Application Security

Creating Stronger, Safer, Web Facing Code. JPL IT Security Mary Rivera June 17, 2011

05.0 Application Development

IT Security & Compliance. On Time. On Budget. On Demand.

BUILDING AN OFFENSIVE SECURITY PROGRAM BUILDING AN OFFENSIVE SECURITY PROGRAM

How to break in. Tecniche avanzate di pen testing in ambito Web Application, Internal Network and Social Engineering

Is Drupal secure? A high-level perspective on web vulnerabilities, Drupal s solutions, and how to maintain site security

PCI-DSS Penetration Testing

SAFECode Security Development Lifecycle (SDL)

Introduction: 1. Daily 360 Website Scanning for Malware

PCI Compliance - A Realistic Approach. Harshul Joshi, CISM, CISA, CISSP Director, Information Technology CBIZ MHM hjoshi@cbiz.com

Web Application Security. Vulnerabilities, Weakness and Countermeasures. Massimo Cotelli CISSP. Secure

Change Management. Why Change Management? CHAPTER

White Paper. Guide to PCI Application Security Compliance for Merchants and Service Providers

How To Ensure That Your Computer System Is Safe

EVALUATING COMMERCIAL WEB APPLICATION SECURITY. By Aaron Parke

Bug Report. Date: March 19, 2011 Reporter: Chris Jarabek

Making Database Security an IT Security Priority

Effective Software Security Management

State of Web Application Security. Ralph Durkee Durkee Consulting, Inc. Rochester ISSA & OWASP Chapters rd@rd1.net

Levels of Software Testing. Functional Testing

HP Fortify application security

Protecting Your Organisation from Targeted Cyber Intrusion

Introduction:... 1 Security in SDLC:... 2 Penetration Testing Methodology: Case Study... 3

IMPROVING VULNERABILITY MANAGEMENT EFFECTIVENESS WITH APPLICATION SECURITY MONITORING

White Paper. Understanding NIST FISMA Requirements

Christchurch Polytechnic Institute of Technology Information Systems Acquisition, Development and Maintenance Security Standard

Transcription:

The AppSec How-To: 10 Steps to Secure Agile Development Source Code Analysis Made Easy 10 Steps In Agile s fast-paced environment and frequent releases, security reviews and testing sound like an impediment to success. How can you keep up with Agile demands of continuous integration and continuous deployment without abandoning security best practices? Companies have found the following ten practices helpful to achieve a holistic secure Software Development Life Cycle (SDLC) process in an Agile SaaS world. The approaches taken by these companies follow a basic philosophy: keeping security as simple as possible and remove any unnecessary load from the development team. 1 Be part of the process Security requirements should be considered as additional development checkpoints. Each benchmark needs to be achieved before proceeding to the next stage of an Agile process. For each step in Agile, associate a security milestone that needs to be achieved. Start already at the post-release planning to perform a security high-level design. This includes the following aspects: - Security in code development. For example, inspect the planned application in terms of which APIs are going to be used. - Security in technologies. Identify technologies that are going to be used. For example, if system testing is performed within a Maven process, security tests should be integrated within this system. - Security in features. For example, forecast any problems associated with regulations. Say, when tracking cookies are used within a product delivered to the UK then prepare compliance to UK privacy regulations. 2 Enforce your policy by using a security package API in each product There are two aspects to this stage: a. Use a security package such as OWASP s Enterprise Security API (ESAPI). ESAPI is a toolkit which enables the developers to easily consume various utilities. The toolkit provides a variety of out-of-the box utilities such as validators, encoders, encryptors, and randomizers. By using ESAPI, developers do not need to investigate the best security practices and spend time researching correct implementation methods. 1

Consider hashing, as an example. Instead of relying on the developer to add a hash salt, the salt can already be implemented as part of the ESAPI configuration. The developer, in turn, is left simply to consume the provided API. Particular emphasis should be made on validators because these prevent the most common Web application vulnerabilities, such as SQLi and XSS. Each organization needs to evaluate where to integrate the validators. Some businesses may decide to apply validators on the controller level (e.g. on the Apache layer or within the Tomcat filter). Other companies prefer to integrate validators within the development code to test each input. While each company needs to decide the right strategy for them, we have found that many companies choose to validate each input within their code. This decision is based on two main reasons: All the regular expressions that are written to validate the input can be constructed as simple as possible in order to avoid any type of performance issue. These regular expressions are actually more similar to a business-oriented validation. In case a problem arises- or a specific validator needs to be changed- only the specific input needs to be changed. On the other hand, a higher level validator requires a whole QA process to verify the entire system. One organization we worked with took code-level validation one step further. The particular organization implemented a validator that does not return the traditional true/ false boolean values, but rather returns null if the input is invalid. In this manner, the security team was able to prevent developers from mistakenly using that same value later on in the code. b. Validate that the developers are using the right API. For each input, ensure that the developer uses the right validator as provided by the security team. This entails failure of the security test in case the developer chooses not to use the API. Enforcement can be achieved through source code analysis that is customized to the security team s requirement. 3 Integrate Source Code Analysis (SCA) within the native process of code management Enforcing the security policy means that the developers cannot proceed with the build process if the checked in code does not comply with policy. To keep up with the fast-paced development environment, the developers must be able to consume the policy without a long training period. The way to address this challenge is by integrating SCA within the different stages of the development process. Particular aspects to pay attention to are: - Integrating the SCA within the build automation tool (such as Maven). Organizations typically run the SCA in two modes. The first is running the scan as incremental tests each time the developer performs a commit. In this way, only the change between the last scan and the current scan is checked. The second is running a full security scan within a full-system test, say during the nightly build. If the build fails, the developer has to fix the flaw before continuing with the development. - Presenting SCA findings within the build management and Continuous Integration server (such as within TeamCity). In case of an SCA alert, it s more efficient for the developer to click on the finding and dynamically identify the specific vulnerability. 2

- Enhancing the SCA with a knowledge base for the developer. Similarly to a developer fixing a compilation error, the developer needs to know how to fix the faulty code. For this, the SCA tool should also contain a knowledge base which describes the risk and the proper remediation advice. 4 Break the build for any high or medium findings Do not compromise security by releasing a product that contains any high or medium findings. This requires eliminating the flaw already at the build process. Meaning, if the developer checks in a few high security bugs, the build will break. Unless the vulnerabilities are fixed, the developer fails to build a package. 5 Use automation to collaborate with the security dynamic test Dynamic testing within the product can be implemented through positive and negative unit tests. - Use positive testing to validate the input. For instance, a positive test validating input in the form of an email address will test that the characters @ and. appear, but no other special characters. - Complement the positive test through a negative test. The negative test should pick up all input that does not conform to the positive test. Using the above scenario, an email address embedding a SQL Injection will be caught by the negative test. Essentially, the complementary negative test acts as the dynamic test. 6 Run a penetration test Engage both professional and your customers as penetration testers: - Perform a penetration testing of the final product by an external vendor. This includes an automated or manual test of the product once it s released in its Alpha stage. - Allow customers to run a penetration test and work as a community to succeed. The organization must perform all the necessary steps in order to release a secure product. That said, many customers are themselves subjected to regulation which requires running penetration testing on third-party products. The benefit to you? Gaining customer confidence. This is particularly important when talking about Software-as-a-Service (SaaS) products whose success is based on the trust that customers put on their providers. 3

7 Source Code Analysis Made Easy Engage technology leaders as security champions by showing them the value Even with large security teams, it is obvious that developers outnumber the security team. To extend security s outreach, engage with the technology leaders and place them as the security champions. Gaining such cooperation with R&D guarantees that also when security is not physically present, security does come up in each and every scrum meeting. 8 Train developers on a regular basis The point here is not necessarily to establish a formal training process where developers are sent to a Web application security course. There are other means for training, such as: - Providing developers with the security knowledge Enhancing the SCA with the knowledge base of a specific vulnerability, as recommended in one of the practices above, is part of this kind of training. By helping developers understand the risk and its mitigation, security awareness increases whereas developers start viewing security and code differently. - Being accessible to developers. Once security becomes an ingrained process, Q&A from the developers begin to pile up at the security team s desk. The security team should have an open door policy to address all the developers concerns. 9 Provide a collaboration platform for security discussions This practice goes hand in hand with the previous practice on training developers. The point here is to not only accumulate or disseminate information related to security practices. This practice focuses on establishing a security collaboration platform with the intent of sharing information and raising discussions surrounding security issues. 10 Start small but think big Many of these practices, especially the practice of breaking the build for any high or medium finding, requires the management and superiors support. We recognize that gaining this type of trust is not an easy goal to achieve. Various companies have found the following steps helpful: - Take one small project and turn it to a success story. Listen to R&D during this process. Learn from mistakes and refine the process moving forward. - With one success story under the belt, move on to a new project. Continue refining, and learning from mistakes. Create 2-3 successful stories. - Review the security bugs that are returned by customers. Compare the number of vulnerabilities in one of these success stories with a different project that does not follow the security practices. 4

Show management how these vulnerabilities interfere with the normal delivery and maintenance of the product. - Progress to the big legacy project. At first, don t break the build for security findings in this big project. It is enough at this stage to identify the gaps, close them and create a program of how development will fix the flaws. - Fix the flaws on the legacy system only after achieving confidence. Fix the flaws on the legacy systems only after understanding how to correctly deliver the security package (such as ESAPI), how to inspect it correctly, and where to correctly apply the validation without any impact to the product. - Proceed to the big project in-making. Naturally, this is the ultimate goal and security should already be integrated within the Agile process. At this step, the validators should already be packaged and set within a single framework. 5