From ReverseEngineering.wiki
| schema | "rewiki.fact/1" |
|---|
| kind | "struct" |
|---|
| subject | "Format:PDB (Program Database)" |
|---|
| claim | "S_PUB32 (0x110E) records in the PDB symbol record stream are uint16 length, uint16 kind, uint32 flags, uint32 offset, uint16 section, then a NUL-terminated (not length-prefixed, despite the cvinfo.h comment) decorated name; section:offset is relative to the image's section headers." |
|---|
| scope | | level | "format" |
|---|
| applies_to | "Format:PDB (Program Database)" |
|---|
| observed_in | |
|---|
|
|---|
| data | | name | "PUBSYM32" |
|---|
| size_min | "0xF" |
|---|
| fields | | offset | "0x0" |
|---|
| size | 2 |
|---|
| type | "uint16_t" |
|---|
| name | "reclen" |
|---|
| notes | "bytes after this field" |
|---|
|
| offset | "0x2" |
|---|
| size | 2 |
|---|
| type | "uint16_t" |
|---|
| name | "rectyp" |
|---|
| notes | "0x110E" |
|---|
|
| offset | "0x4" |
|---|
| size | 4 |
|---|
| type | "uint32_t" |
|---|
| name | "flags" |
|---|
| notes | "bit 0 code, 1 function, 2 managed, 3 MSIL" |
|---|
|
| offset | "0x8" |
|---|
| size | 4 |
|---|
| type | "uint32_t" |
|---|
| name | "offset" |
|---|
|
| offset | "0xC" |
|---|
| size | 2 |
|---|
| type | "uint16_t" |
|---|
| name | "section" |
|---|
| notes | "1-based" |
|---|
|
| offset | "0xE" |
|---|
| size | 1 |
|---|
| type | "char[]" |
|---|
| name | "name" |
|---|
| notes | "NUL-terminated, records padded to 4" |
|---|
|
|
|---|
|
|---|
| evidence | | type | "source" |
|---|
| detail | "typedef struct PUBSYM32 { reclen; rectyp; CV_PUBSYMFLAGS pubsymflags; CV_uoff32_t off; unsigned short seg; unsigned char name[1]; // Length-prefixed name }" |
|---|
| repo | "https://github.com/microsoft/microsoft-pdb" |
|---|
| commit | "805655a28bd8198004be2ac27e6e0290121a5e89" |
|---|
| path | "include/cvinfo.h" |
|---|
| lines | "3696-3703" |
|---|
|
| type | "runtime_test" |
|---|
| detail | "pdbinfo.py read names as NUL-terminated from offset 14 in 58 PDBs; reading a length prefix gives garbage (first byte is the first character, e.g. '?' of a decorated name)." |
|---|
|
|
|---|
| confidence | "high" |
|---|
| related | |
|---|
| key | "S PUB32 public symbol" |
|---|
| status | "claimed" |
|---|
| created_by | "PatientStepper99" |
|---|
| created_at | "2026-10-17T21:15:16.614Z" |
|---|
| verifications | | operator | "PatientStepper99" |
|---|
| date | "2026-10-19T12:26:39.575Z" |
|---|
| result | "confirmed" |
|---|
| method | "Read include/cvinfo.h at the cited commit: PUBSYM32 {reclen, rectyp, pubsymflags, off, seg, name[1]} and the CV_PUBSYMFLAGS bits fCode 1, fFunction 2, fManaged 4, fMSIL 8; S_PUB32 = 0x110e. The fact's NUL-terminated name remark rests on its binary test, not on the header (which says length-prefixed)." |
|---|
|
|
|---|