![](https://csdnimg.cn/release/download_crawler_static/9614839/bg14.jpg)
PrefaCe xvii
the Sage cOmPuter algebra SyStem
One of the most important features of this book is the use of Sage for cryptographic exam-
ples and homework assignments. Sage is an open-source, multiplatform, freeware package that
implements a very powerful, flexible, and easily learned mathematics and computer algebra
system. Unlike competing systems (such as Mathematica, Maple, and MATLAB), there are
no licensing agreements or fees involved. Thus, Sage can be made available on computers and
networks at school, and students can individually download the software to their own personal
computers for use at home. Another advantage of using Sage is that students learn a powerful,
flexible tool that can be used for virtually any mathematical application, not just cryptography.
The use of Sage can make a significant difference to the teaching of the mathematics of
cryptographic algorithms. This book provides a large number of examples of the use of Sage
covering many cryptographic concepts in Appendix B, which is included in this book.
Appendix C lists exercises in each of these topic areas to enable the student to gain
hands-on experience with cryptographic algorithms. This appendix is available to instruc-
tors at the IRC for this book. Appendix C includes a section on how to download and get
started with Sage, a section on programming with Sage, and exercises that can be assigned to
students in the following categories:
• Chapter 2—Classical Encryption: Affine ciphers and the Hill cipher.
• Chapter 3—Block Ciphers and the Data Encryption Standard: Exercises based on
SDES.
• Chapter 4—Basic Concepts in Number Theory and Finite Fields: Euclidean and
extended Euclidean algorithms, polynomial arithmetic, and GF(24).
• Chapter 5—Advanced Encryption Standard: Exercises based on SAES.
• Chapter 6—Pseudorandom Number Generation and Stream Ciphers: Blum Blum
Shub, linear congruential generator, and ANSI X9.17 PRNG.
• Chapter 8—Number Theory: Euler’s Totient function, Miller Rabin, factoring, modu-
lar exponentiation, discrete logarithm, and Chinese remainder theorem.
• Chapter 9—Public-Key Cryptography and RSA: RSA encrypt/decrypt and signing.
• Chapter 10—Other Public-Key Cryptosystems: Diffie-Hellman, elliptic curve.
• Chapter 11—Cryptographic Hash Functions: Number-theoretic hash function.
• Chapter 13—Digital Signatures: DSA.
Online DOcumentS FOr StuDentS
For this new edition, a tremendous amount of original supporting material for students
has been made available online, at two Web locations. The Companion Web site, at
WilliamStallings.com/Cryptography (click on Student Resources link), includes a list of rel-
evant links organized by chapter and an errata sheet for the book.
Purchasing this textbook new also grants the reader six months of access to the Premium
Content site, which includes the following materials:
• Online chapters: To limit the size and cost of the book, four chapters of the book
are provided in PDF format. This includes three chapters on computer security