Implementation Guide · Stage 2

The mTLS Organisation Gateway.

Give an organisation cryptographic access to entityOS without putting a client certificate on every device. One gateway holds the certificate and connects over mTLS; staff use ordinary HTTPS; entityOS still signs in every person individually.

mTLS + X.509 Organisation Identity Office Gateway Hosted Gateway Individual Login Audit Trail
The Core Idea

One certificate per organisation gateway — not one per device.

mTLS gives entityOS a cryptographic answer to which organisation is connecting. Placing the certificate on a gateway the organisation controls keeps that answer — without distributing certificates to every laptop and phone.

Staff devices

Ordinary HTTPS. No client certificates to install, renew, back up or lose.

Organisation gateway

Holds the one client certificate and its private key, and connects to entityOS using mTLS.

entityOS

Validates the certificate, maps it to an organisation, then authenticates each person in the application.

mTLS proves which organisation.
The login proves which person.

Architecture

Four components. Two trust decisions.

The gateway sits between staff and entityOS. Staff talk to it over ordinary HTTPS; it talks to entityOS over mTLS. entityOS then makes two separate decisions: is this a known organisation — and, independently, is this a known person?

Staff Devicesnormal HTTPS · no client certificate
office LAN · VPN · identity-aware access
Organisation Gatewayholds the certificate + private key
mTLS — client certificate presented
entityOS Entry Pointvalidates certificate → organisation
organisation established
entityOS Applicationuser login · permissions · audit
  • 01

    Staff devices

    Use normal HTTPS to reach the gateway. No client certificates are required on laptops, phones or tablets.

    HTTPS
  • 02

    Organisation gateway

    Holds the client certificate and private key, and connects to entityOS using mTLS on behalf of the people allowed through it.

    mTLS client
  • 03

    entityOS entry point

    Validates the certificate against the entityOS trust store, enforces revocation, and maps the certificate to an organisation.

    certificate → organisation
  • 04

    entityOS application

    Authenticates individual users and applies their permissions. Every action is recorded against a person.

    login → person → permissions
Two decisions, never merged

The certificate establishes the organisation at the entry point. It never signs anyone in. Every person still authenticates to the entityOS application, and their permissions come from their own account — not from the fact that they came through the gateway.

Deployment Models

Two places to run the gateway.

Both models put one certificate in one controlled place. They differ in where that place is — and in what staff must pass through before they reach it.

MODEL 01

Office gateway

A small appliance or VM inside the office. Staff reach it over the local network. Remote staff connect to the office through a VPN first, then use the gateway exactly as if they were on site.

Staff device
Office gateway — appliance / VM
entityOS
FitsOrganisations with an office network and an existing VPN for people working away from it.
WatchThe office becomes part of the access path — its power, internet link and VPN. Run a second gateway or keep a documented, tested fallback.
MODEL 02

Hosted gateway

A dedicated gateway in the cloud. Staff must first authenticate to it — through an identity-aware access service or a VPN — before it will use the organisation’s certificate on their behalf.

Staff device
Hosted gateway — dedicated cloud instance
entityOS
FitsDistributed teams, organisations without an office network, and staff who work mostly in the field.
WatchThe access layer in front becomes the control that matters most. The gateway must be unreachable except through it — no direct listener, no side door.
The Key Design Boundary

Who can use the gateway decides what the certificate is worth.

Anyone allowed through the gateway benefits from its mTLS identity. The certificate does not know who is behind it — it only proves that the request came from the gateway. So the gateway’s front door is the real security boundary of this design.

Undermines the protection

An open forwarder

  • Reachable from the public internet
  • Forwards every request it receives
  • Lends the organisation’s certificate to anyone
  • Accepts a destination chosen by the client
  • No record of who used it
The certificate still validates — but it no longer says anything about who is behind it. The mTLS edge now admits whoever can find the gateway.
Preserves the protection

A gated gateway

  • Reachable only from the office network, VPN or access service
  • Staff authenticate (SSO + MFA) before anything is forwarded
  • Forwards only to approved entityOS destinations
  • Never asserts a user’s identity on their behalf
  • Logs every session — who, when, where to
The certificate then means something precise: this request came through our organisation’s controlled access path.

A publicly accessible gateway that automatically forwards everyone would turn an organisation credential into a public one. Gate the gateway first; then the certificate carries the organisation’s trust.

Choosing a Model

Certificates per device, or per gateway.

Stage 2 can issue a certificate to every device, or to the organisation’s gateway. The gateway trades a per-device cryptographic binding for central management — a good trade when device trust is handled by a separate control.

Capability Certificate per device Office gateway Hosted gateway
Client certificates to manageOne per deviceOne per gatewayOne per gateway
Staff device setupCertificate on eachNone — HTTPSNone — HTTPS
Remote staffDirectVPN to the officeAccess service or VPN
What mTLS identifiesThe device’s keyThe organisationThe organisation
Disable the whole organisationEvery certificateOne switchOne switch
Remove one personRevoke their certificateRemove access + loginRemove access + login
Individual login & auditYesYesYes
Gateway session logsNoYesYes
Device trustKey on device onlySeparate controlSeparate control
Single point of failureNoneYes — run twoYes — run two
Infrastructure to runIssuance at scaleAppliance or VMGateway + access layer

A certificate on a device proves the device holds a key — not that it is healthy. A gateway proves the organisation. Neither replaces the individual login, and neither replaces device trust where the risk warrants it.

Defence in Depth

What each layer proves.

The gateway model works because each layer answers one question, and none of them is asked to answer another’s.

01 Access to the GatewayOffice network, VPN or identity-aware access — SSO and phishing-resistant MFA before anything is forwarded. Who may use it
02 Gateway CertificateOne X.509 certificate per gateway; the private key is generated on, and never leaves, the gateway. Organisation
03 Entry Point ValidationChain checked against the entityOS trust store, revocation enforced, certificate mapped to an organisation. Edge
04 One Route InNo alternative path reaches the same resources without passing the mTLS edge. Integrity
05 Application LoginEach person authenticates individually; permissions come from their own account and role. Person
06 Audit TrailGateway session logs plus the entityOS audit trail — who, through which gateway, did what. Evidence

mTLS proves the gateway’s identity — not the health of the device behind it. If device trust matters, add it as its own control: managed-device checks at the access layer, or posture signals from your MDM, evaluated before the gateway forwards anything.

Implementation

Setting it up — the pattern.

Seven decisions, in order. The gateway software varies; the shape does not.

  1. 1

    Register the organisation and its gateway

    Create the gateway as a named record under the organisation in entityOS. The rule is one certificate per gateway: a second gateway — for redundancy, or one office and one hosted — gets its own certificate, mapped to the same organisation and revocable on its own.

  2. 2

    Generate the key on the gateway, then request the certificate

    Create the key pair on the gateway and request the certificate from the entityOS CA with a CSR, so the private key never leaves the machine that uses it. Keep the key readable only by the gateway process, use hardware-backed or managed secret storage where the platform supports it, and prefer a short validity — renewal is automated in step 7.

    openssl req -new -newkey rsa:3072 -nodes \ -keyout org-gateway.key -out org-gateway.csr \ -subj "/O=<organisation>/CN=<gateway-name>" chmod 600 org-gateway.key
  3. 3

    Gate who can use the gateway

    Office gateway: listen on the office network only; remote staff come in over the VPN. Hosted gateway: never expose it directly — put an identity-aware access service or VPN in front, with SSO and phishing‑resistant MFA, and accept inbound connections only from that layer. If someone can reach the gateway without authenticating, they hold the organisation’s mTLS identity.

  4. 4

    Forward only to approved entityOS destinations

    Run the gateway as a reverse proxy with fixed upstreams — the approved entityOS hostnames and nothing else. It must not be a general-purpose forward proxy, and must never accept a destination chosen by the client. Nor should it vouch for users: the gateway proves the organisation; the application proves the person.

    server { listen 443 ssl; # staff: ordinary HTTPS server_name entityos.gateway.example; ssl_certificate /etc/gateway/server.crt; ssl_certificate_key /etc/gateway/server.key; allow 10.20.0.0/16; # office LAN + VPN pool only deny all; location / { proxy_pass https://<entityos-entry-point>; # the only destination proxy_ssl_server_name on; proxy_ssl_verify on; proxy_ssl_trusted_certificate /etc/ssl/certs/ca-certificates.crt; # mTLS: the organisation gateway certificate proxy_ssl_certificate /etc/gateway/org-gateway.crt; proxy_ssl_certificate_key /etc/gateway/org-gateway.key; } }

    Illustrative nginx configuration; HAProxy, Envoy or a managed proxy follow the same shape. The upstream is fixed in configuration, so the gateway cannot be pointed anywhere else.

  5. 5

    Protect the entry point — one route in

    At entityOS, the entry point verifies the certificate chain against the trust store, enforces revocation, and maps the certificate to the organisation. On AWS this is an Application Load Balancer listener in mTLS verify mode with a trust store, which passes the verified certificate details to the target.

    client certificate (serial, subject) → gateway record gateway record → organisation organisation or gateway disabled → reject

    Then close every other route — a default service endpoint, a second listener, a directly reachable origin. Certificate details forwarded by the edge are only trustworthy if nothing else can reach the target; any path that skips the edge skips the check.

  6. 6

    Keep every person individual — and observable

    Each person signs in to the entityOS application with their own account; permissions come from their role, never from having come through the gateway. Keep gateway session logs — who, when, which destination — and correlate them with the entityOS audit trail. No shared accounts behind a shared certificate.

    The gateway’s egress address is fixed and known, so it can also be allowlisted under Stage 1 — and the organisation’s certificate arriving from any other address is a signal worth alerting on.

  7. 7

    Automate renewal; enforce revocation and disable

    Renew automatically, well before expiry, with overlap: install the new certificate, confirm it connects, then retire the old one. Make revocation work in two places — the certificate on the trust store’s revocation list, and an organisation or gateway disable switch in entityOS that takes effect at once, even while the certificate is still valid. Test both before you need them.

Plan the hostname — and the outage

Staff browse to the gateway’s hostname, not entityOS’s. Redirects, cookies and sign-in callbacks must resolve back through the gateway; anything that sends the browser straight to entityOS will be refused at the edge — which is the edge working correctly. And once the organisation depends on one gateway, it is a single point of failure: run a second, with its own certificate, or keep a tested break‑glass path.

The Key Idea

Organisation. Person. Device.

mTLS

Proves the organisation

The gateway’s certificate tells entityOS which organisation’s controlled access path a request came through.

Gateway
↓ client certificate
↓ Entry point
↓ Organisation
LOGIN

Proves the person

The application login tells entityOS who is acting; permissions and the audit trail follow their account.

Staff member
↓ entityOS login
↓ Role + permissions
↓ Audit trail
SEPARATE CONTROL

Device trust

Neither of the above says the device behind the request is healthy. Where that matters, check it at the access layer.

Managed device
↓ posture check
↓ Access layer
↓ Gateway

Centrally managed organisation access — one certificate per gateway, instead of one on every device.

The boundary is the gateway’s front door — anyone allowed through it inherits its mTLS identity, so it must never forward the open internet.

mTLS proves the gateway’s identity; the application login keeps every action attributable to a person; device trust, where required, is its own control. Layered with Stage 1 allowlisting of the gateway’s fixed address, they are independent barriers rather than one wall.