
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.
api-token-manager
Advanced tools
A secure, developer-friendly CLI tool and backend service for sharing secrets with colleagues using short-lived, one-time codes.
Keyshare lets you securely share API keys, tokens, and other secrets with teammates without using insecure channels like Slack or email.
How it works:
keyshare init with a secret → gets an 8-character code (e.g., AB12XY9Q)keyshare fetch with the code → secret is written to their .env file# Clone the repository
git clone https://github.com/yourusername/keyshare.git
cd keyshare
# Generate a master key
node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"
# Create .env file for docker-compose
echo "KEYSHARE_MASTER_KEY=<your-generated-key>" > .env
# Start the services
docker compose up -d
# Install CLI globally
cd packages/cli
npm install -g .
# Install dependencies
npm run bootstrap
# Start MongoDB (if not using Docker)
mongod --dbpath /path/to/data
# Configure server
cd packages/server
cp .env.example .env
# Edit .env and set KEYSHARE_MASTER_KEY
# Start server
npm start
# Install CLI (in another terminal)
cd packages/cli
npm link
# Interactive mode
keyshare init
# From file
keyshare init --from-file ./secret.txt
# Custom TTL (5 minutes)
keyshare init --ttl 5
# With QR code
keyshare init --qr
# Custom API URL
keyshare init --api-url https://keyshare.yourcompany.com
Output:
✓ Share created successfully!
Share code (give this to your colleague):
AB12XY9Q
Expires: 10/4/2025, 9:23:32 AM
TTL: 10 minutes
✓ Code copied to clipboard
⚠ Warning: Share this code securely (encrypted chat, password manager, etc.)
The code can only be used once and will expire automatically.
# Interactive mode
keyshare fetch
# With code
keyshare fetch --code AB12XY9Q
# Custom env file
keyshare fetch --env-file .env.local
# Custom variable name
keyshare fetch --var-name DATABASE_URL
# Just display (don't write to file)
keyshare fetch --no-write
Output:
✓ Share retrieved successfully!
✓ Secret written to /path/to/project/.env
Variable: API_KEY
Backup created
Permissions: 600 (owner read/write only)
⚠ Remember to add .env to your .gitignore file!
keyshare revoke --code AB12XY9Q
keyshare/
├── packages/
│ ├── server/ # Express API + MongoDB
│ │ ├── src/
│ │ │ ├── controllers/
│ │ │ ├── models/
│ │ │ ├── routes/
│ │ │ ├── services/
│ │ │ └── middlewares/
│ │ └── test/
│ └── cli/ # Commander-based CLI
│ ├── src/
│ └── test/
├── docker-compose.yml
└── .github/workflows/
KEYSHARE_MASTER_KEY (32 bytes)/api/sharesCreate a new share.
Request:
{
"secret": "my-api-key-12345",
"ttlMinutes": 10,
"meta": {
"project": "my-app"
}
}
Response:
{
"shareCode": "AB12XY9Q",
"expiresAt": "2025-10-04T09:33:32.000Z",
"ttlMinutes": 10
}
/api/shares/retrieveRetrieve a share by code.
Request:
{
"shareCode": "AB12XY9Q"
}
Response:
{
"secret": "my-api-key-12345",
"meta": {
"project": "my-app"
}
}
Error Responses:
400 - Invalid input401 - Invalid code404 - Share not found410 - Share expired or already used429 - Too many attempts / rate limited/api/shares/revokeRevoke a share before it's used.
Request:
{
"shareCode": "AB12XY9Q"
}
Response:
{
"message": "Share revoked successfully",
"shareCode": "AB12XY9Q"
}
# Run all tests
npm test
# Run server tests only
npm run test:server
# Run CLI tests only
npm run test:cli
# Watch mode
cd packages/server && npm run test:watch
packages/server/.env)| Variable | Description | Required | Default |
|---|---|---|---|
MONGO_URI | MongoDB connection string | Yes | mongodb://127.0.0.1:27017/keyshare |
KEYSHARE_MASTER_KEY | 32-byte encryption key (64 hex chars) | Yes | - |
KEYSHARE_PORT | Server port | No | 4000 |
KEYSHARE_TTL_MINUTES | Default share TTL | No | 10 |
KEYSHARE_RATE_LIMIT_WINDOW_MS | Rate limit window | No | 60000 |
KEYSHARE_RATE_LIMIT_MAX | Max requests per window | No | 5 |
NODE_ENV | Environment | No | development |
.env or environment)| Variable | Description | Default |
|---|---|---|
KEYSHARE_API_URL | API server URL | http://localhost:4000 |
node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"
⚠️ Important:
# Build and run with Docker Compose
docker compose up -d
# View logs
docker compose logs -f server
# Stop services
docker compose down
# Install dependencies
npm run bootstrap
# Start server in dev mode
npm run dev:server
# Run linting
npm run lint
packages/server/src/packages/cli/src/cd packages/cli
# Update version
npm version patch # or minor, major
# Publish
npm publish
# Users can then install with:
npm install -g keyshare-cli
Protected against:
Not protected against:
Contributions are welcome! Please follow these guidelines:
git checkout -b feature/amazing-feature)npm test)git commit -m 'Add amazing feature')git push origin feature/amazing-feature)This project is licensed under the MIT License - see the LICENSE file for details.
Made with ❤️ for developers who care about security
FAQs
Comprehensive API Token Manager with server, SDK, and dashboard
We found that api-token-manager 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.