Erebus.Schema (Erebus v0.2.0-rc.3) View Source
This module provides macros for defining fields on your Ecto model.
Usage:
use Erebus.Schema
use Ecto.Schema
embedded_schema do
hashed_encrypted_field(:first)
data_encryption_key()
end
Link to this section Summary
Functions
Defines field dek
of type map
, which is required for storing encrypted information using
Erebus.
Defines three fields
Link to this section Functions
Defines field dek
of type map
, which is required for storing encrypted information using
Erebus.
Please note that if you're using it with a database underneath, this field needs to be of type
jsonb
underneath.
Defines three fields:
name
: virtual field of typestring
name_encrypted
: field of typebinary
storing encrypted dataname_hash
: field of typestring
, storing sha512 version of given data, for quick searching
Please note that if you're using it with a database underneath, these fields need to be of type:
name_encrypted
:bytea
name_hash
:text