# Hextrap > Hextrap is a software supply chain security platform that protects package installations across PyPI (Python), npm (JavaScript/Node.js), and Go modules. It acts as a security firewall between your package manager and the upstream registry, filtering out malicious, typosquatted, and risky packages before they reach your codebase. ## Documentation - [Getting Started](https://hextrap.com/docs/): Set up your first firewall, generate credentials, and configure your package manager in under 5 minutes. - [MCP Server Setup Guide](https://hextrap.com/docs/setting-up-your-llm-to-use-hextrap-as-an-mcp-server): Connect Claude Code, Claude Desktop, ChatGPT, or any MCP-compatible AI assistant to Hextrap so packages are checked against your firewall before installation. - [API Reference](https://hextrap.com/api/): REST API documentation for programmatic access to firewalls, allow/deny lists, credentials, and activity logs. - [Custom Policies Documentation](https://hextrap.com/docs/custom-policies/): Write custom OPA Rego policies to filter packages by license, score, dependencies, and more. ## Core Features ### Package Firewall Every `pip install`, `npm install`, and `go get` is routed through Hextrap's firewall proxy. Packages are evaluated against your security policies in real time before being allowed through. Blocked packages never reach your environment. ### Allow Lists and Deny Lists Firewalls support explicit allow lists (only these packages are permitted) and deny lists (these packages are always blocked). This shifts security from "block known bad" to "only allow known good," providing stronger protection than scanning alone. ### Typosquat Detection Hextrap continuously polls the PyPI, npm, and Go module registries for newly published packages and checks each one against a database of popular packages using fuzzy string matching. Packages with high similarity scores to popular packages are flagged as suspected typosquats and blocked by firewalls that have typosquat protection enabled. ### Malicious Package Detection Packages identified as malicious through advisories, community reports, or analysis are blocked across all firewalls. The platform integrates with deps.dev and OpenSSF Scorecard data for security scoring. ### Soak Time Firewalls can enforce a configurable soak time that delays new package versions from being installable for a set period after publication. This provides a window for the security community to identify issues with newly released versions before they enter your dependency tree. ### Block Unmaintained Packages Firewalls can be configured to block packages that show signs of being unmaintained or abandoned, reducing risk from dependencies that no longer receive security patches. ### Custom Policies (OPA Rego) Firewalls support custom policies written in the Open Policy Agent (OPA) Rego language. Policies deny by default (`default allow := false`) and users write `allow` rules that evaluate package metadata (name, version, license, registry), security/quality/maintenance scores, dependency counts, advisory counts, SLSA provenance, and community signals (downloads, GitHub stars). If `allow` evaluates to `false`, the package is blocked. Policies use `package hextrap.firewall` and `import rego.v1`. See the [Custom Policies documentation](https://hextrap.com/docs/custom-policies/) for the full input schema and examples. ### Package Scoring Each package receives Security (0-100), Quality (0-100), and Maintenance (0-100) scores computed from deps.dev data, OpenSSF Scorecards, advisory databases, release history, and community signals. An Overall score is calculated as a weighted combination. ## MCP Server Hextrap provides a Model Context Protocol (MCP) server at `https://hextrap.com/mcp/` that lets AI coding assistants check packages against your firewall before installing them. ### Available MCP Tools - `check_package`: Check if a package is allowed by a firewall and whether it is a suspected typosquat. Parameters: `name`, `registry` (pypi/npm/go), `firewall_id`. - `list_firewalls`: List all firewalls you have access to with their IDs, names, and configurations. - `add_to_allowlist`: Add a package to a firewall's allow list. Parameters: `firewall_id`, `package_name`, `registry`. - `add_to_denylist`: Add a package to a firewall's deny list. Parameters: `firewall_id`, `package_name`, `registry`. - `remove_from_allowlist`: Remove a package from a firewall's allow list. Parameters: `firewall_id`, `package_name`. - `remove_from_denylist`: Remove a package from a firewall's deny list. Parameters: `firewall_id`, `package_name`. - `get_activity`: View recent package installation activity for a firewall. Parameters: `firewall_id`, `limit`. - `get_proxy_config`: Get proxy credentials and package manager configuration for a firewall. Parameters: `firewall_id`. - `roll_proxy_credential`: Regenerate proxy credential password. Parameters: `firewall_id`. - `create_service_credential`: Create a named service credential for CI/CD pipelines. Parameters: `firewall_id`, `name`. ### MCP Configuration Authentication uses a Bearer token in the Authorization header. API keys are created from Dashboard > API Keys. Supported transports: streamable HTTP (`type: http`) for Claude Code, SSE (`type: sse`) for Claude Desktop. ## Supported Registries - **PyPI** (Python): Proxy at `pypi.hextrap.com`. Configure via `pip install --index-url` or `PIP_INDEX_URL` environment variable. - **npm** (JavaScript/Node.js): Proxy at `npm.hextrap.com`. Configure via `.npmrc` or `bunfig.toml` for Bun. - **Go modules**: Proxy at `go.hextrap.com`. Configure via `GOPROXY` environment variable. ## Credential System Hextrap uses a two-tier credential system: - **Personal credentials**: For individual developer use. One per user per firewall. - **Service credentials**: Named credentials for CI/CD pipelines (e.g., "GitHub Actions", "GitLab CI"). Each pipeline should have its own credential for auditability. ## Organization and Access Control - Organizations contain teams and firewalls. - Teams have members with role-based permissions. - SSO authentication is supported for enterprise organizations. - Magic link email authentication is available for all users. ## Links - [Homepage](https://hextrap.com/) - [Documentation](https://hextrap.com/docs/) - [MCP Setup Guide](https://hextrap.com/docs/setting-up-your-llm-to-use-hextrap-as-an-mcp-server) - [API Reference](https://hextrap.com/api/) - [Pricing](https://hextrap.com/pricing/) - [Blog](https://hextrap.com/blog/) - [Contact](https://hextrap.com/contact/)