WikiArchitecture
Architecture
Priente-OS, layer by layer.
What each layer does, from the firmware to your product, and how each one trusts the next. First what a kernel is, then the rest of the system, with diagrams.
What is a kernel?
Every program on a computer — a web server, a database, a security product — needs the processor, memory, disks and the network. The part that shares these resources between programs, decides who may reach what and talks to the hardware is called the kernel. The kernel is the heart of the operating system: it manages everything that happens on the system.
Programs never touch the hardware directly; they ask the kernel. Every request, such as “open this file”, “connect to that address” or “start a new program”, reaches the kernel in a common language called the system call interface. The kernel checks the request, carries it out and returns the result. This is where the final word on what a program may or may not do is spoken.
Why our own kernel?
Most operating systems are built on a kernel someone else developed, and inherit its design decisions, its attack surface and its release schedule. Priente-OS is different: we developed the kernel ourselves, from its first line, in Rust, a language that puts memory safety at the centre of the design. Security decisions, such as which program may run and which signature is valid, are made in the lowest layer, in our own code.
- Signed execution inside the kernel. Before a file runs, the kernel checks that it is in a signed list. There is no exception, not even for root.
- Unsafe code in a small core. The little code that must touch the hardware directly lives in a small, auditable core; everywhere else the compiler does not allow unsafe code.
- No code added later. The running kernel has no module loading interface; the kernel changes only with a signed system image.
- Compatibility kept. The kernel offers the system call interface applications expect. Unmodified open-source tools such as PostgreSQL, nginx, Suricata and WireGuard run as they are.
The big picture
Priente-OS is built from layers that verify each other from the bottom up. Each layer checks the signature of the one above before starting it, while persistent data lives apart from the system, on its own partition.
- Hardware and firmware: amd64, arm64 and riscv64; UEFI and Secure Boot.
- Boot manager: decides which of the two system slots boots. Boot chain
- System image: the loader, the kernel and the base system in one signed file. System image
- Kernel: manages the hardware and checks every execution against the signatures. Integrity
- Services: pinit starts and watches services; prienteconf sets up the network and the firewall. Services
- Security platform: the web panel and
psp, on every installation. Security platform - Packages and products: signed optional packages and Priente products running under their own accounts. Product packages
- Data partition: settings, logs, databases and installed packages. Data partition
The boot chain
From the moment the machine powers on until your application runs, each link verifies the next. If a single byte changes anywhere in the chain, that link is refused.
- UEFI firmware
With Secure Boot on, it starts only boot files signed with Priente’s keys. The keys come with the Secure Boot signed media and are enrolled in the firmware once.
- Boot manager
Decides which of the two slots on the disk boots and counts trial boots. Press a key at boot to pick a slot once.
- System image
The loader, the kernel and the base system sit under the same signature. When the firmware verifies the image, it has verified the kernel too.
- Kernel
Verifies the signed package manifests with the keys embedded in it. From then on only files listed in the manifests run.
- Services and applications
The data partition is mounted, packages are verified and unpacked, the firewall is loaded before the network, and the services start.
TPM 2.0 measured boot: every link of the chain is measured into the TPM. When the data partition is encrypted, its key is protected by a TPM seal that opens only with the same chain; if the disk is moved to another machine or the boot chain is changed, the data cannot be read.
The system image, unpacked in memory
The kernel and the base system come in one signed file: the system image. The root file system is unpacked from it into memory at every boot. A change to the system files disappears by itself at the next boot; there is no room for a persistent back door.
- Every machine boots from the same image: what runs where is never in question.
- Settings, logs and data are kept on the data partition, not in the image, and survive an image change.
- Updating the system means replacing the image as a whole with a new one; there is no half-done update. A/B updates
Signed packages and the repository
All software outside the base system — OpenSSH, PostgreSQL, nginx, Suricata, the Priente products — comes as a signed package archive (.ppk). Packages are picked on the installer’s screen, or installed later from the repository with priente-fetch or from the installation medium with priente-pkg.
Two layers of trust
- The repository signature keeps things fresh. The package list is signed, numbered and expires. A mirror that serves an old list, freezes it, or serves another channel’s or architecture’s list is refused.
- The kernel signature protects the code. Each archive’s manifest is handed to the kernel, which verifies the signature with the keys embedded in it. If one archive is refused, nothing changes. Even if the repository were taken over, unsigned code could not run.
Installation, step by step
- Plan
The required packages are worked out and installed first. A package another one needs cannot be removed.
- Download first
Everything is downloaded first and its size and SHA-256 are compared with the signed list. An interrupted download resumes; if a mirror does not answer, the next one is tried.
- The kernel verifies
The kernel checks every archive’s signature.
- Journalled changes
The changes are applied step by step under an operation journal. Even after a power cut, an interrupted operation is completed at the next run.
- Least disruption
Only the upgraded package’s services that were running before are restarted; unrelated services are not touched.
Installed archives are kept on the data partition and are verified and unpacked again at every boot. Packages’ settings under /etc live on the data partition too; upgrades and removals never touch what the administrator changed.
Channels and mirrors
stableis the default channel, with releases proven in the field.- The
featurechannel gets new releases first and also includes everything in stable. You can tie a single package to feature and keep the rest of the system on stable. - Several mirrors are configured; the one with the highest valid serial is used. If the main repository cannot be reached, updates continue from a mirror.
- On networks without internet access, signed packages travel offline; for example, NameDefence Manager serves as a repository mirror for its own Defenders.
Integrity: only signed files run
The core rule of Priente-OS is simple: no file runs unless a signed manifest lists it. The kernel compares the digest of every program, script and shared library it loads with the signed manifests. Even an attacker with root cannot run their own tools.
- Programs, scripts, libraries: the executed file, its loader and every library it loads are checked.
- A running file cannot change: a verified program cannot be written to while it runs; its contents cannot be swapped underneath it.
- No execution from network file systems: files whose contents a remote server controls never run.
- Every attempt is recorded: each refused execution goes to the audit log; the security platform turns it into the critical alarm “An unsigned program was blocked” and can mail it to you.
- Containers in their own cage: containers run, while the host’s signature rule never loosens.
A/B updates and automatic rollback
The disk has two system slots: A and B. While one runs, the new version is written to the idle one. The new version starts with a trial boot and becomes permanent once it passes the health check. If it does not, the machine returns to the previous version by itself; the device in the field stays up.
- Download and verify
The signed image and its manifest are downloaded and the kernel verifies the signature. An older version, an unsigned image or an image for another architecture is refused before anything is written.
- Write the idle slot
The image is written to the idle slot and verified by reading it back. A half-written slot is never tried; after a power cut the old system boots.
- Trial boot
The new system boots directly, without waiting for the firmware; services are back as soon as possible.
- Health check
Are the required services running, did the network interfaces get their addresses, did the products’ own checks pass?
- Confirm or roll back
If everything passes, the new version becomes permanent. If not, or if the new system cannot boot, the machine returns to the previous version.
Products add their own health checks: if a product is not ready, the update is rolled back. The administrator can add conditions too. Commands
The data partition (/data)
An installed disk has two partitions. The EFI partition carries the boot manager and the two system slots. The data partition carries everything that persists: settings, logs, databases, home directories and installed packages. At boot the data partition is mounted at /data and the persistent directories are placed over the system.
| Directory | Contents |
|---|---|
/etc/priente | System settings (system.conf), the security platform, repository and update settings, product accounts |
/etc/ssh | The SSH server’s keys and settings |
/var/lib, /var/log | Service data, databases and logs |
/var/www, /srv, /var/spool | Web content, served files, queues |
/opt, /home, /root | Product directories and home directories |
/etc/<package> | Optional packages’ settings (such as /etc/nginx) |
/data/packages | The installed signed package archives |
- Everything outside these directories comes from the image at every boot.
- A system update never touches the data partition.
- The data partition can be encrypted with a TPM-sealed key: the key opens only with the right boot chain, and a recovery key is set up as well.
Services: pinit
pinit is the Priente-OS service manager: the first process at boot. It starts services in dependency order, watches them, restarts them when they fail and writes their output to the journal. Developed by us from scratch, pinit understands the service files and commands administrators and products are used to: systemctl, journalctl, timedatectl, hostnamectl.
Boot order
- Data partition
Found, opened if encrypted and mounted at
/data; the persistent directories fall into place. - Packages
Installed archives are verified again and unpacked; product accounts are prepared.
- Settings
prienteconfapplies the host name, time zone and DNS, loads the firewall before the network interfaces, then brings up the network. - Services
Enabled services and the packages’ services start; timers are set up.
- Session
The console login opens; root’s shell is psh, with its status bar.
- Timers: periodic jobs (such as automatic updates) run as timer units; a run missed while the machine was off is made once at boot.
- Journal: every service’s output and the system log in one place; its size is set with
prienteconf. - Separation of rights: root can do everything; product accounts manage only their own services and read only their own logs.
The security platform
The Priente Security Platform is part of every installation: a modern web panel and the psp command that does the same work. Security is the first page; everything needed to run the machine is in the same place.
- Attack Radar: failed logins, port scans, packets the firewall drops and panel attempts in one stream. Every source address is scored by its events.
- Log and Prevent modes: the default Log mode records and alarms everything and cuts nothing. Prevent blocks an attacker automatically once they cross the threshold. Management networks stay on the allowlist and are never blocked.
- Built-in decoys: decoy ports with ssh, telnet, http, https, rdp, smb, mysql, postgres and redis profiles. Every connection that touches a decoy is hostile.
- Integrity: the signed-execution mode, Secure Boot, measured boot, the system slots and the signature of every running process on one card.
- Alarms and mail: critical events arrive by mail, grouped; with a daily summary if you like.
- Running the system: updates, processes, services, logs, network, users, two-factor sign-in and a full terminal in the browser.
- Fleet: one machine becomes the manager and the others join it; every server is managed from one panel. Every connection is protected by TLS 1.3 pinned to the manager’s certificate.
Product packages and product accounts
Priente products such as NameDefence, AccessVerifier, Priente Hub, Siem Verifier, MobileITM and Guardpot are signed packages in the repository’s Priente products group. Pick them on the installer’s screen or install them with one command; the database, web server and tools they need come with them. Product updates arrive the same signed way as the system’s.
- Every product has its own account: installing a product creates its system account, with no password and no login. The product’s services run as this account.
- Only its own area: a product account can start and stop its own services, read its own logs and ask for updates through the update service. Other products’ data, the system’s settings and other services stay with the administrator.
- The signature rule does not change: whoever starts it, the kernel runs only signed programs. The account separation limits the harm a faulty or compromised service can do to the system.
- Product setup forms: a product asks for its first settings on the installer’s screen; the answers are written to the data partition and the product’s own setup program applies them at the first boot.
Installation
The installation image boots with UEFI and starts the graphical installer, used with the mouse or the keyboard. The installer writes the system image and the chosen signed packages to the disk, verifying each one.
- Welcome
Keyboard layout and the hardware report: whether every network and storage device is supported, at a glance.
- Disk, name and network
The target disk; host name, DHCP or a static address.
- Administrator and security
The root password and root login over SSH; the security platform’s web panel and radar mode.
- Products and packages
Priente products in a product installation, optional packages in a custom one; what they require is selected automatically.
- Product forms
The chosen products’ first settings; secret fields never appear on the summary or in the log.
- Summary and install
The disk is partitioned; the image and packages are copied with their signatures verified, and the machine boots from the disk.
- Image flavours: Full carries every optional package on the medium (for offline installations); Mini holds everything the products need. Secure Boot signed media are offered for amd64. Download
- Unattended installation: an answers file on the medium installs without a single question; the product forms’ fields come from the same file.
- Reset: an installed device returns to the installer with
priente-installer, no installation medium needed; the installed packages are offered again. Maintenance