Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Encrypt patient data at rest and in backup files. #251

Open
wants to merge 13 commits into
base: dev
Choose a base branch
from

Conversation

schuyler
Copy link
Member

@schuyler schuyler commented Feb 11, 2020

This PR accomplishes a few things:

  • Adds a system-wide encryption secret in /usr/share/buendia/system.key that is created if not already present during buendia-utils postinstall.
  • Modifies buendia-mysql to use this secret to encrypt a separate set of database keys, and updates the database dependency to MariaDB > 10.1.4 to guarantee that AES-CTR encryption-at-rest is available.
  • Updates buendia-backup to use the system key to encrypt OpenMRS and Buendia configuration data on backup, and to decrypt with same on restore.
  • Also updates buendia-backup to backup and restore the system key itself to an external storage device, whenever an external device is used for backup or restore.

This PR lays the groundwork for the security reset mode as described in #250 .

The encryption-at-rest, backup, and restore functions are all tested to some extent in integration tests that work in Vagrant. I've tested this functionality manually both on a fresh Vagrant system, and as an upgrade to an existing Vagrant system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants