Testing & Ethical
Hacking& Ethical
Hacking
Basic of Networking
OSI Models
The OSI (Open Systems Interconnection) model defines
networking functionality
Physical Layer (Layer 1)
Function: Ensures network node connectivity through
wired or wireless means.
Common Attacks:
Sniffing Attack:Gaining physical access to intercept
data.
Physical Damage: Harming cables or devices to disrupt
services
Data Link Layer (Layer 2)
Function: Manages communication between connected
network nodes and breaks data into frames for
transmission..
Common Attacks:
MAC Spoofing: Altering MAC addresses to masquerade
as another device.
ARP Spoofing: Associating an attacker's MAC with
another IP.
Network Layer (Layer 3)
Function: Responsible for packet forwarding, including
routing through routers.
Common Attacks:
IP Spoofing: Creating IP packets with a false source
address.
Routing Attacks: Manipulating routing tables with false
information.
Man-in-the-Middle (MITM) Attack
Denial-of-Service (DoS): Overwhelming the network
with traffic.
Transport Layer (Layer 4)
Function: Provides transparent transfer of data and
ensures complete data transfer.
Common Attacks:
SYN Flood: Exhausting server resources during TCP
handshake.
UDP Flood: Overwhelming target with UDP packets.
Session Layer (Layer 5)
Function: Manages communication sessions, ensuring
efficient data transfer and closing sessions upon
completion
Common Attacks:
Session Hijacking: Stealing a valid session.
Presentation Layer (Layer 6)
Function: Translates data between application layer and
network format, performs encryption/decryption.
Common Attacks:
SSL Stripping: Downgrading HTTPS to HTTP.
Phishing Attack: Attackers use deceptive techniques
(e.g., fake emails or websites) to trick users into disclosing
sensitive information or installing malicious software.
Application Layer (Layer 7)
Function: Interfaces directly with user applications to
facilitate communication
Common Attacks:
SQL Injection: Manipulating or destroying databases.
Cross-Site Scripting (XSS): Injecting malicious scripts.
OSI Layers
An identifierfor a computer or device on a TCP/IP
network.
The format of an IP address is a 32-bit numeric
address written as four numbers separated by
periods.
Each number can be zero to 255. For example,
1.160.10.240 could be an IP address.
IP Addressing (IPv4)
127.0.0.0
Network number that cannot be assigned to any
network
127.0.0.1
The loopback address
Used for diagnostic testing of the local TCP/IP
installation
Loopback address
Port
A port number is a way to
identify a specific process
to which an internet or
other network message is
to be forwarded when it
arrives at aserver.