CompTIA Security+
CompTIA Security+
The Collection
Worm- self-replicating malware that travels throughout a network without the assistance of host
application or user interaction.
Ransomware- Takes control of a user’s system or data and asks for a ransom.
Trojan- Appears to be something useful but includes a malicious component, such as installing
a backdoor on a user’s system. They infect the systems from rogueware, pirated software,
infected USB drives etc.
# the trojan and the file are the same entity, so just the trojan cannot be blocked without
blocking the actual file.
Rootkit- Have root-level or kernel level access and can modify system files and system access.
Rootkits hide their processes to avoid detection with hooking techniques. Tools that can inspect
RAM can discover these hidden hooked processes.
# If an attacker can access the system despite loading different OS from different media than its a type of firmware-leve
Kernel- core part of the OS.
Firmware- initializes the hardware and starts the OS
Keylogger- keeps track of every single keystroke. Keylogging software has two major functions;
record keystrokes, and transmit those keystrokes to a remote location. Local file scanning and
software best-practices can help prevent the initial installation, and controlling outbound network
traffic can block unauthorized file transfers.
Adware- learns users’ habits for the purpose of targeted advertising. E.g. pop-ups.
Spyware- Monitors the user’s computer and the user’s activity and sends this information to the
third party.
Bots- multiple computers acting as software robots and functioning together in a network for
malicious purposes like sending spam, launching DDoS.
RAT- Remote Access Trojan made for spying on, hijacking or destroying computers.
Logic bomb- a string of code embedded into an application or script that will execute in a
response to an event such as when a specific application is executed or a specific time arrives.
Backdoor- provides another way of accessing a system. Many types of malware create
backdoors, allowing attackers to access systems from remote locations.
# Pharming- Web browser; Spimming- Instant Message like Facebook Messenger. Pharming is
a scamming practice in which malicious code is installed on a personal computer or server,
misdirecting users to fraudulent Web sites without their knowledge or consent. Pharming has
been called "phishing without a lure."
Phishing- emailing users to trick them into revealing personal information or clicking a link.
Spam is an unwanted email. Phishing is malicious spam.
Spear Phishing- Targeted form of phishing. Instead of sending an email to everyone like in
phishing, attackers send email to target users or groups.
Whaling- Form of spear phishing that targets high-level executives.
Vishing- Use of phone calls for phishing. By spoofing caller ID etc.
Tailgating- following an employee through the door without showing credentials
Impersonation- identity theft. impersonate others like repair tech to get into the server room
Dumpster Diving- searching through trash to gain information from discarded documents
Shoulder Surfing- looking over the shoulder
Hoax- false message, often an email telling users there is virus and encouraging to delete file or
change system configuration
Watering hole attack- Observing which website a user often uses and infecting it with malware.
DoS- attack from a single source to disrupt the services provided by another system
DDoS- attack from multiple computers to a single target.
Man-in-the-Middle- Uses a separate computer that accepts traffic from the sender,
reads/modifies it and forwards it to the receiver.
Buffer overflow-
● common when attacking Application level servers and services.
● A buffer is a memory stack that has a certain holding size.
● Through a specifically and maliciously crafted packet, information can overflow in that
stack. This can result in a DoS, system compromise, remote takeover of a system etc.
Use patches.
Occurs when an application receives more data than it can handle or receives unexpected data
that exposes system memory. Use Input validation to prevent.
# includes a series of No Operation (NOP) commands, such as hexadecimal 90 (x90). When
successful they can crash applications and expose memory, allowing attackers to run malicious
code on the system.
Injection- Attackers use SQL injection attacks to pass queries to back-end databases through
web servers. E.g. search Darril Gibson’; SELECT * FROM Customers; --
Cross-site scripting- If input validation is not done, attackers can include script in their input
and the script becomes a part of the web process.
● Non-persistent XSS attack- the injected script is executed and passed back. Doesn’t
store.
● Persistent XSS attack- permanently stored on the web server or backend storage.
● DOM-based XSS attack- script is executed in the browser via DOM as opposed to the
web server.
To defend XSS:
● Use antiXSS libraries to strip scripts from the input sequences.
● Limit types of uploads and screen the size of uploads, whitelist inputs
● Session hijacking
Cross-Site request forgery (XSRF)- causes users to perform actions on web sites such as
making purchases, without their knowledge.
# Also known as session riding or one-click attack.
For e.g. Hacker may change http://internetsite.com/[email protected] to
http://internetsite.com/[email protected]
Privilege escalation- exploits a programming flaw or buffer overflow to obtain admin-level or
root-level access.
ARP poisoning-
Normal ARP process:
1. ARP request: who has this IP: 192.168.1.1?
2. ARP reply: I have that IP. My MAC is 00-11-22-33-44-55
Attackers can reply with a spoofed MAC which poisons the victim’s ARP cache. The attacker
then performs a man-in-the-middle attack or DoS.
Amplification- use of a large number of machines to flood requests to one machine like DDoS
attack.
DNS poisoning- modifies the IP address associated with a website and replaces it with the IP
address of a malicious web site. Use DNSSEC to prevent this attack.
Domain hijacking- changing the registration of domain name without the authorization of the
valid owner. Ex. register a domain name immediately after the original owner’s registration
expires.
Man-in-the-browser- intercept and manipulate communications immediately after a victim
leaves the browser or before they exit the network interface.
Zero day- Exploits an undocumented or unknown vulnerability.
Replay- Captures data including credentials in a session and later impersonates one party in
the session. Use Timestamps and sequence numbers to prevent it.
Pass the hash- Capture the hash from the authentication protocol (LM, NTLM) that does not
encrypt the hash. Use the hash instead of the password to authenticate. Implement stronger
protocols like NTLMv2 or Kerberos.
Hijacking and related attacks:
● Clickjacking- hiding malicious code in a transparent layer. Users think they are clicking
one thing but in reality, are clicking the hidden control.
● Session hijacking- attacker learns the user’s session ID from the cookies and uses it to
impersonate the user.
● Typo-squatting (URL hijacking)- Buying domain names close to legitimate one. E.g.
buying apples.com instead of apple.com and hosting malicious content.
Driver manipulation: changing the behavior of the system by changing the driver. Always use
signed drivers.
● Shimming- putting a layer of code between the driver and the OS to enable changes
between different versions of an OS without modifying the original driver code.
# There’s a file that has the same name as a Windows system DLL file and has the same API
interface but handles the input very differently. It also looks like applications have been attached
to this file rather than the real system DLL.- Shimming Not Refactoring!!
● Refactoring- rewriting the existing code to fix software bugs or add functionality.
Attackers can add the malicious code while maintaining the functionality.
MAC spoofing- impersonating MAC address of authorized systems to bypass MAC address
filtering
IP spoofing- Each IP packet contains source IP. Attackers can insert a different IP in the source field and
hide its actual IP.
Smurf attack-
● attacker spoofs their IP address with victim’s,
● sends the ping out as a broadcast and
● the victim gets flooded with ping responses.
● Disable directed broadcasts on routers to mitigate the threat.
SYN Flood Attack- Attacker sends a SYN packet, victim server responds with SYN/ACK,
attacker never completes the handshake (does not send an ACK). Attackers flood with the SYN
packets, leaving the server with multiple half-open connections. Use a flood guard.
Xmas Attack- attacker does port scan with specific flags within the TCP packet header. Based
on the open ports, the port scanner can detect what services and protocols are running, the OS
version etc.
Wireless Attacks:
Replay- capture data sent between 2 entities, modify it and attempt to impersonate one of the
parties by replaying it. WPA using TKIP is vulnerable. WPA2 using CCMP and AES is not.
IV- IV is a random number used to create encryption keys in WEP. When the key is repeated,
and IV is known it's easy to decipher the key by comparing the ciphertext.
Evil Twin- a rogue access point using the same SSID as a legit AP
Rogue AP- WAP placed within a network to sniff data
Jamming- Transmitting noise on the same frequency to degrade performance
WPS- WPS allows users to configure a wireless network by pressing buttons or by entering a
short PIN; attackers can brute force.
Bluejacking- Sending unsolicited message to nearby Bluetooth device
Bluesnarfing- Unauthorized access from Bluetooth connection
RFID
● enables one way wireless communication, typically between an unpowered RFID tag
and a powered RFID reader.
● RFID tags can be scanned at distances of up to 100 meters without a direct line of sight
to the reader.
● Used for asset tracking in warehouses, airport baggage handling, livestock identification,
EZpass and track progress of the automobiles through the production line as it is built.
NFC- subset of RFID
● capable of 2-way communication and can therefore be used for more complex
interactions such as card emulation (contact less payment)
● P2P sharing because it acts as both a reader and a tag.
● requires close proximity, typically 5cm or less
● only a single NFC tag can be scanned at one time.
Disassociation- disassociate wireless client from the network with hidden SSID. when they
send a reassociation request packet, read the cleartext SSID. Also causes DoS. combine with
session hijacking and impersonate the client. Can also implement Evil Twin by transmitting
stronger signals with the same SSID after disassociation.
Cryptographic Attacks:
Hash Collision- occurs when the hashing algorithm creates the same hash from different
passwords.
Birthday- Attacker steals the hash, uses his list of passwords to produce that hash to identify
the password. Same as collision attack.
Rainbow tables- Rainbow tables are huge databases of password hash. Use a search function
to find password from the hash or vice versa. Use long passwords or salting to prevent this
attack.
Dictionary- Uses a dictionary of words with variation as a password.
Brute force- guess all possible character combinations. Also called exhaustive attack. Use
account lockout policy and complex passwords.
● Online- against the live logon which can be blocked by account lockout policy
Script kiddies- just enough understanding of computer systems to be able to download and run
scripts that others have developed.
Hacktivist- conveys a social or political message by hacking a website or a system.
Organized Crime- to monetize the effort
Nation states/APT- elite hackers that conduct information warfare.
Insiders- employees already have access to the organization and its assets.
Competitors- information component is easier to copy, steal or disrupt than older, more
physical assets making it an alluring target for competitors.
Attributes of actors:
Use of any information that is available via web sites and social media to conduct an attack.
Data that is collected through publicly available information. This can be used to help make
decisions. Can be used by threat actors to help find their next target or how to best attack their
target. OSINT is also incredibly helpful for mitigating risks and for identifying new threat actors.
Back Orifice Remote admin tool (rootkit,keylogger). can sniff passwords and access
a desktop’s file system and more, while remaining undetected
Cain & Abel password recovery tool for windows. uses packet sniffing, dictionary
attack, brute force and cryptanalysis attack
Security Onion free and open source IDS, security monitoring and log management
solution
DBAN Darik’s Boot and Nuke. erase hard drives, desktops or laptops or server
Roo
# If your IP is blocked every time you perform a vulnerability scan, you’ve successfully done a
passive test of the client’s security controls.
● Buffer overflow- input buffer that is used to hold program input is overwritten with data
that is larger than the buffer can hold. If the input validation is not handled properly, the
extra characters continue to fill memory, overwriting other portions of the program
● Pointer dereference- change the memory location pointed by the pointer that results in
an unexpected result.
● DLL injection- adding an evil DLL in the correct dictionary for additional functionality.
System sprawl/undocumented assets- old OS running legacy app
architecture/design weaknesses- attackers can traverse the network more likely if the network
is not segmented.
New threats/zero day- Unknown threat
Improper certificate and key management- failure to properly validate a key before use can
result in an expired or compromised key being used. Improper key management results in
failure to secure data.
2.0 Technologies and Tools
2.1 Install and configure network components
Firewall:
A network security system that monitors and controls incoming and outgoing network traffic
based on predetermined security rules.
# A firewall with 2 network interfaces is called a dual-homed firewall. Activated only when the
first interface fails.
ACL- identifies what traffic is allowed and what is blocked based on networks, subnets, IP
addresses, ports and some protocols. A packet filtering firewall is based on ACLs and only
examines the packet header.
Application-based vs. network based-
● Application based Firewall is typically a software installed in the host and can analyze
traffic on a deeper level.
● Network based usually looks in IP and ports.
● Application based firewall is most detrimental to network performance because it
requires more processing per packet.
● The packet filtering firewall provides high performance.
● Kernel proxy firewalls are built into the OS kernel.
Stateful vs stateless-
● a stateful firewall inspects traffic and decides based on the context or state of the traffic.
● It keeps track of established sessions and inspects traffic based on its state within a
session.
● If it detects TCP traffic without a corresponding 3-way handshake, it will block it.
● Stateless firewalls use ACLs to make decisions.
Implicit deny- last rule in ACL that blocks all access that has not been explicitly granted above
VPN Concentrator:
VPN offers a means of cryptographically securing a communication channel and the
concentrator is the endpoint for this activity.
Remote Access
● Remote access VPN allows a remote host to connect to a network; usually a roaming
employee connecting to its corporate network.
● E.g. Use SSL-VPN with a fixed IP of the office.
Site-to-site
● connects two networks from remote sites without requiring additional steps on part of the
user.
● E.g. Use IPSec between 2 site’s Firewall with static IPs on both sides.
TLS (SSL-VPN)
● Typically provides Layer 6 encryption services for Layer 7 applications.
● TLS based VPNs have some advantages over IPSec-based VPNs when networks are
heavily NAT encoded.
● SSL Portal VPNs are used to securely access the web from a browser.
● SSL Tunnel VPNs allow not only web access but also applications and other network
services.
● E.g. OpenVPN, OpenConnect
IPsec Protocols:
IKE builds the tunnels for us but it doesn’t authenticate or encrypt user data. AH and ESP are 2
protocols that we use to actually protect user data.
● AH- provides authentication for the data and the IP header of a packet using one way
hash. Doesn’t offer encryption service. Doesn’t play well with NAT/PAT.
● ESP- provides confidentiality (encryption), data origin authentication, connectionless
integrity, anti-replay service and limited traffic-flow confidentiality by defeating traffic flow
analysis. Since ESP supports encryption, it is more popular.
Both Protocols support 2 different modes.
● Tunnel Mode- Entire packet is encrypted and/or authenticated. Used with VPNs
transmitted over the (public) internet. Site-to-site
● Transport mode- Only IP payload is encrypted; the destination and source IP
addresses and other IP header information are readable. Used in a PRIVATE network.
IKEv2 (streamlines the processes of IKEv1)
● requires less bandwidth than IKEv1
● supports EAP authentication (next to PSK and digital certificates)
● built-in support for NAT traversal (required when your IPsec peer is behind a NAT
router).
● built-in keepalive mechanism for tunnels.
-------------------------------------------------------------------------------------------------------------------------------
Split tunnel
● Not all traffic is routed via the VPN to avoid encryption bottlenecks.
● For e.g. Internet search will not be encrypted but any traffic going to the office will be
encrypted.
Full tunnel
● Encrypts all traffic including internet traffic.
● Even if you are browsing the internet it will be encrypted and the traffic is sent to the
office before going to the internet.
● Full tunneling can significantly spike the traffic flow. Always pay attention to this before
deploying.
Always-on VPN- self-configures and connects once an internet connection is sensed and
provides VPN functionality without user intervention.
NIPS/NIDS:
● NIDS is the low maintenance device involved in analyzing traffic in the network.
● Easy and economical to manage because the signatures are not configured on all the
hosts in a network segment.
● NIDS cannot analyze encrypted information
Signature-based (misused-based)- identifies issues based on known attacks or vulnerabilities.
lower false alarm rates.
Heuristic/behavioral-
● looking for evidence of compromise rather than the attack itself.
● low false positive than Anomaly based but higher than signature based.
● Heuristic model uses artificial intelligence to detect intrusions and malicious traffic.
Anomaly-
● 2 step approach. starts with a performance baseline of normal behavior and then
compares network traffic against this baseline.
● Can detect potentially a wide range of zero-day attacks.
● Most likely to produce a high number of false alerts because deviations from normal
behavior does not always indicate a possible attack.
● May miss novel attack if they don’t stick out
Inline
● NIPS is considered inline
● Refers to being in between the Firewall and the rest of the network.
● stops the traffic if it spots the signature match or anomaly before it hits the network.
Passive
● Not inline but mirrored.
● NIDS is a passive network solution
● may sit on the inner network side, DMZ or WAN.
● alerts admin of suspicious connection or potential threat
Router:
ACLs- identifies what traffic is allowed and what is blocked based on networks, subnets, IP
addresses, ports and some protocols
Anti-spoofing- enable source IP checking in router to prevent spoofing from the network to
perform DDos attack.
Network Address Translation (NAT)- NAT router acts as the interface between a LAN and the
internet using one IP address.
Switch:
Port security- Disable unused ports and limit the number of MAC per port. Use 802.1x server
to provide port-based authentication.
Layer 2 vs Layer 3- layer 2 switch routes traffic based on MAC within same network while layer
3 switch routes traffic based on IP between 2 different networks
Loop prevention- loops occur when 2 ports of a switch are connected together. Use STP,
Rapid STP to prevent switching loop
Flood guard- by monitoring traffic rate and percentage of bandwidth occupied by broadcast,
multicast and unicast traffic, flood guard can detect when to block traffic to prevent flooding
attacks like ping floods, SYN floods, ICMP floods (smurf attacks) etc.
Proxy:
Proxy Server- acts as an Internet gateway, firewall and internet caching server for a private
network. Hosts on the private network contact the proxy server with an Internet Web site
request.
Forward proxy
● Forwards request for services from client.
● Provides caching to improve performance and reduce internet bandwidth usage.
● Uses URL filters to restrict access to certain sites;
● logs user activity.
Reverse proxy
● Typically installed on the server side.
● Receives request on behalf of client
● Also called a surrogate proxy.
● Used for hiding internal servers, load balancing.
Transparent-
● Accepts and forwards requests without modifying them.
● Doesn’t require client side configuration.
● Non-transparent proxies can modify or filter requests such as filtering traffic based on
destination URLs.
Application/multipurpose- proxy for a specific application or for multipurpose.
Load balancer
Scheduling
● Affinity
o Uses client’s IP address to ensure the client is redirected to the same server
during a session.
o Designed to keep a host connected to the same server across a session.
o For new connections, it creates a new affinity entry and assigns the session to
the next server in available rotation.
● Round-robin
o Sends each new request to the next server in rotation.
o Can use weighting factors to take server load into account.
Active-passive- active load balancer does the balancing job and passive balancer steps in if
active balancer fails
Active-active- both share the load balancing duties. Efficient performance but failure of one will
lead to session interruption and traffic loss.
Virtual IPs-
● use of virtual IPs for servers so that the router only sends packets to the balancer and
does not see actual IP of servers to send packets directly.
● An IP address and a specific port number that can be used to reference different
physical servers.
● Provides IP addresses that can float between two or more physical network nodes and
provide redundancy.
● Virtual IP load-balancing doesn’t take a load of each interface and assumes all loads are
similar
Access point:
SSID- identifies the name of wireless network
MAC filtering- blocks unauthorized devices by only allowing certain MAC on AP. Attacker can
use sniffer to discover allowed MAC and circumvent by spoofing its MAC
Signal strength-
● Decibels-isotropic (dBi) identifies gain on omnidirectional antennas. Higher the better.
● Decibels-dipole (dBd) identifies gain on the dipole antenna. Higher dBd indicates the
antenna can transmit and receive over greater distance.
● Decibels-milliwatt (dBm) identifies the power level of the WAP and refers to the power
ratio in decibels referenced to one milliwatt. Higher the better.
● Cannot modify the dBi or dBd gain without changing physical properties.
● Yagi- Directional antenna that uses a dipole, folded dipole, or half-wave dipole combined
with additional elements like reflector or director element. High gain with narrow radiation
pattern.
Perform site survey for proper antenna selection and placement. Enough strength to cover all
workspace but not very wide to prevent security issues.
Fat vs. thin- fat APs are standalone and thin APs are controller based.
Controller-based vs. standalone- controller based APs allows for centralized management
and control, which can facilitate better channel management for adjacent APs, better load
balancing and easier deployment of patches and firmware updates. Easier for NAC. standalone
is simpler than controller-based.
DLP
USB blocking- prevents data loss by blocking USB ports.
Cloud-based- detects the data moved to cloud and blocks.
Email- email server like exchange also has DLP.
NAC:
Agent
● code is stored in the host machine
Agentless
● the code resides on the network and is deployed to memory for use in a machine
requesting connections.
Permanent
● Agents are pre-deployed to the endpoints
Dissolvable
● Deployed when needed and removed after use. Has a minimum impact than Agentless.
Host health checks- NAC uses health agents to inspect clients for health, such as having up-
to-date antivirus software and restrict access of unhealthy clients to a quarantine network.
Mail gateway
Spam filter- blocks spam. Ex. Appriver, mimecast.
DLP- blocks data leak by implementing Data Loss Prevention policy.
Encryption- encrypts the mail traffic. Add-in solutions like Pretty Good Privacy (PGP), built in
S/MIME (secure/Multipurpose Internet Mail Extensions) etc.
Bridge- network segregating device operating in layer 2. most convenient for interconnecting
two or more physically separated network segments.
SSL/TLS accelerators- use this transparent device between web server and the internet for
encrypting traffic per SSL/TLS instead of using larger and larger web servers to encrypt traffic.
SSL decryptors- opens the SSL/TLS traffic using man-in-the-middle technique, screens the
traffic and re-encrypts it. Prevents encrypted attack.
Media gateway- handles different protocols for voice and video signals and translates them to
common protocols used in a network.
Hardware security module- manages and stores encryption keys. Typically, a peripheral
device connected via USB or a network connection.
● Netstat- shows active TCP/IP network connections, routing tables and protocol statistics
● nslookup- gather information from DNS servers, lookup names and IP addresses.
Replaced by dig.
● dig- Domain Information Groper. More advanced than nslookup and shows more
detailed domain information. Is primarily used for Linux but can be used in windows as
well.
● Arp- to identify MAC from IP (IP to MAC)
● Nmap- network scanner that has many capabilities including identifying all the active
hosts and their addresses in a network, the protocols and services running on each of
these hosts and the OS of the host.
● Netcat- used to remotely administer systems and can also perform banner grabbing.
Banner grabbing gathers info on OS, services and applications. Hackers can open a
backdoor using this.
Web application firewall- performs restrictions based on rules associated with HTTP/HTTPS
traffic.
# WAF provides load balancing.
ANT- operates in a 2.4GHz ISM (industrial, scientific, and medical) band to communicate. Used
in heart monitors, sports and fitness sensors. Usage with Fitness sensors such as Fitbit. collects
data on users and uses ANT to send the data to mobile device applications.
Infrared- line-of-sight wireless technology. used in remote controls, wireless keyboard and
mouse.
USB- used to connect devices physically.
Wi-Fi direct
● Allows devices to connect without AP.
● Uses single hop, meaning the camera will not have access to the internet.
● E.g. using a camera app to connect to the camera to download images.
Ad hoc
● is similar but it uses multiple hop. Hence, has access to the internet.
Tethering
● Allows you to share one device’s internet connection with other devices.
● Wi-Fi tethering is the same as Mobile Hotspot.
● Can be used to bypass corporate web security to access prohibited websites while still
being connected to the LAN. Implement a policy against tethering to prevent this.
Payment methods
Deployment models:
BYOD- allow users to bring their own mobile device to work and attach them to the network.
COPE (Corporate Owned, Personally Enabled)
● Can be used for personal use as well.
CYOD (Choose Your Own Device)
● Organization creates a list of acceptable devices
● Employees can purchase those and bring to work
Corporate-owned- Organization purchases devices and issues them to employees.
VDI- Virtual desktop that a user can access from a mobile device
VMI- Virtual Mobile Infrastructure would allow the field teams to access their applications from
many different types of devices without the requirement of a mobile device management or
concern about corporate data on the devices.
Use cases
Voice and video- RTP delivers audio and video over IP networks. This includes VoIP,
streaming media, video teleconferencing applications and devices using web-based push-to-talk
features. SRTP provides encryption, message authentication and integrity of RTP. SRTP
provides protection against replay attacks.
Time synchronization- NTP and Simple NTP is used. Use NTPSec.
Email and web-
● SMTP transfers email between SMTP servers. Use S/MIME
● POP3 transfers emails from servers down to the clients.
● IMAP4 is used to store email on an email server.
Web servers use HTTP to transmit web pages to client’s web browsers.
HTTPs encrypts web traffic.
File transfer- SSH, IPSec, SFTP are used to encrypt data-in-transit while FTP and TFTP are
unsecured protocols. Use FTPS or SFTP.
Directory services- provides secure access to the network. E.g. AD DS, LDAP.
Remote access- To access systems from remote locations. RDP uses TCP or UDP 3389.
Domain name resolution- DNS is used for resolving host names into IP. Use DNSSEC
Routing and switching-
● R/STP prevents switching loops.
● Flood guards block MAC flood attacks.
● Port security prevents unauthorized users.
● VLANs provide increased segmentation.
Network address allocation- IPv4 and IPv6. Private IPs are defined in RFC 1918. Use it to
mitigate DHCP starvation attacks. “Gobbler” can be used to execute a DHCP starvation attack.
Subscription services- E.g. Office 365 uses a subscription model.
3.0 Architecture and Design
3.1 Frameworks, best practices and secure configuration
guides
Framework- a collection of standardized policies, procedures and guides, meant to direct a
user, firm, or any organization.
● Application server
Defense-in-depth/Layered security:
Implementing several layers of protection
Vendor diversity- implementing security controls from different vendors to increase security.
Control diversity- use of different security control types such as technical controls,
administrative controls and physical controls.
● Administrative- policies, regulations, laws etc. System TESTING and security
awareness.
● Technical- Firewalls, IDS proxy server
User training- informs users of threats, helping them avoid common attacks.
Segregation/segmentation/isolation:
Physical- E.g. SCADA operates on their own network.
Logical (VLAN)- create separate VLAN for routers, switches, VOIP phones etc.
Virtualization- provides server isolation. Cheaper solution than Failover cluster
Air gaps- an air gapped system is not connected to any other systems.
Tunneling/VPN:
Site-to-site- encrypted traffic between 2 sites.
Remote access- from user to the site
# IPSec is not a type of VPN. It is the encryption protocol used in VPN solutions.
# Firewall --- DMZ -- Firewall --- SSL accelerator --- Load balancer --- web server
SDN:
Uses virtualization technologies to route traffic instead of using hardware routers and switches.
SDN separates the logic used to forward or block traffic (data plane) and the logic used to
identify the path to take (control plane). Hardware routers use rules within an ACL to identify
whether a router will forward or block traffic on the data plane. This is always proprietary
because it's implemented on specific hardware routers. SDN implements the data plane with
software and virtualization technologies, allowing an organization to move away from proprietary
hardware.
Operating systems:
Types:
● Network- IOS runs in cisco routers, switches etc.
● Workstation- Windows 10
● Appliance- Embedded OS
● Patch- more formal and larger software update. Often contains enhancement and fixes
bugs.
● Service Pack- large collection of patches and hotfixes rolled into a single large pack.
Disabling unnecessary ports and services- minimizes risk
Least functionality- system should be deployed with the least amount of applications, services
and protocols.
Secure configurations
Trusted operating system- meets a set of predetermined requirements of the organization.
# Defined by EAL4.
Application whitelisting/blacklisting- Whitelist: list of applications authorized to run. Blacklist:
list of applications a system block.
Disable default accounts/passwords-
Peripherals
Wireless keyboards & Wireless mice- can send information in clear text. Risk of keylogging.
Wireless mouse is susceptible to mouse spoofing but not malware infection.
Displays- if the display shows sensitive or private data, their view should be limited. Disable
telnet if being used to download content from the internet.
Wi-Fi-enabled MicroSD cards
Printers/MFDs- can be remotely managed. Turn off telnet, SSH if not using.
External storage devices- data exfiltration risk
Digital camera
● Continuous Integration-
o ELI5: There is a central repository of mainline code. As a software developer you
check out the part of code, work on it for a day and merge it. If conflict occurs, it's
easier to fix because it's just one day worth of work.
o It includes a version control and supports roll back.
o involves a series of steps that are automatically performed to integrate code from
multiple sources, create a build and test. Each time a build or a set of code
passes the tests, it’s automatically deployed out to a staging environment where
further testing such as load testing and manual exploratory testing is conducted.
This process can be repeated for days depending upon the project delivery
requirements.
o CI is done using platforms designed specifically for the purpose and
implementing CI is as simple as using the right tool. E.g. Jenkins, Bamboo.
o CI server runs automated tests on every new commit that emerges into the
remote repository mainline. Also issues custom notifications when a test or build
fails, triggering releases generation, triggering deployments to a specific
environment and so on.
● Baselining- applying changes to the baseline code every day and building the code
from these changes.
● Immutable Systems- servers are never modified after they’re adopted. If something
needs to be updated, fixed, or modified in any way, new servers built from a common
image with the appropriate changes are provisioned to replace the old ones.
● Infrastructure as code-
o means by which engineers define the computer systems their code needs to run.
o refers to managing and provisioning data centers with code and that defines the
VM.
o Configuration Orchestration tools like Terraform and AWS CloudFormation are
designed to automate deployment of servers and other infrastructure
o Configuration management tools like Chef, Puppet help configure the software
and systems on this infrastructure that has already been provisioned.
Version control and change management- change management prevents unauthorized
changes. version control system documents each change with rollback features. Tracks who
made the change and when.
Provisioning and deprovisioning- allocating resources based on demand of that resource.
Deprovisioning an app means removing the app.
Secure coding techniques
● Proper error handling- applications should show generic error messages to users but
log detailed information. If an application doesn’t catch an error, it often provides
debugging information that an attacker can use against the application. Control the
information provided when the application catches an error.
● Proper input validation- check input data for validity before using it. For e.g. verify
proper characters, block HTML code and certain characters used by SQL like -, ‘, = etc.
to prevent SQL injection.
● Normalization- organizing the tables and columns to reduce redundant data and
improve overall database performance.
● Stored procedures- SQL queries that execute on the server side instead of the client
application. The client application calls the procedure on the server and this prevents the
client from making any changes to the actual SQL queries.
Create a SQL code and save it. Next time you need to run the code, you can use the
stored procedure instead of building from scratch. Also provides security by not allowing
any code to run. Prevents SQL injection attack.
● Code signing- applying digital signature to code for verifying the code integrity.
● Encryption
● SaaS- Appropriate for highly scalable, on-demand applications. Eg. google mail, google
docs etc. availability
● PaaS- Suitable for STANDARD resources. Provides customers with a fully managed
platform, which the vendor keeps up to date with current patches. provides infrastructure
to create and host applications.
● IaaS- Appropriate for highly customized, poorly scaling solutions that require specific
resources to run. provides customers with access to hardware in a self-managed
platform. Customers are responsible for all OS updates and patches.
● Private- costly
● Hybrid
● Configuration validation- ensure that the system will do what it is supposed to do and
only what it is supposed to do with no added functionality.
Templates- allow rapid, error-free creation of systems and services, including configurations,
connection of services, testing and deployment.
Master Image- premade fully patched image of your organization’s system
Non-persistence- does not save changes to configuration or application
● Snapshots- easy to revert to the previous configurations if the change contains errors.
● RAID 5- block-striped with error check. Provides High Availability because 3rd drive is a
parity drive that has data building information
● RAID 10- stripe of mirrors
3.9 Physical Security Controls
Lighting- allows more people and activities to be observed.
Signs- visual cues. keep people away from restricted areas
Fencing/gate/cage- build a perimeter
Security guards
Alarms- set to provide accurate and useful alerts.
Safe
Secure cabinets/enclosures
Protected distribution/Protected cabling- physically secure cable to prevent tapping and DoS
Air Gap- a method of isolating an entity to effectively separate it from everything else. Provides
physical isolation
Mantrap- prevents tailgating. Controls access to the data center.
Faraday Cage- prevents illicit monitoring of computer systems through Van Eck emissions.
blocks electromagnetic fields.
Lock types- smart locks are a type of cipher lock that can be programmable. E.g. Keyscan
system. Mechanical locks can be warded or tumbler. Combination lock requires correct
combination.
Biometrics- Biometric features can change over time with medical conditions. Re-identification
needed
Barricades/bollards- blocks vehicles
Tokens/cards- RFID badge. better than metallic keys because it can be revoked remotely
Environmental controls
● HVAC- provides cooling capacity
● Hot and cold aisles- provides cooling in the data center via proper air flow.
● Fire suppression- FM-200 is a Fire Extinguishing system. Water and soda acid are
used in class A fire (paper, laminates, wooden furniture). Halon or CO2 was used for
class C fire (electrical wiring & distribution boxes). Halon destroys Ozone. Use dry
powder for combustible metal.
Cable locks- effective for small equipment
Screen filters
Cameras- can replace security guards.
Motion detection-
Logs
Infrared detection- detects changes in heat waves
Key management
4.0 Identity and Access Management
4.1 Identity and access management concepts
Identification, authentication, authorization and accounting (AAA)
● Identification- when users claim their identity with username, email etc.
Multi-Factor authentication
● Something you know- password, PIN-------------------- Type I authentication
● Something you do- gesture in touch screen, signature, keyboard cadence (timing)
Federation
● provides central authentication between 2 or more nonhomogeneous environments by
using a federated identity management system, often integrated as a federated
database.
● Most significant disadvantage of federated identities is transitive trust. The security of
federated identities is impacted by the security of others.
Single Sign-On (SSO)- enhances security by requiring users to use and remember only one
set of credentials for authentication.
Transitive trust
● creates an indirect trust relationship.
● If A trusts B and B trusts C, A trusts C because of a transitive relationship.
● During the use of the Kerberos protocol, KDC stores, distributes and maintains both
cryptographic session keys and secret keys.
● The master key is used to exchange the session keys.
● The keys are automatically distributed to the communicating client and the server.
● The KDC also provides the authentication services for the users.
Kerberos is a network authentication protocol in AD or Unix. Requires
1. A method of issuing tickets used for authentication- KDC: has 2 parts- Authentication
Server (AS) and Ticket-Granting Server (TGS)
2. Time synchronization
3. A database of subjects or users.
#Kerberos by default does not provide SSO but can be enabled.
TACACS+
● alternative to RADIUS but cisco proprietary.
● TACACS is the first generation and combines the authentication and auditing process.
● XTACACS is the second generation and separates the authentication, authorization and
auditing processes.
● TACACS+ is the 3rd generation and provides all the features of XTACACS along with
extended two-factor user authentication.
● TACACS+ uses multiple challenge responses for authentication, authorization and
auditing.
● It can interact with Kerberos and encrypts the entire authentication process which are its
benefits over RADIUS.
● TACACS+ client sends START and CONTINUE packets and the server sends REPLY
packets.
# communications between a user (typically a PC) and the TACACS+ client are subject to
compromise as they are usually not encrypted.
● Uses TCP 49
CHAP-
● uses username and password combination to authenticate users.
● Used in PPP so its most common application is dial-up internet access user
authentication.
● More secure than PAP.
● uses a 3-way handshake process to prevent replay attack where the server challenges
the client.
● Client then responds with appropriate authentication information.
● Stops Session hijacking. RADIUS and PAP don't.
PAP-
● Password Authentication Protocol sends passwords in clear text.
● Use only as a last resort when the remote server does not support a stronger scheme
such as CHAP or EAP.
● PPP uses PAP with dialup connection for authentication.
MSCHAP-
● Microsoft’s CHAP is used by its client. Replaced by MSCHAPv2.
● It performs mutual authentication.
● Client authenticates to Server and Server authenticates to client.
RADIUS-
● Cross-platform remote access protocol
● Provides AAA.
● Centralized method of authentication for multiple remote access servers.
● RADIUS encrypts the password packets but not the entire authentication process.
● Uses UDP 1813 for accounting and 1812 for authenticating.
DIAMETER-
● An improvement over RADIUS
● Utilizes EAP, thereby providing better security than RADIUS
● Created to deal with VOIP and wireless services.
● Diameter was designed to be backwards compatible with RADIUS, some RADIUS
servers have trouble working with Diameter servers.
SAML- (Security Assertion Markup Language )
● an XML based standard used to exchange authentication and authorization information
between different parties.
● Not good for mobile.
○ Principal- user
○ Identity Provider (IdP)- source of identity information and authentication decision.
authenticates principals and returns identity information to service providers. E.g.
Auth0, ADFS, and Okta.
○ Service Providers (SP)- services that are requesting authentication and identity
information about the principal.
OpenID Connect-
● allows clients to verify the identity of end users without managing their credentials.
● good for mobile. uses JWT Tokens.
● E.g. Many applications allow users to sign in using their Facebook credentials.
● OpenID works with OAuth and supports REST.
● OpenID connect is used for authentication while using OAuth for authorization
OAuth-
● Uses similar methodology as SAML to share login information
● SAML provides more control to enterprises to keep their SSO logins more secure,
whereas OAuth is better on mobile.
● Many companies use it to provide secure access to protected resources.
● Ex. you can use the same account with Google, Facebook, PayPal, Twitter etc.
Primary use SSO for Enterprise SSO for consumer apps API authorization
case
Shibboleth-
● open source and freely available federated identity solution.
● Includes open SAML libraries written in C++ and Java, making it easier for developers to
expand its usefulness.
Secure token-
● provides for authentication across stateless platforms and
● can be used to identify the holder of the token to any service that uses the WS-Trust
standard.
● Tokens are transportable.
NTLM-
● legacy proprietary SSO protocols that provide authentication, integrity and confidentiality
within windows systems.
● Replaced by Kerberos
● They use a MD hashing algorithm to challenge users and check their credentials which
is weak and ineffective.
● Smart cards- has embedded microchips and a certificate. The embedded certificate
holds users’ private key and is matched with a public key.
Biometric factors
● Fingerprint Scanner- For authentication and identification
● Retinal Scanner- use the pattern of blood vessels at the back of the eye. Most intrusive.
● Iris Scanner- pattern of the iris around the pupil. Compares the picture of the iris.
o MFA is better than just an Iris scanner.
● Voice recognition- uses speech recognition to identify acoustic features. Least
intrusive.
● Facial recognition- based on facial features
Tokens- key fob with LCD that displays a number for a one time use and changes periodically.
Uses one-time password authentication. can store digital certificates.
Token is provided with each request to the server. No session information is stored on the
server.
● Hardware- Key fob like token
● Shared and generic accounts/credentials- should not be used otherwise IAAA cannot
be implemented
● Guest accounts- limited access to computer or network. Shared logon.
● Service accounts- used by the service or application and not an end user.
● Privileged accounts- has additional rights and privileges beyond a regular user
General concepts
● Least privilege- technical control where users or processes are granted only those
rights and permissions needed to perform their assigned tasks or functions.
● Onboarding/Offboarding
● Disablement- disable account as soon as possible. Disabling the account ensures that
user security keys (cryptographic keys) are retained. If the keys are deleted (such as
when the account is deleted), it might not be possible to access files that the user
encrypted.
● Lockout- prevent users from guessing password
● Password history- implement system to remember password history and prevent user
to reuse
● Password reuse- prevent reuse of password
● Password length- enforces character length. More significant than password history or
password age.
5.0 Risk Management
5.1 Importance of policies, plans and procedures
Standard Operating Procedure- step by step instructions employees can use to perform
common tasks
Agreement types
● BPA- relationship between 2 partners including their obligations toward the partnership.
Helps settle conflict when they arise. Just establishes expectations. Includes profit/loss
sharing and addition/subtraction of partners.
● SLA- performance expectations from vendors such as minimum uptime and maximum
downtime levels.
● ISA- Interconnection Security Agreement. Technical and security requirements for
planning, establishing, maintaining and disconnecting a secure connection between 2 or
more entities.
● MOU/MOA- defines responsibilities of both parties. Not as strict as SLA or ISA
onot as formal as a traditional contract but still has a level of importance to all
involved parties
Personal management
● Mandatory vacations- helps to discover malicious activities while the employee is
away.
● Job rotation- ensures employees cannot continue malicious behavior.
● Separation of duties- prevents one person from controlling all critical functions.
● Continuing education
● Acceptable use policy/rules of behavior- purpose of IT equipment for users and their
responsibilities when they access the systems.
● Adverse actions- actions against employees when wrongdoing has been found. E.g.
Josh is a bank manager and has suspicions that one of his tellers has stolen money
from their respective station. After talking with his supervisor, he places the
employee on leave with pay, changes their computer account to suspended, and
takes their prox card and building keys
General security policies
● Social media networks/applications
MTBF- Mean Time Between Failures is a prediction of how often a repairable system will fail.
MTTR- Mean Time to Restore/Repair identifies the average time to restore a failed system
MTTF- expected lifetime of a non-repairable system.
Mission-essential functions
Identification of critical systems
Single Point of Failure- weakness which can enable one fault to cause a whole system to stop
operating. A configuration can be a SPoF. A cluster is not SPoF because it has several systems
connected together to rely on each other.
Impact- cost associated with a realized risk
● Life
● Property
● Safety
● Finance
● Reputation
Privacy impact assessment-
● Identifies potential risks related to PII
● ensures the organization is complying with laws and regulations.
Privacy threshold assessment-
● analysis of whether PII is collected and maintained by a system.
● Risk register- comprehensive document listing known information about risks. Typically
includes risk scores along with recommended security controls.
● Likelihood of occurrence- chance that a particular risk can occur
● Testing
o Penetration testing authorization
o Vulnerability testing authorization- Tools: Password crackers, network
scanners (ping, SYN stealth, port, service OS), Network mapping, wireless
scanner/cracker, rogue system detection, banner grabbing
● Risk response techniques
Accept- low cost or low impact risk can be accepted.
o
Transfer- purchasing insurance, outsourcing or contracting a third party.
o
Avoid- by not participating in risky activity. Ex. avoiding an application that
o
requires too many ports open in the firewall.
o Mitigate- implement controls. Using antivirus to mitigate risk of malware.
Change management
● Lessons learned- Perform a root cause analysis and document any lessons learnt.
● Record time offset- difference between the system clock and the actual time.
● Screenshots- take pictures before analysis. shows the state of a computer at the time it
was collected by law enforcement
● Witness interviews- for first hand report
Preservation
Recovery- restoring of lost data
● Incremental- backs up all the data that has changed since the last full or incremental
backup. quickest to backup but slowest to restore.
● Snapshots- captures the data at a point in time. Image backup. If a system crashed,
restoring the snapshot would be the fastest way to restore the system.
● Full- backs up all selected data
Geographic considerations
● Off-site backups- copy of backup in a separate geographic location
● Distance- some needs to be really close so that backups can be easily retrieved. Some
need to be far away so that it is saved from geographical disaster.
● Location selection
● Data sovereignty- data stored within their borders is subject to their laws. Data
originating within their borders must be stored there.
Continuity of operation planning
● Exercises/tabletop
● After-action reports
● Failover- process for moving from a normal operational capability to the continuity-of-
operations version of the business.
● Alternate processing sites- involve contracting with a third party, who provides a
location and equipment to be used in the event of an emergency.
● Alternate business practices- new sites might not have everything needed for normal
operations so seek for alternate business practices. Ex. work from home, revert to paper
and pen.
● Shredding- repeatedly overwriting the space where the file is located with 1s and 0s.
● Wiping- bit level overwriting process. DoD standard 5220.22-M recommends 7 wipes to
completely wipe data.
Data sensitivity labeling and handling
● Confidential- secret among a certain group of people
Low power devices- ECC is used for low-power application. Use it for wireless devices,
handheld computers, smart cards etc.
Low latency- Stream ciphers have low latency
High resiliency- addresses the issue of data leakage from a side-channel attack.
Supporting confidentiality- use encryption
Supporting integrity- use hashing
Supporting obfuscation- accomplished through encryption and steganography
Supporting authentication- validating that the message originator is indeed who they say they
are. Often implemented using digital certificates.
Supporting non-repudiation- use digital signatures
Resource vs. security constraints- resource constraints include available bandwidth, financial
constraints etc. Security constraints would deal with the limitations of the particular cryptography
chosen.
6.2 Cryptography algorithms and their basic characteristics
Symmetric Algorithms:
AES 128-bit 128, 192, 256 Fast, Strong, Efficient (less resource intensive)
3DES 64 56, 112, 168 Triple DES; Uses 48 rounds of computation. Used in
legacy hardware that does not support AES
RC4 Stream 1-2048 Rivest Cipher; Susceptible to weak keys. Used in WEP.
Cipher
Cipher modes
● It divides the plaintext into blocks and encrypts each block using the SAME key.
● Uses a special binary field (called a Galois field) to provide authenticated encryption.
Stream vs. block- Stream cipher process one bit at a time and block cipher process one block
of bits at a time. Block cipher example- DES, AES, IDEA, Blowfish, RC5
Asymmetric algorithms
● If the private key encrypts information, only the matching public key can decrypt it
RSA
● Provides both encryption and authentication.
● uses the product of 2 very large prime numbers. It is difficult to factor large prime
numbers. Therefore, it is difficult to break the encryption.
● Requires higher processing power due to the factorability of numbers but ensures
efficient key management.
● TPMs and Hardware Security Modules (HSMs) provide secure storage for RSA keys.
● Based on Diffie-Hellman key exchange concepts using static keys.
● Used as a de facto standard for Digital Signatures.
● Can prevent MITM attack by providing authentication before the exchange of public and
private keys.
● Lacks Forward Secrecy so if an attacker records the encrypted packet and steals the
private key, data is exposed.
● Use RSA and DH together for authentication and perfect forward secrecy.
DSA
● Digital signature standard for the US government.
● Published by NIST and NSA.
Diffie-Hellman
● A key exchange algorithm. privately shares symmetric keys over the public network.
Supports both static and ephemeral keys. Commonly used for TLS.
● Does not encrypt actual data.
● Vulnerable to MITM because DH does not have an authentication mechanism. Use RSA
with DH for authentication.
● Groups- more than 25 groups: DH Group 1, DH Group 2 and so on. Higher means more
secure. E.g. DH group 1 uses 768 bits, DH group 2 uses 3072 etc.
● DHE- Diffie-Hellman Ephemeral. Generates different keys for each session.
● ECDHE- Elliptic Curve Diffie-Hellman Ephemeral. Uses ephemeral keys generated using
ECC.
# ELGamal is an asymmetric public key encryption algorithm based on the Diffie-Hellman key
agreement.
Elliptic curve- requires less processing power but is difficult to crack. Used for low-power
devices like small wireless devices.
PGP/GPG-
● PGP establishes a web of trust between users which means the users generate and
distribute their public key.
● These keys are signed by users for each other, establishing a community of users who
trust each other for communication.
● Every user has a collection of signed public keys stored in a file known as a key ring.
● A level of trust and validity are associated with each key in that list.
● For example, if A trusts B more than C, there will be a higher level of trust for B
compared to C.
● PGP does not use either CA servers or formal trust certificates. The users trust each
other. In a PKI, CAs are arranged in a hierarchy and sign public key pairs.
● If a user wants to receive a file encrypted with PGP, the user must first supply the public
key.
● Some PGP follows S/MIME standards and some follow OpenPGP. GNU Privacy Guard
(GPG) is a free software based on the OpenPGP standard. GPG is an alternative to the
PGP.
PGP can encrypt, decrypt and digitally sign email. Flexible use of both symmetric and
asymmetric algorithms. PGP provides following functionalities:
● Confidentiality through IDEA (International Data Encryption Algorithm)
Hashing algorithms:
Techniques used to increase the strength of stored passwords by salting it. Helps prevent brute
force and rainbow table attacks.
BCRYPT- adds additional salt before encrypting with Blowfish. Uses on UNIX and Linux.
PBKDF2- Password-Based Key Derivation Function 2. Adds a salt of at least 64 bits. Used in
WPA2, Apple iOS and Cisco OS.
Obfuscation:
XOR- eXclusive OR uses a binary key to create a cipher text. By itself, XOR does not provide a
high level of security. Consequently, it is used in combination with symmetric ciphers.
ROT13- rotates 13 places.
Substitution ciphers- replaces plaintext with ciphertext using a fixed system. E.g. ACE to BDF
has a 1 letter fixed system.
WPA-
● improved wireless security by giving alternatives to WEP with existing hardware.
● Susceptible to password cracking attacks.
● Attacker uses protocol analyzer to capture the authentication traffic and then uses an
offline brute force attack to discover the passphrase.
● Supports older devices.
WPA2-
● permanent replacement for WPA.
● supports CCMP (based on AES) which is much stronger than the older TKIP protocol.
CCMP-
● Counter Mode with Cipher Block Chaining Message Authentication Code Protocol
● Mode in which the AES cipher is used to provide message integrity.
● much more secure than TKIP.
● WPA2 with CCMP only uses a PSK, not usernames.
TKIP-
● Temporal Key Integrity Protocol
● Used with WPA.
● Not secure anymore.
Authentication protocols:
IEEE 802.1x-
● Port based authentication.
● More secure than simply disabling unused ports or MAC filtering.
● Secures the authentication process prior to a client gaining access to the network. Can
be implemented with RADIUS or DIAMETER, LDAP, TACACS+ etc.
● 802.1x is a network-based authentication protocol that opens ports for network access
when an organization authenticates a user’s identity and authorizes them for access to
the network.
● The user’s identity is determined based on their credentials or certificate, which is
confirmed by the RADIUS server.
● The RADIUS server is able to do this by communicating with the organization’s directory,
typically over LDAP or SAML protocol.
● When a user is authenticated via 802.1x for network access, a virtual port is opened on
the access point allowing for communication.
PEAP-
● encapsulates EAP within TLS. Hence, protected EAP.
● EAP was designed assuming a secure communication channel.
● Authenticates Wi-Fi clients using only server-side certificates.
EAP-FAST-
● EAP Flexible Authentication via Secure Tunneling.
● Cisco’s proposal to replace LEAP. Retains the “Lightweight” implementation.
● Uses PAC (Protected Access Credentials) to establish the TLS tunnel in which the
client's credential is verified.
● Consists of 3 phases- provisioning, establishment of a tunnel and authentication.
EAP-TLS-
● Relies on client-side and server-side certificates to perform authentication
● Advantage: a compromised password is not enough to break EAP-TLS. Intruder still
needs info on the client-side certificate.
● One drawback is that the certificates must be managed on both the client and server
side.
● Unlike most TLS implementations of HTTPS, such as on the World Wide Web, the
majority of implementations of EAP-TLS require client-side X.509 certificates without
giving the option to disable the requirement, even though the standard does not
mandate their use. Some have identified this as having the potential to dramatically
reduce adoption of EAP-TLS and prevent "open" but encrypted access points.
EAP-TTLS-
● TTLS encapsulates the TLS session, allowing for ANY authentication of the client.
● Authenticates clients using only server-side certificates.
● encrypts user credentials when users enter their usernames and passwords.
Implemented in Enterprise mode and would use an 802.1x server.
RADIUS Federation-
● a group of RADIUS servers that assist with network roaming.
● The servers will validate the login credentials of a user belonging to another RADIUS
server’s network.
● The use of SSL-based tunneling and EAP packets makes the distributed authentication
of RADIUS possible.
Methods:
PKI- group of technologies used to request, create, manage, store, distribute, and revoke digital
certificate.
# Issuer signs the certificate. Principal possesses a public key. Verifier verifies a public key
chain. Subject seeks to have a certificate validated.
CA- Certificate Authority. Issues, manages, validates and revokes certificates. E.g. VeriSign,
GoDaddy.
Intermediate CA- Issues certificates that have been issued by a root authority or by another
higher-level intermediate authority. Organizations frequently take the root CA offline for security
reasons and allow the intermediate CA to actually issue certificates.
CRL- list of revoked certificates and is publicly available. Typically cached so not up-to-date.
Has a latency period of 24-48 hours. Is slowly being replaced by OCSP.
# Revoked certificates cannot be renewed. If a certificate is revoked, you must create a new
certificate and key pair.
OCSP- Online Certificate Status Protocol. If CA revokes a certificate, the client using OCSP will
know immediately. Generates a lot of real-time traffic.
CSR- Certificate Signing Request is a message sent from a user or application to a CA to apply
for a digital certificate. Create RSA-based private key
Certificate- digital document that includes public key and information on the owner of the
certificate: serial number, issuer, validity dates, subject, public key, usage etc.
Public key- publicly available.
Private key- should be kept secret. If the private key is exposed, a new public-private key
should be created.
Object identifiers (OID)- optional extensions for X.509 certificates. They are dotted decimal
numbers that would assist with identifying objects. E.g. 2.5.4.9 would identify a street address.
Concepts
Online vs. offline CA- Online CS is always connected, accessible and vulnerable. An offline
CA is isolated from the network which reduces the likelihood that it could be compromised. For
this reason, organizations frequently take the root CA offline and allow the intermediate CA to
actually issue certificates.
Stapling (timestamp)- Web server staples timestamped OCSP response to a certificate to
prevent traffic for each OCSP request to CA.
Pinning (host)- helps identify a fraudulent certificate. Once a certificate is associated with a
certain host, that certificate is “pinned” to the host. In the event that another certificate is
presented for the same host, it is likely that the new certificate is not valid.
When configured with public key pinning, the server responds to client HTTPS requests with an
extra header which includes a list of hashes derived from valid public keys used in the website.
Also includes a max-age field specifying how long the client should store and use the data.
Trust model- defines how various CAs trust each other. Also defines how the client of a given
CA would trust the certificate from another CA. E.g.
● PGP uses the Web of Trust model.
● Kerberos uses KDC.
● PKI uses CA.
Key escrow
● addresses the issue that a key might be lost.
● It's a proactive approach where copies of the private keys are held in escrow (stored) by
a third party.
● The third party (key recovery agent) manages access to and use of the private keys.
Certificate chaining- refers to the trust relationships between CAs and helps determine which
certificate has the highest-level trust. For example, if you get a certificate from “A” and “A” trusts
the root certificate, the highest-level trust is the root certificate.
Types of certificates
Wildcard- can be used for multiple domains provided the domain name has the same root
domain. *.google.com
Subject Alternate Name (SAN)- allows you to add additional information such as an IP, host
name associated with the certificate. also used for multiple domains that have different names.
E.g. Google uses SANs of *.google.com, *.android.com, *cloud.google.com
Code signing- process of assigning a certificate to code (executables). Uses digital signatures
to provide an assurance that the software code has not been modified.
Self-signed- digitally signed by users. Often provided by IIS. a self-signed certificate will
transmit a public key but that key will be rejected by browsers.
Machine/Computer- issued to a device or a computer. Identifies the computer within a domain.
Email- encryption of email and digital signature uses email certificate. E.g. S/MIME
User- can be issued to users. Used for encryption, authentication, smart cards, and more.
Root- first certificate created by the CA that identifies itself. If the CA’s root certificate is placed
in the store, all certificates issued by this CA are trusted.
# The root CA must certify its own public key pair.
Domain validation- low-cost and are often used by web admins to offer TLS to a domain. They
are validated using only the domain name.
Extended validation- provides additional validation for HTTPS web sites. The certificate
provides the name of the legal entity responsible for the website. Provides a higher level of trust
than domain validation because they are validated using more than the domain information.
Certificate formats
CER
● contains the certificate encoded in encrypted Base64.
● Storage of a single certificate. Does not support storage of the private key or certification
path.
● Can be read by Windows servers.
P7B (PKCS#7)
● Only contains certificates and chain certificates, not the private key
DER
● The parent format of PEM.
PFX (PKCS#12)
● Provided enhanced security versus the plain-text PEM format.
● Supports storage of private and public keys and all certificates in the path in one
encrypted file.
● Preferably used by Windows and can be freely converted to PEM through use of
openSSL.