Example of DSA Key Parameters and Properties

This section provides 2 DsaKeyChecker.java output examples to show DSA key parameters and properties.

Let's compile and run DsaKeyChecker.java on my first DSA key pair, dsa_512.pub and dsa_512.pri, generated in the previous tutorial:

C:\herong>javac DsaKeyChecker.java

C:\herong>java DsaKeyChecker dsa_512

DSA Key Parameters:
p = 13232376895198612407547930718267435757728527029623408872245156039
q = 857393771208094202104259627990318636601332086981
g = 54216440574364751416096484883257051280474283943804743768346673007
x = 792647853324835944125296675259316105451780620466
y = 10783827985936883407800478884376885258012329124816552994400318669

DSA Key Verification:
What's key size? 512
Is p a prime? true
Is q a prime? true
Is p-1 mod q == 0? 0
Is g**q mod p == 1? 1
Is q > x? true
Is g**x mod p == y? true

The output looks good. The key size is 512 bits, measured by the number of bits of the prime modulus "p".

Below the output on my second DSA key pair, dsa_1024.pub and dsa_1024.pri:

C:\herong>java DsaKeyChecker dsa_1024

DSA Key Parameters:
p = 17801190547854226652823756245015999014523215636912067427327445031
q = 864205495604807476120572616017955259175325408501
g = 17406820753240209518581198012352343653860449079456135097849583104
x = 774290984479563168206130828532207106685994961942
y = 11413953692062257086993806233172330674938775529337393031977771373

DSA Key Verification:
What's key size? 1024
Is p a prime? true
Is q a prime? true
Is p-1 mod q == 0? 0
Is g**q mod p == 1? 1
Is q > x? true
Is g**x mod p == y? true

Table of Contents

 About This Book

 Cryptography Terminology

 Cryptography Basic Concepts

 Introduction to AES (Advanced Encryption Standard)

 Introduction to DES Algorithm

 DES Algorithm - Illustrated with Java Programs

 DES Algorithm Java Implementation

 DES Algorithm - Java Implementation in JDK JCE

 DES Encryption Operation Modes

 DES in Stream Cipher Modes

 PHP Implementation of DES - mcrypt

 Blowfish - 8-Byte Block Cipher

 Secret Key Generation and Management

 Cipher - Secret Key Encryption and Decryption

 Introduction of RSA Algorithm

 RSA Implementation using java.math.BigInteger Class

 Introduction of DSA (Digital Signature Algorithm)

Java Default Implementation of DSA

 DsaKeyGenerator.java - Generating DSA Key Pair

 DSA 512-bit and 1024-bit Key Pair Examples

 DsaKeyChecker.java - Reading and Checking DSA Keys

Example of DSA Key Parameters and Properties

 java.security.Signature - The Data Signing Class

 DsaSignatureGenerator.java - Generating DSA Digital Signature

 DsaSignatureGenerator.java Test Results

 DsaSignatureVerifier.java - Verifying DSA Digital Signature

 DsaSignatureVerifier.java Test Results

 Private key and Public Key Pair Generation

 PKCS#8/X.509 Private/Public Encoding Standards

 Cipher - Public Key Encryption and Decryption

 MD5 Mesasge Digest Algorithm

 SHA1 Mesasge Digest Algorithm

 OpenSSL Introduction and Installation

 OpenSSL Generating and Managing RSA Keys

 OpenSSL Managing Certificates

 OpenSSL Generating and Signing CSR

 OpenSSL Validating Certificate Path

 "keytool" and "keystore" from JDK

 "OpenSSL" Signing CSR Generated by "keytool"

 Migrating Keys from "keystore" to "OpenSSL" Key Files

 Certificate X.509 Standard and DER/PEM Formats

 Migrating Keys from "OpenSSL" Key Files to "keystore"

 Using Certificates in IE

 Using Certificates in Google Chrome

 Using Certificates in Firefox

 Outdated Tutorials


 Full Version in PDF/EPUB