Skip to main content

Windows Supply Chain Scanner Policy

Install and configure swif-scan on managed Windows devices to find exposed credentials, malicious packages, and vulnerable packages.

Overview

The Windows Supply Chain Scanner Policy installs swif-scan, Swif's supply chain scanner, on managed Windows devices. swif-scan looks for:

  • Exposed credentials: API keys, tokens, and private keys left in files, such as an AWS access key in a .env file. It can also check with the provider whether a key still works.

  • Malicious packages: installed package versions that threat feeds list as malicious.

  • Vulnerable packages: installed packages with known vulnerabilities (CVEs).

The Swif agent installs, runs, updates, and removes swif-scan, and reports what it finds to Swif. swif-scan limits its own CPU use, so devices stay usable during a scan.

Important: The full credential is never sent to Swif. When swif-scan finds a credential, it reports the type of key, where it was found, a fingerprint, the key's length, and at most its first 8 characters. The full key never leaves the device. If you turn on credential verification, the key is sent only to its own provider, for the check.

Swif has a Supply Chain Scanner policy for each platform: Apple, Windows, and Linux. You can set up all three from Security > Supply Chain Attack. See Set up from the Supply Chain Attack page.


Requirements

Requirement

Details

Platform

Windows 10 or later

Device ownership

Company-owned and BYOD

Swif agent

Installed and running

Network

HTTPS (port 443) access to the hosts in Network requirements below


How it works

  1. You assign the policy to your Windows devices.

  2. The Swif agent installs swif-scan.

  3. The agent runs scans in the background.

  4. The agent collects the results, and sends them to Swif.

Removing the policy removes swif-scan and its data from the device.


Settings reference

The settings, defaults, and ranges are the same as the Apple Supply Chain Scanner Policy.

Credentials

Setting

What it does

Default

Range

Scan for Credentials

Looks for API keys, tokens, and private keys in files on the device

On

—

Largest File to Read (MB)

swif-scan skips files larger than this, and reports them as not checked, not as clean. 0 reads files of any size. Shown when Scan for Credentials is on.

16

0–512

Verify Credentials with Their Provider

Asks each key's provider whether the key still works, so you can tell a live key from a revoked one. The key is kept in memory only for the request.

On

—

Providers Not to Ask

Providers swif-scan never contacts, for example for contractual reasons. Their keys are reported as unverified. Shown when verification is on.

Empty

Letters, digits, ., -, and _

Verification Timeout (seconds)

How long swif-scan waits for one provider's answer. A check that times out is reported as failed, not as invalid. Shown when verification is on.

10

1–60

About verification

  • Provider audit logs: the checks appear in each provider's audit logs, for example in AWS.

  • Proxies: checks may fail behind a proxy that blocks them.

  • How Providers Not to Ask matches: an entry such as aws or github covers every detector whose name starts with it. google, amazon, microsoft, hashicorp, vault, 1password, xai, and crates.io also cover their related detectors.

Packages

Setting

What it does

Default

Check for Malicious Packages

Matches installed packages against known malicious packages from OSV, Aikido, Datadog, and VSX Sentry. Covers npm, PyPI, RubyGems, Go, Maven, and more, plus VS Code extensions.

On

Check for Vulnerable Packages

Also matches installed packages against known vulnerabilities (CVEs)

Off

A malicious package finding means remove the package. Upgrading it isn't enough.

Plan before turning on vulnerability checks. They can report hundreds of findings on one device. Decide how your team will review and prioritize them first.

Where to scan

Setting

What it does

Default

Folders to Scan

The folders swif-scan checks for credentials and project packages, as absolute paths on a local drive, such as C:\Projects. Folders left out are reported as not checked, not as clean.

Empty: every user's profile folder, such as C:\Users\jane

Mask File Paths

Findings show a masked path instead of the full one. See How paths are masked.

Off

Folders to Scan doesn't limit package checks. With package checks on, swif-scan also checks software installed on the device, under Program Files, Program Files (x86), and ProgramData, and global packages. These are checked even if they're outside Folders to Scan.

How paths are masked

File

Reported as

In a profile folder, such as C:\Users\jane\projects\app\.env

~user1/projects/app/.env. Only the account name is replaced. The folders below it are kept.

Anywhere else, such as C:\Projects\app\.env

...\.env. Only the file name is kept.

Masking makes it harder to find the file to fix, especially outside profile folders.

Advisory data

swif-scan downloads advisory data only for the package types it finds on the device. A package type's data is downloaded again only when OSV changes it, but then in full. npm's data (about 220 MB) changes most days, so a device with npm packages can download about 220 MB a day.

Setting

What it does

Default

Range

Advisory Data Mirror

Where swif-scan downloads OSV's advisory data from. Leave empty to download from OSV directly.

Empty

An http or https URL

Disk Budget for Advisory Data (MB)

The disk space swif-scan can use for advisory data. An archive that doesn't fit is refused, and the check it's for is reported as failed.

512

64–8,192

Using a mirror. A mirror must serve OSV's own layout (<url>/ecosystems.txt and <url>/<ecosystem>/all.zip), and must be kept up to date. It doesn't make the download smaller. Malware lists from Aikido, Datadog, and VSX Sentry are still downloaded from their own sites.

Performance

Setting

What it does

Default

Range

CPU Budget (% of one core)

swif-scan pauses as needed to stay under this share of one CPU core. A lower budget makes scans take longer.

15

1–35

Longest Scan (hours)

A scan that runs out of time stops, and is reported as partial. The next scan continues where it left off. A partial scan never marks an earlier finding as resolved.

6

1–12


What's reported

Section

Details

Coverage

Which checks ran, and which the policy turned off

Credentials

The type of key (such as awsaccesskey), the file and line number, a fingerprint, the first characters of the key, the key's length, the verification result, and when it was first and last seen. Never the full key.

Package findings

Whether each package is malicious or vulnerable, its ecosystem (such as npm or PyPI), version, and location, the advisory and CVE IDs, severity, and why it matched

Scan statistics

Duration, folders scanned, files checked, average and peak CPU use, and peak memory

For details of what's reported for each credential, see the Apple Supply Chain Scanner Policy.


Network requirements

swif-scan connects over HTTPS, on port 443, to:

Purpose

Hosts

Installing swif-scan

cdn.swifteam.com (used by the Swif agent)

OSV advisory data

osv-vulnerabilities.storage.googleapis.com, or your mirror's host if Advisory Data Mirror is set

Aikido malware list

malware-list.aikido.dev

Datadog and VSX Sentry malware lists

raw.githubusercontent.com

Credential verification (only when on, and only the provider of a key that was found)

The same provider hosts as the Apple policy. See Apple Supply Chain Scanner Policy.


Before you start

  1. Check your network. Make sure devices can reach the hosts in Network requirements. If you use a proxy, check that it allows these requests.

  2. Decide on credential verification. Verification shows which keys still work, but the checks appear in providers' audit logs. List any providers swif-scan shouldn't contact in Providers Not to Ask.

  3. Plan for findings. Decide who will act on exposed credentials and malicious packages. If you turn on vulnerability checks, plan how to handle a large number of findings.

  4. Consider privacy, especially on BYOD devices. Turn on Mask File Paths if file paths could contain personal or customer names.

  5. Choose a pilot group of devices, such as a few developer laptops.


Create the policy

  1. In Swif, go to Device Management > Policies, then select Create new policy > Configure a Policy.

  2. Select Windows Supply Chain Scanner Policy.

  3. Enter a clear name, such as Supply Chain Scanner – Windows Pilot.

  4. Review the settings. The defaults suit most organizations.

  5. Save the policy.

  6. Assign it to your pilot devices.

Set up from the Supply Chain Attack page

You can also set up the scanner from Security > Supply Chain Attack, where its results appear. Click Configure Policies, then Configure Policy next to Windows Supply Chain Scanner Policy. Swif opens a new Windows policy, already chosen. Continue from step 3 above.

The page reminds you while any platform isn't covered yet. See Apple Supply Chain Scanner Policy.


Example configurations

Example 1: Find exposed credentials and malicious packages (defaults)

Setting

Value

Scan for Credentials

On

Verify Credentials with Their Provider

On

Check for Malicious Packages

On

Check for Vulnerable Packages

Off

The recommended starting point.

Example 2: Developer laptops with vulnerability checks

Setting

Value

Folders to Scan

C:\Projects, C:\src

Check for Malicious Packages

On

Check for Vulnerable Packages

On

Disk Budget for Advisory Data (MB)

2048

Scans shared project folders, as well as checking installed software, and adds vulnerability findings, with more disk space for advisory data.

Example 3: Privacy-focused scanning for BYOD devices

Setting

Value

Verify Credentials with Their Provider

Off

Mask File Paths

On

Doesn't contact providers, and masks the account name in file paths. Installed software is still checked.


Verify the policy

  1. In Swif, open the device, and confirm that the policy shows as applied.

  2. Go to Security > Supply Chain Attack. Once the device has sent its first report, it's listed under Devices, with what was found.


Troubleshooting

Credential checks show as failed

  • The provider didn't answer within Verification Timeout (seconds). A failed check doesn't mean the key is invalid.

  • A proxy may be blocking the requests. Check that devices can reach the providers.

A package check shows as failed

The advisory data didn't fit in Disk Budget for Advisory Data (MB), or couldn't be downloaded. Increase the budget, or check that devices can reach the advisory data sources.

A scan is reported as partial

It ran longer than Longest Scan (hours). The next scan continues where it left off. Raise Longest Scan (hours) or CPU Budget (% of one core) if scans regularly don't finish.

Package findings come from outside Folders to Scan

This is expected. With package checks on, swif-scan also checks software under Program Files, Program Files (x86), and ProgramData, and global packages.

A file shows as not checked

It's larger than Largest File to Read (MB), or it's outside Folders to Scan. Increase the limit, set it to 0 for no limit, or add the folder.


Related resources

Did this answer your question?