2
$\begingroup$

I am working on a portable secure chat via desktop or mobile, which adopts OTP plus asymmetric encryption. The idea goes like this:

Suppose that Alice and Bob are clients, and the server is run by Steve. Steve generates the server private/public key pair, while Alice and Bob generates their client key pairs`. For each message, the client generates a random AES key for encrypting that specific message, that is then encrypted with the server's public key. The client also signs the message with its private key as well. The server decrypts such message, encrypts it with the public key of every online client, and broadcasts it to them.

Is there any problem with CPU load on the server or client, or problem with security breaches happening during message transfer, or is this idea just useless and needs to be scrapped? The ECC keypair would be 521 bits, while the AES key would be 256 bits.

$\endgroup$
5
  • 2
    $\begingroup$ Any particular reason for not using TLS (which does much of the same thing)? $\endgroup$ Jun 6 at 16:14
  • $\begingroup$ @EugeneStyer I want this chat application to run on a port other than 443 or 8080, therefore TLS might be unusable. $\endgroup$
    – Red Sun
    Jun 6 at 22:25
  • 2
    $\begingroup$ Port 443 is used for HTTPS (which uses TLS), but TLS itself is not limited to those ports. You can specify the port # to be used when you create the TLS/SSL socket. $\endgroup$ Jun 7 at 2:44
  • $\begingroup$ What use were you going to make of OTPs? $\endgroup$
    – Paul Uszak
    Jun 7 at 20:19
  • $\begingroup$ @PaulUszak I am going to encrypt each message with a different random AES key. That's what I mean for OTP. $\endgroup$
    – Red Sun
    Jun 8 at 15:20
1
$\begingroup$

I refer to your own answer.

using TLS is good enough

Is there any problem with ...snip... security breaches happening during message transfer,

Well yes, there is a problem. Have you understood the implication of @forest 's cryptic comment? E2E = end to end. À la Signal.

With TLS, client/server messaging will be encrypted, but the messages will be plaintext as they pass through the server. That means anyone with physical/judicial access to the server will be able to read all the messages. And initiate Man in the Middle attacks. Read about all the troubles with Blackberry phones.

It's all about what you want to achieve, and some of that can be troublesome.

$\endgroup$
0
$\begingroup$

So I have found the answer. The answer provided in the comment by Eugene Styer states that just using TLS is good enough, as TLS is not limited to a specific port.

$\endgroup$
2
  • $\begingroup$ Well, it certainly won't be E2E... $\endgroup$
    – forest
    Jun 8 at 0:31
  • 1
    $\begingroup$ @forest: The question does not describe an end-to-end system either $\endgroup$
    – Ben Voigt
    Jun 10 at 15:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.