Case Study

DoD Dark Site API Gateway: STIG-Compliant, COTS-Free, Self-Service

A DoD facility running in an air-gapped environment needed a scalable API gateway with authentication, authorization, and full audit capability. The existing proprietary appliance was expensive, opaque, and impossible to self-service. We replaced it with a fully open-source stack that is FIPS-capable, STIG-compliant by default, and deployable offline from a single command.

Commercial off-the-shelf gateway appliances are the default choice in many government environments, but they come with a set of problems that compound over time in sensitive or air-gapped deployments.

No Code Visibility

All API traffic flows through a closed binary. There is no way to verify what the appliance actually does with that traffic. In a classified environment, that is not an acceptable unknown.

Vendor-Controlled Patch Cycle

When a vulnerability is found, the organization waits for the vendor to issue a patch, then waits again for the patch to go through the approval process. Self-managed open source allows immediate mitigation.

License Costs at Scale

Proprietary appliances charge per node, per throughput tier, or both. Scaling the gateway to cover additional services means additional licensing costs. The open-source replacement scales to any size for the cost of compute.

No Self-Service

Adding a new route, updating an auth policy, or changing rate limits required vendor involvement or specialized appliance knowledge. Teams were blocked waiting for gateway changes that should have taken minutes.

The replacement stack is built entirely on proven open-source components, each with full source code available for audit, reproducible container builds, and no external dependencies required at runtime.

Nginx (Red Hat UBI9)

TLS termination and load balancing at the edge. Built on Red Hat Universal Base Image 9 for FIPS-capable cryptography. TLS 1.2 minimum enforced, DoD-approved cipher suites only, version information suppressed, DoD consent banner served at login.

Apache APISIX

The API gateway layer. Handles routing, RBAC policy enforcement, rate limiting, request validation, and plugin-based extensibility. All policies are declarative and version-controlled. Real-time policy updates take effect without a service restart.

Keycloak

Identity and access management. Handles authentication, SSO, MFA readiness, and Active Directory federation via LDAPS. Short-lived tokens, 15-minute session timeouts, brute force protection, and a 24-password history policy are all configured by default.

PostgreSQL (Hardened)

Persistent storage for Keycloak state. SCRAM-SHA-256 authentication, connection and DDL logging, 15-minute idle session timeout, and SSL configuration provided. Hardened postgresql.conf and pg_hba.conf included in the repository.

etcd

Distributed configuration store for APISIX. Provides consistent, high-availability storage for gateway routing and policy state. Runs entirely within the security boundary with no external connectivity required.

Prometheus Metrics

APISIX exposes metrics for scraping. Full audit trail of all API transactions available for SIEM integration. Log export scripts included for forensic analysis and incident response workflows.

The stack implements Zero Trust aligned with NIST SP 800-207, the CISA Zero Trust Maturity Model, and the DoD Zero Trust Reference Architecture. Every API request is authenticated and authorized independently. Network location grants nothing.

  1. 1
    Verify identity (Keycloak)

    Every request must carry a valid token issued by Keycloak. Tokens are short-lived. Users authenticate against Active Directory via LDAPS federation. MFA can be enforced per realm or per client.

  2. 2
    Enforce policy (APISIX)

    APISIX validates the token on every request via the Keycloak plugin and enforces RBAC policies at the gateway edge. Routes only accept traffic from identities with the required role. No implicit trust based on internal network position.

  3. 3
    Validate the request

    Rate limiting, input validation, and request size enforcement run as APISIX plugins before traffic reaches any backend service. Malformed or over-limit requests are rejected at the gateway.

  4. 4
    Log everything

    Every transaction is logged with timestamps across all components. Keycloak logs all authentication and admin events. APISIX logs all routing decisions. PostgreSQL logs all connections and DDL. Logs are structured for SIEM ingestion and forensic export.

The hardened deployment configuration addresses 26 of 32 applicable STIG controls automatically on first deploy. The remaining 6 require manual steps that are fully documented: TLS certificate generation, Keycloak password policy configuration, AD federation setup, FIPS mode activation, image signing, and network segmentation for Kubernetes.

FIPS 140-2 capability is built in. The Nginx layer uses Red Hat UBI9 which is FIPS-capable. Running the stack on a FIPS-enabled RHEL host brings the entire deployment into compliance. Keycloak FIPS strict mode is a single environment variable.

The environment has no internet access. All images must be transferred physically or over a classified network. The repository includes tooling to handle this without manual intervention.

There are no license checks, no telemetry, no phone-home behavior, and no dependency on any external service once the images are loaded. The deployment is fully self-contained.

One of the primary goals was eliminating the bottleneck of gateway changes requiring specialized vendor knowledge or a ticket to a central team. The APISIX admin interface and declarative configuration make route and policy management accessible to any developer with appropriate access.

The proprietary appliance carried licensing costs that scaled with usage and required vendor support contracts. The open-source replacement has no licensing cost at any scale.

Whether you are replacing a costly COTS appliance, building security infrastructure for an air-gapped facility, or need a Zero Trust gateway that you can actually audit and own, we can scope and deploy it.

We work in classified and restricted environments and understand what compliance actually requires versus what vendors claim it requires.

Get in Touch