Apollo18.Based64Cipher (Apollo18 v1.0.12)

Provides cipher mechanism to make your things be like Apollo 18: Officially don't exists, only the owner know that it (if ?) exists.

The truth is out there (Maybe ...).

Uses the Apollo18.Cipher mechanism, applying additional steps, to encode/decode to/from base64 before/after cipher/decipher.

This module functionalities are present in web/javascript version. This could be usefull to send/receive messages between a web browser client (Javascript side) and a server (Elixir side). For javascript instantiation use:

let cipher = new Based64Cipher();

Remember of take additional care to handle securely key and salt values when use it whit javascript. Rotate the key each X minutes and store it ciphered for example. If you want maximum security try use one new key per message. Never, never, never use sequential keys, always randomize, please!

Link to this section Summary

Functions

Same doc as for Apollo18.Cipher. Only add a base64 encode conversion to received text/string before call Apollo18.Cipher.cipher(string,salt).

Same doc as for Apollo18.Cipher. Only add a base64 decode conversion to received text/string after receive the result of call Apollo18.Cipher.decipher(string,salt).

Link to this section Functions

Link to this function

cipher(string, salt \\ 1, key \\ 0)

(since 1.0.0)

Same doc as for Apollo18.Cipher. Only add a base64 encode conversion to received text/string before call Apollo18.Cipher.cipher(string,salt).

Link to this function

decipher(string, salt \\ 1, key \\ 0)

(since 1.0.0)

Same doc as for Apollo18.Cipher. Only add a base64 decode conversion to received text/string after receive the result of call Apollo18.Cipher.decipher(string,salt).