Jeremy’s IT Lab lecture video:

Day 48 - Security Fundamentals


Commands

No Commands :)


Security Fundamentals Info

CIA Triad

The CIA triad forms the foundation of security. It consists of:

  1. Confidentiality
    • Only authorized users should be able to access data.
    • Some data is available publicly while some is secret and is meant to be accessed by specific people.
  2. Integrity
    • Data should not be tampered with (modified) by unauthorized users.
    • Data should be correct and authentic
  3. Availability
    • The network and its systems should be operational and accessible to authorized users.

Vulnerability, Exploit, Threat, Mitigation

  1. Vulnerability
    • It is any potential weakness that can compromise the CIA triad of a system.
  2. Exploit
    • It is something that can potentially be used to exploit the vulnerability.
  3. Threat
    • It is the potential of a vulnerability to be exploited.
  4. Mitigation
    • A mitigation technique is something that can protect against threats.

Common Attacks

1. Denial of Service

Denial of Service (DoS) or Distributed Denial of Service (DDoS) attacks are attacks that threaten the availability of a system.

Example DoS attack: TCP SYN flood

A common DoS attack is the TCP SYN flood attack, where an attacker will send a big amount of TCP connection requests without actually initiating a connection, which will fill up the target’s TCP connection table.

  • This attack is accomplished through the following steps:
    • TCP three-way handshake: SYN || SYN-ACK || ACK
    • The attacker sends countless TCP SYN messages to the target.
    • The target sends a SYN-ACK message in response to each SYN it receives.
    • The attacker never replies with the final ACK of the TCP three-way handshake.
    • The incomplete connections fill up the target’s TCP connection table.
    • The attacker continues sending SYN messages.
    • The target is no longer able to make legitimate TCP connections.
TCP SYN flood Demonstration

In a DDoS attack, the attacker infects many target computers with malware (called a botnet) and uses them to initiate a DoS attack, like the TCP SYN flood.

2. Spoofing

Spoofing attacks aren’t a single type of attack, as they are usually used with other types of attacks.
To spoof an address is to use a fake source IP/MAC address.
Some examples of spoofing can be seen in TCP SYN flood attacks or DHCP exhaustion.

Example Spoofing attack: DHCP Exhaustion

  • In DHCP Exhaustion, an attacker uses a spoofed MAC address to flood DHCP Discover messages.
  • This results in the target’s DHCP pool becoming full, resulting in a DoS to other devices.
DHCP exhaustion Demonstration

3. Reflection/Amplification

A reflection/amplification attack is an attack that’s used to send large amounts of data to a target in order to cause a DoS.

  • In a reflection attack, the attacker sends traffic to a reflector, and spoofs the source address of its packets using the target’s IP address.
  • The reflector sends the reply to the target’s IP.
  • If the amount of data sent to the target is large enough, it can result in a DoS.

A reflection attack become an amplification attack when the amount of traffic sent by the attacker is small, but it triggers a large amount of traffic to be sent from the reflector to the target.

Reflection/Amplification Demonstration

4. Man-in-the-middle

A man-in-the-middle involves the attacker placing himself between the source and destination to eavesdrop on communications, or modify traffic before it reaches the destination.

These attacks compromise the Confidentiality and Integrity of communications.

Example man-in-the-middle attack: ARP Spoofing

ARP Spoofing, also known as ARP Poisoning is a common man-in-the-middle attack.

  • A host sends an ARP request, asking for the MAC address of another device.
  • The target of the request sends an ARP reply, informing the requester of its MAC address.
  • The attacker waits and sends another ARP reply after the legitimate replier.
  • If the attacker’s ARP reply arrives last to the host, it will overwrite the legitimate ARP reply in the host’s ARP table.

  • In the host’s ARP table, the entry for the target will have the attacker’s MAC address.
  • Therefore, when the host tries to send information to the target, it will forwarded to the attacker instead, where the data can be inspected and even modified before it is sent to the actual recipient (Target) of the data.
ARP Spoofing Demonstration

5. Reconnaissance

Reconnaissance attacks aren’t actual attacks by themselves, but they are used to gather information about a target which can be used for a future attack.

  • It often includes publicly available information. Such as:
    1. The nslookup result for a website.
    2. A WHOIS query for a website in order to learn email addresses, phone numbers, physical addresses and etc.

6. Malware

Malware (malicious software) refers to a variety of harmful programs that can infect computers. They can threaten any part of the CIA triad. Some types of malware are:

  1. Viruses
    • They infect other software (a ‘host program’).
    • The virus spreads as the software is shared by other users.
    • They typically corrupt or modify files on the target computer.
  2. Worms
    • They do not require a host program.
    • They are standalone malware and they are able to spread on their own without user interaction.
    • The spread of worms can congest the network, but the ‘payload’ of a worm can cause additional harm to target devices.
  3. Trojan Horses
    • They are harmful software that are disguised as legitimate software.
    • They are spread through user interaction such as opening email interactions or downloading a file from the internet.

7. Social Engineering

Social engineering attacks involve targeting people, which are the most vulnerable part of any system.
These attacks involve psychological manipulation to make the target reveal confidential information or perform a specific action.
These attacks include.

  1. Phishing
    • Typically involves fraudulent emails that appear to come from a legitimate business, and they contain links to fraudulent websites that seem legitimate. It is used to steal information.
    • There are multiple types of phishing:
      • Spear phishing is a more targeted form of phishing, ie. aimed at employees of a certain company.
      • Whaling is phishing targeted at high-profile individuals, ie. a company president.
      • Vishing (voice phishing) is phishing performed over the phone.
      • Smishing (SMS phishing) is phishing using SMS text messages.
  2. Watering hole
    • They are attacks that compromise sites that the victim frequently visits.
    • If a malicious link is placed on the website that the target trusts, they are more likely to click on it without hesitation.
  3. Tailgating
    • They are attacks that involve entering restricted, secured areas by simply walking in behind an authorized person as they enter.

Most systems use a username/password combo to authenticate users.

Usernames are often easy to guess, and the strength of the password is relied on to provide security. Some methods of learning a user’s password include:

  1. Guessing
  2. Dictionary Attacks
    • A program runs through a ‘dictionary’ of common words/passwords to find the target’s password.
  3. Brute-force Attacks
    • A program tries every possible combination of letters, numbers and special characters to find the target’s password.

Multi-Factor Authentication (MFA)

Multi-Factor Authentication (MFA) involves providing more than just a username/password to authenticate. It usually involves two of the following:

  1. Something you know
    • A username/password combo, PIN and etc.
  2. Something you have
    • Pressing a notification that appears on your phone, a badge that is scanned and etc.
  3. Something you are
    • Biometrics such as fingerprints, face scan, palm scan, retina scan and etc.

Requiring multiple factors of authentication greatly increases security. Even if an attacker learns the target’s password (something you know) for example, they won’t be able to get authenticated unless they provide a second form of authentication.


Digital Certificates

Digital certificates are another form of authentication used to prove the identity of the holder of the certificate.

  • They are used for websites to verify that the website being accessed is legitimate.

Authentication, Authorization, Accounting (AAA)

Authentication, Authorization, Accounting (AAA) is a framework for controlling and monitoring users of a system. It consists of:

  1. Authentication
    • The process of verifying a user’s identity.
  2. Authorization
    • The process of granting the user the appropriate access and permissions.
  3. Accounting
    • The process of recording the user’s activities on the system.

Enterprises typically use an AAA server to provide AAA services.

  • ISE (Identity Services Engine) is Cisco’s AAA server.

AAA servers usually support the two following AAA protocols:

  1. RADIUS
    • Open standard.
    • Uses UDP ports 1812 - 1813
  2. TACACS+
    • Cisco proprietary.
    • Uses TCP port 49

Security Program Elements

  1. User awareness
    • Programs that are designed to make employees aware of potential security threats.
  2. User training
    • Programs that are more formal than user awareness programs which educate users on the corporate security policies.
  3. Physical access control
    • Used to protect equipment and data from potential attackers by only allowing authorized users into protected areas such as network closets or data center floors.

Jeremy’s IT Lab előadásvideó:

48. Nap - Biztonsági Alapismeretek


Parancsok

Nincsenek parancsok :)


Biztonsági Alapismeretek (Security Fundamentals)

A CIA Triád (CIA Triad)

A CIA triád képezi az információbiztonság alapját. Három pillérből áll:

  1. Confidentiality (Bizalmasság)
    • Csak a jogosult felhasználók férhetnek hozzá az adatokhoz.
    • Egyes adatok nyilvánosan elérhetők, míg mások bizalmasak, és csak meghatározott személyek számára hozzáférhetők.
  2. Integrity (Sértetlenség)
    • Az adatokat illetéktelen felhasználók nem módosíthatják.
    • Az adatoknak pontosnak, helyesnek és hitelesnek kell lenniük.
  3. Availability (Rendelkezésre állás)
    • A hálózatnak és a rendszereknek működőképesnek és elérhetőnek kell lenniük a jogosult felhasználók számára.

Sebezhetőség, Kihasználás, Fenyegetés, Kockázatcsökkentés

  1. Vulnerability (Sebezhetőség)
    • Bármilyen potenciális gyengeség, amely veszélyeztetheti egy rendszer CIA triádját.
  2. Exploit (Kihasználás)
    • Olyan eszköz vagy módszer, amely felhasználható a vulnerability kihasználására.
  3. Threat (Fenyegetés)
    • Annak a lehetősége, hogy egy vulnerability-t kihasználnak (exploited).
  4. Mitigation (Kockázatcsökkentés)
    • Olyan technika, amely védelmet nyújt a fenyegetésekkel szemben.

Gyakori Támadások

1. Szolgáltatásmegtagadás (Denial of Service)

A Denial of Service (DoS) vagy az elosztott Distributed Denial of Service (DDoS) támadások a rendszer rendelkezésre állását veszélyeztetik.

Példa DoS támadásra: TCP SYN flood

Egy gyakori DoS támadás a TCP SYN flood, ahol a támadó hatalmas mennyiségű TCP kapcsolatfelvételi kérést küld a célpontnak anélkül, hogy ténylegesen felépítené a kapcsolatot, így megtelve a célpont TCP kapcsolattáblája.

  • A támadás lépései:
    • TCP three-way handshake: SYN || SYN-ACK || ACK
    • A támadó rengeteg TCP SYN csomagot küld a célpontnak.
    • A célpont minden SYN-re egy SYN-ACK üzenettel válaszol.
    • A támadó sosem küldi el a TCP three-way handshake utolsó ACK lépését.
    • A függőben lévő kapcsolatok feltöltik a célpont TCP kapcsolattábláját.
    • A támadó folyamatosan küldi a SYN üzeneteket.
    • A célpont már nem tud új, legitim TCP kapcsolatokat fogadni.
TCP SYN flood szemléltetése

A DDoS támadásnál a támadó rengeteg számítógépet fertőz meg kártevővel (ezt nevezik botnet-nek), és ezekkel hajt végre DoS támadást.

2. Megszemélyesítés / Címhamisítás (Spoofing)

A Spoofing nem egyetlen támadástípus, általában más támadások részeként használják.
A spoofolás során a támadó hamis forrás IP/MAC címet használ.
Példák a spoofing használatára a TCP SYN flood vagy a DHCP exhaustion támadások.

Példa Spoofing támadásra: DHCP Exhaustion

  • A DHCP Exhaustion támadásban az attacker spoofolt (hamisított) MAC címekkel árasztja el a hálózatot DHCP Discover üzenetekkel.
  • Ennek eredményeként a célpont DHCP címkészlete megtelik, így más eszközök nem kapnak IP címet (DoS).
DHCP exhaustion szemléltetése

3. Visszaverés / Erősítés (Reflection/Amplification)

A reflection/amplification támadás célja, hogy nagymennyiségű adatot küldjön egy célpontnak, ezzel DoS állapotot előidézve.

  • A reflection támadásban az attacker traffic-et küld egy reflector-nak, a forrás IP-t pedig a target IP-jével helyettesíti.
  • A reflector a választ a target-nek küldi vissza.
  • Ha az adat mennyisége elég nagy, az DoS-t okoz.

A reflection támadás akkor válik amplification támadássá, ha az attacker által küldött kevés traffic nagymennyiségű választ vált ki a reflector-ból a target felé.

Reflection/Amplification szemléltetése

4. Man-in-the-middle

A man-in-the-middle (közbeékelődéses) támadásban az attacker a forrás és cél közé ékelődik, hogy lehallgassa vagy módosítsa a kommunikációt.

Ezek a támadások a Confidentiality és Integrity elveit sértik meg.

Példa man-in-the-middle támadásra: ARP Spoofing

Az ARP Spoofing (más néven ARP Poisoning) egy gyakori man-in-the-middle támadás.

  • Egy host elküld egy ARP kérést az eszköz MAC címéért.
  • A target elküldi a valódi ARP választ.
  • Az attacker kivár, majd küld egy saját ARP választ.
  • Ha az attacker válasza érkezik utolsónak, az felülírja a legitim bejegyzést a host ARP táblájában.

  • A host ARP táblájában a target bejegyzésénél már az attacker MAC címe áll.
  • Így amikor a host információt küld a target-nek, az az attacker-hez érkezik, aki megtekintheti vagy módosíthatja azt, mielőtt továbbítaná a valódi Target-nek.
ARP Spoofing szemléltetése

5. Reconnaissance

A Reconnaissance támadás nem önálló támadás, hanem információgyűjtés a target-ről a jövőbeli támadásokhoz.

  • Többnyire nyilvános adatokat használ:
    1. nslookup lekérdezések.
    2. WHOIS lekérdezések e-mailek, telefonszámok, címek megszerzéséhez.

6. Malware

A Malware (malicious software) káros programok gyűjtőneve. Bármely CIA elemet veszélyeztethetik. Típusok:

  1. Viruses
    • Gazdaprogramokat fertőznek meg.
    • A vírus terjed, ahogy a felhasználók megosztják a programokat.
    • Jellemzően módosítják vagy megrontják a fájlokat.
  2. Worms
    • Önállóak, nem igényelnek gazdaprogramot.
    • Önmaguktól terjednek, felhasználói közreműködés nélkül.
    • A férgek hálózati forgalmat generálhatnak, vagy károsíthatják a target eszközt.
  3. Trojan Horses
    • Legitim szoftvernek álcázott kártevők.
    • Felhasználói közreműködéssel terjednek (e-mailek, letöltések).

7. Social Engineering

A Social engineering támadások célpontja az ember, a legsebezhetőbb pont. Pszichológiai manipulációt használnak információk megszerzésére.
Ide tartoznak:

  1. Phishing
    • Átverős e-mailek, amelyek megbízható üzletnek tűnnek, és hamis weboldalakra irányítanak információk lopásához.
    • Típusok:
      • Spear phishing: Célzott, pl. cégalkalmazottak ellen.
      • Whaling: Magas rangú személyek elleni támadás.
      • Vishing (voice phishing): Telefonos adathalászat.
      • Smishing (SMS phishing): SMS alapú adathalászat.
  2. Watering hole
    • A támadó olyan weboldalakat fertőz meg, amelyeket a célpont gyakran látogat.
    • Ha a target megbízik az oldalon, nagyobb eséllyel kattint a kártevő linkre.
  3. Tailgating
    • Fizikai területre való behatolás egy authorized személy mögött besétálva.

A legtöbb rendszer username/password kombinációt használ.

A jelszavak gyengesége a biztonsági kockázat. Jelszó-szerzési módszerek:

  1. Guessing (Találgatás)
  2. Dictionary Attacks (Szótári támadások)
    • Egy program szótárból próbálja megtalálni a jelszót.
  3. Brute-force Attacks (Nyers erő támadások)
    • Minden lehetséges karakterkombinációt kipróbál.

Multi-Factor Authentication (MFA)

A Multi-Factor Authentication (MFA) többféle hitelesítési tényezőt követel meg:

  1. Something you know
    • Username/password, PIN stb.
  2. Something you have
    • Telefonos értesítés, jelvény stb.
  3. Something you are
    • Biometria (ujjlenyomat, arcfelismerés stb.).

Több tényező jelentősen növeli a biztonságot. Ha a jelszó (something you know) kiszivárog, a második tényező még védelmet nyújt.


Digital Certificates

A Digital certificates hitelesítési eszközök az identitás igazolására.

  • Weboldalaknál igazolják a legitimitást.

Authentication, Authorization, Accounting (AAA)

Authentication, Authorization, Accounting (AAA) a hozzáférés-vezérlés keretrendszere:

  1. Authentication
    • Identitás ellenőrzése.
  2. Authorization
    • Jogosultságok megadása.
  3. Accounting
    • Tevékenységek naplózása.

Az AAA szerverek nyújtják ezeket a szolgáltatásokat.

  • ISE (Identity Services Engine) a Cisco AAA szervere.

AAA protokollok:

  1. RADIUS
    • Open standard.
    • UDP portok 1812 - 1813
  2. TACACS+
    • Cisco proprietary.
    • TCP port 49

Security Program Elements

  1. User awareness
    • Tájékoztatás a biztonsági fenyegetésekről.
  2. User training
    • Formális képzés a vállalati biztonsági irányelvekről.
  3. Physical access control
    • Berendezések fizikai védelme a jogosulatlan hozzáférés megakadályozására (pl. szerverszobák).