liberatti/nxguard

By liberatti

โ€ขUpdated about 1 month ago

NXGuard is a high-performance, secure API Gateway and Reverse Proxy powered by OpenResty

Image
Networking
Security
Web servers
0

1.0K

liberatti/nxguard repository overview

โ NXGuard Logo NXGuard

License Version Platform

NXGuard is a high-performance, secure API Gateway and Reverse Proxy powered by OpenResty and ModSecurity. It provides a robust layer of protection for your API ecosystem, ensuring scalability, security, and operational simplicity.


โ ๐Ÿš€ Key Features

  • ๐Ÿ›ก๏ธ Advanced Security: Native integration with ModSecurity v3 for real-time threat detection (SQLi, XSS, etc.).
  • โšก High Performance: Leverages the power of OpenResty (Nginx + LuaJIT) for sub-millisecond request processing.
  • ๐Ÿ“Š Real-time Monitoring: Detailed transaction logging and telemetry for proactive threat identification.
  • โš–๏ธ Smart Load Balancing: Sophisticated traffic distribution across backend services.
  • ๐Ÿ› ๏ธ Operational Simplicity: Lightweight architecture with a modern management interface.
  • ๐ŸŒ Scalability: Modular design built for horizontal scaling in containerized environments.

โ ๐Ÿ“ธ Dashboard Preview

NXGuard Dashboard Preview Modern, intuitive management interface for full control over your API security.


โ ๐Ÿ—๏ธ Architecture

NXGuard Architecture Diagram High-performance architecture integrating OpenResty, ModSecurity, and Redis.


โ ๐Ÿšฆ Getting Started

โ Quick Start with Docker Compose

Deploy a full NXGuard stack including the Management UI and IPGuard in seconds:

services:
  redis:
    image: redis:7.2
    command: ["redis-server", "--save", "", "--appendonly", "no"]

  nxguard:
    image: liberatti/nxguard:latest
    environment:
      NXGUARD_ROLE: "main"
      SERVERID: "nxguard-admin"
      NXGUARD_IPGUARD_URL: "http://ipguard:5000"
      REDIS_CACHE_HOST: redis
    ports:
      - 5000:5000
      - 80:80
      - 443:443
    deploy:
      resources:
        limits:
          memory: 256M

  ipguard:
    image: liberatti/ipguard:latest
    volumes:
      - ipguard_data:/opt/ipguard/data
    deploy:
      resources:
        limits:
          memory: 64M
      replicas: 2

volumes:
  ipguard_data:

โ ๐Ÿงช Security Validation

Validate your WAF rules using GoTestWAF:

docker run --rm -v ${PWD}/reports:/app/reports \
    wallarm/gotestwaf --url=https://<YOUR_ENDPOINT> --noEmailReport

โ ๐Ÿ”ข WAF Rule ID Reservations

RangeDescription
1 - 99,999Local/Internal Use
100,000 - 199,999Oracle Published Rules
200,000 - 299,999Comodo Published Rules
300,000 - 399,999GotRoot.com Rules
900,000 - 999,999OWASP Core Rule Set (CRS)
2,000,000 - 2,999,999Trustwave SpiderLabs Rules

โ ๐Ÿ“ก Telemetry Notice

To improve our security engine, NXGuard collects anonymous traffic statistics over 24-hour cycles. No sensitive, personal, or request-specific data is ever collected. This information is used solely to enhance threat detection accuracy.


โ ๐Ÿ“„ License

This project is licensed under the Apache License 2.0. See the LICENSEโ  file for the full text.


Developed with โค๏ธ by Gustavo Liberatti

Tag summary

Content type

Image

Digest

sha256:e9e362100โ€ฆ

Size

176.1 MB

Last updated

about 1 month ago

docker pull liberatti/nxguard