avensby ÅbenKat
Accessibility
Text size
Contrast
Motion
Links

These last while the page is open. The site also follows your computer's own settings for contrast, motion and text size, and works with a keyboard and screen readers.

Download for Windows
Blue cyanotype of ferns laid flat, by Anna Atkins
Fig. 01Anna Atkins, ferns, cyanotype, 1840sParanoid first

Security

Avens assumes things will go wrong: laptops get stolen, insiders get curious, and files get edited behind the app's back.

This page says plainly what Avens protects, how, and what it doesn't protect yet.

What is protected

  1. 01.Patient data
    Patients' details (demographics) and their clinical records.
  2. 02.Credentials and keys
    Staff passphrases, and every key that comes from them.
  3. 03.Accountability
    Who read or changed which record, and proof that no record has been rewritten.
01.

Encryption on disk

The whole vault database is encrypted with SQLCipher and a 256-bit key, including its write-ahead log, and no plaintext temporary files are written. On top of that, each patient's details and every version of every record are sealed again with that patient's own keys, using XChaCha20-Poly1305.

02.

Separate keys for separate data

A demographics key, held by every member, opens patients' details. A clinical key, held only by clinicians with clinical access, opens clinical records. An administrator's account never contains the clinical key, so administrators can't read clinical records, even by opening the files directly.

03.

Keys come only from passphrases

Each member's keys are sealed with a key derived from their passphrase by Argon2id, with 64 MiB of memory and three passes: slow on purpose, about a second per try. Passphrases are at least 12 characters, and common ones are refused. The interface never receives a key, only the views its member may see, and every lock wipes the keys from memory.

04.

A signed audit log

Every sign-in, lock, failed sign-in, chart opening, break-glass access, record change, export, printout, staff change and key change is logged. Each entry is signed (Ed25519) by the member who made it and chained to the one before (BLAKE3). The log begins with an entry signed by a one-off key that is destroyed at once, it is checked in full at every sign-in, and cutting it short is reported at the next sign-in. Only administrators can read it.

05.

Signed records

Every record version is signed by its author and checked against what their role may write. Corrections and “entered in error” add versions and need a reason; nothing is overwritten. Anything changed outside the app is marked, kept out of summaries, and can't be exported or printed.

06.

Break-glass access

To open a chart outside their department, a clinician chooses a reason and writes a justification of 10 to 500 characters. Access lasts 60 minutes, in that session only, and is written to the audit log at once for administrators to review.

07.

The rollback witness

Signed notes of how far the log had got are kept outside the vault folder. If an older copy of the vault is put back, every member sees an alert until an administrator acknowledges it.

08.

Limits on guessing

After 5 failed sign-ins within 15 minutes, each further try must wait: 30 seconds at first, doubling up to 15 minutes. An unknown username gets the same answer, in the same time, as a wrong passphrase.

09.

The two-person rule

An administrator adds a member. A doctor who holds clinical access grants it to them, after checking their key fingerprint in person. No single person can create a clinician.

10.

Removing a member changes the keys

The vault master key and the demographics key change, so a copy of the member's old key opens nothing new. When the member was a clinician, the clinical key changes too.

11.

A limited recovery code

The recovery code is shown once. It adds one administrator, once, and never gives clinical access, and every member is told when it was used.

12.

Encrypted backups

Daily backups are encrypted like the vault, and go to destinations where files can be added but not changed or deleted. A restore checks everything before it replaces anything, and is recorded in the audit log.

13.

The desktop app itself

The window can't reach the network: it shows only Avens's own pages, and refuses new windows and downloads. Avens itself makes two kinds of request: a daily check for signed updates, which an administrator can switch off, and an optional download of the local model during setup. No patient data is ever sent, and there is no telemetry. The window is hidden from screenshots and screen sharing by default; only an administrator can switch that off, and it is logged. The vault locks after 5 minutes without use (adjustable from 1 to 60), must be on a local disk, and only one Avens window can use it at a time.

14.

The supply chain

Dependencies are locked to exact versions, and npm packages can't run install scripts. cargo deny, npm audit and a secrets scan run on every change, and every download in the build is checked by its SHA-256. Release files are signed with the Avens release key, which is kept offline, and Avens installs an update only when that signature checks out.

Who can do what

¹ With clinical access, inside their department; outside it, only through break-glass access.
² Only a doctor who holds clinical access.

ActionAdminis­tratorDoctorNurse
See the patient list: names, dates of birth, departments, blood typesYesYesYes
Open charts, the summary and the emergency screenNoYes¹Yes¹
Record vitals, lab results, notes, allergies and triageNoYes¹Yes¹
Record diagnoses, medications and encountersNoYes¹No
Export a chart as FHIR, or print itNoYes¹No
Read and verify the audit logYesNoNo
Add and remove members, change the vault's keys, set the recovery codeYesNoNo
Grant clinical access to new cliniciansNoYes²No
Set backup destinations, restore over the vault on this computerYesNoNo
Change their own passphraseYesYesYes

What isn't protected yet

Known and deliberate limits, or planned work.

01.

Malware during a session

A program running as the signed-in Windows user, while the vault is unlocked, can read what is decrypted in memory. Auto-lock limits how long that window stays open.

02.

Offline guessing

Anyone who copies the vault files or a backup can try passphrases on their own computer. The slow key derivation is the defence, so strong passphrases matter.

03.

Destruction

A member working on the files directly can delete or corrupt data. That is detected and shown, not prevented; backups make it recoverable.

04.

Departments are a rule, not encryption

Every clinician holds the same clinical key, so department boundaries and break-glass access are enforced by the app, and made accountable by the signed log.

05.

Two people acting together

An administrator and a doctor acting together can create a clinician account. The log names both.

06.

Old backups keep old keys

A passphrase removed or changed later still opens backups made before. Retiring old backups is planned.

07.

One vault per Windows user

Anyone who signs in to that Windows account can copy or delete the vault's encrypted files. A protected service that would stop this is designed, not built.

08.

Rolling back the witness too

Someone who puts back both an old vault and an old witness file isn't detected. Witnesses off the machine are planned.

09.

Deleting is best effort

Old copies of data can linger on disk, especially on SSDs.

10.

The local model

The optional model is experimental and not clinically validated. It can be wrong, and text inside a note can steer what it writes.

11.

Unsigned installers

Windows SmartScreen warns about the installer until code signing lands. Check its SHA-256 first.

In detail

Documents kept with the Avens source code.

  1. 01.Threat model
    Adversaries, defences, and every known limitation.
    docs/THREAT_MODEL.md
  2. 02.Crypto format
    The key hierarchy, envelopes, audit log, witness, recovery code and backups, byte by byte.
    docs/CRYPTO_FORMAT.md
  3. 03.Architecture
    Data flows, and the protected-service design.
    docs/ARCHITECTURE.md
  4. 04.Backups
    Making backup destinations nobody can erase.
    docs/BACKUPS.md
These are pre-release versions for testing. They aren't certified as a medical device, so don't use them for real patients.
Back to top