How do you use Wireshark to analyze malware network traffic? (2024)

Last updated on Sep 4, 2024

  1. All
  2. Malware Analysis

Powered by AI and the LinkedIn community

1

Set up the environment

2

Start Wireshark and capture traffic

3

Identify the malware traffic

4

Analyze the malware protocol

5

Extract the malware artifacts

6

Report and share the findings

7

Here’s what else to consider

Wireshark is a popular tool for capturing and analyzing network traffic, which can help you understand how malware communicates with its servers, victims, or peers. In this article, you will learn how to use Wireshark to analyze malware network traffic in six steps.

Top experts in this article

Selected by the community from 12 contributions. Learn more

How do you use Wireshark to analyze malware network traffic? (1)

Earn a Community Top Voice badge

Add to collaborative articles to get recognized for your expertise on your profile. Learn more

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate…

    How do you use Wireshark to analyze malware network traffic? (3) 4

  • Dario Nisi Postdoc researcher

    How do you use Wireshark to analyze malware network traffic? (5) 3

  • Mohamed Essam CISSP | IAM | Cyber Security Solutions

    How do you use Wireshark to analyze malware network traffic? (7) 1

How do you use Wireshark to analyze malware network traffic? (8) How do you use Wireshark to analyze malware network traffic? (9) How do you use Wireshark to analyze malware network traffic? (10)

1 Set up the environment

Before you start analyzing malware network traffic, you need to set up a safe and isolated environment to run the malware sample. This can be done using a virtual machine, a sandbox, or a dedicated device. You also need to configure your network settings to allow Wireshark to capture the traffic from the malware host. You can use a bridged network, a NAT network, or a proxy to do this.

Add your perspective

Help others by sharing more (125 characters min.)

  • Mohamed Essam CISSP | IAM | Cyber Security Solutions
    • Report contribution

    Verifying DNS records for any signs of suspicious domains or IP addresses.Investigating HTTP traffic to identify malicious URLs or detect attempts to download malicious files. Utilizing Wireshark's raw data can facilitate the extraction of files based on file headers and signatures, such as identifying executables that start with "MZ."Investigating TCP and UDP streams may reveal unconventional connections like IRC connections.Saving the packet capture (pcap) data and employing Linux tools like ngrep can aid in extracting Indicators of Compromise (IoCs). Network analysis, in this context, proves to be an invaluable method for identifying and mitigating potential security threats

    Like

    How do you use Wireshark to analyze malware network traffic? (19) 1

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate | Speaker | Writer
    • Report contribution

    Creating a safe networking environment for Wireshark analysis involves setting up a virtual machine (VM) with proper network isolation to prevent any accidental exposure of captured traffic to the actual network. By configuring a VM with NAT for internet access and a Host-Only Adapter for isolated network communication, you create a safe environment for analyzing network traffic with Wireshark. This setup ensures that any captured traffic is contained within the virtual environment and doesn't affect the actual network. Analyze HTTP/HTTPS requests and responses. Analyze DNS requests to identify communication with suspicious domains. Use Wireshark's "Follow TCP Stream" feature to reconstruct and analyze complete conversations.

    Like

    How do you use Wireshark to analyze malware network traffic? (28) 3

2 Start Wireshark and capture traffic

Next, you need to launch Wireshark and start capturing the network traffic from the malware host. You can choose the interface that corresponds to your network configuration, or use the promiscuous mode to capture all traffic on the network. You can also apply filters to narrow down the traffic to the malware host or the protocol you are interested in.

Add your perspective

Help others by sharing more (125 characters min.)

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate | Speaker | Writer
    • Report contribution

    Starting Wireshark with best practices involves configuring the tool and adopting a systematic approach to effectively capture and analyze network traffic. Run Wireshark using appropriated permissions, select the network interface, configure the capture filters, use the limit captured data size, colorize the packts for visual clarity, use IO graphs for trends, By incorporating these best practices when starting Wireshark, you can enhance your ability to capture, analyze, and interpret network traffic effectively. Adopting a systematic and organized approach helps in making the most of Wireshark's powerful features for network troubleshooting, security analysis, and protocol debugging.

    Like

    How do you use Wireshark to analyze malware network traffic? (37) 4

  • Dario Nisi Postdoc researcher
    • Report contribution

    First of all, you need to find the best place from which to run wireshark.For example, suppose you are analyzing malware in a VM. Running wireshark from within the VM guest might be suboptimal (the malware might find out the running wireshark process and decide to hide its malicious behavior). A better choice is to sniff the traffic at the host level by properly setting up a TAP interface from the hypervisor (e.g., VirtualBox, VMWare, KVM, etc.).Similarly, in more complex analysis setups involving several machines, one could run wireshark on a bastion host that serves as internet gateway for all the analysis machines.

    Like

    How do you use Wireshark to analyze malware network traffic? (46) 3

3 Identify the malware traffic

Once you have captured some traffic, you need to identify the packets that belong to the malware communication. This can be challenging, as malware often uses encryption, obfuscation, or spoofing to evade detection. However, you can look for some clues, such as unusual ports, domains, or patterns, that can indicate malicious activity. You can also compare the traffic with a baseline of normal traffic from the same host or network.

Add your perspective

Help others by sharing more (125 characters min.)

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate | Speaker | Writer
    • Report contribution

    Identifying malware traffic using Wireshark involves analyzing the captured network packets to identify patterns, behaviors, and indicators of compromise (IoCs). Examine DNS traffic for suspicious domain names. Look for traffic using non-standard or uncommon protocols. Analyze HTTP and HTTPS traffic for anomalies. Identify and analyze encrypted traffic using the "ssl" filter. Use Wireshark's "Follow TCP Stream" feature to reconstruct and analyze complete conversations. Identify beaconing behavior, where malware sends periodic signals to a command and control (C2) server.

    Like

    How do you use Wireshark to analyze malware network traffic? (55) 3

  • Sean Khan Director, A.SA
    • Report contribution

    Note that wireshark itself can't identify which program is creating which traffic. Therefore, you need to query the OS for details of which process used which port at what time, etc...

    Like

    How do you use Wireshark to analyze malware network traffic? (64) 1

4 Analyze the malware protocol

After you have identified the malware traffic, you can analyze the malware protocol to understand how the malware communicates with its servers, victims, or peers. You can use Wireshark's built-in tools, such as dissectors, decoders, or statistics, to examine the structure, content, and behavior of the protocol. You can also use external tools, such as hex editors, encryption tools, or scripting languages, to decode, decrypt, or manipulate the protocol.

Add your perspective

Help others by sharing more (125 characters min.)

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate | Speaker | Writer
    • Report contribution

    Analyzing malware protocols using Wireshark involves examining the characteristics and behaviors of network traffic associated with potential malware infections. Determine the protocol associated with the suspected malware. Use the "Follow TCP Stream" or "Follow UDP Stream" feature to reconstruct the entire communication between hosts. Analyze the payload of packets associated with the protocol. Some malware protocols may have specific plugins or dissectors in Wireshark. Review metadata such as IP addresses, port numbers, and timestamps. Cross-reference identified IP addresses, domains, or patterns with threat intelligence feeds. If the malware uses non-standard ports, investigate the traffic on those ports.

    Like

    How do you use Wireshark to analyze malware network traffic? (73) 2

  • Dario Nisi Postdoc researcher
    • Report contribution

    Wireshark is great at figuring out what protocols each network packet uses, providing tons of information.However, malware loves to encrypt its traffic, often using HTTPs or plain TLS.Since encrypted traffic is almost useless for any qualitative analysis, you will have to find a way to recover encryption keys.In general, there are two ways of doing that.One idea could be to use a TLS-aware proxy (e.g., mitmproxy or Polarproxy), that breaks end-to-end encryption and provide unencrypted traffic you can then analyze with Wireshark.While this work in most cases, proxies fall short against certificate pinning.A more resilient approach consists in recovering keys from the malware process, but this is tedious and more complex.

    Like

    How do you use Wireshark to analyze malware network traffic? (82) 2

5 Extract the malware artifacts

Another useful step in analyzing malware network traffic is to extract the malware artifacts from the captured packets. These can include files, commands, credentials, or indicators of compromise, that can provide more information about the malware's functionality, purpose, or origin. You can use Wireshark's export function, or other tools, such as NetworkMiner, to extract the artifacts from the traffic.

Add your perspective

Help others by sharing more (125 characters min.)

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate | Speaker | Writer
    • Report contribution

    You can export functionality provides flexibility in saving different types of data, including packet dissections, extracted files, and DNS/HTTP objects. Use these export features to facilitate further analysis and sharing of information with security teams. You can use tools that can be used for capturing and analyzing data about hosts on the network. It provides insights into the hosts, services, files, and other artifacts present in the captured traffic such as:- Xplico- CapLoader- Moloch- Suricata- MISP ( Focused in Malware's IOCs) used for capturing and analyzing data about hosts on the network. It provides insights into the hosts, services, files, and other artifacts present in the captured traffic.

    Like

    How do you use Wireshark to analyze malware network traffic? (91) 3

  • Ricardo Miranda Information Security Management | Cyber Security | CISSP | CCISO | CISM | DPO | CASP | ECSA | CEH | CHFI | ECIH | ISO 27001 Lead Implementer | 27701 Lead Implementer
    • Report contribution

    When traffic is encrypted, this extraction is not simple.It is challenging to identify C2 traffic and artifacts.Using tools such as rita or zeek helps a lot.

    Like

    How do you use Wireshark to analyze malware network traffic? (100) 1

6 Report and share the findings

The final step in analyzing malware network traffic is to report and share your findings with other analysts, researchers, or stakeholders. You can use Wireshark's save function, or other tools, such as Snort, to create a report that summarizes your analysis, highlights the key findings, and provides recommendations or mitigation strategies. You can also share your findings with the security community, or report them to the relevant authorities or organizations.

Add your perspective

Help others by sharing more (125 characters min.)

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate | Speaker | Writer
    • Report contribution

    Creating a summary report for malware traffic analysis involves presenting key findings, details about the identified malware, and potential impacts on the network. You should create a Executive Summary, Introduction, Malicious Indicators, Payload analysis (some keys findings), impact of this possible attack and recommendations.Adjust the idea based on the specifics of your analysis, the types of malware identified, and the organization's context. Include any additional details that are relevant to the analysis and its implications.

    Like

    How do you use Wireshark to analyze malware network traffic? (109) 2

7 Here’s what else to consider

This is a space to share examples, stories, or insights that don’t fit into any of the previous sections. What else would you like to add?

Add your perspective

Help others by sharing more (125 characters min.)

  • Filipi Pires Global Threat Researcher and Cybersecurity Advocate at senhasegura | Snyk Ambassador | Hacking Is Not a Crime Advocate | Speaker | Writer
    • Report contribution

    Extracting malware from network traffic requires a cautious approach to prevent accidental execution and ensure the safety of the analyst and the network. Always follow best practices for handling and analyzing potential malware files. Wireshark's export functionality provides flexibility in saving different types of data, including packet dissections, extracted files, and DNS/HTTP objects. Use these export features to facilitate further analysis and sharing of information with security teams.

    Like

    How do you use Wireshark to analyze malware network traffic? (118) 2

Malware Analysis How do you use Wireshark to analyze malware network traffic? (119)

Malware Analysis

+ Follow

Rate this article

We created this article with the help of AI. What do you think of it?

It’s great It’s not so great

Thanks for your feedback

Your feedback is private. Like or react to bring the conversation to your network.

Tell us more

Report this article

More articles on Malware Analysis

No more previous content

  • How do you handle packed, polymorphic, and metamorphic malware in static analysis? 15 contributions
  • How do you determine the origin and intent of a malware campaign? 10 contributions
  • What are the benefits and challenges of malware clustering and phylogeny? 11 contributions
  • How do you prepare for malware analysis job interviews? 4 contributions
  • How do you deal with incomplete or inaccurate decompilation results? 5 contributions
  • How do you apply malware analysis to incident response and threat hunting? 10 contributions
  • What are the advantages and disadvantages of static and dynamic disassembly? 3 contributions
  • How do you compare memory snapshots to detect malware persistence and stealth? 1 contribution
  • What are the main differences between malware forensics and malware analysis? 7 contributions

No more next content

See all

More relevant reading

  • Network Security What is the best way to analyze malware traffic without network performance issues?
  • Cybersecurity What are the best encryption algorithms for malware analysis?
  • Cybersecurity What are the challenges of classifying malware for cybersecurity?
  • Computer Engineering What is the best way to identify and analyze malware on a network?

Are you sure you want to delete your contribution?

Are you sure you want to delete your reply?

How do you use Wireshark to analyze malware network traffic? (2024)
Top Articles
How to Convert Hours Into Days? | Learn and Solve Questions
4 Reasons to Keep Your Finances Separate After Marriage - Experian
Farepay Login
CLI Book 3: Cisco Secure Firewall ASA VPN CLI Configuration Guide, 9.22 - General VPN Parameters [Cisco Secure Firewall ASA]
Google Sites Classroom 6X
Chris wragge hi-res stock photography and images - Alamy
Rubfinder
World of White Sturgeon Caviar: Origins, Taste & Culinary Uses
Space Engineers Projector Orientation
Helloid Worthington Login
Dusk
Peraton Sso
Craigslist Free Stuff Santa Cruz
Watch The Lovely Bones Online Free 123Movies
Yard Goats Score
Amazing deals for Abercrombie & Fitch Co. on Goodshop!
Promiseb Discontinued
Poe Str Stacking
Craigs List Tallahassee
Albert Einstein Sdn 2023
fft - Fast Fourier transform
Narragansett Bay Cruising - A Complete Guide: Explore Newport, Providence & More
Barbie Showtimes Near Lucas Cinemas Albertville
Rays Salary Cap
Guide to Cost-Benefit Analysis of Investment Projects Economic appraisal tool for Cohesion Policy 2014-2020
A Plus Nails Stewartville Mn
Duke Energy Anderson Operations Center
Salons Open Near Me Today
Martin Village Stm 16 & Imax
Most popular Indian web series of 2022 (so far) as per IMDb: Rocket Boys, Panchayat, Mai in top 10
Scioto Post News
Craigslist Neworleans
W B Crumel Funeral Home Obituaries
Toonily The Carry
Emerge Ortho Kronos
R Nba Fantasy
Craigslist Gigs Wichita Ks
Ktbs Payroll Login
Craigslist Florida Trucks
Invalleerkracht [Gratis] voorbeelden van sollicitatiebrieven & expert tips
Hireright Applicant Center Login
Brandon Spikes Career Earnings
Craigslist Farm And Garden Reading Pa
Courses In Touch
Gas Buddy Il
20 Mr. Miyagi Inspirational Quotes For Wisdom
Contico Tuff Box Replacement Locks
Sitka Alaska Craigslist
Concentrix + Webhelp devient Concentrix
Sams La Habra Gas Price
Jigidi Jigsaw Puzzles Free
Latest Posts
Article information

Author: Reed Wilderman

Last Updated:

Views: 6443

Rating: 4.1 / 5 (72 voted)

Reviews: 87% of readers found this page helpful

Author information

Name: Reed Wilderman

Birthday: 1992-06-14

Address: 998 Estell Village, Lake Oscarberg, SD 48713-6877

Phone: +21813267449721

Job: Technology Engineer

Hobby: Swimming, Do it yourself, Beekeeping, Lapidary, Cosplaying, Hiking, Graffiti

Introduction: My name is Reed Wilderman, I am a faithful, bright, lucky, adventurous, lively, rich, vast person who loves writing and wants to share my knowledge and understanding with you.