Home

Awesome

Virgil PureKit MariaDB Demo

The Demo App is a simple web application that illustrates how Virgil PureKit can be used with MariaDB to store and share data in the most secure way. The Demo App is based on use case involving a hypothetical business scenario involving a patient, physician and laboratory, and shows how distinct roles within a customer's application can be defined and used to restrict ePHI access in a HIPAA-compliant manner.

<img width="100%" src="https://cdn.virgilsecurity.com/assets/images/github/purekit_demo/purekit_mariadb.png" align="left" hspace="6" vspace="6">

Read more about demo and how it works here.

Prerequisites

Clone the demo

git clone https://github.com/VirgilSecurity/virgil-mariadb-demo.git

Setup and run demo

Variable NameDescription
virgil_appIdYour Virgil Application ID. At Virgil Dashboard in your "PureKit Demo" application, navigate to "Settings" and copy the App ID.
virgil_atYour Virgil Application token. At Virgil Dashboard in your "PureKit Demo" application, navigate to the PureKit tab and click "Generate credentials" if you haven't. Copy and save the generated App Token.
virgil_pkPHE Service public key of your PureKit application. At Virgil Dashboard in your "PureKit Demo" application, navigate to the PureKit tab and click "Generate credentials" if you haven't. Copy and save the generated PHE Service public key.
virgil_nmsYour PureKit Nonrotatable master secret.
virgil_buYour PureKit Backup public key.
virgil_skYour PureKit App secret key.

To generate virgil_nms, virgil_bu and virgil_sk, install the Virgil CLI and then run the following command:

virgil purekit keygen all

Make sure to save the generated keys in a safe storage.

docker-compose up

Explore demo

The Demo App consists of three cards (actors): Patient (Alice), Physician (Bob) and Lab.

At any moment you can restart the demo and check the database using the buttons in the top.

Actors

In the beginning of the demo flow, each actor the following:

Alice has:

Bob has:

Lab has:

Usage

At the Patient card:

At the Physician card:

At the Lab card:

View MariaDB records

Now, to see the results of your actions in the database:

Build docker images (optional)

Prerequisites

To re-build docker images for demo's client and server use the steps below:

mvn clean package
docker build -t virgilsecurity/mariadb-demo-server .
docker build -t virgilsecurity/mariadb-demo-client .

License

This Demo is released under the 3-clause BSD License.

Support

Our developer support team is here to help you.

You can find us on Twitter or send us email support@VirgilSecurity.com.

Also, get extra help from our support team on Slack.