Skip to main content

Nebu

Enterprise-grade, Matrix-compatible chat server - Apache 2.0, SSO-ready, horizontally scalable.

Nebu

Nebu (named after the Nebuchadnezzar, the ship of the free from The Matrix) is an enterprise chat server that implements the Matrix Client-Server API. Standard Matrix clients (Element, Cinny, FluffyChat and others) work out of the box without any modifications.

Nebu is built for organizations that require full data sovereignty: on-premise deployment, no vendor lock-in, no telemetry, and no federation overhead.

Architecture: Two runtime components - a single Elixir/OTP application (Matrix API, media gateway and Admin UI as the module namespaces Nebu.Matrix/Media/Admin; Room GenServers via Horde, Session Manager via ETS, Presence, Event Dispatcher) and PostgreSQL as an append-only event log. No Go, no Redis, no NATS, no Kafka.

Security and Compliance: Authentication exclusively through the organisation's own OIDC provider (Keycloak, Azure AD, Google Workspace, Dex), no password management of its own, Ed25519 message signatures for authenticity and non-repudiation, audit logging, legal export, and four-eyes principle for privileged access.

OAuth 2.0 (Matrix v1.15): Optionally Nebu acts as an OAuth 2.0 authorization server (broker model) in front of the OIDC provider. Current Matrix clients (Element Web, FluffyChat) register themselves with Dynamic Client Registration, an administrator approves new clients, and Matrix access and refresh tokens are issued by Nebu alone and can be revoked. The provider only authenticates the human. The feature is off by default and is switched in the Admin UI; while it is off, the existing OIDC login is unchanged.

End-to-end encryption (client infrastructure, rooms stay unencrypted): Nebu supports the client-side E2EE infrastructure of Matrix clients: server-side key backup (room_keys), to-device messages, a device key directory (keys/upload, query, claim, changes, device_lists in sync) and cross-signing with server-verified Ed25519 signatures for device verification. The server stores only public keys and opaque blobs, decrypts nothing and logs no key material. Rooms are deliberately kept unencrypted: m.room.encryption and m.room.encrypted are refused so that the archive, audit log and legal export stay complete. To-device messages are limited to a fixed list of types and are rate and size limited. Not supported: end-to-end encrypted Element Call calls.

Implemented Matrix Scope: Login, logout, sync, send, messages, createRoom, join, typing, receipts, profile, presence, media upload/download/thumbnail, key backup, to-device, key directory and cross-signing, OAuth 2.0 API (optional). Intentionally excluded: federation, identity server, encrypted rooms.

Tech Stack: Elixir 1.20+ / OTP 27+ (Bandit, Plug, Phoenix LiveView), PostgreSQL 16+, Docker.

Software-Details

Created at

05/02/26

Last updated

12/02/26

Status

development

Platform
  • web
  • linux
Software-Version

0.4.0

License

Apache-2.0

Last updated: