Finalize protocol encryption.

Signed-off-by: Karang <arthur.hennequin@free.fr>