Safeguard Docs

Application Security Testing (SAST & DAST)

Find vulnerabilities in your source code (SAST) and running applications (DAST) with Safeguard's first-party, tenant-isolated application security testing.

Application Security Testing (SAST & DAST)

Safeguard includes first-party application security testing: static analysis of your source code (SAST) and dynamic testing of your running applications (DAST), alongside the SCA, secrets, container, and IaC scanning you already use. Findings from every engine share one unified model, so a runtime issue can be correlated to the exact source-code sink that caused it.

Note: SAST and DAST are generally available. The platform wiring, the unified findings model, and the DAST safety controls are in place. This page documents the capability and how to configure it.

How it fits the platform

Application security testing runs through the same path as your other scans:

Connect a repository or target → scan (in CI, in your pipeline, or on a local/on-prem runner) → findings in the app and API

You add a Safeguard SAST or Safeguard DAST integration the same way you add a repository or registry. Scans run in your pipeline or on a local/on-prem runner, and findings land in your tenant-scoped findings view - queryable in the app and through the API.

SAST - static analysis

SAST analyzes source code without running it, tracing untrusted input from a source (a request parameter, CLI arg, file read) to a dangerous sink (a SQL query, command exec, file path) across functions and files.

AspectDetail
InputsA connected repository or a local directory (no build required)
LanguagesJavaScript/TypeScript, Python, Java
What you getA finding with the source→sink dataflow trace, CWE/OWASP mapping, severity, and a code location
Where it runsPipeline, or a local runner so source never leaves your perimeter

Each SAST finding carries a dataflow trace - the ordered hops from source to sink - so a developer can see exactly why it was flagged, not just where.

DAST - dynamic analysis

DAST tests a running application for runtime issues (missing security headers, injection classes, misconfigurations) by sending safe, non-destructive requests and observing responses.

DAST is a defensive, authorized-testing capability. It is not a general offensive tool, and the following controls are enforced in code, not as UI conveniences:

  • Verified targets only. A target is unverified until you prove ownership (DNS TXT record, uploaded file, meta tag, or verified email domain). Active checks cannot run against an unverified target.
  • Strict scope. Every outbound request is checked against an allow-listed host/path scope. Out-of-scope requests are blocked and logged.
  • Rate limits & budgets. Conservative per-target limits (requests/second, requests/node, max duration) are mandatory and configurable.
  • Non-destructive by default. Detection uses benign markers and bounded, time-based or out-of-band inference - never data-destroying or denial-of-service payloads.
  • Safety modes. passive, safe_active, and authenticated_safe_active for normal use. A heavier lab_aggressive mode is off by default, never auto-selected, and requires elevated authorization plus a target flagged owned-and-isolated.
  • Full audit trail. Every DAST request and finding change is recorded with actor, tenant, and timestamp.

What a DAST scan reports

  • Error disclosure. Stack traces, internal paths, SQL text and database-library errors (Mongoose, Sequelize, Hibernate, Django ORM, SQLAlchemy, Doctrine, Eloquent, Prisma, Entity Framework) are reported when the scan's own probes, a malformed request body or a form submitted with its own values provoke them. Each row carries a control request and steps that replay as written.
  • Configuration files. php.ini, .user.ini, .htaccess, .htpasswd, phpinfo pages, .env and .git files are checked at the root and under every directory the crawl reaches, and confirmed by the file's own content.
  • Client-side and response policy. Cross-origin policies that trust any origin on a request the page sends, per-page framing policy (clickjacking), meta refresh redirects, HttpOnly cookie values written back into a page or a loaded script, and scripts loaded from the URL fragment.
  • Cross-site scripting. Reflected XSS is also tested through the GET form of a POST field, upload file names and the URL path, and is confirmed in a real browser where the reflection is unencoded.
  • Proof behind a sign-in. The re-test that marks a finding Validated is sent with the same session the scan used. If you give the scan login field names, those names are kept for the retry with a different identifier.
  • Not tested is not passed. A check whose every request got no answer (the application stopped responding) is recorded as not tested with the first error. Requests to the application's own sign-in address are sent without the scan's session.
  • One finding per parameter. Two vulnerable parameters of one form are two findings.

API Security - Postman collections

The Safeguard API Security integration tests an API from a live URL, an OpenAPI or Swagger file, a pasted curl command, or a Postman collection. A Postman collection already says where each of its requests goes, so it needs no base URL: Safeguard reads the collection and tests every host its requests reach.

What to upload

  • The collection, exported from Postman as Collection v2.1 (v2.0 also works), as .json.
  • Its environment, if the collection uses one. If your URLs use variables such as {{baseUrl}} that are set in a Postman environment, export that environment and upload it with the collection. Its values are merged into the collection before upload and take priority over the collection's own values, the same way Postman applies an active environment.

How requests are read

  • Variables come from the collection's Variables tab and the uploaded environment. Values that refer to other variables are followed, and Postman's built-in dynamic variables such as {{$guid}} and {{$timestamp}} are filled in.
  • Headers, request bodies (raw JSON, URL-encoded and text form fields, GraphQL) and auth are sent as the collection defines them. Bearer token, API key (header or query), basic auth and an OAuth 2.0 access token already saved in the collection are supported. Auth is inherited from folders and from the collection, as in Postman.
  • Scripts are not run. If a pre-request or test script sets a variable (usually a login request that stores a token), that value does not exist during a scan. The sheet warns you when this applies; put the value in the environment instead, ideally a token for a test account.
  • A request whose host comes from a variable nobody defined cannot be placed, so it is skipped and listed in the results. A path or query value nobody defined (for example {{orderId}}) is filled with a placeholder, and the request is still tested.

Which hosts are tested

Before you start the scan, the sheet lists every host the collection calls. You choose which ones to test:

  • Your own hosts are ticked by default.
  • Well-known third-party services (for example payment, identity, email and messaging providers) are not ticked by default. Tick one only if you are authorised to test it.
  • Local and private addresses (localhost, private IP ranges, .local and .internal names) cannot be reached from Safeguard's scanner and are not tested. Scan those with a runner inside your network.
  • One scan tests at most 10 hosts, two at a time, in order of how many requests they have. The hosts share the scan's time, so every host gets a fair share and the results of each host are kept even if another host is slow or fails.

Reading the results

The project page shows a Hosts tested panel: each host, whether it was tested in full, partly tested, did not answer, or was not tested and why, plus the requests that could not be sent. A host that was not tested has no findings because it was not looked at, not because it is clean. The same information appears as two informational findings: Some hosts in the uploaded collection were not fully tested and Some requests in the uploaded collection were not tested.

Credentials

Tokens, API keys and passwords in the collection or its environment are used to sign the scan's requests to the hosts you tick, and are stored with the uploaded file. They are removed from findings, the endpoint inventory and reports. Use a test account's credentials where you can.

Updating a collection

Open the integration and choose Update, then upload the new version of the collection (and environment). The new file replaces the old one, and a scan starts when you save. Leave the upload empty to change only the name or scan mode.

Target verification & safety

Before a DAST scan can touch a target you must verify ownership. Choose a method:

MethodHow
DNS TXTAdd a provided TXT record to the target's domain
File uploadHost a provided token file at a well-known path
Meta tagAdd a provided <meta> tag to the site
Email domainVerify via an address on the target's domain

Until verification succeeds, the target stays unverified and only passive, non-intrusive checks (if any) are permitted.

Unified findings & correlation

SAST, DAST, and SCA findings share one model with correlation keys. When a DAST-confirmed runtime issue maps to the SAST source-code sink that produced it, the two are linked and prioritized together - a confirmed, reachable, exploitable finding rises to the top. Every finding is tenant/org-scoped (X-Tenant-Id, X-Org-Id, X-Descendant-Org-Ids) end to end.

Configuration

Add an AppSec integration from the Integrations page:

  • Safeguard SAST - select a repository or point at a source directory.
  • Safeguard DAST - register a target, verify ownership, set the in-scope hosts/paths and safety mode.

Scans then trigger through the standard integration → pipeline → CLI flow, and results appear in your findings views.

CLI

Run scans locally or in CI with the Safeguard CLI:

# Static analysis of a source directory
safeguard appsec sast --dir ./src --tenant-id <tenant> --product-id <product>

# Dynamic analysis of a verified, in-scope target
safeguard appsec dast \
  --target-id <target> \
  --base-url https://app.example.com \
  --scope-host app.example.com \
  --tenant-id <tenant>

The DAST command refuses to run against an unverified or out-of-scope target - the safety kernel enforces this regardless of flags.

Reports

Findings appear in the app's AppSec views with severity, rule, CWE, location, and (for SAST) the dataflow trace. There is no CLI command for listing them yet.

On this page