Cryptographic Applications Overview
Cryptographic Applications Overview
Presented by,
Lavanya V
Asst. Prof ,ECE Dept
• In this chapter, we’ll look at how cryptography is used in real life through some
applications.
• The main purpose is not just to see the applications but to understand how choices
were made when applying cryptography.
• And we’ll notice that,
-Not all decisions were perfect, at first mistakes or weaker choices were
sometimes made.
-Many decisions are trade-offs; balancing things like security, cost, speed &
convenience.
• The applications chosen are different from each other so we can see different
kinds of decisions in different environment.
The chosen applications are:-
1. Cryptography on the internet(for securing the internet).
2. Cryptography for wireless local area network.
3. Cryptography for mobile telecommunication.
4. Cryptography for secure payment card transaction.
5. Cryptography for video broadcasting.
6. Cryptography for identity cards.
1. Cryptography on the internet
• Cryptography is widely used on the Internet, and one of the most famous
examples is SSL (Secure Sockets Layer).
• SSL is one of the top three important protocols that help create a secure
connection over a network.
• The Internet works in four layers (called the Internet Protocol Suite).
• SSL works at the Transport Layer (this layer is responsible for end-to-end
communication between devices).
• But secure connections can also be made at other layers:
-Application Layer → using SSH (Secure Shell).
-Internet Layer → using IPsec (Internet Protocol Security).
SSL(Secure Sockets Layer) – Concepts and Issues
• SSL background
• SSL security requirements
• Cryptography used in SSL
• SSL protocols
• SSL key management
• SSL security issues
• SSL design issues
➢ SSL Background
• When data is sent through a secure channel, only the sender & the receiver can
read it.
• Even if a hacker is watching the communication they cannot understand or access
the data.
➢Data origin authentication:
• It ensures the data really comes from the person or system it's supposed to.
• This prevents attackers from sending fake or tampered messages pretending to be
someone else.
➢Entity authentication:
• Before communication begins, both parties (like your browser and the server)
need to prove who they are.
• This helps prevent imposters from joining the connection.
❑Hence, SSL only protects the link between your browser & the web server.
❑If the web server then sends your data to another place, that second transfer also
needs its own security.
➢ Cryptography used in SSL
• SSL is made for situations where two parties don’t know each other beforehand &
haven’t shared any secret keys, they can quickly create a secure connection.
-> Like, when you buy something from a new online store you just found that
even though you’ve never talked to them before, SSL makes sure you can safely
send your payment details.
• SSL uses a mix of different cryptographic techniques (this is called hybrid
encryption) to keep data secure.
Here are the main cryptographic tools used:
• Public-key cryptography – used to safely exchange keys.
• Digital signatures – used to verify identities and sign certificates.
• Symmetric encryption – keeps the actual data private.
• MACs (Message Authentication Codes) – ensure data comes from the right
source and wasn’t changed.
• Hash functions – used in MACs, digital signatures, and for making secure keys.
In SSL, different websites, servers & clients may prefer different security
algorithms. So SSL is flexible – it supports many options
Flexibility in SSL
• Different systems (like browsers or servers) might prefer different algorithms or
key sizes.
• So, SSL supports many types of algorithms, for example:
❑Block Cipher(like AES) (a strong block cipher, often used in CBC mode)
-for authentication
• At start of an SSL session, both sides negotiate & agree on which set of algorithms
to use, this chosen set is called a cipher suite.
What is a Cipher Suite?
• When an SSL connection starts, both sides agree on which algorithms to use (like
which type of encryption, signature, etc.).
-> Think of it like two people deciding on a language to talk in before
starting a connection – once agreed, they stick with it.
➢ SSL Protocols
• SSL essentially consists of two cryptographic protocols:
1. Handshake protocol
2. Record protocol
➢Handshake Protocol:
This protocol performs all the tasks that require agreement between the two
entities before they set up the secure SSL channel. In particular, this protocol can be
used to:
• agree on the cryptographic algorithms to be used to establish the securechannel;
• establish entity authentication;
• establish the keys that will be needed to secure the channel.
➢Record Protocol: This protocol implements the secure channel.
-This includes:
• formatting the data (for example, breaking it up into blocks);
• computing MACs on the data;
• encrypting the data.
➢SIMPLE SSL HANDSHAKE PROTOCOL DESCRIPTION
• This message from the client initiates the communication session and requests the establishment
of an SSL-protected channel.
• As part of this request message, the client sends some data, including:
-Session ID-acts as a unique identifier for the session
-pseudorandom number (rC) - ensures freshness (rC- unencrypted)
-List of supported cipher suites
➢ Server Response:
• The client computes a MAC on the hash of all the messages sent so far.
• This MAC is then encrypted and sent to the server.
➢Server Finished:
Where?
Browsers like Chrome, Firefox, Safari, etc.
How?
• When you visit [Link] the browser and the website perform an SSL
handshake.
• Ensures that your data (login, payment info, messages) is encrypted.
Real Example: Logging in to your online banking site.
➢Online Shopping / E-Commerce:
Where?
• Sites like Amazon, Flipkart, etc.
How?
• SSL handshake secures payment info when you enter credit card details.
• Ensures the server is authentic (you’re not on a phishing site).
Real Example: Entering credit card info during checkout.
SSL RECORD PROTOCOL
Purpose:
SSL Record Protocol secures communication after the SSL Handshake is complete.
• Here, both client and server derive cryptographic data needed for secure
communication (encryption & MAC keys).
• This includes:
-Symmetric session keys (for encryption/decryption).
-Symmetric MAC keys (for integrity check).
-IVs (Initialization Vectors, if needed).
• These are all generated using a key derivation function to compute a key block.
Key Block Generation:
• A key derivation function is used to generate a key block using:
-Master key-KM
-Random values- rC & rS
• It produces a key block.
• The block is divided into four keys:
-KECS: encryption(client->server)
-KESC: encryption(server->client)
-KMCS: MAC(client->server)
-KMSC: MAC(server->client)
How Messages Are Sent (Client → Server)
1)MAC Creation
Client makes a MAC (Message Authentication Code) on the data using key KMCS.
This ensures integrity (server can later check if data is unchanged).
2) Attach MAC and Pad
The MAC is attached to the original data.
Padding is added(if needed) so the size fits encryption block length.
3)Encrypt
The final data(original message + MAC + padding) is encrypted using key KECS
How Messages Are Received (Server Side)
1)Decrypt
Server decrypts the message using KECS.
2) Verify MAC
Server checks the MAC with key KMCS.
If the MAC matches -> data is correct & unmodified.
• These two systems are not totally separate – they overlap in the key management
lifecycle.
• Public keys help to exchange or agree on symmetric keys.
• Then symmetric keys handle fast, secure data transfer.
->Key generation:
Two types of keys are used in SSL:
• Asymmetric keys → Generated using public-key systems (e.g., RSA). Not defined
by SSL itself.
• Symmetric keys → Created inside SSL, these are the session keys derived from a
master secret.
Key Derivation (how session keys are made from master secret):
• Lightweight method → does not need heavy computation.
• From one master secret, many different session keys can be generated.
• Saves cost → Public-key cryptography is expensive, so one master secret can be
reused to derive multiple keys efficiently.
Master Secret Generation:
• Depends on the client to generate a pre-master secret (random number).
• If the client fails to generate it securely, all session keys can be compromised.
Key Lengths:
• The size of the keys (e.g., 128-bit, 256-bit) is negotiable.
• Final key agreement is done during the SSL Handshake Protocol.
->Key establishment:
• The main goal is to establish a pre-master secret using the SSL Handshake
Protocol.
• Usually done with RSA public-key encryption.
• SSL also supports Diffie–Hellman for key establishment.
->Key storage:
Both client and server must securely store private keys.
• These are the most critical since they are used across many sessions.
Session keys (symmetric keys) from the SSL Handshake are temporary.
• Used only for one session.
• If compromised, only that session is affected.
->Key usage:
SSL follows the idea of key separation:
• Different keys are derived from the master secret for encryption and MAC
(Message Authentication Code).
• This ensures better security for the communication channel.
SSL improves security further by:
• Using different keys for each communication direction (client → server and
server → client).
• Prevents reflection attacks.
Trade-off in SSL:
• For convenience, the master secret (Km) is used for two purposes:
-As a key derivation key.
-As a MAC key.
• This slightly breaks the rule of full key separation but is considered practical.
➢SSL security issues
• SSL is a popular communication protocol and is generally regarded as
cryptographically ‘strong’ if used with respected cryptographic algorithms.
• Most security problems experienced using recent versions of SSL have arisen from
aspects that are beyond the scope of the protocol specification.
These include:
1. Process failures.
2. Implementation failures
3. Key management failures.
4. Usage failures.
➢Process Failures
• SSL relies on checking the server's public key to ensure it’s trustworthy.
• Often users ignore browser warnings about unverified certificates.
• Hackers can exploit this by using fake certificates pretending to be real websites.
• Even if the certificate is verified, if it's for the wrong server, users might still trust it
• This is a phishing risk, where attackers trick users into thinking the site is
legitimate.
Important Note: This is not a flaw in SSL itself, but a failure in how it’s used.
➢Implementation Failures
• SSL is flexible in how it is used and how it's built into systems.
• It can support:
-One-way authentication (server only)
-Two-way authentication (server and client).
• This flexibility helps it fit many different applications and environments.
➢Minimal Use of Public-Key Operations
• In SSL, the client does more work than the server during setup.
• Example:
-The client encrypts a key (using public key encryption).
-The server decrypts it (using private key decryption).
• Some algorithms (like RSA) are harder to decrypt than encrypt.
• Some algorithms (like RSA) are harder to decrypt than encrypt.
SSL was carefully designed to:
• Be widely usable and trusted,
• Work in many environments,
• Use public-key cryptography only when needed,
• And shift more work to clients to reduce server load.
2) Cryptography for wireless local area networks
• Wireless networks need strong security → Because they send data over radio
waves, anyone nearby can try to intercept or attack them. This makes them more
vulnerable than wired networks.
• Design mistakes happened → When creating some wireless security standards,
errors were made in how cryptography (the math used to protect data) was
applied.
• Result -> these mistakes made wireless networks weaker than expected and open
to attacks
• WLAN background
• WLAN security requirements
• WEP(Wired Equivalent Privacy)
• Attacks on WEP
• WPA and WPA2 (Wi-Fi Protected Access)
• WLAN security issues
• WLAN design issues
1) WLAN background
• Wireless networks send data through the air → anyone nearby can listen or attack
without needing physical access.
• Benefits of Wireless Communication
• Main advantage: Convenience – no messy wiring needed.
• Can set up networks easily in homes, offices, and public places (cafes, stations, etc)
• Devices can connect without physical restrictions.
Weakness of Wireless Networks
• Without built-in security, wireless data can be intercepted and modified.
• Unlike wired, attackers don’t need to enter the building – they just need to be
within range.
Wireless Local Area Network (WLAN)
• WLAN is a type of wireless network typically used at home/office
• Governed by IEEE 802.11 standards (commonly called Wi-Fi).
• Devices certified to meet these standards are labeled as Wi-Fi.
Simple WLAN Architecture
• A wireless access point (AP): connects wireless devices to the wired network (e.g.,
internet).
• Devices: laptops, PCs, PDAs, or any gadget with a wireless network card.
• Multiple devices can connect to one access point, or multiple access points can be
used.
These issues are not just about practice but also teach important lessons in how
cryptographic design errors can weaken real systems.
2) WLAN security requirements
The scope of the security requirements for a WLAN are defined by the notion that;
• WLANs should be as secure as wired networks.
• This is tricky because wireless and wired networks are very different.
• Still, this idea is used as a security target to guide design.
Because, even wired networks are not fully protected from DoS (e g:cutting a
cable)
Key Security Requirements for WLANs
Confidentiality:
• The receiver should know that the data really came from the right sender.
• Prevents attackers from modifying or injecting fake data after the connection
starts.
• Problem: The old WEP standard only gave weak integrity protection, which was not
secure enough.
WLANs should protect data privacy, confirm the identity of devices, and ensure
that data really comes from the right source.
Early standards like WEP failed at these requirements, making networks vulnerable.
3)WEP
There are three cryptographic design decisions that are common to all of the WLAN
security mechanisms that we discuss:
1) Compatibility across devices
• WLANs use devices from many manufacturers → the cryptography must be widely
available.
• Proprietary algorithms would not be practical.
2) Simplicity(unlike SSL)
• WLANs don’t need the full complexity of SSL.
• Instead of negotiating algorithms each time (like SSL Handshake), WLANs use fixed
algorithms to keep things simple.
3) Speed & Efficiency
• WLANs need to work fast → symmetric cryptography (same key for encryption and
decryption) is better than slower public-key cryptography.
-> However, the cryptographic details of each of the proposed mechanisms vary
considerably.
Hence, the original proposal of WEP, which uses are;
WEP (Wired Equivalent Privacy) used 3 main techniques:
1) Encryption – RC4 stream cipher
• Used to keep data private
• At that time, RC4 was popular(also used in SSL).
• But later, RC4 was found to be weak and not good enough for modern security
2) Integrity – CRC checksum
• Used to check that data was not changed during transmission.
• Problem: CRC is weak → attackers can change the data and then recalculate CRC
easily.
• So it cannot reliably protect data integrity.
3) Authentication – Challenge–response protocol
A simple method to verify identity of devices.
• Provided only basic authentication(not very strong)
CONFIDENTIALITY AND INTEGRITY MECHANISMS IN WEP
Purpose:
• The whole process works because only someone with the correct WEP key K can
encrypt the nonce properly.
• If Alice doesn’t have the key, she can’t respond correctly, so Bob won’t authenticate
her.
• Bob tests Alice by sending a random puzzle. Alice solves it using the secret WEP
key. If Bob verifies the solution, Alice is authenticated.
1) Alice asks to connect
• Alice (the device) sends a request to Bob (the wireless access point) asking to
authenticate.
2) Bob sends a challenge
• Bob sends a random number (called a nonce 𝑟𝐵 )to Alice.
• This is like a puzzle that only someone with the secret key can solve.
3) Alice encrypts the challenge
• Alice uses the WEP key (K) to encrypt the nonce.
• During this process, she also generates an Initialization Vector (IV) which helps in
encryption.
4) Alice sends back encrypted data
• Alice sends Bob both the IV and the encrypted challenge (ciphertext).
5) Bob checks the answer
• Bob uses the same WEP key (K) to decrypt the ciphertext.
• If the decrypted value matches the original nonce 𝑟𝐵 , Bob confirms Alice is genuine.
4) Attacks on WEP(Key Management Weaknesses)
Main Idea:
WEP fails because it uses a weak, shared, and exposed key. Once attackers capture
enough data, they can break the encryption and access the entire wireless network.
• There are several serious problems with WEP key management:
1) Use of a shared fixed key(Single Point of Failure)
2) Exposure of the WEP key
3) No key separation
4) Key length.
1)Use of a shared fixed key.(Single Point of Failure)
• WEP uses one common key 𝐾for the whole Wi-Fi network.
• If the key is leaked from just one device, the entire network security is broken.
2)Exposure of the WEP key
• The WEP key is directly used in encryption.
• Every time authentication happens, parts of the key are exposed.
• This makes it easier for attackers to capture and figure out the key.
3)No key separation
• The same WEP key is used for multiple purposes (authentication, encryption, etc.).
• Good security requires different keys for different tasks, but WEP ignores this.
4) Key length
• The smallest WEP key is only 40 bits, which is too short and can be cracked quickly
with modern computing.
• Even when longer keys are allowed, many WEP systems generate them from user
passwords, which can be weak.
• This reduces the actual security level and makes brute-force attacks easier.
WEP ENTITY AUTHENTICATION WEAKNESSES
1) Rogue Wireless Access Point
• WEP only authenticates from Alice (user/device) to Bob (access point), not the
other way around.
• This is unilateral authentication.
• An attacker can set up a fake access point.
• Alice might connect and authenticate to this rogue access point, thinking it’s
legitimate.
2) Lack of Session Key
• WEP does not generate a new session key during authentication.
• The same key is reused, so authentication is only valid at that moment in time.
• This means an attacker could later hijack the communication session.
3) Keystream Replay Attack
How it works
Thus WEP has provided us with a wide range of valuable cryptographic design
lessons, many of which have wider implications.
5) WPA and WPA2
MUTUAL ENTITY AUTHENTICATION AND KEY ESTABLISHMENT
• WPA/WPA2 use a pairwise master key (PMK) → provides stronger and dynamic
security.
• Alice uses rA, rB, and PMK to derive the same four keys (EK, MK, DEK, DMK).
• She checks Bob’s MAC to confirm Bob knows PMK.
Alice → Bob: