Small improvement

Part of the private chat branch is adopted, the messages beeing sent
from private chat yet need to be encrypted.