Public-Key Encryption and Discrete Logarithm Problems 173 Discrete Logarithm Problems 174 Encryption and Decryption in ElGamal Encryption 176 The Extended Euclidean Algorithm 181 Calculating the Private Key in RSA Key Generation 182 4 Practical Applications of Encryption 185 Hybrid Encryption 186 Hash Functions and Message Authentication Codes 190 Falsification 190 Tampering Countermeasures 192 Hash Functions 193 Identity Fraud 194 Identity Fraud Countermeasures 195 Structure of Message Authentication Codes 196 Repudiation 197 Drawbacks of Message Authentication Codes 199 Digital Signatures 200 Repudiation Measures 200 The Workings of a Digital Signature 201 Man-in-the-Middle Attack 203 Using Certificates to Protect Against Man-in-the-Middle Attacks 204 Public-Key Infrastructure 206 Zero-Knowledge Interactive Proof 217 Preparatory Stage 217 Implementation Stage Verification Process 218 Methods of Identity Fraud 220 Anti-Identity Fraud in a Zero-Knowledge Interactive Proof 222 What Next 224 Pseudorandom Numbers and Encryption Security 224 PGP 224 SSL TLS 225 Quantum Cryptography 225 Biometrics 225 Index 227 Contents
Preface When thinking about information societies which rely on networks that function function with the internet at their core we can see how many aspects of our lives have become more convenient In addition to now being able to search for information on the web and communicate via email other network services like online shopping and internet banking have become widespread While the age of networking comes with many benefits we also encounter phrases like safe and secure information security protection of personal information encryption and so on that have a somewhat unpleasant ring to them These words are everywhere not a day goes by without seeing them Why is such talk so prevalent Networks require a variety of information to be exchanged and this includes information that could cause problems when in the hands of others and information that we wish to keep secret We must take measures to protect information in order to prevent important data such as our credit card numbers bank account numbers medical histories loan debts and email addresses from easily leaking to outsiders This information can be abused and as such there is no doubt that protecting information is the most important issue that faces us in the age of networking In our connected society where there are so many unreliable factors the ability to distinguish authentic information and provide protection from dangers such as fraud forgery revision and interception is crucial Cryptography is the core technology we use to create network services that the public can use safely Cryptographic technology has evolved rapidly in recent years It is no longer longer just the domain of information security specialists and is now necessary knowledge for the users themselves who up until now have used convenient network services without a thought So how then does cryptography work How does it actually provide information information security and protect personal information Using manga this book explains how cryptography works and what it does The complex math is broken down into friendly explanations We’ve done our best to make this an effortless learning experience where you can enjoy the story Of course there are also ciphertexts worked into the story so do your best to decipher them while having fun By the time you’ve finished reading this book you’ll no doubt have a thorough understanding of the fundamentals of cryptography and security Lastly we’d like to express our most sincere gratitude to those who helped us publish this book first to the folks at Ohmsha Ltd and also to Mr Idero Hinoki who provided the illustrations Masaaki Mitani and Shinichi Sato April 2007