Task 1 Introduction

#1.1 Read above.

Answer: No answer is needed.

Task 2 Anomalous DNS

#2.1 Investigate the dns-tunneling.pcap file. Investigate the dns.log file. What is the number of DNS records linked to the IPv6 address?

Command:

Generate DNS logs

zeek -C -r dns-tunneling.pcap -s dns.log

Search the number of DNS records linked to the IPV6 address

cat dns.log | grep "AAAA" | wc -l

None

Answer: 320

#2.2 Investigate the conn.log file. What is the longest connection duration?

See the structure of the file.

Head conn.log

None

Print duration and sort in descending order

None

cat conn.log | zeek-cut duration | sort -n | uniq

None

Answer: 9.420791

#2.3 Investigate the dns.log file. Filter all unique DNS queries. What is the number of unique domain queries?

See the structure of the file.

Head dns.log

None

Search all unique domain queries.

Command: cat dns.log | zeek-cut query |rev | cut -d '.' -f 1–2 | rev | sort | uniq

None

Answer: 6

#2.4 There is a massive amount of DNS queries sent to the same domain. This is abnormal. Let's find out which hosts are involved in this activity. Investigate the conn.log file. What is the IP address of the source host?

See the structure of the file.

None

Find the source ip address.

Command: cat dns.log | zeek-cut id.orig_h

None
None

Answer: 10.20.57.3

Task 3 Phishing

#3.1 Investigate the logs. What is the suspicious source address? Enter your answer in defanged format.

Generate logs.

None

Check conn.log.

Cat conn.log

None

defanged format: 10[.]6[.]27[.]102

Answer: 10[.]6[.]27[.]102

#3.2 Investigate the http.log file. Which domain address were the malicious files downloaded from? Enter your answer in defanged format.

Verify the format of the file.

None

Review the log.

None

Pass to defang format:

Using CyberChef

Link: https://gchq.github.io/CyberChef/#recipe=Defang_URL(true,true,true,'Valid%20domains%20and%20full%20URLs')&input=c21hcnQtZmF4LmNvbQ

None

Answer: smart-fax[.]com

#3.3 Investigate the malicious document in VirusTotal. What kind of file is associated with the malicious document?

To respond to this question, we should use the next command:

zeek -C -r phishing.pcap file-extract-demo.zeek

None

Cat files.log -> view files.log

zeek -C -r phishing.pcap hash-demo.zeek

None

cat files.log | zeek-cut md5

None

Extract files

File extract_files/* | nl

None

cat files.log | zeek-cut puid conn_uids tx_hosts rx_hosts mine_type extracted | nl

None

Find hash md5

cat files.log | zeek-cut md5 puid conn_uids tx_hosts rx_hosts mine_type extracted | nl

None

Search in virustotal: b5243ec1df7d1d5304189e7db2744128

None

Tab Relations

None

Answer: VBA

#3.4 Investigate the extracted malicious .exe file. What is the given file name in Virustotal?

Check in the page of Virustotal.

We had the hash md5 from the preview exercise.

Hash md5: 749e161661290e8a2d190b1a66469744127bc25bf46e5d0c6f2e835f4b92db18

None

Answer: PleaseWaitWindow.exe

#3.5 Investigate the malicious .exe file in VirusTotal. What is the contacted domain name? Enter your answer in defanged format.

Hash md5: 749e161661290e8a2d190b1a66469744127bc25bf46e5d0c6f2e835f4b92db18

None
None

Go to CyberChef

Convert URL in Defang format.

None

Answer: hopto[.]org

#3.6 Investigate the http.log file. What is the request name of the downloaded malicious .exe file?

Verify the log.

Cat http.log

None

Search extensions in the file

cat http.log | zeek-cut uri

None

Answer: knr.exe

Task 4 Log4J

#4.1 Investigate the log4shell.pcapng file with detection-log4j.zeek script. Investigate the signature.log file. What is the number of signature hits?

Generate logs.

zeek -C -r log4shell.pcapng detection-log4j.zeek

None

Count the number of signatures hits.

Command: cat signatures.log | zeek-cut sig_id | wc -l

None

Answer: 3

#4.2 Investigate the http.log file. Which tool is used for scanning?

Check the file.

Head http.log

None

Filter by the tool

Command: cat http.log | zeek-cut user_agent

None

Result:

None

Answer: nmap

#4.3 Investigate the http.log file. What is the extension of the exploit file?

Search the extension of the exploit file.

None

Answer: .class

#4.4 Investigate the log4j.log file. Decode the base64 commands. What is the name of the created file?

Check the file log4j.log

None

Decode the base64 command.

echo 'd2hpY2ggbmMgPiAvdG1wL3B3bmVkCg==' | base64 –d

None

Answer: pwned

Task 5 Conclusion

Answer: No answer is needed.