\newacronym{AEAD}{AEAD}{Authenticated Encryption with Associated Data}
\newacronym{AES}{AES}{Advanced Encryption Standard}
\newacronym{BEAST}{BEAST}{Browser Exploit Against SSL/TLS}
\newacronym{CBC}{CBC}{cipher block chaining}
\newacronym{CDN}{CDN}{content distribution network}
\newacronym{CSPRNG}{CSPRNG}{cryptographically secure pseudorandom number generator}
\newacronym{CSRF}{CSRF}{\gls{cross-site request forgery}}
\newacronym{DES}{DES}{Data Encryption Standard}
\newacronym{FIPS}{FIPS}{Federal Information Processing Standards}
\newacronym{GCM}{GCM}{Galois Counter Mode}
\newacronym{HKDF}{HKDF}{HMAC-based (Extract-and-Expand) Key Derivation Function}
\newacronym{HMAC}{HMAC}{Hash-based Message Authentication Code}
\newacronym{HSTS}{HSTS}{HTTP Strict Transport Security}
\newacronym{IV}{IV}{\gls{initialization vector}}
\newacronym{KDF}{KDF}{key derivation function}
\newacronym{MAC}{MAC}{message authentication code}
\newacronym{MITM}{MITM}{man-in-the-middle}
\newacronym{OCB}{OCB}{offset codebook}
\newacronym{OTR}{OTR}{off-the-record}
\newacronym{PRF}{PRF}{pseudorandom function}
\newacronym{PRNG}{PRNG}{pseudorandom number generator}
\newacronym{PRP}{PRP}{pseudorandom permutation}
\newacronym{RSA}{RSA}{Rivest Shamir Adleman}

\newglossaryentry{secret-key encryption}{
  name=secret-key encryption, description={Encryption that uses the
  same key for both encryption and decryption. Also known as
  symmetric-key encryption. Contrast with \gls{public-key encryption}}
  }
\newglossaryentry{symmetric-key encryption}{
  name=symmetric-key encryption, description={See \gls{secret-key
  encryption}}}
\newglossaryentry{keyspace}{
  name=keyspace, description={The set of all possible keys}}
\newglossaryentry{block cipher}{
  name=block cipher, description={Symmetric encryption algorithm that
  encrypts and decrypts blocks of fixed size}, }
\newglossaryentry{substitution-permutation network}{
  name=substitution-permutation network, description={Generic design
  for block ciphers where the block is enciphered by repeated
  substitutions and permutations} }
\newglossaryentry{stream cipher}{
  name=stream cipher, description={Symmetric encryption algorithm that
  encrypts streams of arbitrary size} }
\newglossaryentry{mode of operation}{
  name=mode of operation, description={Generic construction that
  encrypts and decrypts streams, built from a block
  cipher},plural=modes of operation }
\newglossaryentry{ECB mode}{
  name=ECB mode, description={Electronic code book mode; mode of
  operation where plaintext is separated into blocks that are
  encrypted separately under the same key. The default mode in many
  cryptographic libraries, despite many security issues} }
\newglossaryentry{CBC mode}{
  name=CBC mode, description={Cipher block chaining mode; common mode
  of operation where the previous ciphertext block is XORed with the
  plaintext block during encryption. Takes an initialization vector,
  which assumes the role of the \enquote{block before the first
  block}}}
\newglossaryentry{initialization vector}{
  name=initialization vector, description={Data used to initialize
  some algorithms such as \gls{CBC mode}. Generally not required to be
  secret, but required to be unpredictable.
  Compare \gls{nonce}, \gls{salt}} }
\newglossaryentry{CTR mode}{
  name=CTR mode, description={Counter mode; a \gls{nonce} combined
  with a counter produces a sequence of inputs to the block cipher;
  the resulting ciphertext blocks are the keystream} }
\newglossaryentry{nonce}{
  name=nonce, description={\emph{N}umber used \emph{once}. Used in
  many cryptographic protocols. Generally does not have to be secret
  or unpredictable, but does have to be unique.
  Compare \gls{initialization vector}, \gls{salt}} }
\newglossaryentry{AEAD mode}{
  name=AEAD mode, description={Class of \gls{block cipher} \glspl{mode
  of operation} that provides authenticated encryption, as well as
  authenticating some unencrypted associated data}}
\newglossaryentry{OCB mode}{
  name=OCB mode, description={Offset codebook mode;
  high-performance \gls{AEAD mode}, unfortunately encumbered by
  patents} }
\newglossaryentry{GCM mode}{
  name=GCM mode, description={Galois counter mode; \gls{AEAD mode}
  combining \gls{CTR mode} with a \gls{Carter-Wegman MAC}}}
\newglossaryentry{message authentication code}{
  name=message authentication code, description={Small piece of
  information used to verify authenticity and integrity of a message.
  Often called a tag}}
\newglossaryentry{one-time MAC}{
  name=one-time MAC, description={\Gls{message authentication code}
  that can only be used securely for a single message. Main benefit is
  increased performance over re-usable \glspl{MAC}}}
\newglossaryentry{Carter-Wegman MAC}{
  name=Carter-Wegman MAC, description={Reusable \gls{message
  authentication code} scheme built from a \gls{one-time MAC}.
  Combines benefits of performance and ease of use}}
\newglossaryentry{GMAC}{
  name=GMAC, description={\Gls{message authentication code}
  part of \gls{GCM mode} used separately}}
\newglossaryentry{salt}{
  name=salt, description={Random data that is added to a cryptographic
  primitive (usually a one-way function such as a cryptographic hash
  function or a key derivation function) Customizes such functions to
  produce different outputs (provided the salt is different). Can be
  used to prevent e.g. dictionary attacks. Typically does not have to
  be secret, but secrecy may improve security properties of the
  system. Compare \gls{nonce}, \gls{initialization vector}} }
\newglossaryentry{public-key algorithm}{
  name=public-key algorithm, description={Algorithm that uses a pair
  of two related but distinct keys. Also known
  as \glspl{asymmetric-key algorithm}. Examples
  include \gls{public-key encryption} and most \gls{key exchange}
  protocols} }
\newglossaryentry{asymmetric-key algorithm}{
  name=asymmetric-key algorithm, description={See \gls{public-key
  algorithm}} }
\newglossaryentry{public-key encryption}{
  name=public-key encryption, description={Encryption using a pair of
  distinct keys for encryption and decryption. Also known as
  asymmetric-key encryption. Contrast with \gls{secret-key
  encryption}} }
\newglossaryentry{asymmetric-key encryption}{
  name=asymmetric-key encryption, description={See \gls{public-key
  encryption}} }
\newglossaryentry{key exchange}{
  name=key exchange, description={The process of exchanging keys
  across an insecure medium using a particular cryptographic protocol.
  Typically designed to be secure against eavesdroppers. Also known
  as key agreement} }
\newglossaryentry{key agreement}{
  name=key agreement, description={See \gls{key exchange}}}
\newglossaryentry{oracle}{
  name=oracle, description={A \enquote{black box} that will perform
  some computation for you}}
\newglossaryentry{encryption oracle}{
  name=encryption oracle, description={An \gls{oracle} that will
  encrypt some data}}
\newglossaryentry{OTR messaging}{
  name=OTR messaging, description={Off-the-record messaging, messaging
  protocol that intends to mimic the properties of a real-live private
  conversation. Piggy-backs onto existing instant messaging
  protocols}}
\newglossaryentry{cross-site request forgery}{
  name=cross-site request forgery, description={Kind of attack where a
  malicious website tricks the browser into making requests to another
  website. Can be prevented by properly authenticating requests
  instead of relying on ambient authority such as session cookies}
}
