anchor.diff:  %% blocks we have a deadlock.
   %%
   %% The init + start sequence tries to implement Password Encrypted
  -%% Key Exchange using an ephemeral public/private keypair and the
  +%% Key Exchange using a node public/private keypair and the
   %% shared secret (the Cookie) to create session encryption keys
   %% that can not be re-created if the shared secret is compromized,
  -%% which should create forward secrecy.
  +%% which should create forward secrecy.  You need both nodes'
  +%% keypairs and the shared secret to decrypt the traffic
  +%% between the nodes.
   %%
   %% All exchanged messages uses {packet, 2} i.e 16 bit size header.
   %%
  -%% The init message contains a random number and encrypted: a public key
  +%% The init message contains a random number and encrypted: the public key
   %% and two random numbers.  The encryption is done with Key and IV hashed
   %% from the unencrypted random number and the shared secret.
   %%
  -%% The exchanged epemeral public/private keypairs are used
  -%% to create a shared key that is hashed with one of the encrypted
  +%% The other node's public key is used with the own node's private
  +%% key to create a shared key that is hashed with one of the encrypted
   %% random numbers from each side to create Key and IV for the session.
   %%
   %% The start message contains the two encrypted random numbers
  
positive.code: -record(params,
          {socket,
           dist_handle,
           public_key_type,
           public_key_params,
           hmac_algorithm,
           aead_cipher,
           iv,
           key,
           tag_len,
           rekey_interval
          }).
  
  current_params(Socket) ->
      #params{
         socket = Socket,
         public_key_type = ecdh,
         public_key_params = brainpoolP384t1,
         hmac_algorithm = sha256,
         aead_cipher = aes_gcm,
         iv = 12,
         key = 16,
         tag_len = 16,
         rekey_interval = 32768}.
  
  %% -------------------------------------------------------------------------
  %% Erlang distribution plugin structure explained to myself
  
negative.code:     {Ciphertext, Tag} =
          crypto:block_encrypt(AeadCipher, Key1A, IV1A, {AAD, Plaintext, TagLen}),
      Msg = [R1A, Tag, Ciphertext],
      {R2A, R3A, Msg}.
  %%
  init_msg(
    #params{
       hmac_algorithm = HmacAlgo,
       aead_cipher = AeadCipher,
       key = KeyLen,
       iv = IVLen,
       tag_len = TagLen,
       rekey_interval = RekeyInterval} = Params,
    Secret,
    #public_key_pair{
       type = PublicKeyType,
       params = PublicKeyParams,
       private = PrivKey},
    R2A, R3A, Msg) ->
      %%
      RLen = KeyLen + IVLen,
      case Msg of
  