
Security News
Axios Supply Chain Attack Reaches OpenAI macOS Signing Pipeline, Forces Certificate Rotation
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.
AI-safe .env files: Schemas for agents, Secrets for humans.
varlock scan + git hooksSee https://varlock.dev for full docs and examples.
A sample .env.schema:
# @currentEnv=$APP_ENV
# ---
# @type=enum(development, staging, production)
APP_ENV=development #sets default value
# API port
# @type=port @example=3000
API_PORT=
# API url including expansion of another env var
# @required @type=url
API_URL=localhost:${API_PORT}
# API key with validation, securely fetched from 1Password
# @required @sensitive @type=string(startsWith=sk-)
OPENAI_API_KEY=exec('op read "op://api-prod/openai/api-key"')
# Non-secret value, included directly
# @type=url
SOME_SERVICE_API_URL=https://api.someservice.com
You can get started with varlock by installing the CLI:
# Install as a dependency in a js project
npm install varlock
# OR as standalone CLI via homebrew
brew install dmno-dev/tap/varlock
# OR via cURL
curl -sSfL https://varlock.dev/install.sh | sh -s
See the full installation docs.
Validate your .env.schema with:
varlock load
If you need to pass resolved env vars into another process, you can run:
varlock run -- node script.js
Or you can integrate more deeply with one of our integrations to get log redaction and leak prevention.
Your .env.schema gives AI agents full context on your config — variable names, types, validation rules, descriptions — without ever exposing secret values. Combined with varlock scan to catch leaked secrets in AI-generated code, varlock is purpose-built for the AI era. Learn more in the AI-safe config guide.
Varlock is built on top of @env-spec, a new DSL for attaching a schema and additional functionality to .env files using JSDoc style comments. The @env-spec package contains a parser and info about the spec itself.
FAQs
AI-safe .env files: Schemas for agents, Secrets for humans.
The npm package varlock receives a total of 30,302 weekly downloads. As such, varlock popularity was classified as popular.
We found that varlock demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OpenAI rotated macOS signing certificates after a malicious Axios package reached its CI pipeline in a broader software supply chain attack.

Security News
Open source is under attack because of how much value it creates. It has been the foundation of every major software innovation for the last three decades. This is not the time to walk away from it.

Security News
Socket CEO Feross Aboukhadijeh breaks down how North Korea hijacked Axios and what it means for the future of software supply chain security.