0

The RSA key for example, can generate the public key from the private key, which is possible to encrypt a message with the private key. What I am trying to achieve is this:

  • A encrypts a message using B's public key,
  • B decrypts the message using its private key, but cannot encrypt a message and decrypt it by itself using its private key.

This is useful for validating that the message was sent by A.

3

This is useful for validating that the message was sent by A.

It would prove only that the message was sent by someone who has the B's public key. It's not only A, but since the key is public, it's everyone.

B [ ] cannot encrypt a message and decrypt it by itself using its private key.

Yes. Technically B cannot encrypt the message using their private key and decrypt it using the same private key. But B can encrypt the message using B's public key, since it's public.

1

Validating that A sent the message isn't the encryption objective. We use encryption for confidential data, it doesn't matter the data have been changed or not.

What you mentioned by (Validating) is the Digital Signature purpose, in other words (Integrity and identity), Because digital signature depends on the sender private key. And so, just the sender can apply the signature. if the content (data) is modified, the signature will be invalid.

Therefore, if A added the digital signature for his message, B can easily validate A's message using A's Public Key.

Check this link for more information.

  • this is a good answer. Digital sign (encrypt with private key) is used to prove the author of a message. – robob Dec 27 '16 at 6:41

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.