Skip to main content

WebNet0 picoCTF 2019 Solution

Analyze a network packet capture and extract the flag from the captured session data.

Published: April 2, 2026Updated: August 13, 2026

Description

We found a packet capture and a key file. Decrypt the TLS traffic and recover the flag. Download both the pcap and the key.

Download the pcap file and the RSA private key file from the challenge page.

Open Wireshark.

Solution

Want to try it yourself first?

The guided walkthrough reveals hints one step at a time.

Walk me through it
  1. Step 1Load the RSA key into Wireshark
    Observation
    The challenge ships an RSA private key alongside the pcap. That key is there to decrypt the TLS traffic, which Wireshark will do once you point its TLS preferences at it.
    In Wireshark, go to Edit > Preferences > Protocols > TLS (formerly SSL). Under RSA Keys, add the downloaded key file. Then close and re-open the pcap so Wireshark applies the decryption key.
    What didn't work first

    Tried: Looking for TLS settings under Edit > Preferences > Protocols > SSL instead of TLS.

    Older Wireshark builds labeled the protocol 'SSL'; newer ones call it 'TLS'. If your version only lists TLS, that is the right entry. It was renamed, not changed.

    Tried: Adding the key file and immediately searching packets without re-opening the pcap.

    Wireshark decrypts at load time. Add the key while the pcap is already open and the existing packets are not re-decrypted. Close and reopen the file, or hit File > Reload, for the key to take effect.

    Learn more

    TLS encrypts network traffic using symmetric keys negotiated during a handshake. Wireshark can decrypt these sessions when given the server's RSA private key, because the private key decrypts the pre-master secret from the handshake, which derives all session keys. This only works with RSA key exchange, not DHE or ECDHE (ephemeral Diffie-Hellman), which generates session keys that the static private key cannot recover.

  2. Step 2Follow TLS streams to find the flag
    Observation
    With the key loaded, Wireshark starts showing decrypted TLS Application Data. The plaintext HTTP responses are readable now, so following a TLS stream should surface the flag.
    After adding the key, right-click on a TLS Application Data packet and select Follow > TLS Stream. Browse each stream for the flag - it appears in the HTTP response header of one of the conversations.
    What didn't work first

    Tried: Right-clicking a packet and selecting Follow > TCP Stream instead of Follow > TLS Stream.

    TCP Stream shows the raw encrypted bytes, not the decrypted content. Even with the RSA key loaded, you must choose Follow > TLS Stream to see the plaintext HTTP data that Wireshark has decrypted in memory.

    Tried: Searching the HTTP response body for the flag instead of looking at the response headers.

    Here the flag sits in an HTTP response header, not the page body. Read only the body in the TLS stream output and you walk right past it. Scroll up to the headers, or use Find Packet (Ctrl+F) to search all packet content for picoCTF.

    Learn more

    Once Wireshark has the RSA private key, TLS Application Data decrypts to readable HTTP. Follow TLS Stream shows the full request and response in plaintext. Use Edit > Find Packet and search for 'picoCTF' in packet bytes to locate the relevant packet without examining each stream individually.

    Packet captures combined with private keys are a powerful forensic tool. This is why forward secrecy (DHE/ECDHE key exchange) is strongly recommended - without forward secrecy, a leaked private key can decrypt all past recorded sessions.

Interactive tools
  • Hex ViewerView text or raw hex bytes as a xxd-style hex dump with byte offset, hex columns, and ASCII sidebar. Highlights printable characters and null bytes.
  • Strings ExtractorPull printable text from any binary, library, or image. ASCII and UTF-16 detection, configurable minimum length, flag-like highlight, no command line needed.

Flag

Reveal flag

picoCTF{nongshim.shrimp.crackers}

Wireshark decrypts TLS when the server RSA private key is provided - the flag is in an HTTP response header inside the encrypted stream.

Key takeaway

TLS with RSA key exchange has a serious weakness: the static server private key decrypts the pre-master secret from any recorded handshake, so one key compromise retroactively exposes every past session someone captured. Ephemeral key exchange (DHE and ECDHE) fixes this by generating a fresh session key per connection that is never transmitted and cannot be recovered from the static key. That property is forward secrecy, and it is why modern TLS configs mandate ECDHE and why hoarding old packet captures is a liability.

Related reading

Useful tools for Forensics

Where to go next