1. How secure is the chat? I've read that it is encrypted, but can someone explain to me how that is done? Especially with chatpartners on different hubs.
Can the hub read the messages or even decide that chats are not encrypted? I mean they could change the code before they open the gates, without people realizing it.
And what kind of encryption is used?
It's end-to-end encrypted using AES. The hubs only forward the encrypted messages, they can't see anything. To deliver your message, your wallet connects to the recipient's hub (if it's different from your home hub).
The encryption keys are constantly rotated for
perfect forward secrecy. This has a side effect that if you restore from an old backup or try to use the same wallet on two devices (which rotate the keys independently), the keys get out of sync and your wallet can't decrypt a received message. This is one of the common reasons for not receiving blackbytes, which are delivered through chat messages.