office.pcap — five minutes of a mid-size office network
A synthetic but dissector-clean capture of a 180-seat office: Microsoft 365, an on-premises domain controller and file server, Teams Phone handsets, AirPrint MFPs, IP cameras, building controls, and a guest SSID. End hosts are a deliberate mix of Windows 11, Windows Server, macOS, Ubuntu, Fedora, iOS and Android, with each stack’s real TCP fingerprint, so the same file works for passive OS identification, protocol work, flow analysis and triage practice.
| Property | Value |
|---|---|
| File | office.pcap.gz (9 MB compressed, 12 MB raw) |
| Frames | 22,089 over 303.7 s |
| Window | Tuesday 2026-11-10, 09:14:00–09:19:04 PST |
| Link type | Ethernet, 802.1Q tagged |
| Built by | mkoffice.py — same seed in, byte-identical file out |
Nothing in it is real traffic, no host or user exists, and the only private data in the file is invented. Everything dissects: zero malformed frames, zero bad checksums.
This file is the benign baseline: there is no attack traffic in it, which
is what makes it useful as a comparison. For triage practice there is a
second file, office-attack.pcap.gz — the same five
minutes with one intrusion laid over them, documented on
the attack overlay page, with twelve Suricata rules that fire on
it and none on this one.
The site
northstarlogistics.example — one building, two floors, a Catalyst-class core
doing all inter-VLAN routing, a Palo Alto at the edge doing NAT.
| VLAN | Subnet | What lives there |
|---|---|---|
| 10 | 10.21.10.0/24 | corporate laptops, desktops, phones on the corp SSID |
| 20 | 10.21.20.0/24 | servers: AD/DNS/KDC, file server, SIEM, backup, camera recorder |
| 30 | 10.21.30.0/24 | Teams-certified desk phones |
| 40 | 10.21.40.0/24 | MFPs, IP cameras, building-management gateway |
| 50 | 10.21.50.0/24 | guest SSID, NATed, no route to the inside |
| 99 | 10.21.99.0/24 | switch and AP management — the native (untagged) VLAN |
| 100 | 10.21.100.0/30 | routed link, core to edge firewall |
IPv6 runs on VLAN 10 only, SLAAC from 2001:db8:21:10::/64, with the RA’s
Other-config flag set and no DHCPv6 address assignment.
Hosts
| Host | Address | Stack | Role in the capture |
|---|---|---|---|
wks-fin-07 |
10.21.10.52 | Windows 11 24H2 (Dell) | Outlook, Teams audio call, SharePoint upload, Kerberos, SMB3, LDAPS |
wks-sales-12 |
10.21.10.61 | Windows 11 24H2 (Lenovo) | Teams meeting with video and screen share, Windows Update, DO peering, QUIC |
wks-hr-03 |
10.21.10.64 | Windows 11 24H2 | floor-1 machine; appears only as the Delivery Optimization peer |
scan-pc-01 |
10.21.10.200 | Windows 10 22H2 | the legacy box: LLMNR, NBT-NS, EDR telemetry, NCSI |
mbp-eng-02 |
10.21.10.88 | macOS 15 | Bonjour, APNs, iCloud, Homebrew, OCSP, AirPrint |
mbp-mkt-05 |
10.21.10.91 | macOS 15 | Slack, Zoom call, Okta sign-in |
dev-ws-01 |
10.21.10.120 | Ubuntu 24.04 | apt over HTTP, SSH to GitHub, docker pull, SSH to the switch |
dev-ws-02 |
10.21.10.121 | Fedora 42 | dnf over TLS, avahi, codeload |
iphone-jlin |
10.21.10.161 | iOS | APNs, Bonjour, captive probe |
pixel-rsmith |
10.21.10.165 | Android | full DHCP handshake, connectivity check, QUIC video |
dc01 |
10.21.20.10 | Windows Server 2025 | AD DS, DNS, KDC, NTP, DHCP (via relay) |
fs01 |
10.21.20.20 | Windows Server 2022 | SMB 3.1.1 with encryption required |
siem01 |
10.21.20.40 | Ubuntu 24.04 | syslog, NetFlow collector, SNMP poller, ICMP monitoring |
nvr01 |
10.21.20.55 | Linux | pulls RTSP from both cameras |
phone-3012/14 |
10.21.30.61/.62 | Android-based desk phones | Teams Phone call over the transport relay |
prn-mfp-01/02 |
10.21.40.11/.12 | HP MFP firmware | IPP Everywhere, Bonjour, SNMP, vendor telemetry |
cam-lobby-01, cam-dock-02 |
10.21.40.21/.22 | Axis cameras | RTSP + RTP video |
bms-gw-01, bms-ctrl-02 |
10.21.40.30/.31 | embedded | Modbus/TCP polling every 10 s |
guest-ios-a, guest-win-b |
10.21.50.113/.120 | iOS, Windows 11 | captive portal, DoH, QUIC video |
External addresses are taken from the ranges those services really publish —
Teams media out of 52.112.0.0/14, SharePoint out of 13.107.136.0/22,
Entra ID out of 20.190.128.0/18, Canonical out of 185.125.190.0/24 — so
whois and BGP lookups line up with the SNI. The specific host addresses inside
those ranges are invented.
Where the capture was taken
One SPAN session on the core switch, source Po1, both directions. Po1
is the trunk down to the floor-2 access stack, so the file contains exactly
the frames that crossed that trunk. Three consequences are worth knowing
before you build an exercise on this file:
- Every frame carries the floor-2 device’s VLAN tag, in both directions.
A client’s request to the file server and the server’s reply are both
tagged VLAN 10, because that is the VLAN the frame was carried on as it
crossed
Po1. VLAN 20 never appears. - Direction is readable from the MAC and the TTL. Going up: the sender’s
own MAC and its initial TTL (128 for Windows, 64 for everything else).
Coming back down: the core’s MAC
00:1e:bd:4a:11:01as source and a TTL one lower, because the core routed it. Internet replies arrive with the core’s MAC and a path-worn TTL (52–57 typically). - Same-VLAN traffic between stacks is bridged, not routed. The Delivery
Optimization transfer between
wks-sales-12(floor 2) andwks-hr-03(floor 1) keeps both real MACs and does not lose a TTL hop. That is the fingerprint of traffic that never left the layer-2 domain.
What is therefore absent, by construction: server-to-server traffic
(dc01 to fs01), the DC’s own recursive DNS to its forwarder, firewall
syslog and flow export, and anything else where neither end sits behind Po1.
The generator asserts this, so a scene that could not have been captured here
fails the build rather than quietly lying. Flow export in this file comes from
the access stack itself (sw-floor2, a Catalyst running Flexible NetFlow),
which does cross the trunk.
What is in it
$ tshark -r office.pcap -q -z io,phs
| Layer | Frames | Layer | Frames |
|---|---|---|---|
| VRRPv3 | 1,200 | TLS (records) | 501 |
| STUN/TURN (Teams media) | 8,648 | QUIC | 1,270 |
| RTP (camera video) | 1,800 | HTTP | 36 |
| RTCP | 60 | SMB2/SMB3 | 49 |
| STP (RSTP) | 150 | Kerberos | 6 |
| LLDP / CDP | 40 / 6 | SSH | 97 |
| DNS / mDNS / LLMNR / NBT-NS | 84 / 16 / 4 / 2 | RTSP | 16 |
| DHCP / DHCPv6 | 8 / 2 | Modbus/TCP | 58 |
| ICMP / ICMPv6 | 25 / 28 | syslog | 24 |
| SNMPv2c | 20 | NetFlow v9 (cflow) |
9 |
| NTP | 16 | ARP | 21 |
Also in there: SSDP, IPP (a real Print-Job operation with a PDF behind it), OCSP, a 302 to a captive portal, Microsoft Delivery Optimization peer-to-peer on TCP 7680, and IPv6 router advertisements, neighbour discovery, duplicate address detection and MLDv2.
Deliberate rough edges
Real captures are not tidy, so this one contains, on purpose:
- a dropped SMB3 segment: three duplicate ACKs with a SACK block, then the
retransmission (
tcp.analysis.retransmission), wpad.corp.northstar.exampleNXDOMAIN three times, then an HTTP fetch of/wpad.datthat 404s,- one NXDOMAIN typo and one SERVFAIL (a zone with broken DNSSEC this morning),
- an IPv4 address conflict: two hosts announcing 10.21.10.161 by ARP,
- RDP to a host that does not offer it (SYN, then RST/ACK),
- a SYN to a filtered port, retried at 1 s and 3 s, never answered,
- an ICMP port-unreachable for a stray JetDirect probe,
- an OCSP responder answering
tryLater, so the client soft-fails to a cached CRL (304 Not Modified), - a Slack session the server closes after 41 idle seconds,
- a MAC flap and an 802.1X failure in the switch’s syslog.
Rebuilding it
cd netsec/office_capture
python3 mkoffice.py # -> office.pcap (12 MB, ~25 s)
python3 mkoffice.py --out /tmp/x.pcap --seed 7 # a different office
gzip -9 -k office.pcap # what is committed here
python3 mkattack.py # -> office-attack.pcap, baseline + incident
python3 mkattack.py --overlay-only --out /tmp/atk.pcap # the attack frames alone
python3 mkattack.py --baseline-only --out /tmp/b.pcap # identical to office.pcap
gzip -9 -k office-attack.pcap
Needs scapy (python3 -m pip install scapy, or the python-scapy package);
built and checked against scapy 2.8.0 and Wireshark 4.7.4. The committed file
is the default seed; office.pcap itself is gitignored, since it rebuilds
byte-for-byte.
Generator details that matter if you edit it, all of them scapy defaults that produce a file which looks fine until a dissector disagrees:
SMB2_Negotiate_Protocol_Response.ServerTime, SMB2 create/close timestamps, and Kerberosrtimeare filled with now unless you pass them, which silently breaks reproducibility.- The VRRPv3 IPv4 checksum is computed over a pseudo-header, which current
Wireshark flags as bad. RFC 9568
settled the ambiguity RFC 5798 left: for IPv4 the checksum covers the VRRP
message alone, so
mkoffice.pyfills the field in by hand. - Kerberos
KDCOptionsandAPOptionsare 32-bitBIT STRINGs (RFC 4120 sect. 5.4.1), and scapy encodes a one-byte default and trims trailing zero bytes off a flag string. Parsers that read all four bytes — Zeek among them — then run off the end of the field, so both generators spell the bits out. PassmsgType=13toKRB_TGS_REPtoo: scapy shares one KDC-REP structure withKRB_AS_REPand leaves the message type at 11. SMB2_Session_Setup_Response’s security blob goes in a payload subfield namedSecurity, notSecurityBlobas in the request. Use the wrong name and scapy drops the blob without an error, leaving a zero-length field.
Diffing the baseline against the overlay
pcapdiff.py answers “which packets does the attack file have that the
baseline does not?” It compares the two captures as multisets of raw packet
bytes rather than line-by-line, because a capture is an unordered bag of
frames: the moment one side gains a packet, a positional diff reports every
later frame as changed. Hashing each frame and taking a set difference is
exact and runs in one pass.
$ python3 pcapdiff.py office.pcap office-attack.pcap --summary
A office.pcap 22089 packets
B office-attack.pcap 25274 packets
shared 22089
only in B (added) 3185
only in A (removed) 0
B is a strict superset of A: every baseline packet survives.
Added by protocol:
TCP/443 1568
TCP/445 1033
TCP/80 173
UDP/53 122
ICMP 118
TCP/88 40
TCP/3128 25
TCP/135 21
ARP 19
...
Added by endpoint pair (top 15):
10.21.10.61 -> 198.51.100.73 818
10.21.20.20 -> 10.21.10.61 668
198.51.100.73 -> 10.21.10.61 416
203.0.113.45 -> 10.21.10.61 230
...
Added time span: 1794330858.000000 .. 1794331134.006776 (276.007 s)
Three things worth reading off that output. The patient zero is
10.21.10.61, the only host in every added pair. The intrusion occupies 276
of the capture’s 303.7 seconds. And removed is zero with all 22,089
baseline frames shared — the overlay only adds, with original timestamps
intact, so any finding in office-attack.pcap that also appears in
office.pcap is background, not attack.
Write the added frames out to study them on their own:
python3 pcapdiff.py office.pcap office-attack.pcap -o /tmp/added.pcap
tshark -r /tmp/added.pcap -q -z conv,tcp # just the intrusion's flows
That is the same set of frames mkattack.py --overlay-only emits, recovered
from the finished captures instead of the generator — which is the point as
an exercise: students get both files, not the script.
Needs dpkt (pacman -S python-dpkt, or python3 -m pip install dpkt);
checked against dpkt 1.9.8. Exit status is 0 when the captures hold the same
packets, 1 when they differ, 2 on error, so it drops into a make rule or a
CI check. Useful flags:
-tfolds the timestamp into packet identity, so a replayed or time-shifted copy of a frame counts as different. Off by default, since retransmissions and identical keepalives are supposed to collide.-r PCAPwrites the packets only in A, for a diff that cuts both ways.--top Nsets how many rows each summary table prints.
A caveat for other captures: with timestamps excluded, genuinely duplicate
frames are indistinguishable, so the counts are multiset counts. That is
right for a layered file like this one and wrong for, say, comparing a TAP
against a SPAN port — use -t there, or one of the tools below.
If you need something else
No general-purpose pcap differ ships with Wireshark or in the Arch repos, and the ones that exist solve a different problem than the question above:
- isginf/pcap-diff — scapy-based, diffs two or more files and can ignore fields (MACs, IP IDs, TCP sequence/ack) before comparing. Reach for it when the two captures should hold the same traffic seen through different rewriting, like NAT or a tunnel.
- jgibbard/pcap_diff — C++, matches
frames by timestamp within a tolerance (
-d/-D, default 10 ms) and supports byte masks. Built for capture-point comparison, where the same packet appears twice with skew. - EFF pcapdiff and the BlackArch
tpcatpackage built on it — forged, dropped, and mangled packet detection between two observation points. Notetpcatstill depends on python2 and wxPython, so it is effectively unmaintained.
Worked examples
capinfos — what am I holding?
$ capinfos office.pcap
Number of packets: 22 k
Capture duration: 303.730000 seconds
Earliest packet time: 2026-11-10 09:14:00.370000
Average packet rate: 72 packets/s
tcpdump — the 802.1Q trap, in one line
Every frame on this trunk is tagged, and BPF does not look past a VLAN header unless you tell it to:
$ tcpdump -r office.pcap -nn 'udp port 53' | wc -l
0
$ tcpdump -r office.pcap -nn 'vlan and udp port 53' | wc -l
84
That single result is worth a whole lecture slot on why a “nothing is
happening” capture is usually a filter problem. (tcpdump cannot read the
.gz directly: gunzip -k office.pcap.gz first, or pipe zcat into
tcpdump -r -.)
tshark — passive OS identification
TTL, advertised window and the order of the TCP options are the fingerprint:
$ tshark -r office.pcap -Y 'tcp.flags.syn==1 && tcp.flags.ack==0' \
-T fields -e ip.src -e ip.ttl -e tcp.window_size_value -e tcp.options | sort -u
| Host | TTL | Window | SYN options (abbreviated) | Stack |
|---|---|---|---|---|
| 10.21.10.52 | 128 | 64240 | 020405b4 0103 0308 0101 0402 |
Windows 11 |
| 10.21.10.88 | 64 | 65535 | 020405b4 0103 0306 0101 080a… 0402 0000 |
macOS 15 |
| 10.21.10.120 | 64 | 64240 | 020405b4 0402 080a… 0103 0307 |
Ubuntu 24.04 |
| 10.21.10.165 | 64 | 65535 | 020405b4 0402 080a… 0103 0308 |
Android |
Windows offers MSS, NOP, WS, NOP, NOP, SACK-permitted and no timestamps; the BSD-derived stacks put the timestamp option before SACK-permitted and end with EOL; Linux leads with SACK-permitted and ends with the window scale. Note the window scale shift differs too: 8 on Windows and Android, 7 on Linux, 6 on Apple.
tshark — TLS fingerprints line up with the stacks
Wireshark computes JA3 and JA4 for every Client Hello, and each stack in the building has its own:
$ tshark -r office.pcap -Y 'tls.handshake.type==1' \
-T fields -e ip.src -e tls.handshake.ja4 | sort | uniq -c | sort -rn
| JA4 | Stack | Seen from |
|---|---|---|
t13d2312h2_f5f6aa22264f_… |
Windows Schannel | .52, .61, .200, guest .120 |
t13d1912h2_49231063e37c_… |
Apple | .88, .91, .161, guest .113 |
t13d3112h2_e8f1e7e78f70_… |
OpenSSL (apt, dnf, docker) | .120, .121 |
t13d1513h2_8daaf6152771_… |
Chromium/Edge | .52, guest .120 |
t12d120500_feb2c0f92e6b_… |
printer firmware, TLS 1.2, no ALPN | 10.21.40.11 |
wks-fin-07 (10.21.10.52) shows up twice on purpose: its Outlook and LDAPS
sessions are Schannel, and its sign-in at login.microsoftonline.com is the
browser. One IP address is not one client.
tshark — who is talking to whom, and about what
# Every TLS server name in the file, by client
tshark -r office.pcap -Y 'tls.handshake.extensions_server_name' \
-T fields -e ip.src -e tls.handshake.extensions_server_name | sort | uniq -c | sort -rn
# Teams QoS marking: EF for audio, AF41 for video, AF21 for sharing
tshark -r office.pcap -T fields -e ip.dsfield.dscp | sort | uniq -c | sort -rn
# 13190 0 7006 46 (EF) 1352 34 (AF41) 290 18 (AF21)
# The queries that failed, with the hosts that asked
tshark -r office.pcap -Y 'dns.flags.rcode != 0 && dns.flags.response==1' \
-T fields -e ip.dst -e dns.qry.name -e dns.flags.rcode
# Top conversations by bytes
tshark -r office.pcap -q -z conv,ip | head -15
Wireshark — the camera stream decodes itself
The RTSP exchange carries its SDP, so Wireshark knows the RTP payload type and decodes the stream without any “Decode As” work:
- filter
rtspand follow the TCP stream to readDESCRIBE/SETUP/PLAYand the SDP body, - filter
rtpfor the 1,800 video packets, then Telephony → RTP → RTP Streams for jitter and loss per stream.
Teams media is the contrast case: it is SRTP inside TURN ChannelData on UDP 3478, so you get STUN and an opaque payload no matter what you do — which is the point. The ICE binding request shows the USERNAME and a valid FINGERPRINT, and the binding response shows the relayed address.
Zeek — the same five minutes as structured logs
$ zeek -C -r office.pcap
$ ls
conn.log dhcp.log dhcpv6.log dns.log files.log http.log
kerberos.log modbus.log ntp.log quic.log snmp.log ssh.log
ssl.log syslog.log weird.log
$ cat ssl.log | zeek-cut id.orig_h server_name | head -3
10.21.10.52 outlook.cloud.microsoft
10.21.10.61 outlook.cloud.microsoft
10.21.10.52 teams.cloud.microsoft
$ cat conn.log | zeek-cut service | sort | uniq -c | sort -rn | head -5
60 dns
45 -
26 ssl
15 http
10 snmp
-C is required: Zeek checksum-validates by default and this file is
synthetic. weird.log is instructive rather than a defect — Zeek’s dynamic
protocol detection calls RTSP on TCP 554 an HTTP conversation with an
unknown_HTTP_method, which it does with real RTSP too. Those ten RTSP
weirds are the only ones in the file, and there is no analyzer.log at all,
which is the bar a synthetic capture should clear: nothing in it defeats a
parser.
kerberos.log is worth a look next to the attack file’s:
$ cat kerberos.log | zeek-cut request_type client service cipher
AS jlin/CORP.NORTHSTAR.EXAMPLE krbtgt/CORP.NORTHSTAR.EXAMPLE aes256-cts-hmac-sha1-96
TGS jlin/CORP.NORTHSTAR.EXAMPLE cifs/fs01.corp.northstar.example aes256-cts-hmac-sha1-96
Exercise ideas
- Baseline inventory. Produce the host table above from the file alone: who is on which VLAN, what OS, what role. Which three hosts are not on the mirrored stack, and how can you tell?
- Direction and topology. Explain why
ip.src==10.21.20.20frames are tagged VLAN 10 and arrive with TTL 127. Draw the topology from the evidence: BPDUs, CDP, LLDP, VRRP, ARP and the TTL deltas. - Encrypted-traffic analysis. You cannot read the payloads. Determine what each user was doing anyway — from SNI, QUIC connection IDs, DSCP, packet sizes, timing and flow volumes.
- Legacy exposure. Find every protocol in the file that an attacker on the same VLAN could abuse (LLMNR, NBT-NS, mDNS, SSDP, SNMPv2c with a community string in the clear, plaintext HTTP for Windows Update content, WPAD). Write the remediation memo.
- Flow analysis. Compare what the NetFlow v9 records in the file claim against what the packets actually show, and explain why an exporter’s counters and a packet capture disagree.
- Triage drill. Nothing in this file is malicious. Have students justify
that conclusion for the five flows that look worst at a glance: the DO
peer transfer on 7680, the 1,200 VRRP frames, the EDR telemetry beacon to
AWS, the Modbus polling, and the Teams media to
52.112.0.0/14. - Tooling. Carve the print job out of the IPP POST; extract the SSH
algorithm lists and spot which endpoint is the dated one (the switch offers
ssh-rsaandhmac-sha1, the Ubuntu client leads withsntrup761x25519-sha512). - Earn the baseline. Do exercise 6 first, then run the same five flows
down in
office-attack.pcap, where some of them are no longer benign. Knowing what normal looks like is the only reason the attack file is tractable.
What is synthetic, and where it shows
Be straight with students about this; it is also a good critical-reading exercise.
- Encrypted payloads are random bytes. TLS, SRTP and QUIC payloads carry no real ciphertext, so nothing decrypts and no key log exists. Wireshark’s expert info reports QUIC decryption failures for that reason — in a real capture the Initial packets would decrypt and show a ClientHello with SNI, since the initial keys derive from the connection ID.
- SMB session setup is not modeled. Negotiate is real and plaintext; everything after it is SMB3 transform headers. Do not use this file to teach NTLM or SPNEGO internals.
- Kerberos structures are correct ASN.1 — AS-REQ, pre-auth-required error, AS-REQ with PA-ENC-TIMESTAMP, AS-REP, TGS-REQ, TGS-REP — but the encrypted parts are noise, so no ticket is decipherable.
- Camera video is one packet per frame. Real H.264 fragments a key frame across many packets; bitrates and loss patterns here are not realistic.
- Volumes are scaled down. 331 kbit/s average is far below a real 180-seat office. Treat throughput exercises as relative, not absolute.
- mDNS queries appear twice (IPv4 and IPv6), which Wireshark labels a retransmission. Bonjour really does query on both families.
- Timestamps are PST with no capture-time zone metadata, because the file is a classic pcap, not pcapng.
References
- Microsoft 365 URLs and IP address ranges — the Teams media ports (UDP 3478–3481), the
52.112.0.0/14and52.122.0.0/15ranges, and the QUIC (UDP 443) entries for Exchange Online and SharePoint - Implement Quality of Service in Microsoft Teams — the client source-port ranges and DSCP values used for the media flows: audio 50000–50019/EF, video 50020–50039/AF41, sharing 50040–50059/AF21
- Prepare your organization’s network for Teams — bandwidth figures behind the call sizes
- Delivery Optimization FAQ — TCP 7680 for peering, HTTPS 443 to the cloud service, content over HTTP
- Aligning on mDNS: ramping down NetBIOS and LLMNR — why mDNS dominates and LLMNR/NBT-NS appear only on the one legacy host
- RFC 9568 — VRRPv3; section 5.2.8 resolves the IPv4 checksum ambiguity left by RFC 5798
- RFC 8489 (STUN) and RFC 8656 (TURN ChannelData) — the Teams media framing
- RFC 9000 and RFC 9001 — QUIC packet headers and initial keys
- RFC 8446 — TLS 1.3, for the hand-built ClientHello extensions
- RFC 6762 / RFC 6763 — mDNS and DNS-SD, including the cache-flush bit
- RFC 4120 — Kerberos V5 message structures
- RFC 8010 / RFC 8011 — IPP encoding and the Print-Job operation
- MS-SMB2 — SMB 3.1.1 negotiate contexts and the transform header
- Wireshark display-filter reference and Zeek log reference
- dpkt documentation — the reader/writer and decoders
pcapdiff.pyis built on
Course pages that pair with this file: tshark,
wireshark, tcpdump,
pcap_tools, network_flow_analysis,
capture.