With my ongoing homelab build, part of my directive is to ensure that the supply chain for anything deployed is properly managed.
I have added vulnerability managers, a package manager, SBOM tracking, and when custom built software is involved, a CI pipeline that adds a layer of assurance that my infrastructure will be less likely to be hit by something like the Shai-Halud malware in packages.
I have deliberately made choices to use self hosted, open source software and rely as much as I can on my own compute resources.
| Git Repo | Gitea |
| CI Orchestration | Woodpecker CI |
| SBOM | Dependency-Track and Syft |
| Package Vulnerability Tracking | Grype |
| Local Package Repo | Gitea |
Dependencies
All dependencies are first evaluated for existing known issues and compared with the last few versions to help reduce the vulnerabilty footprint. Generally, the build environment does not download the latest build, unless it is at least a few weeks old and/or there’s a security reason why the latest should be used. Once selected, the dependency is pinned by their hash, not just version number.
Syft, Grype, and Dependency-Track are all used to regularly monitor for any drift in the Software Bill of Materials and ensure the versions and components have no published security vulnerabilities. Everything built or deployed has an SBOM, it is re-scanned at least nightly, run against a mirrored, offline copy of the Grype database.
CI
CI builds from offline vendor bundles, using the lockfile’s hash. Each bundle has an offline proof, and negative controls are in place – a build without the specific bundle fails.
New bundles come through a CI issues queue with both an AI review and human review and approval.
CI Runners are throwaway VMs, based on a cloned instance running on an isolated network segment, with only limited routes to needed infrastructure.
Secrets and Permissions
Secrets are stored outside of the CI pipeline and only used by a coordination server. AI tooling never handles secrets directly; AI tools instead have the underlying coordination server read secrets via stdin, to minimize exposure.
Any suspected leaked credential or key is rotated; if an AI tool finds it in a log file, commits it to a repo, creates a command that displays a key, or if the human operator doesn’t handle the secret properly, it is invalidated and rotated as soon as it is found.
Each system is given its own dedicated runner account and reduced life API tokens using least privilege principles. There are a lot of accounts to maintain, but with recent incidents, this is imperative to long term security.
Adversarial Agent Scanning
Everything deployed or custom written using an AI agent gets a periodic scan by an “adversarial agent.” The agent is given a brief to review the code and find security vulnerabilities; my current process uses both Fable and Opus 5.5 in Ultracode mode. In testing, each has found different issues, so the more tooling that can look at this, the better. Future plans include adding a local LLM to scan code on commit and using a different coding model subscription to add another layer.
Final Thoughts
For both infrastructure and software, those that build, deploy, and maintain have to do everything right all the time. A threat actor needs to find the one mistake to get in. Careful steps must be taken to properly layer security, add checkpoints, and keep deep historical data so there’s evidence in case something bad does happen.