Grizzly Sec
Grizzly Sec is a drop-in Express middleware that automatically documents your API, monitors live traffic, detects security anomalies, and helps you secure your endpoints with minimal setup.
Features
- Automatic OpenAPI-style documentation generation based on live traffic
- Real-time detection of suspicious activity and request anomalies
- Centralized logging and traffic monitoring
- Minimal configuration, designed for fast integration into existing Express servers
Installation
npm install grizzly-sec
Quick Start
const express = require('express');
const grizzlySec = require('grizzly-sec');
const app = express();
app.use(grizzlySec({
apiKey: 'your-api-key',
}));
app.get('/api/users/:id', (req, res) => {
res.json({ id: req.params.id, name: 'John Doe' });
});
app.listen(3000, () => {
console.log('Server listening on port 3000');
});
Configuration Options
apiKey | String | Yes | Your API key from Grizzly Sec |
baseUrl | String | No | Override base URL used in tracking (defaults to inferred from request) |
excludedUrls | String[] | No | List of route patterns (glob syntax) to exclude from logging and tracking |
Example with Exclusions and Custom Base URL
app.use(grizzlySec({
apiKey: 'your-api-key',
baseUrl: 'https://mywebsite.com',
excludedUrls: ['/health', '/internal/**','/api/project/*/docs']
}));
How It Works
Grizzly Sec captures request and response data on every route, calculates payload sizes and response time, and sends the metadata securely to the Grizzly ingestion service. Sensitive headers are redacted, and excluded routes are bypassed for efficiency and privacy.
Privacy & Security
Data Protection: All request and response payloads are automatically censored before transmission. While we preserve the structure and keys of your data, all values are redacted with ***REDACTED***
to ensure no sensitive information is transmitted to our servers.
Header Filtering: Only essential headers (user-agent
, content-type
, accept
) are transmitted in full. All other headers are redacted for privacy.
Liability Disclaimer
Grizzly Sec is provided "as is" without any warranties. We are not liable for any damages, data loss, or security incidents that may occur from the use of this software. Users are responsible for:
- Ensuring compliance with their own privacy policies and data protection regulations
- Properly configuring exclusions for sensitive routes
- Monitoring and validating the security of their own applications
- Understanding that while we implement privacy measures, users should conduct their own security assessments
The automatic censoring of payloads is a privacy feature but does not guarantee complete data protection. Users should implement additional security measures as appropriate for their specific use cases.
Documentation
For full documentation and feature guides, visit:
https://www.grizzly-sec.com/docs
License
MIT
Author
Created by Rohan Chari
https://github.com/rohan-chari