Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Crafting Secure Software
Crafting Secure Software

Crafting Secure Software: An engineering leader's guide to security by design

Arrow left icon
Profile Icon Greg Bulmash Profile Icon Thomas Segura
Arrow right icon
Can$12.99 Can$60.99
Full star icon Full star icon Full star icon Full star icon Full star icon 5 (1 Ratings)
eBook Sep 2024 156 pages 1st Edition
eBook
Can$12.99 Can$60.99
Paperback
Can$75.99
Subscription
Free Trial
Arrow left icon
Profile Icon Greg Bulmash Profile Icon Thomas Segura
Arrow right icon
Can$12.99 Can$60.99
Full star icon Full star icon Full star icon Full star icon Full star icon 5 (1 Ratings)
eBook Sep 2024 156 pages 1st Edition
eBook
Can$12.99 Can$60.99
Paperback
Can$75.99
Subscription
Free Trial
eBook
Can$12.99 Can$60.99
Paperback
Can$75.99
Subscription
Free Trial

What do you get with eBook?

Product feature icon Instant access to your Digital eBook purchase
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Product feature icon AI Assistant (beta) to help accelerate your learning
OR
Modal Close icon
Payment Processing...
tick Completed

Billing Address

Table of content icon View table of contents Preview book icon Preview Book

Crafting Secure Software

The Software Supply Chain and the SDLC

Software development and manufacturing have an unsurprising trend in common. In modern manufacturing, companies rarely make all their parts in-house. The automotive industry, for example, relies on a broad and complex network of vendors. This also means a defective vendor component can disrupt the entire supply chain. Consider how one vendor’s faulty airbag inflators caused the largest recall in American automotive history, impacting over half a dozen automakers who used those parts and tens of millions of vehicles. Modern software development faces similar issues.

In modern software development, too, it is increasingly rare for companies to create everything completely in-house. Like automakers, software companies rely on a range of third-party building blocks. Taking the supply chain management concept from manufacturing, each of these blocks becomes part of their SSC.

In this chapter, we will cover the following topics:

    ...

What is the software supply chain?

An SSC is every third-party element used by a software manufacturer to create and deliver their product. This includes, but is not limited to, the following:

  • The operating system(s) and hardware: These include workstations, servers, storage, network switches and routers, Windows/Mac/Linux embedded systems, and infrastructure as a service (IaaS).
  • Software for creating and building software: This includes editors, languages, compilers, plugins, libraries/frameworks, task runners, and build systems.
  • Software providing services to software: In this category, you have databases, APIs, software as a service (SaaS), platform as a service (PaaS), and backend as a service (BaaS).
  • Tools used for tracking and enabling work: These are tools that support version control, ticketing, messaging, and collaboration.
  • Tools for delivering software: These include file transfer, server software, containers, container orchestration, and monitoring...

Common supply chain attack vectors and defenses

In the complex landscape of modern software development, security threats are ever-evolving. As software systems increasingly rely on third-party components, external updates, and extensive code repositories, the potential attack surface grows, presenting significant challenges to maintain security and integrity. This section delves into several critical security scenarios and outlines proactive defenses to mitigate these risks.

Compromise of third-party components

Third-party components, such as libraries, frameworks, and packages can become dangerous if a threat actor is able to do one of these three things:

  • Inject malicious code into the one you use
  • Use a deceptive variation on that third-party component’s name, so you end up using a component the threat actor controls instead of the one you usually use
  • Use a known vulnerability in a component that has not been patched (or you have not updated to the...

Threat modeling

There are multiple approaches and tools in threat modeling, but at its core, there are three main areas: mapping data flows, analyzing attack surfaces, and assessing the impacts of failure.

The Open Web Application Security Project (OWASP) has a three-step threat-modeling process:3

  1. Decompose the application.
  2. Determine and rank threats.
  3. Determine countermeasures and mitigation.

Decompose the application

This starts with understanding the use cases for the application. For example, with a game, one use case might be to play the game, while another might be to top up tokens from the in-app store.

Then, identify the entry points where an attacker could interact with the application, resources, and assets that would be of interest to an attacker, and the trust levels and access rights the application grants to external entities such as users, tech support, moderators...

Risk assessment

While threat modeling is a technical activity that is more objective in nature, using risk assessment is more subjective and tied to your priorities, needs, and sensitivities.

Integrating risk assessment to rank the threats

Risk assessment takes two main vectors into account—likelihood and damage:

  • Likelihood: How likely is the threat to manifest? This takes into account how prized the result will be to an attacker and how easily they could get that result given your current defenses.
  • Damage: What would be the actual impact if an attacker successfully manifested the threat? Would it create additional threats? Would it expose anything of value to theft or discovery?

An example of a common threat is an automated “bot” filling out and submitting a form to register as a website user.

For example, a decade ago, it was easy for people to buy tens of thousands of followers on social media sites to make themselves look influential...

Real-world SSC attacks

Most of the SSC discussion to this point has been conceptual. The next section will highlight some examples of attacks on the SSC to illustrate how they can happen and the damage they can cause.

PHP: No harm, but foul

Based on a multi-year tracking survey by W3Techs, the PHP programming language was the backend language for over 80% of websites from 2014 to 2018, a figure that was still above 75%, as of February 2024.6

As mentioned in Chapter 1, Git is a protocol and system for source code management and version control. GitHub neither invented it nor owns it, but they are the most prominent commercial host of it for developers around the world.

PHP is an open source project hosted on its own Git server. In 2021, the server was breached and two backdoors were not only inserted in the source code for the programming language, but they were committed under the...

Summary

It’s not just our world that’s interconnected; our software is interconnected in ways few outside the industry can really grasp. Open source is not limited to big monoliths such as the WebKit browser engine, Linux, and the Apache web server. It contains packages that are dependencies for your dependencies, such as Log4j and left-pad.

Supply chain attacks can poison or infiltrate dependencies, browser and IDE plugins, source code management, build systems, testing tools, monitoring tools, and more. Attackers are opportunistic and find entry through probing, testing, phishing, and poisoning, to name a few.

This is why the SSC is something to consider at every stage of the SDLC, from gathering requirements to deployment and monitoring. Now that you understand the importance of the SSC, you’ll explore ways to secure it further in this book.

The next chapter will go deeper into methods of attacking and protecting one of the foundational elements of...

Left arrow icon Right arrow icon

Key benefits

  • Develop a strong security posture by grasping key attack vectors in the SDLC
  • Implement industry-leading best practices to protect software from evolving threats
  • Utilize legislative and regulatory landscapes to mitigate compliance-related costs

Description

Drawing from GitGuardian's extensive experience in securing millions of lines of code for organizations worldwide, Crafting Secure Software takes you on an exhaustive journey through the complex world of software security and prepares you to face current and emerging security challenges confidently. Authored by security experts, this book provides unique insights into the software development lifecycle (SDLC) and delivers actionable advice to help you mitigate and prevent risks. From securing code-writing tools and secrets to ensuring the integrity of the source code and delivery pipelines, you’ll get a good grasp on the threat landscape, uncover best practices for protecting your software, and craft recommendations for future-proofing against upcoming security regulations and legislation. By the end of this book, you’ll have gained a clear vision of the improvements needed in your security posture, along with concrete steps to implement them, empowering you to make informed decisions and take decisive action in safeguarding your software assets.

Who is this book for?

This book is an essential read for security and IT leaders navigating the complexities of modern software development. The book is also useful for chief security officers (CSOs), chief information security officers (CISOs), security architects, DevOps professionals, and IT decision makers. A basic understanding of software engineering, version control, and build and delivery mechanisms is needed. This guide will empower you to comprehend and mitigate threats in today's dynamic software factories, regardless of your technical depth.

What you will learn

  • Get to grips with security trends and GitGuardian's role in modern software
  • Analyze major security breaches and their impact on the industry
  • Develop a threat model tailored to your business and risk appetite
  • Implement security measures across your entire SDLC
  • Secure secrets within codebases, configurations, and artifacts
  • Design and maintain secure build pipelines and deployment setups
  • Navigate security compliance, including current and future laws
  • Prepare for future security with AI-generated code integration

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Sep 12, 2024
Length: 156 pages
Edition : 1st
Language : English
ISBN-13 : 9781835885079
Vendor :
GitGuardian
Category :
Tools :

What do you get with eBook?

Product feature icon Instant access to your Digital eBook purchase
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Product feature icon AI Assistant (beta) to help accelerate your learning
OR
Modal Close icon
Payment Processing...
tick Completed

Billing Address

Product Details

Publication date : Sep 12, 2024
Length: 156 pages
Edition : 1st
Language : English
ISBN-13 : 9781835885079
Vendor :
GitGuardian
Category :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
$19.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
$199.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just Can$6 each
Feature tick icon Exclusive print discounts
$279.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just Can$6 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total Can$ 203.97
Crafting Secure Software
Can$75.99
Data Engineering Best Practices
Can$63.99
In-Memory Analytics with Apache Arrow
Can$63.99
Total Can$ 203.97 Stars icon
Banner background image

Table of Contents

9 Chapters
Chapter 1: Introduction to the Security Landscape Chevron down icon Chevron up icon
Chapter 2: The Software Supply Chain and the SDLC Chevron down icon Chevron up icon
Chapter 3: Securing Your Code-Writing Tools Chevron down icon Chevron up icon
Chapter 4: Securing Your Secrets Chevron down icon Chevron up icon
Chapter 5: Securing Your Source Code Chevron down icon Chevron up icon
Chapter 6: Securing Your Delivery Chevron down icon Chevron up icon
Chapter 7: Security Compliance and Certification Chevron down icon Chevron up icon
Chapter 8: Best Practices to Drive Security Buy-In Chevron down icon Chevron up icon
Other Books You May Enjoy Chevron down icon Chevron up icon

Customer reviews

Rating distribution
Full star icon Full star icon Full star icon Full star icon Full star icon 5
(1 Ratings)
5 star 100%
4 star 0%
3 star 0%
2 star 0%
1 star 0%
Zardus Sep 22, 2024
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Decent overview of the security considerations of a dev-project.
Subscriber review Packt
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

How do I buy and download an eBook? Chevron down icon Chevron up icon

Where there is an eBook version of a title available, you can buy it from the book details for that title. Add either the standalone eBook or the eBook and print book bundle to your shopping cart. Your eBook will show in your cart as a product on its own. After completing checkout and payment in the normal way, you will receive your receipt on the screen containing a link to a personalised PDF download file. This link will remain active for 30 days. You can download backup copies of the file by logging in to your account at any time.

If you already have Adobe reader installed, then clicking on the link will download and open the PDF file directly. If you don't, then save the PDF file on your machine and download the Reader to view it.

Please Note: Packt eBooks are non-returnable and non-refundable.

Packt eBook and Licensing When you buy an eBook from Packt Publishing, completing your purchase means you accept the terms of our licence agreement. Please read the full text of the agreement. In it we have tried to balance the need for the ebook to be usable for you the reader with our needs to protect the rights of us as Publishers and of our authors. In summary, the agreement says:

  • You may make copies of your eBook for your own use onto any machine
  • You may not pass copies of the eBook on to anyone else
How can I make a purchase on your website? Chevron down icon Chevron up icon

If you want to purchase a video course, eBook or Bundle (Print+eBook) please follow below steps:

  1. Register on our website using your email address and the password.
  2. Search for the title by name or ISBN using the search option.
  3. Select the title you want to purchase.
  4. Choose the format you wish to purchase the title in; if you order the Print Book, you get a free eBook copy of the same title. 
  5. Proceed with the checkout process (payment to be made using Credit Card, Debit Cart, or PayPal)
Where can I access support around an eBook? Chevron down icon Chevron up icon
  • If you experience a problem with using or installing Adobe Reader, the contact Adobe directly.
  • To view the errata for the book, see www.packtpub.com/support and view the pages for the title you have.
  • To view your account details or to download a new copy of the book go to www.packtpub.com/account
  • To contact us directly if a problem is not resolved, use www.packtpub.com/contact-us
What eBook formats do Packt support? Chevron down icon Chevron up icon

Our eBooks are currently available in a variety of formats such as PDF and ePubs. In the future, this may well change with trends and development in technology, but please note that our PDFs are not Adobe eBook Reader format, which has greater restrictions on security.

You will need to use Adobe Reader v9 or later in order to read Packt's PDF eBooks.

What are the benefits of eBooks? Chevron down icon Chevron up icon
  • You can get the information you need immediately
  • You can easily take them with you on a laptop
  • You can download them an unlimited number of times
  • You can print them out
  • They are copy-paste enabled
  • They are searchable
  • There is no password protection
  • They are lower price than print
  • They save resources and space
What is an eBook? Chevron down icon Chevron up icon

Packt eBooks are a complete electronic version of the print edition, available in PDF and ePub formats. Every piece of content down to the page numbering is the same. Because we save the costs of printing and shipping the book to you, we are able to offer eBooks at a lower cost than print editions.

When you have purchased an eBook, simply login to your account and click on the link in Your Download Area. We recommend you saving the file to your hard drive before opening it.

For optimal viewing of our eBooks, we recommend you download and install the free Adobe Reader version 9.