jdbc 7

24
Digital Signatures [email protected]

Upload: tuan-ngo

Post on 10-May-2015

689 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Jdbc 7

Digital Signatures

[email protected]

Page 2: Jdbc 7

Need for digital signatures

are used to digitally sign messages or objects.

Ensuring message content integrity

The signature is appended at the end of message before transmission. If an encrypted message is tampered with, the digital signature becomes invalid.

Verifying the authenticity of the message sender

A digital signature ensures that an encrypted message cannot be deciphered by unintended recipients

Page 3: Jdbc 7

What is a Digital Signature made up of?

are generated by Public Key Cryptography using public and private keys to encrypt and decrypt messages.

Public key

Private key

Page 4: Jdbc 7

Comparing Digital signatures with message digest?

A message digest is a fixed-length result of converting the contents of a message into a hash-like a cyclic redundancy check.

A message digest is appended at the end of a message and transmitted to validate the contents of the original message.

A digital signature differs from a simple message digest in:

A message digest alters the content of a message into a fixed length result. The original message content cannot be recovered from digest.

A message digest does not provide secrecy but a digital signature is encrypted.

Page 5: Jdbc 7

Working of Digital Signatures

Encryption:

Decryption:

Page 6: Jdbc 7

Validating data integrity

No difference between data that is sent and received.

Page 7: Jdbc 7

Drawbacks of digital signatures

Non-Repudiation

If sender lost its private key, the authenticity of all messages having digital signatures using that key would have been compromised.

Time Stamping

do not contain any record of the date and time when a particular document was signed.

Page 8: Jdbc 7

Standards and Features of Digital Certificates

A Digital Certificate is a data structure with a digital signature.

The data structure also contains information like the public key, identity of the key owner and name of certification authority who guarantees the authenticity of the key owner.

A signature is viewed as trusted when it is generated by a Certification Authority (CA) since digitally signed data cannot be altered without detection.

Two types of certification standards:

X.509

PGP (Pretty Good Privacy)

Page 9: Jdbc 7

Verifying the authenticity of the sender

Page 10: Jdbc 7

Verifying the authenticity of the sender

Page 11: Jdbc 7

Verifying the authenticity of the sender

Page 12: Jdbc 7

Verifying the authenticity of the sender

Page 13: Jdbc 7

Verifying the authenticity of the sender

Page 14: Jdbc 7

Digital Keys and Key Store

A digital key is a kind of a password or a passphrase used in cryptography calculations.

A file containing a collection of public and private keys is known as a keystore.

Keystore not only stores the user’s certificate with its public and private keys but also stores other’s certificates with a public key.

Page 15: Jdbc 7

Signing a Jar File

Page 16: Jdbc 7

Verification of Digital Certificate

The recipient receives a signed JAR file and a certificate file containing the public key corresponding to the private key used to sign the JAR file.

Import the certificate as a Trusted Certificate

Verify the JAR file Signature

The imported public key certificate is used to verify

Page 17: Jdbc 7

Verification of Digital Certificate

Page 18: Jdbc 7

Signing and Verifying Data Using Security Tools

Page 19: Jdbc 7

Generating public and private keys

A key pair generated by using the KeyPairGenerator class.

Create a Key-Pair Generator

Initialize the Key-Pair generator

Page 20: Jdbc 7

Digitally signing the data

Get a Signature Object

Initialize the Signature Object

Supply the data to be Signed to the Signature Object

Generate the Signature

Page 21: Jdbc 7

Digitally signing the data

Page 22: Jdbc 7

Digitally signing the data

Page 23: Jdbc 7

Verifying the signature

Page 24: Jdbc 7

Verifying the signature