Kcl.State.new_peer

You're seeing just the function new_peer, go back to Kcl.State module for more information.
Link to this function

new_peer(state, their_public)

View Source

Specs

new_peer(t(), Kcl.key()) :: t() | :error

update the state for a new peer

The shared secret is computed from the state and new peer public key. The previous_nonce value is also reset to 0.