Cryptography
Cryptography
Understanding Cryptography
and PKI
CompTIA Security+
Get Certified Get Ahead
By Darril Gibson
• To verify integrity
– MD5 (use is discouraged)
– SHA (SHA-3 previously known as Keccak)
• Brute force
– Attempts to guess all possible character
combinations
• Salting passwords
– Prevent rainbow table attacks, along with other
password attacks
• Key stretching
– Used to increase the strength of stored passwords
(Bcrypt, PBKDF2, and Argon2)
GetCertifiedGetAhead.com © 2021 YCDA, LLC
– Key
• A number that provides variability
• Either kept private and/or changed frequently
• Decryption algorithm
– Move back ____ spaces to decrypt
– For example, move back 3 spaces to decrypt
• Stream ciphers
– Encrypt data as a single bit or byte at a time in a stream
– An important principle when using a stream cipher
• Encryption keys should never be reused
• If a key is reused, it is easier to crack the encryption
GetCertifiedGetAhead.com © 2021 YCDA, LLC
• 3DES
– 64-bit block cipher
• Used for
– Encryption
– Authentication
– Digital signatures
– Serial number
– Issuer
– Validity dates
– Subject
– Public key
– Usage
GetCertifiedGetAhead.com © 2021 YCDA, LLC
• Lightweight Cryptography
– Deployed to smaller devices (RFID tags, sensor
nodes, smart cards, IoT devices)
GetCertifiedGetAhead.com © 2021 YCDA, LLC
• Modes of operation
– Authenticated, counter, and unauthenticated
• Steganography
– Audio, image, video steganography
GetCertifiedGetAhead.com © 2021 YCDA, LLC
I passed! I passed!
Digital Digital
Signature Signature
Lisa Bart
Hash of message Encrypted hash
encrypted with decrypted with
sender’s private key sender’s public key
– SSL deprecated
– Both require certificates issued by CAs
Server responds
with certificate
Encrypting
3 4 5
HTTPS
Client creates Encrypted Server decrypts
traffic with symmetric key symmetric key symmetric key
and encrypts it sent to server with private key
TLS with public key
UcaNP@$$
6
The session is encrypted
with the session key using
symmetric encryption
Other Cryptographic Protocols
• Blockchain
– Public record-keeping technology
– Distributed, decentralized, public ledger
• Crypto Diversity
– Using different methods to protect security keys
• Use cases
• Updating certificates
• Revoked certificates
– Revoked by serial number
– Published in Certificate Revocation List (CRL)
– Publicly available
GetCertifiedGetAhead.com © 2021 YCDA, LLC
Certificate Revocation List
• Issued in a
version 2
certificate
CRL
4
OCSP Stapling
CA