GitAntivirus is an intelligent security scanning service that automatically detects and fixes vulnerabilities in your repositories. It can be triggered via comments and provides automated security scanning, leak detection, and auto-remediation capabilities.
- π Automated Security Scanning - Detects security vulnerabilities, leaks, and exposed secrets
- π Credential Detection - Identifies exposed API keys, tokens, environment variables
- π Black Hole Detection - Finds potential security holes and misconfigurations
- π¦ Package Security - Scans package.json and dependencies for vulnerabilities
- π€ Auto-Fix Capability - Automatically creates PRs with security fixes
- π Detailed Reports - Generates comprehensive scan reports
- π Global Repository Support - Works on any public GitHub repository
- π¬ Comment-Triggered - Simply mention @GitAntivirus or @GitAnt to trigger scans
Simply mention the bot in a comment on any issue or pull request:
@GitAntivirus scan this repository
or use the shorter alias:
@GitAnt check for vulnerabilities
GitAntivirus automatically scans for:
-
π Exposed Secrets
- API keys (AWS, Google Cloud, Azure, etc.)
- Access tokens and authentication credentials
- Private keys and certificates
- Database connection strings
-
π Sensitive Files
.envfiles and environment configurations- Configuration files with credentials
- Backup files with sensitive data
-
π» Code Vulnerabilities
- JavaScript security issues
- JSON structure problems
- Dependency vulnerabilities in package.json
- Known CVEs in packages
-
π³οΈ Security Holes
- Insecure configurations
- Exposed endpoints
- Permission misconfigurations
-
Scan a Repository
@GitAntivirus scan -
Scan and Auto-Fix
@GitAntivirus scan and fix -
Check Specific Files
@GitAntivirus check package.json -
Generate Report
@GitAntivirus report
@GitAntivirus full-scan- Deep scan of entire repository@GitAntivirus check-dependencies- Scan package.json dependencies@GitAntivirus fix-package- Auto-fix package.json issues@GitAntivirus detect-leaks- Focus on credential/key detection@GitAntivirus troubleshoot- Diagnose repository issues
GitAntivirus automatically adds labels to issues and PRs:
security- Security vulnerabilities foundcredentials-leak- Exposed credentials detectedauto-fix- Automated fix appliedneeds-review- Manual review requiredvulnerability-high- Critical security issuevulnerability-medium- Medium severity issuevulnerability-low- Low severity issue
GitAntivirus is built with a modular architecture:
GitAntivirus/
βββ scanner/ # Core scanning engine
β βββ secrets.js # Secret detection
β βββ files.js # File analysis
β βββ packages.js # Package vulnerability scanning
β βββ code.js # Code analysis
βββ fixes/ # Auto-fix implementations
β βββ credentials.js
β βββ packages.js
β βββ config.js
βββ reporters/ # Report generation
β βββ markdown.js
β βββ json.js
βββ web/ # Web interface
βββ index.html
Detects exposed credentials using pattern matching and entropy analysis:
// Example patterns detected:
- AWS Access Keys: AKIA[0-9A-Z]{16}
- GitHub Tokens: ghp_[a-zA-Z0-9]{36}
- API Keys: [a-zA-Z0-9]{32,}
- Private Keys: -----BEGIN.*PRIVATE KEY-----Analyzes files for sensitive content:
// Scanned file types:
- .env, .env.local, .env.production
- config.json, secrets.json
- .aws/credentials
- .ssh/* keysChecks dependencies for known vulnerabilities:
// Checks against:
- npm audit database
- Snyk vulnerability database
- GitHub Security AdvisoriesAnalyzes code for security issues:
// Detects:
- Hardcoded credentials
- SQL injection vulnerabilities
- XSS vulnerabilities
- Insecure cryptographyGitAntivirus can automatically fix:
- Remove exposed credentials - Replaces with environment variable references
- Update vulnerable packages - Updates to patched versions
- Fix configuration issues - Corrects insecure settings
- Add .gitignore entries - Prevents future exposure of sensitive files
// Programmatic usage
const GitAntivirus = require('gitantivirus');
const scanner = new GitAntivirus({
repo: 'owner/repo',
token: process.env.GITHUB_TOKEN
});
// Run scan
const results = await scanner.scan();
// Apply fixes
await scanner.autoFix(results);
// Generate report
const report = scanner.generateReport(results);GitAntivirus can scan any public GitHub repository:
- Fork or clone the repository
- Run GitAntivirus scan
- Review findings
- Create PR with fixes to original repository
@GitAntivirus scan and contribute to owner/repo
This will:
- Clone the target repository
- Run security scan
- Create a PR with fixes
- Add detailed report of findings
- No Data Storage - Scan results are not stored permanently
- Token Security - All tokens are encrypted and never logged
- Private Repo Support - Requires proper authentication
- Audit Logging - All actions are logged for transparency
GitAntivirus generates detailed reports including:
- Executive Summary - High-level overview of findings
- Vulnerability Details - Detailed description of each issue
- Risk Assessment - Severity ratings and impact analysis
- Remediation Steps - How to fix each issue
- Code Snippets - Exact locations of vulnerabilities
# Security Scan Report
## Summary
- Total Issues: 12
- Critical: 2
- High: 4
- Medium: 4
- Low: 2
## Critical Issues
### 1. Exposed AWS Credentials
**File:** `config/aws.js:15`
**Severity:** Critical
**Description:** AWS access key found in source code
**Remediation:** Move to environment variables
### 2. Vulnerable Package
**Package:** `lodash@4.17.15`
**Severity:** Critical
**CVE:** CVE-2020-8203
**Remediation:** Update to version 4.17.21- Install the GitAntivirus GitHub App
- Grant repository access
- Trigger scans via comments
- Fork this repository
- Install dependencies:
npm install
- Set up environment variables:
cp .env.example .env # Edit .env with your configuration - Run locally:
npm start
Create a .gitantivirus.yml file in your repository root:
# GitAntivirus Configuration
version: 1.0
scanning:
enabled: true
auto_fix: true
scan_dependencies: true
scan_secrets: true
exclusions:
paths:
- node_modules/
- dist/
- build/
files:
- "*.test.js"
- "*.spec.js"
severity_threshold: medium
notifications:
enabled: true
channels:
- github_issues
- pull_requests
auto_fix:
enabled: true
create_pr: true
require_approval: falseWe welcome contributions! Please see our contributing guidelines:
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests
- Submit a pull request
MIT License - see LICENSE file for details
- π§ Email: support@cyberai.ecosystem
- π¬ Discord: Join our server
- π Documentation: Full Docs
- π Issues: GitHub Issues
GitAntivirus is part of the CyberAi Ecosystem, providing automated security solutions for the open-source community.
Made with β€οΈ by the CyberAi Team
Keeping your code secure, one commit at a time.