Cryptography is the subfield of cryptology concerned with how to carry out interactions securely in the presence of adversaries. The typical problem is how to send secret messages to someone over an insecure or untrusted medium (such as the Internet, or through the mail).

However cryptography is about much more than simply creating secure ciphers. It also answers questions about how to verify someone's identity (authentication), how groups can share secrets (secret sharing), how to detect and prevent cheating in various situations (voting protocols, traitor detection), data integrity, fault tolerance, and electronic cash to name but a few.

There are three broad classes of cryptographic techniques: classical cryptography, machine cryptography, and modern cryptography.