Secure development

Protecting application source, dependencies and release provenance

Software provenance: package, network, signature arranged to illustrate protecting application source, dependencies and release provenance.

Protecting application source, dependencies and release provenance connects a security requirement to the behaviour of a real feature. The relevant controls need to remain effective across custom code, integrations and the production configuration. Understanding application source and dependencies and release provenance helps establish which security property the feature needs and where that property is actually enforced.

What does this involve?

A software dependency becomes part of the application's effective behaviour and maintenance commitment. The important inventory is what the release actually contains, including transitive packages, bundled binaries and code that arrives through a build or update process.

No piece of software is developed in a vacuum; regardless of the technologies used to develop it, software is embedded in a Software Supply Chain (SSC). According to NIST, an entity's SSC can be defined as "a collection of steps that create, transform, and assess the quality and policy conformance of software artifacts". From a developer's perspective, these steps span the entire SDLC and are accomplished using a wide range of components and tools. Common examples (by no means exhaustive) of components that are especially relevant from a developer's perspective include:

Each of these components must be secured; a flaw in a single component, such as a vulnerable third-party dependency or misconfigured VCS, can put an entire SSC in jeopardy. Thus, in order to strengthen Software Supply Chain Security (SSCS), developers should possess a general understanding of what the SSC is, common threats against it, and practices and techniques that can be applied to reduce SSC risk.

Why it matters

Consider a realistic failure: a release depends on a mutable package or build artefact whose origin and changes cannot be verified.

A compromised or vulnerable component may run with the application's privileges or receive information the business did not expect to share. Impact depends on reachability, permissions and actual data flows rather than a package name alone.

Implementation guidance should be applied to a real feature and its deployment. Framework defaults, custom handlers and integrated services all influence whether the intended protection remains effective.

How penetration testers check for it

Trace the relevant feature from its entry point to the data or operation it protects, including custom code and alternate paths.

  • Inventory components in real release artefacts.
  • Review provenance, integrity and relevant known weaknesses.
  • Inspect transitive dependencies and unexpected runtime activity.
  • Confirm whether affected code is reachable under realistic conditions.

How to fix it

Use the appropriate maintained mechanisms and verify the result in the actual production configuration.

  • Source code threats. These types of threats focus on violating the integrity of source code which is then built and deployed or potentially consumed by other software projects. Threats in this category include VCS exploits, the introduction of malicious or vulnerable code into a codebase, or building code from an unauthorised branch.
  • Build environment threats. These threats modify a software artifact but without altering the underlying source code or exploiting the build process itself. Examples include build cache poisoning, compromising a privileged account used by the build tool, or publishing software built from an untrusted source.
  • Dependency related threats. Threats that result from the consumption of both direct and transitive software dependencies. The most common threat is using a vulnerable or compromised dependency.
  • Deployment and runtime threats. These threats exploit either the deployment process or runtime environment. Common examples include compromising a privileged CI/CD account, software misconfigurations, and deployment of compromised binaries.
  • Remove unnecessary components and reduce their permissions.
  • Verify remediation in the shipped release and its supporting artefacts.

A vulnerability identifier is a starting point for investigation. Version evidence, affected functionality and deployment conditions determine whether it creates a confirmed application risk.

Recheck the changed behaviour against the original failure conditions and the legitimate user journey. Keep enough evidence to show which release and configuration were verified, and include related entry points that depend on the same security decision.

Read about our methodology or contact pentested.com to discuss secure development and code review.

See your first test report this week.

Book a 30 minute demo. We will verify one of your targets with you and run a test against it, so you can judge the results on your own systems.

Book a demo