How is Digital Signature used with a Document?

how is digital signature used

A digital signature scheme is primarily a mechanism of making sure the digital documents (such as email, contract documents etc) are not forged in between (integrity) when exchanged between two entities. In addition, it solves the problem of non-repudiation (when a person disagrees that he/she did not sign the document).

A digital signature is nothing but a sequence of numbers which get generated with a document and later used to verify whether the document is signed with the appropriate private key.

Creating a document with a digital signature comprises of the following:

  • Creation of private-public key pair using key generation algorithm. The public key, as per the name, could be shared with the world. The private key remains private to the user.
  • A document signing function which generates the digital signature. The function takes the document and private key as input parameters and generates signature as output.
  • A signature verifying function which ensures that document is signed with an appropriate private key by passing the input parameters as document, signature and public key.

How is Digital Signature created?

The following are the steps for creating a digital signature of a document:

  • A key-generation algorithm is used to create a private-public key pair.
  • The document along with the private key is passed to a mathematical function (signing algorithm). The mathematical function generates a sequence of numbers/characters which represents the digital signature of the document.
  • Alternatively, instead of using the plain document with a private key, the digest of the document along with private key is used to generate the digital signature. The document is passed through a cryptographic hash function which generates the fixed-length digest.

The following diagram depicts the above-mentioned process:

how is digital signature generated

Figure 1. how is digital signature generated

How does the Document with Digital Signature is verified?

The following are the steps for signing the document with digital signature:

  • The document along with digital signature is sent to the other person. In the diagram below, Alice creates a digital signature of the document and sends the document along with the digital signature to Bob. She also shares her public key to the Bob.
  • The other person, Bob in the diagram given below, passes the following to another mathematical function (signature verification algorithm) which returns the response related to whether the document is signed with the same public-private key pair.
    • Document
    • Digital signature
    • Public key
how is digital signature used

Figure 2. How is digital signature used

References

Summary

In this post, you learned about digital signature scheme including how digital signature is created and used.

Did you find this article useful? Do you have any questions or suggestions about this article? Leave a comment and ask your questions and I shall do my best to address your queries.

Ajitesh Kumar
Follow me

Ajitesh Kumar

I have been recently working in the area of Data analytics including Data Science and Machine Learning / Deep Learning. I am also passionate about different technologies including programming languages such as Java/JEE, Javascript, Python, R, Julia, etc, and technologies such as Blockchain, mobile computing, cloud-native technologies, application security, cloud computing platforms, big data, etc. For latest updates and blogs, follow us on Twitter. I would love to connect with you on Linkedin. Check out my latest book titled as First Principles Thinking: Building winning products using first principles thinking. Check out my other blog, Revive-n-Thrive.com
Posted in Cryptography. Tagged with , .

Leave a Reply

Your email address will not be published. Required fields are marked *