How To Integrate Security Into Devops
How To Integrate Security Into Devops
Key Challenges
DevOps compliance is a top concern of IT leaders, but information security is seen as an
inhibitor to DevOps agility.
Security infrastructure has lagged in its ability to become "software defined" and
programmable, making it difficult to integrate security controls into DevOps-style workflows in
an automated, transparent way.
Modern applications are largely "assembled," not developed, and developers often download
and use known vulnerable open-source components and frameworks.
Recommendations
Information security architects should:
Start with secure development and training, but don't make developers become security
experts or switch tools.
Embrace the concept of people-centric security and empower developers to take personal
responsibility for security compensated for with monitoring. Embrace a "trust and verify"
mindset.
Require all information security platforms to expose full functionality via APIs for automatability.
Use proven version control practices and tools for all application software and, equally as
important, for all scripts, templates and blueprints used in DevOps environments.
Adopt an immutable infrastructure mindset where production systems are locked down and
changed via development.
Table of Contents
List of Figures
Figure 1. Information Security Professionals: Do You Believe Your Information Security Policies/Teams
Are Slowing IT Down?............................................................................................................................ 3
Figure 2. IT Operations Professionals: Do You Believe Your Information Security Policies/Teams Are
Slowing IT Down?.................................................................................................................................. 4
Figure 3. DevSecOps............................................................................................................................. 5
By 2019, more than 50% of enterprise DevOps initiatives will have incorporated application security
testing for custom code, up from less than 10% in 2016.
Introduction
In 2012, Gartner introduced the concept of DevSecOps (originally "DevOpsSec"; see Note 1) to the
market in "DevOpsSec: Creating the Agile Triangle." In this research note, we identified the need for
information security professionals to become actively involved in DevOps initiatives and to remain
true to the spirit of DevOps, embracing its philosophy of teamwork, coordination, agility and shared
responsibility.
Based on hundreds of discussions with clients, we estimate that fewer than 20% of enterprise
security architects have engaged with their DevOps initiatives to actively and systematically
incorporate information security into their DevOps initiatives; and fewer still have achieved the high
degrees of security automation required to qualify as DevSecOps. Using the best practices outlined
in this research, we believe security architects can optimize and improve their overall security
posture by designing a set of integrated controls to deliver DevSecOps without undermining the
agility and collaborative underpinnings of the DevOps philosophy.
However, surveys at Gartner's data center and information security summits in 2015 indicate that
information security is viewed as an inhibitor to the agility and speed required by digital business
and DevOps initiatives. Both information security professionals (Figure 1) and IT operations
professionals (Figure 2) were surveyed.
Figure 1. Information Security Professionals: Do You Believe Your Information Security Policies/Teams Are
Slowing IT Down?
n = 41
n = 93
As shown in Figures 1 and 2, both information security and IT operations professionals, in nearly
identical ratios (approximately 4 to 1), believe information security is slowing down IT's ability to
respond to the needs of the business.
At the time of the original DevOpsSec research in 2012, DevOps was relatively new. However,
1
recent Gartner research indicates that 38% of enterprises are now using DevOps, and 50% will be
actively using it by the end of 2016. In the same survey, security and audit tools represented the
single highest-rated category of tools in terms of importance to an effective and efficient DevOps
implementation, and 82% of respondents indicated that they had to deal with one or more
1
regulations in their DevOps initiatives. The good news is that DevOps teams understand that
security and compliance are necessary. Now is the time for security architects to engage these
teams and apply the best practices identified in this research.
Analysis
Security Controls Must Be Programmable and Automated Wherever Possible
DevSecOps can be depicted graphically as the rapid and agile iteration from development (the left
side of Figure 3) into operations (the right side of Figure 3), with continuous monitoring and analytics
at the core.
Our goal as information security architects must be to automatically incorporate security controls
without manual configuration throughout this cycle in a way that is as transparent as possible to
DevOps teams and doesn't impede DevOps agility, but fulfills our legal and regulatory compliance
requirements as well as manages risk. Security controls must be capable of automation within
DevOps toolchains in order to enable this objective. This is important for two reasons. First,
automation reduces the chance of misadministration and mistakes, which are leading causes of
operations incidents, unexpected downtime and successful security attacks. Second, high levels of
automation eliminate the need for involvement from a security professional to manually configure a
security setting using a security console (and thus impacting the agility of DevOps environments).
When security platform capabilities such as identity and access management (IAM), firewalling,
vulnerability scanning, application security testing and so on are exposed programmatically, the
integration and automation of these security controls are enabled throughout the DevOps life cycle
in automated toolchains. Information security sets the policies, which can then be applied
programmatically based on the type of workload. However, many security vendors are behind in
their ability to be driven programmatically, and require a trained person to go to their console, or
only a portion of their security functionality is exposed via APIs.
Link to existing IAM systems for identities and permissions such as Active Directory or
Lightweight Directory Access Protocol (LDAP). Require tooling vendors to integrate with these
systems for access control. Security policies are enforced in the tools, and all tooling access
and activities are monitored.
Define and assign different required roles for development versus production. Ideally, no person
directly touches the live environment, except via scripts and APIs.
Mandate that the product team is responsible and auditable for its product changes on a "trust
and verify" basis. Verification can be achieved by use of audit logs and configuration
repositories, such as Git.
Train developers in secure coding best practices and how to write resilient code that sanitizes
input and blocks common attack patterns, such as buffer overflows, SQL injection and cross-
site scripting.
Develop a simple threat-and-risk model assessment tool and implement it as a part of the
planning and design process. Base the level of threat modeling on the risk of the application.
Applications handling sensitive data or directly accessing the internet should require deeper
threat modeling and collaboratively involve information security.
Plan to mask, de-identify or synthesize data used in development for testing. Do not use
sensitive production data.
One best practice is to train developers to adopt a lightweight "spell checker" type scanning tool for
quick checks of security within the developer's integrated development environment (IDE) as they
develop code. Automated scanning and security test software should be part of the continuous
integration test toolchain. Use interactive application security testing (IAST; see "Critical Capabilities
for Application Security Testing") if the application development is being performed on a platform
that supports instrumentation such as Java, .NET and PHP. IAST is well-suited for the highly
automated testing needed for DevSecOps. If IAST isn't possible, use application security testing
(AST) tools and services that can be fully automated without requiring a security professional to be
involved. For example, DAST tools can be driven automatically using Selenium scripts, or SAST
scans can be triggered automatically from scripting tools. AST-testing-as-a-service providers are a
possibility, but only if the SLA of the AST services provider meets enterprise SLA requirements (for
example, a guaranteed 24-hour turnaround).
Evaluate and adopt IAST for applications that support it, and favor solutions using self-inducers
for automated testing.
Plan to fully automate any traditional static or dynamic tools or services that are used. For
example, DevOps toolchain scripting tools can invoke automated testing. Do not make
developers leave their native environment and toolchains.
If SAST and DAST solutions are used, require vendors to support differential scans that test only
the modified code and downstream-impacted modules.
Acknowledge and accept that having zero vulnerabilities isn't possible. Reduce false positives
(albeit with a risk of higher false negatives) and trim the output of AST tools and services to
focus developers first on the highest severity, highest confidence vulnerabilities. Favor AST
scanning tools and services that use machine learning and collective intelligence to trim results
to only the highest confidence results.
By policy, don't allow custom code with known critical vulnerabilities to enter production.
Accept that vulnerabilities that represent lower levels of risk may or may not be addressed in
future iterations. Approaches that identify and accept manageable risk are necessary.
Work with DevOps managers to measure and motivate development teams to produce code
with fewer vulnerabilities. Make security metrics a part of code quality metrics and hold
development teams accountable.
Prioritize OSS software module identification and vulnerability scanning in development in 2016
3
and 2017.
Scan all applications, system images, virtual machines and containers in development for
unknown, embedded or vulnerable OSS components in the operating system, application
platform and in the application itself.
4
Implement an "OSS firewall" to proactively prevent developers from downloading known
vulnerable code from Maven, GitHub and other OSS code repositories by policy.
Architect DevOps processes to automatically scan the contents of all system images, including
the base OS, application platform and all containers for known vulnerabilities and configuration
issues as part of the continuous integration process. By policy, don't allow systems to leave
development with known critical vulnerabilities.
Require developers to remove unnecessary modules and harden all systems to industry
standard best practices.
Ensure that DevOps teams have implemented good version control practices and tools to
maintain clear accountability and traceability for all the application software that is deployed
into the live environment.
Extend the scope of the version control and automated deployment tools to the configuration,
infrastructure setup and monitoring configuration.
Use automation scripts to deploy to the staging environment for final tests (may be an
automated test in advanced DevOps environments).
Scan scripts for errors and embedded risk, such as embedded credentials, encryption keys, API
keys and so on, that represent significant and avoidable risk.
Implement system integrity measurement on systems as they are booted, including hardware-
based root of trust measurements of the basic input/output system, bootloader, hypervisor and
OS on systems you own.
Store VMs at rest encrypted and hashed, if VMs are used in the DevSecOps workflow. Verify
against tampering at boot.
Use a container management system (if containers are used) that supports hashing or other
techniques to measure and verify system integrity when loaded.
Bottom Line
DevSecOps is an objective where security checks and controls are applied automatically and
transparently throughout the development and delivery of IT-enabled services in rapid-development
DevOps environments. Simply layering on standard security tools and processes won't work.
Secure service delivery starts in development, and the most effective DevSecOps programs start at
the earliest points in the development process and follow the workload throughout its life cycle, as
shown in Figure 3. Even if you aren't actively using DevOps, the best practices identified in this
research note will apply to any security architect looking to accelerate the development and delivery
of IT-enabled services using agile development, test-driven development or other methodologies.
If you haven't already, get involved in DevOps initiatives and start pressuring all security vendors for
full programmability of their services for automatability. For 2016, begin the immediate scanning of
services in development for vulnerabilities, and make OSS software module identification,
configuration and vulnerability scanning a priority in 2016. Make custom code scanning a priority in
2017. Longer term, automate security controls wherever possible to reduce the chance for
misconfiguration, mistakes and mismanagement.
Above all, successful DevSecOps initiatives must remain true to the original DevOps philosophy:
teamwork and transparency, and continual improvement through continual learning.
"Embrace DevOps Product Teams to Turbocharge Your I&O Organization and Control Costs"
"Leveraging the DevOps Toolchain to Automate and Secure Virtualization, Private Cloud and Public
Cloud Environments"
Evidence
1 Gartner Enterprise DevOps Survey Study: This research was conducted via an online survey from
9 May to 13 May 2016 among Gartner Research Circle Members a Gartner-managed panel
composed of IT and business leaders.
Objectives: To learn how organizations are adopting DevOps as a means to accelerate enablement;
to go faster while improving quality; additionally, to inform on topics, including starting a DevOps
approach, pitfalls to avoid, scaling efforts, integrating information security, pursuing this in a
regulated environment and quantifying benefits.
In all, 252 IT and business leaders participated, with 95 members qualified by indicating they are
already using DevOps.
2"2016 Report on the State of the Software Supply Chain," Sonatype; F. Rashid, "71 Percent of
Applications Use Components With Severe or Critical Security Flaws: Report," Security Week, 30
April 2013.
3 Vendors offering OSS scanning capabilities: Black Duck; HPE (partners with Sonatype); IBM
(partners with Black Duck); OpenLogic; Palamida; Sonatype; Synopsys (acquired Protecode);
Veracode
The practices described in this document are best evangelized across the product teams by having
a security community that encourages standards and common practices across all the DevOps
product teams. How this community aligns within the larger organization is described in "Embrace
DevOps Product Teams to Turbocharge Your I&O Organization and Control Costs."
The Open Web Application Security Project offers threat-risk-modeling guidance. In addition,
several third-party threat modeling tools are available. Vendors offering threat-modeling tools
include:
Corporate Headquarters
56 Top Gallant Road
Stamford, CT 06902-7700
USA
+1 203 964 0096
Regional Headquarters
AUSTRALIA
BRAZIL
JAPAN
UNITED KINGDOM
2016 Gartner, Inc. and/or its affiliates. All rights reserved. Gartner is a registered trademark of Gartner, Inc. or its affiliates. This
publication may not be reproduced or distributed in any form without Gartners prior written permission. If you are authorized to access
this publication, your use of it is subject to the Usage Guidelines for Gartner Services posted on gartner.com. The information contained
in this publication has been obtained from sources believed to be reliable. Gartner disclaims all warranties as to the accuracy,
completeness or adequacy of such information and shall have no liability for errors, omissions or inadequacies in such information. This
publication consists of the opinions of Gartners research organization and should not be construed as statements of fact. The opinions
expressed herein are subject to change without notice. Although Gartner research may include a discussion of related legal issues,
Gartner does not provide legal advice or services and its research should not be construed or used as such. Gartner is a public company,
and its shareholders may include firms and funds that have financial interests in entities covered in Gartner research. Gartners Board of
Directors may include senior managers of these firms or funds. Gartner research is produced independently by its research organization
without input or influence from these firms, funds or their managers. For further information on the independence and integrity of Gartner
research, see Guiding Principles on Independence and Objectivity.