Protocol 65 of 81Layer 7FrameAssembly v3.1.2
llms-full.txt
kerberosKerberos Network Authentication Service v5 (Active Directory)

Active Directory Tickets & RC4 Kerberoasting (pc <-> dc kerberos Port 88)

Default Port / Protocol
UDP 88 (or TCP 88 via transport tcp)
Host Endpoint Rule
Dual-Stack IPv4/IPv6
Wireshark Display Filter
kerberos
Standards & Specs
RFC 4120, RFC 3962, RFC 4757
Wire Stack:Ethernet II[802.1Q / QinQ / MPLS]IPv4 / IPv6UDP 88 (or TCP 88 via transport tcp) (transport tcp|udp)Kerberos v5

What It Does on the Wire

Trigger SOC Kerberoasting rules (tgsreq + sname "MSSQLSvc/..." + etype 23) without firing offensive tools at a real Domain Controller — add transport tcp and the compiler prepends the 4-byte RFC 4120 TCP record length automatically.

Kerberos v5 (kerberos, RFC 4120) is the core ticket-granting authentication protocol in Microsoft Active Directory and enterprise Linux realms on port 88. kerberos defaults to UDP port 88, and adding transport tcp switches to TCP port 88—automatically prepending the mandatory 4-byte RFC 4120 big-endian record-length header used by Windows Domain Controllers when tickets carry large PAC group memberships.

FrameAssembly encodes full ASN.1 DER Kerberos v5 (pvno 5) messages for asreq, asrep, tgsreq, tgsrep, and krberror with customizable realm, client principal (cname), service SPN (sname), and encryption type (etype, such as 18 for AES256 or 23 for RC4-HMAC).

Test Kerberoasting (etype 23 RC4 Downgrade) NDR & Suricata Rules

Generate a tgsreq requesting sname "MSSQLSvc/sql01.corp.internal:1433" with etype 23 (rc4-hmac) so SOC teams can validate Kerberoasting alerts without running offensive tools against a live Domain Controller.

Validate AS-REP Roasting & Username Enumeration (krberror) Detections

Simulate bursts of asreq and krberror packets across workstation VLANs to verify Zeek kerberos.log and CrowdStrike/Defender/NDR identity detections.

Domain Controller Firewall Checks (UDP 88 + TCP 88)

Verify branch-to-DC firewall rules allow both UDP 88 and transport tcp port 88 so users in many AD security groups do not fail login when Kerberos switches to TCP.

Minimal Quickstart (kerberos_quickstart.frasm)

Hit Preview Packets to compile in-browser and eyeball timestamps + wire byte lengths, or ship it straight to the Playground.

kerberos_quickstart.frasm7 lines
Open in Playground
host domain_pc { ip 10.10.20.45 }
host ad_dc01 { ip 10.10.0.10 }
compile {
domain_pc -> ad_dc01 kerberos asreq realm "CORP.INTERNAL" cname "jdoe" sname "krbtgt/CORP.INTERNAL" etype 18 wait 2ms
domain_pc <- ad_dc01 kerberos asrep realm "CORP.INTERNAL" cname "jdoe" etype 18
}

What the Compiler Calculates So You Don't Have To

  • Encodes valid ASN.1 DER RFC 4120 APPLICATION tags (10 AS-REQ, 11 AS-REP, 12 TGS-REQ, 13 TGS-REP, 30 KRB-ERROR) with pvno = 5.
  • Splits slash-separated SPNs like "MSSQLSvc/db01.corp.internal:1433" into multi-component PrincipalName ASN.1 sequences automatically.
  • Prepends the 4-byte RFC 4120 §7.2.2 TCP record-mark length automatically whenever transport tcp is specified.
Multi-Frame Lab · Ready to Compile

AES256 TGT Login Over TCP 88 + RC4 (etype 23) Kerberoasting Detection Lab

Models a normal Windows workstation obtaining an AES256 TGT over TCP port 88, followed by an RC4 (etype 23) tgsreq/tgsrep SPN ticket request to trigger SOC Kerberoasting signatures.

kerberos_ad_detection_lab.frasm14 lines
Open in Playground
host wkstn_14 { ip 172.16.20.14 }
host dc01_ad { ip 172.16.1.10 }
compile {
// 1. Normal Active Directory TGT exchange over TCP port 88 (etype 18 = AES256)
wkstn_14 -> dc01_ad tcp syn srcport 53088 dstport 88 win 65535 mss 1460 wait 1ms
wkstn_14 <- dc01_ad tcp syn ack win 65535 mss 1460 wait 1ms
wkstn_14 -> dc01_ad tcp ack wait 1ms
wkstn_14 -> dc01_ad kerberos asreq realm "CORP.INTERNAL" cname "alice" sname "krbtgt/CORP.INTERNAL" etype 18 transport tcp wait 2ms
wkstn_14 <- dc01_ad kerberos asrep realm "CORP.INTERNAL" cname "alice" etype 18 transport tcp wait 5ms
// 2. Suspicious RC4-HMAC (etype 23) Service Ticket Request for SQL SPN (Kerberoasting test)
wkstn_14 -> dc01_ad kerberos tgsreq realm "CORP.INTERNAL" cname "alice" sname "MSSQLSvc/db-prod.corp.internal:1433" etype 23 transport tcp wait 2ms
wkstn_14 <- dc01_ad kerberos tgsrep realm "CORP.INTERNAL" cname "alice" sname "MSSQLSvc/db-prod.corp.internal:1433" etype 23 transport tcp
}
Terminal Commands (FrameAssembly CLI v3.1.2)
# 1. Eyeball relative timestamps, ports & wire lengths in your terminal
frameassembly show kerberos_ad_detection_lab.frasm

# 2. Compile .frasm -> classic .pcap (tcpdump/tcpreplay/Suricata) or nanosecond .pcapng
frameassembly kerberos_ad_detection_lab.frasm kerberos_ad_detection_lab.pcap
frameassembly kerberos_ad_detection_lab.frasm kerberos_ad_detection_lab.pcapng

# 3. Round-trip .pcap <-> .frasm whenever you want to scrub or tweak an existing capture
frameassembly reverse kerberos_ad_detection_lab.pcap kerberos_ad_detection_lab_edited.frasm

All kerberos Keywords & Header Options

Every sub-keyword and header option is lowercase [a-z0-9]+ with zero underscores — mix and match them in any order after kerberos:

src_host -> dst_host kerberos [asreq | asrep | tgsreq | tgsrep | krberror] [realm "<text>"] [cname "<text>"] [sname "<text>"] [etype <number>] [transport <udp|tcp>]
Keyword / OptionAccepted ValueDefaultEffect on Packet
asreq | asrep | tgsreq | tgsrep | krberrorKerberos v5 message typeasreq (msg-type 10)Selects Authentication Service Request/Reply (10/11), Ticket-Granting Service Request/Reply (12/13), or Error (30).
realm "<text>"Quoted uppercase Kerberos realm (e.g. "CORP.INTERNAL")"EXAMPLE.COM"Encodes the Realm GeneralString inside the ASN.1 DER body.
cname "<text>" | sname "<text>"Quoted Client Principal Name or Service Principal Name (SPN)cname "alice", sname "krbtgt/EXAMPLE.COM"Encodes PrincipalName components in KDC-REQ-BODY / KDC-REP.
etype <number>RFC 3961 encryption ID (18 AES256, 17 AES128, 23 RC4-HMAC; negative vendor IDs allowed)18 (aes256-cts-hmac-sha1-96)Sets the requested or encrypted-part etype integer.
transport <udp|tcp>udp or tcpudpSwitches between UDP 88 and TCP 88 (with 4-byte RFC 4120 TCP length prefix).

Cross-Layer Wrappers Valid with kerberos

802.1Q VLAN / QinQ / MPLS tags, IPv4/IPv6 QoS & TTL fields, wait gaps, and transport overrides allowed on this protocol

12 options
OptionRange / FormatDefaultEffect on Packet
wait <number><ns|us|ms|s|m>Time gap (ns, us, ms, s, m)10msAdvances the packet timestamp clock after sending this packet and before the next packet (wait 0ns sends back-to-back).
payload "<text>" | hexpayload "<hex>"Quoted text or hex bytes (choose one)OmittedAppends or overrides raw payload bytes ("deadbeef" or "de:ad:be:ef") and updates packet lengths and checksums.
srcmac <mac> | dstmac <mac>Colon, hyphen, or Cisco dot MACHost MAC / RFC multicast MACOverrides the 14-byte Ethernet II source or destination MAC address for this single packet.
vlan <0..4095> [pcp <0..7>] [dei <0|1>]VLAN ID 0..4095, PCP 0..7, DEI 0..1UntaggedWraps the packet in an IEEE 802.1Q VLAN tag (0x8100) with optional 802.1p QoS priority.
qinq <0..4095> [innervlan <0..4095>]Outer S-VLAN 0..4095, Inner C-VLAN 0..4095Untagged (innervlan 1 when qinq is set)Double-tags the packet with outer IEEE 802.1ad S-Tag (0x88a8) plus inner IEEE 802.1Q C-Tag (0x8100).
mpls <0..1048575> [exp|tc <0..7>] [bos <0|1>] [mplsttl <0..255>]Label 0..1048575, exp/tc 0..7, bos 0..1, ttl 0..255Unlabeled (at most 1 mpls tag per packet)Inserts a 32-bit MPLS label header (0x8847) ahead of the Layer 3 header.
ttl <0..255> [dscp <0..63>] [ecn <0..3>]TTL/Hop Limit 0..255, DSCP 0..63, ECN 0..3ttl 64, dscp 0, ecn 0Sets IPv4 TTL or IPv6 Hop Limit plus DiffServ (DSCP) and ECN QoS markings.
ipid <0..65535> [df] [mf] [fragoffset <0..8191>]IPv4 ID, DF/MF flags, fragment offset 0..8191ipid 1, flags 0, fragoffset 0Sets IPv4 Identification, Do-Not-Fragment (df), More-Fragments (mf), and fragment offset (ignored over IPv6).
flowlabel <0..1048575>20-bit IPv6 Flow Label (0..1048575)0Sets the 20-bit IPv6 Flow Label for ECMP routing tests (ignored when running over IPv4 hosts).
srcport <0..65535> | dstport <0..65535>Port number 0..65535srcport 49152 (remembered), UDP 88 (or TCP 88 via transport tcp)Overrides source or destination port and remembers the port pair automatically on <- replies.
transport <tcp|udp>tcp or udp (supported on 9 dual-L4 protocols)transport udpSwitches Layer 4 transport between TCP (psh ack + length framing where required) and UDP.
seq <number> | acknum <number> | win <0..65535> | syn | ack | psh | fin | rstTCP sequence/ack numbers, window size, flags & RFC 7323 optionspsh ack, win 65535, automatic TCP seq/acknumWhen using TCP (transport tcp or default TCP): overrides automatic TCP sequence tracking, flags, or mss/wscale/sackperm/tsval/tsecr.

Gotchas & Quick Fixes

No Hyphens in asreq, asrep, tgsreq, tgsrep, or krberror

Avoid
domain_pc -> ad_dc01 kerberos tgs-req etype 23
Valid v3.1.2 Syntax
domain_pc -> ad_dc01 kerberos tgsreq etype 23

Write Kerberos message types as single lowercase words without hyphens.

Field Guide 03
Poke Stateful Firewalls, Suricata, Zeek & OT Conduits