FREE E LEARNING PLATFORM • AKTU B.TECH

Cryptography And Network Security

B. TECH (ELECTRONICS AND COMPUTER ENIGNEERING) SEVENTH SEMESTER (DETAILED SYLLABUS) BCIT701Cryptography & Network Security

Download Syllabus PDF Download Lab Manual PDF

Cryptography & Network Security AKTU 2025 Solution

Q.1. Define cryptography and state any two security services.
Answer

Cryptography: Cryptography is the science and practice of securing communication and data by transforming readable information (plaintext) into an unreadable format (ciphertext) using mathematical algorithms and secret keys, ensuring that only authorized parties can reverse the process and read the original message.

Two Security Services:

  • Confidentiality: Ensures that sensitive information is accessible only to authorized users and is protected from passive attacks such as eavesdropping.
  • Data Integrity: Guarantees that received data has not been altered, inserted, deleted, or replayed in an unauthorized manner during transmission.
Q.2. What is the difference between stream cipher and block cipher?
Answer
Parameter Stream Cipher Block Cipher
Unit of Processing Encrypts data one bit or one byte at a time. Encrypts data in fixed-size blocks (e.g., 64-bit or 128-bit).
Speed & Complexity Faster execution and simpler hardware/software implementation. Relatively slower and computationally more complex.
Key Reuse & Diffusion Uses a pseudorandom keystream XORed with plaintext; low diffusion. Reuses the same secret key across blocks; high diffusion and confusion.
Examples RC4, A5/1, ChaCha20. DES, Triple DES (3DES), AES.
Q.3. State Fermat's Little Theorem.
Answer

Statement: If p is a prime number and a is any positive integer not divisible by p (i.e., gcd(a, p) = 1), then a raised to the power (p − 1) is congruent to 1 modulo p.

a^(p − 1) ≡ 1 (mod p)

Alternative Form: For any integer a and prime p, ap ≡ a (mod p).

Q.4. What is the purpose of a digital signature?
Answer

A digital signature is a cryptographic value calculated from the data and a secret key known only to the signer. Its primary purposes are:

  • Authentication: Verifies the identity of the sender who signed the message.
  • Integrity: Proves that the message has not been tampered with after signing.
  • Non-Repudiation: Prevents the sender from falsely denying having sent or signed the message.
Q.5. What is Diffie-Hellman key exchange used for?
Answer

The Diffie-Hellman key exchange is a cryptographic protocol used to allow two communicating parties—who have no prior knowledge of each other—to jointly establish a shared secret key over an insecure public communication channel. This shared secret key is subsequently used to encrypt further communications using a symmetric-key cipher (such as AES).

Q.6. Define Public Key Infrastructure (PKI).
Answer

Public Key Infrastructure (PKI) is a comprehensive set of hardware, software, policies, roles, and procedures required to create, manage, distribute, use, store, and revoke digital certificates and manage public-key encryption. It binds public keys to respective identities of entities (people or organizations) through a trusted third party known as a Certificate Authority (CA).

Q.7. Mention any two functions of a firewall.
Answer
  • Packet Filtering & Access Control: Inspects incoming and outgoing network packets against predefined security rules (IP addresses, ports, protocols) to permit or block traffic.
  • Network Perimeter Isolation & Logging: Acts as a barrier between a trusted internal network and an untrusted external network (Internet) while logging unauthorized access attempts.
Q.8. Explain substitution and transposition ciphers with suitable examples.
Answer

1. Substitution Cipher

In a substitution cipher, each plaintext character, bit, or group of characters is replaced by another character, number, or symbol according to a fixed system or key. The position of characters remains unchanged, while their identities change.

Example (Caesar Cipher with shift key K = 3):
Formula: C = (P + 3) mod 26
Plaintext: HELLO → H(+3)=K, E(+3)=H, L(+3)=O, L(+3)=O, O(+3)=R → Ciphertext: KHOOR.

2. Transposition Cipher

In a transposition cipher, the plaintext characters are not altered; instead, their positions are rearranged (permuted) according to a defined rule or key.

Example (Rail Fence Cipher with depth = 2):
Plaintext: MEET AT DAWN (without spaces: MEETATDAWN)
Row 1: M   E   A   D   W
Row 2:   E   T   T   A   N
Reading row-by-row gives Ciphertext: MEADWETTAN.

Substitution vs Transposition Cipher Diagram
Figure 1: Working Principle of Substitution Cipher vs. Transposition Cipher
Q.9. Explain modular arithmetic and Extended Euclidean Algorithm with example.
Answer

1. Modular Arithmetic

Modular arithmetic is a system of arithmetic for integers where numbers "wrap around" upon reaching a certain value called the modulus (n). For any integer a and positive integer n, a mod n is the remainder when a is divided by n such that 0 ≤ r < n.

  • Addition: [(a mod n) + (b mod n)] mod n = (a + b) mod n
  • Multiplication: [(a mod n) × (b mod n)] mod n = (a × b) mod n
  • Example: 17 mod 5 = 2 (since 17 = 3 × 5 + 2).

2. Extended Euclidean Algorithm

The Extended Euclidean Algorithm not only computes the Greatest Common Divisor gcd(a, b) of two integers a and b, but also finds two integers x and y (Bézout's coefficients) satisfying:

a · x + b · y = gcd(a, b)

When gcd(a, m) = 1, the coefficient x gives the modular multiplicative inverse of a modulo m (i.e., a−1 mod m).

Example: Find the modular inverse of 7 modulo 26 (i.e., 7−1 mod 26).

Step Division (r1 = q × r2 + r) Quotient (q) t = t1 − q × t2
Init r1 = 26, r2 = 7 — t1 = 0, t2 = 1
1 26 = 3 × 7 + 5 3 t = 0 − 3(1) = −3
2 7 = 1 × 5 + 2 1 t = 1 − 1(−3) = 4
3 5 = 2 × 2 + 1 2 t = −3 − 2(4) = −11
4 2 = 2 × 1 + 0 2 t = 4 − 2(−11) = 26

Since r1 = 1, gcd(26, 7) = 1 and t1 = −11. Converting to positive modulo 26: (−11 + 26) mod 26 = 15.
Verification: (7 × 15) mod 26 = 105 mod 26 = 1.

Q.10. Explain authentication requirements and hash functions. Discuss birthday attack.
Answer

1. Authentication Requirements

In network communication, message authentication protects against active attacks such as:

  • Masquerade: Insertion of messages from a fraudulent source.
  • Content Modification: Changing the contents of a message.
  • Sequence Modification: Insertion, deletion, or reordering of messages in a sequence.
  • Timing Modification: Delay or replay of valid messages.
  • Repudiation: Denial of receipt by receiver or denial of transmission by sender.

2. Cryptographic Hash Functions

A hash function H accepts a variable-length block of data M as input and produces a fixed-size hash value (message digest) h = H(M). Key security properties include:

  • Pre-image Resistance (One-way property): Given h, it is computationally infeasible to find M such that H(M) = h.
  • Second Pre-image Resistance: Given M1, it is computationally infeasible to find M2 ≠ M1 such that H(M2) = H(M1).
  • Strong Collision Resistance: It is computationally infeasible to find any pair (M1, M2) such that H(M1) = H(M2).

3. Birthday Attack

A Birthday Attack is a brute-force cryptographic attack based on the mathematical Birthday Paradox, which states that in a group of just 23 people, there is a greater than 50% probability that two people share the same birthday. Applied to an n-bit hash function, an attacker generates 2n/2 random variants of a legitimate message and 2n/2 variants of a fraudulent message to find a collision H(M1) = H(M2), significantly reducing attack complexity from 2n to 2n/2.

Cryptographic Hash Function and Birthday Attack
Figure 2: Cryptographic Hash Generation and Birthday Collision Attack Mechanism
Q.11. Explain symmetric key distribution methods and Diffie-Hellman key exchange.
Answer

1. Symmetric Key Distribution Methods

For two parties A and B to communicate using symmetric encryption, they must share the same secret key securely. Four standard distribution methods are:

  1. Physical Delivery: Key is physically selected by A and delivered manually to B.
  2. Third-Party Physical Delivery: A trusted third party selects the key and physically delivers it to both A and B.
  3. Encrypted Delivery via Old Key: If A and B previously shared a key, one party transmits the new key encrypted with the old key.
  4. Key Distribution Center (KDC): A trusted centralized KDC shares a unique master key with each user and dynamically generates a temporary session key encrypted for both A and B upon request.

2. Diffie-Hellman Key Exchange Algorithm

  1. Global Public Elements: Select a large prime number q and a primitive root α of q (where α < q).
  2. User A Key Generation: Selects private key XA < q and computes public key YA = αXA mod q.
  3. User B Key Generation: Selects private key XB < q and computes public key YB = αXB mod q.
  4. Shared Secret Computation:
    • User A computes: K = (YB)XA mod q
    • User B computes: K = (YA)XB mod q

Both parties arrive at the exact same shared secret key K = αXAXB mod q.

Diffie-Hellman Key Exchange Flow
Figure 3: Diffie-Hellman Key Exchange Protocol between User A and User B
Q.12. Explain IP Security architecture and its components.
Answer

IP Security (IPSec) is a suite of protocols developed by the IETF to provide security services at the Network Layer (IP layer), including access control, connectionless integrity, data origin authentication, anti-replay protection, and confidentiality.

Components of IPSec Architecture:

  • Authentication Header (AH - Protocol 51): Provides data integrity, data origin authentication, and anti-replay protection for IP packets, but does not provide encryption (confidentiality).
  • Encapsulating Security Payload (ESP - Protocol 50): Provides confidentiality (encryption) along with optional authentication, integrity, and anti-replay services.
  • Security Association (SA): A one-way logical relationship between sender and receiver that defines security parameters (encryption algorithm, keys, lifetime). Uniquely identified by a 32-bit Security Parameter Index (SPI), Destination IP, and Security Protocol ID.
  • Internet Key Exchange (IKE): Handles automated cryptographic key management and SA negotiation between peers.
  • Modes of Operation:
    • Transport Mode: Protects only the upper-layer payload; original IP header remains intact (used for end-to-end host communication).
    • Tunnel Mode: Encrypts and encapsulates the entire original IP packet inside a new IP packet with a new outer header (used for gateway-to-gateway VPNs).
IPSec Architecture and Modes
Figure 4: IPSec Architecture and Packet Structure in Transport vs. Tunnel Mode
Q.13. Describe the Feistel structure and explain the working of DES.
Answer

1. Feistel Cipher Structure

Proposed by Horst Feistel, the Feistel structure divides a plaintext block of length 2w bits into two equal halves: Left (L0) and Right (R0). The data passes through n identical rounds where substitution and permutation are applied alternately:

Li = Ri−1
Ri = Li−1 ⊕ F(Ri−1, Ki)

Decryption uses the exact same algorithm as encryption, simply applying the round subkeys in reverse order (Kn, Kn−1, ..., K1).

2. Working of Data Encryption Standard (DES)

DES is a symmetric-key block cipher operating on a 64-bit plaintext block using a 56-bit effective key (from a 64-bit input key after discarding 8 parity bits) across 16 rounds:

  1. Initial Permutation (IP): Rearranges the 64-bit plaintext block according to a fixed IP table and splits it into 32-bit L0 and 32-bit R0.
  2. 16 Feistel Rounds: In each round i, Ri−1 (32 bits) enters the round function F:
    • Expansion Permutation (E-box): Expands 32-bit Ri−1 to 48 bits.
    • Key Mixing: XORs the 48-bit expanded block with the 48-bit round subkey Ki.
    • Substitution (S-boxes): Eight S-boxes map each 6-bit chunk into 4 bits, producing a 32-bit output (provides non-linear confusion).
    • Permutation (P-box): Permutes the 32 bits before XORing with Li−1.
  3. 32-bit Swap & Final Permutation (FP / IP−1): After Round 16, L16 and R16 are swapped and passed through the inverse initial permutation to produce the 64-bit ciphertext.
DES and Feistel Round Structure
Figure 5: General DES Architecture and Single Feistel Round Function F(R, K)
Q.14. Discuss block cipher modes of operation and explain Triple DES.
Answer

1. Block Cipher Modes of Operation

Modes of operation allow a block cipher to encrypt messages longer than a single block securely:

  • Electronic Codebook (ECB): Each plaintext block is encrypted independently using the same key (Ci = EK(Pi)). Identical plaintext blocks produce identical ciphertext blocks (vulnerable to pattern analysis).
  • Cipher Block Chaining (CBC): Each plaintext block is XORed with the previous ciphertext block before encryption (Ci = EK(Pi ⊕ Ci−1)), using an Initialization Vector (IV) for the first block.
  • Cipher Feedback (CFB): Converts a block cipher into a self-synchronizing stream cipher by encrypting the previous ciphertext and XORing with plaintext.
  • Output Feedback (OFB): Generates a keystream by repeatedly encrypting an IV, then XORs the keystream with plaintext; bit errors do not propagate.
  • Counter (CTR): Encrypts a monotonically increasing counter value and XORs it with plaintext; supports parallel encryption/decryption.

2. Triple DES (3DES)

To overcome the vulnerability of standard 56-bit DES to brute-force attacks, Triple DES (3DES) applies the DES algorithm three times to each block using an Encrypt-Decrypt-Encrypt (EDE) sequence:

Encryption: C = EK3( DK2( EK1(P) ) )
Decryption: P = DK1( EK2( DK3(C) ) )
  • Two-Key 3DES (112-bit effective key): Uses K1 and K2 with K3 = K1.
  • Three-Key 3DES (168-bit effective key): Uses three distinct keys K1, K2, K3.
  • Backward Compatibility: Setting K1 = K2 = K3 reduces 3DES to single DES.
CBC Mode and Triple DES EDE
Figure 6: Cipher Block Chaining (CBC) Mode and Triple DES (EDE) Encryption
Q.15. Describe the AES encryption and decryption process.
Answer

The Advanced Encryption Standard (AES) is a non-Feistel symmetric block cipher operating on a 128-bit data block (arranged as a 4×4 byte matrix called the State). Depending on key size (128, 192, or 256 bits), AES executes 10, 12, or 14 rounds.

AES Encryption Process (128-bit key = 10 Rounds):

  1. Initial Round: AddRoundKey — Bitwise XOR of the 128-bit State with Round Key 0.
  2. 9 Main Rounds (Each consisting of 4 transformations):
    • SubBytes: Non-linear byte-by-byte substitution using an invertible 16×16 lookup table (S-box) over GF(28).
    • ShiftRows: Cyclically shifts rows of the State to the left (Row 0: 0 bytes, Row 1: 1 byte, Row 2: 2 bytes, Row 3: 3 bytes).
    • MixColumns: Multiplies each column of the State by a fixed polynomial matrix over GF(28) for diffusion.
    • AddRoundKey: XORs the State with the current round subkey derived from Key Expansion.
  3. Final Round (Round 10): Executes SubBytes, ShiftRows, and AddRoundKey (omits MixColumns).

AES Decryption Process:

Decryption reverses the transformations using inverse operations with round keys applied in reverse order (K10 down to K0): InvShiftRows, InvSubBytes, AddRoundKey, and InvMixColumns.

AES Encryption and Decryption Structure
Figure 7: AES Encryption and Decryption Round Architecture
Q.16. Explain RSA algorithm along with its security considerations.
Answer

The RSA (Rivest-Shamir-Adleman) algorithm is an asymmetric (public-key) cryptosystem whose security relies on the computational difficulty of factoring the product of two large prime numbers.

1. RSA Algorithm Steps:

  1. Key Generation:
    • Choose two large distinct prime numbers p and q.
    • Compute modulus n = p × q.
    • Compute Euler's totient function: φ(n) = (p − 1)(q − 1).
    • Select public exponent e such that 1 < e < φ(n) and gcd(e, φ(n)) = 1.
    • Compute private exponent d such that d ≡ e−1 (mod φ(n)).
    • Public Key: PU = {e, n}; Private Key: PR = {d, n}.
  2. Encryption (for plaintext M < n): C = Me mod n
  3. Decryption: M = Cd mod n

2. Security Considerations of RSA:

  • Brute-Force Attack: Trying all possible private keys; prevented by using large key sizes (2048-bit or 4096-bit).
  • Mathematical Attacks (Factorization): Attempting to factor n into p and q to find φ(n); mitigated by choosing strong primes of equal bit-length where p−1 and q−1 have large prime factors.
  • Timing Attacks: Measuring the time taken for modular exponentiation to deduce bits of d; prevented using constant-time exponentiation and blinding techniques.
  • Chosen Ciphertext Attack (CCA): Exploiting the multiplicative property of RSA (E(M1)·E(M2) = E(M1M2)); prevented by using randomized padding schemes such as OAEP (Optimal Asymmetric Encryption Padding).
RSA Key Generation, Encryption and Decryption
Figure 8: RSA Key Generation, Encryption, and Decryption Workflow
Q.17. Describe Secure Hash Algorithm (SHA) and its security features.
Answer

Secure Hash Algorithm (SHA) is a family of cryptographic hash functions published by NIST (including SHA-1, SHA-256, SHA-384, and SHA-512) used to verify data integrity and generate digital signatures.

Working of SHA (e.g., SHA-512 / SHA-256):

  1. Message Padding: Appends a '1' bit followed by '0' bits so the message length becomes congruent to 896 mod 1024 (for SHA-512) or 448 mod 512 (for SHA-256).
  2. Appending Length: Appends a 128-bit (or 64-bit) representation of the original message length, making total length a multiple of the block size.
  3. Buffer Initialization: Initializes chaining variables (registers a, b, c, d, e, f, g, h) with fixed fractional parts of square roots of the first 8 primes.
  4. Compression Function Processing: Processes each block through 80 (or 64) rounds using bitwise logical functions, modular additions, circular shifts, and round constants Kt to update the hash buffer.
  5. Final Output: Concatenates the final buffer values to output a fixed-length digest (e.g., 256-bit or 512-bit).

Security Features of SHA:

  • Avalanche Effect: Changing a single bit in the input message alters approximately 50% of the output hash bits.
  • Pre-image & Collision Resistance: SHA-2 (SHA-256/512) provides high resistance against pre-image (2256) and birthday collision attacks (2128).
  • Deterministic & Fixed-Length Output: Always yields the exact same digest length regardless of input file size.
SHA Message Processing Pipeline
Figure 9: Secure Hash Algorithm (SHA) Block Processing Pipeline
Q.18. Explain ElGamal Digital Signature technique and Digital Signature Standard (DSS).
Answer

1. ElGamal Digital Signature Technique

Based on the difficulty of computing discrete logarithms over finite fields:

  • Key Generation: Select large prime q, primitive root α, and private key XA (1 < XA < q−1). Compute public key YA = αXA mod q.
  • Signing Message M (hash m = H(M)):
    1. Choose random integer K such that 1 ≤ K ≤ q−1 and gcd(K, q−1) = 1.
    2. Compute S1 = αK mod q.
    3. Compute S2 = K−1(m − XAS1) mod (q−1). Signature is (S1, S2).
  • Verification: Compute V1 = αm mod q and V2 = (YA)S1(S1)S2 mod q. Valid if V1 = V2.

2. Digital Signature Standard (DSS / DSA)

Published by NIST (FIPS 186), DSS uses the Digital Signature Algorithm (DSA) exclusively for digital signatures (not encryption) alongside SHA:

  • Global Parameters: Prime p, prime divisor q of (p−1), and generator g = h(p−1)/q mod p.
  • Signing: Generates two signature components r = (gk mod p) mod q and s = [k−1(H(M) + xr)] mod q, where x is the private key and k is a per-message secret random number.
  • Verification: Computes w = s−1 mod q, u1 = [H(M)w] mod q, u2 = (rw) mod q, and v = [(gu1yu2) mod p] mod q. Signature is valid if v = r.
DSS Signing and Verifying Architecture
Figure 10: Digital Signature Standard (DSS) Signing and Verification Process
Q.19. Describe X.509 certificates and Public Key Infrastructure (PKI).
Answer

1. X.509 Digital Certificates

ITU-T Recommendation X.509 defines the standard format for public-key certificates used to bind a user's identity to their public key, signed by a trusted Certificate Authority (CA). Key fields of an X.509 certificate include:

  • Version & Serial Number: X.509 version (v1, v2, or v3) and unique integer assigned by the CA.
  • Signature Algorithm Identifier: Algorithm used by CA to sign the certificate (e.g., SHA-256 with RSA).
  • Issuer Name: X.500 Distinguished Name (DN) of the issuing CA.
  • Validity Period: Not Before and Not After timestamps.
  • Subject Name & Subject Public Key Info: Identity of the certificate owner, their public key, and algorithm parameters.
  • Extensions (v3) & CA Digital Signature: Key usage constraints and the CA's cryptographic signature over all preceding fields.

2. Public Key Infrastructure (PKI) Components

  • Certificate Authority (CA): Trusted entity that issues, signs, and revokes digital certificates.
  • Registration Authority (RA): Verifies user identity before forwarding certificate requests to the CA.
  • Certificate Repository & CRL/OCSP: Stores active certificates and publishes Certificate Revocation Lists (CRLs) or responds via Online Certificate Status Protocol (OCSP) for revoked certificates.
X.509 Certificate Structure and PKI
Figure 11: X.509 Certificate Format and PKI Trust Architecture
Q.20. Explain Kerberos authentication protocol and electronic mail security using PGP.
Answer

1. Kerberos Authentication Protocol

Kerberos is a centralized network authentication protocol based on symmetric-key cryptography and a trusted third-party Key Distribution Center (KDC) consisting of two servers:

  1. Authentication Server (AS): Verifies client credentials and issues an encrypted Ticket-Granting Ticket (TGT).
  2. Ticket-Granting Server (TGS): Validates the TGT and issues a Service-Granting Ticket (SGT) for a specific application server.
  3. Service Access: The client presents the SGT and an encrypted Authenticator (containing timestamp) to the target Server to establish an authenticated session.

2. Electronic Mail Security using PGP (Pretty Good Privacy)

Developed by Phil Zimmermann, PGP secures email using a combination of asymmetric and symmetric cryptography:

  • Authentication (Digital Signature): Sender hashes the message with SHA, encrypts the hash with their private key (PRA), and prepends it to the message.
  • Compression: Compresses the message + signature using ZIP to save bandwidth and strengthen cryptographic security.
  • Confidentiality: Generates a one-time symmetric session key (Ks) to encrypt the compressed data (using AES/CAST-128), and encrypts Ks using the receiver's public key (PUB).
  • Radix-64 Conversion: Converts binary ciphertext into printable ASCII characters for compatibility with email servers.
Kerberos and PGP Architecture
Figure 12: Kerberos Ticket Exchange Flow and PGP Email Security Pipeline
Q.21. Describe SSL and Secure Electronic Transaction (SET).
Answer

1. Secure Sockets Layer (SSL)

SSL (and its successor TLS) provides end-to-end security between a web client and server at the Transport/Session boundary. Its architecture has two layers:

  • SSL Handshake Protocol: Authenticates the server (and optionally client) using X.509 certificates, negotiates cipher suites, and exchanges a pre-master secret to derive symmetric session keys.
  • SSL Change Cipher Spec & Alert Protocols: Signals transition to newly negotiated encryption parameters and reports connection errors/warnings.
  • SSL Record Protocol: Fragments application data, compresses it, attaches a Message Authentication Code (MAC), encrypts the payload, and appends an SSL header.

2. Secure Electronic Transaction (SET)

Developed by Visa and MasterCard, SET is an open protocol designed to protect credit card transactions over the Internet among three participants: Cardholder, Merchant, and Payment Gateway.

  • Key Feature — Dual Signature: Links two messages intended for different recipients so the Merchant sees only the Order Information (OI) (hiding card details) and the Bank/Payment Gateway sees only the Payment Information (PI) (hiding purchase items):
    DS = EPR_Cardholder[ H( H(PI) || H(OI) ) ]
SSL Protocol Stack and SET Dual Signature
Figure 13: SSL Protocol Stack and SET Dual Signature Mechanism
Q.22. Discuss intrusion detection systems, viruses, and the role of firewalls in network security.
Answer

1. Intrusion Detection Systems (IDS)

An IDS monitors network traffic or system activities for malicious behavior and policy violations, alerting administrators upon detection:

  • Host-Based IDS (HIDS): Monitors system calls, audit logs, and file integrity on a single host.
  • Network-Based IDS (NIDS): Captures and analyzes live network packets across network segments.
  • Detection Methods: Signature-based detection (matches known attack patterns) and Anomaly-based detection (detects deviations from normal baseline behavior).

2. Computer Viruses

A virus is a self-replicating malicious program that attaches itself to a legitimate executable host file and spreads when the infected file is executed. Its lifecycle comprises four phases: Dormant phase, Propagation phase, Triggering phase, and Execution phase (e.g., Boot sector virus, Macro virus, Polymorphic virus).

3. Role of Firewalls in Network Security

A firewall enforces a security policy at the perimeter between an internal trusted network and external untrusted networks:

  • Packet Filtering Firewall: Evaluates IP headers, TCP/UDP ports, and flags against static rules.
  • Stateful Inspection Firewall: Tracks active connection states in a state table to allow only legitimate return traffic.
  • Application-Level Gateway (Proxy): Inspects application payloads (HTTP, FTP, SMTP) and hides internal host IP addresses via NAT.
Network Security Defense with Firewall and IDS
Figure 14: Layered Network Security Architecture Integrating Firewall and IDS
Letter of Recommendation Request