How to make a End-To-End encryption?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Gamemap

Is it possible to make a end to end encryption in Godot?

I’m trying to make a Chat programm in Godot and want to encrypt the data from programm A over a Server to programm B.
I found the X509 Certificate but this encrypts only the connection between programm A and the Server. (Please tell me if this is wrong.)

EDIT: Could a Enet Mesh (Godot 4.0) help to solve my problem?
EDIT2: I think Crypto.encrypt() and .decrypt() could solve my problem. (Godot 3.4 and 4.0) Is this correct?

I hope someone can help me,