1

For same chunk of data, which one is faster? Public key encryption or digital signature? Confidentiality is not important. I am trying to achieve non-repudiation for the communication.

Thanks!

1
  • 2
    You're effectively asking what's faster -- a train or going by railroad.
    – mricon
    Commented Jul 1, 2014 at 18:13

3 Answers 3

1

Digital signatures use public key cryptography, so it's not very clear what you're asking. That being said, public key encryption by itself cannot be used for non-repudiation, so you'll always want digital signatures, regardless of which one is faster.

6
  • Thanks! Let me clarify my question.Non-repudiaiton can be achieved through digital certificates and digital signatures both. By certificates, I mean by encrypting whole message with private/public key, and signatures encrypt only hash of message. So my question is that which process is faster?
    – Lokesh
    Commented Jul 1, 2014 at 18:18
  • That's not actually a clarification, as digital certificates are USED to make digital signatures.
    – mricon
    Commented Jul 1, 2014 at 18:20
  • Apologies for the confusion. Let me rephrase. I have 100 MB of data. I can either encrypt it with my private key, or I can generate hash of it. Which process is faster? I have to go through all data in both cases. Hope this clears the problem.
    – Lokesh
    Commented Jul 1, 2014 at 18:22
  • No, that's not what digital certificates are. Digital certificates are just your public keys signed by a certification authority. My answer stands -- in public key cryptography encryption by itself cannot be used for non-repudiation.
    – mricon
    Commented Jul 1, 2014 at 18:22
  • You are still conflating a whole lot of concepts, but let me assure you that you always want to generate a hash. This is how digital signatures work -- a one-way hash of your entire message is computed (e.g. sha256) and then encrypted with your private key. Anyone who has your public key can then verify the message.
    – mricon
    Commented Jul 1, 2014 at 18:26
0

Whatever you use to create a digital signature will actually use a hashing function inside it. The digital certificate itself won't touch the 100 Gig of data, and isn't worth thinking about yet.

What you should care about is the hashing function used to create the hash that the (optional) private key in the certificate will sign. Encryption is probably irrelevant here.

The answer you need is: Use a SHA1 or SHA2 hash over the data.

If you want to see a comparison of various hashing functions, see this. Note that some of those hashing functions listed are insecure for cryptographic purposes and should't be relied upon

0

Using Public Key(of the receiver) to encrypt the content will NOT GIVE YOU Non-Repudiation. It only gives INTEGRITY of the content that you know ONLY the legitimate receiver can read the content.

If you want Non-Repudiation that Sender cannot REPUDIATE that he did not send the content, then you will have to sign the content using Private Key of the Sender(aka Digital Signature). Therefore sender cannot deny NOT sending the data, since the signature can be verified using the sender's public key.

1
  • I suppose by you will have to sign you mean sender will have to sign
    – Tarun
    Commented Apr 12, 2016 at 10:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .