<summary><strong>Naučite hakovanje AWS-a od nule do heroja sa</strong><ahref="https://training.hacktricks.xyz/courses/arte"><strong>htARTE (HackTricks AWS Red Team Expert)</strong></a><strong>!</strong></summary>
* Ako želite da vidite svoju **kompaniju reklamiranu na HackTricks-u** ili da **preuzmete HackTricks u PDF formatu** proverite [**PLANOVE ZA PRIJATELJSTVO**](https://github.com/sponsors/carlospolop)!
* **Pridružite se** 💬 [**Discord grupi**](https://discord.gg/hRep4RUj7f) ili [**telegram grupi**](https://t.me/peass) ili nas **pratite** na **Twitteru** 🐦 [**@hacktricks_live**](https://twitter.com/hacktricks_live)**.**
Data exfiltration can be achieved using various protocols other than HTTP/HTTPS, such as DNS, ICMP, or SMTP. These protocols are often allowed to traverse network boundaries and can be used to bypass egress filtering.
2.**Detection**
- Monitor network traffic for unusual DNS requests, especially those containing encoded data.
- Look for abnormal ICMP traffic patterns that may indicate data exfiltration.
- Analyze SMTP traffic for unexpected attachments or unusual sending patterns.
3.**Prevention**
- Implement egress filtering rules that restrict the use of alternative protocols.
- Use deep packet inspection to detect and block exfiltration attempts over alternative protocols.
- Encrypt sensitive data before transmission to make exfiltration more difficult.
4.**Tools**
- **[Iodine](https://github.com/yarrick/iodine):** Tunnel IPv4 data through a DNS server.
- **[ChopChop](https://github.com/MITRECND/chopchop):** Craft and send arbitrary IP packets.
- **[SMTP-Tester](https://github.com/le4f/smtp-tester):** Test SMTP server for open relays.
#### Exfiltration Over Unencrypted/Unauthenticated Protocols
1.**Description**
Exfiltrating data over unencrypted or unauthenticated protocols, such as FTP or Telnet, can expose sensitive information to interception by network eavesdroppers.
2.**Detection**
- Monitor network traffic for clear-text passwords or sensitive data being transmitted over unencrypted protocols.
- Look for unauthorized FTP or Telnet connections originating from internal hosts.
3.**Prevention**
- Encrypt data before transmission using secure protocols like SFTP or SSH.
- Disable or restrict the use of unencrypted/ unauthenticated protocols within the network.
- Implement strong authentication mechanisms to prevent unauthorized access to sensitive services.
4.**Tools**
- **[Wireshark](https://www.wireshark.org/):** Analyze network traffic to identify clear-text data transmissions.
- **[Nmap](https://nmap.org/):** Scan for open FTP or Telnet ports on network devices.
- **[FileZilla](https://filezilla-project.org/):** Securely transfer files using SFTP/FTP over SSH.
#### Exfiltration Over DNS
1.**Description**
DNS exfiltration involves encoding sensitive data within DNS queries or responses to bypass network security controls and exfiltrate data.
2.**Detection**
- Monitor DNS traffic for unusually large queries or responses that may contain exfiltrated data.
- Look for patterns in DNS requests that deviate from normal domain resolution behavior.
- Analyze DNS query timings and volume for signs of data exfiltration.
3.**Prevention**
- Implement DNS sinkholing to redirect suspicious DNS traffic to controlled servers.
- Use DNS firewall rules to block unauthorized DNS queries containing suspicious data.
- Encrypt DNS traffic using DNS over HTTPS (DoH) or DNS over TLS (DoT) to prevent eavesdropping.
4.**Tools**
- **[Dnscat2](https://github.com/iagox86/dnscat2):** Multi-platform tool for tunneling data through DNS servers.
- **[Dns2tcp](https://github.com/bortzmeyer/dns2tcp):** Tunnel TCP over DNS.
- **[dnsteal](https://github.com/m57/dnsteal):** Extract data from DNS traffic.
Netcat (NC) je moćan alat za mrežno preusmeravanje podataka. Može se koristiti za prenos podataka između sistema putem TCP ili UDP veza. NC može biti korišćen za slanje fajlova, snimanje portova i mnoge druge mrežne operacije.
Program `debug.exe` ne samo što omogućava inspekciju binarnih fajlova već takođe ima **mogućnost da ih rekonstruiše iz heksadecimalnog koda**. To znači da, pružajući heksadecimalni kod binarnog fajla, `debug.exe` može generisati binarni fajl. Međutim, važno je napomenuti da debug.exe ima **ograničenje u sastavljanju fajlova do 64 kb veličine**.
<summary><strong>Naučite hakovanje AWS-a od nule do heroja sa</strong><ahref="https://training.hacktricks.xyz/courses/arte"><strong>htARTE (HackTricks AWS Red Team Expert)</strong></a><strong>!</strong></summary>
* Ako želite da vidite svoju **kompaniju reklamiranu na HackTricks-u** ili **preuzmete HackTricks u PDF formatu** Proverite [**PLANOVE ZA PRIJAVU**](https://github.com/sponsors/carlospolop)!
* **Pridružite se** 💬 [**Discord grupi**](https://discord.gg/hRep4RUj7f) ili [**telegram grupi**](https://t.me/peass) ili nas **pratite** na **Twitteru** 🐦 [**@hacktricks_live**](https://twitter.com/hacktricks_live)**.**