Proca.Server.Keys (proca v3.3.1)
Stores encryption keys and nonces for each Org id
State is: {my_org_id, fn -> id_to_keys_map, nonce}
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor.
Fetch all active public keys
Increment nonce by 1. Should be run after every successful encryption.
Initialize Key server with our org name.
Start Encrypt server
Link to this section Functions
Link to this function
child_spec(init_arg)
Returns a specification to start this module under a supervisor.
See Supervisor
.
Link to this function
encryption(from_to)
Link to this function
handle_continue(atom, arg)
Fetch all active public keys
Link to this function
increment_nonce(nonce)
Increment nonce by 1. Should be run after every successful encryption.
Link to this function
init(org_name)
Initialize Key server with our org name.
Pass the org name to handle_continue :get_keys to fetch all keys
Link to this function
start_link(org_name)
Start Encrypt server
Link to this function