Overview
Signatures are byte patterns used to locate functions and data in the game binary at runtime. They’re essential for making the library work across game patches without hardcoding addresses.Signature Format
All signatures in FFXIVClientStructs must follow these strict rules:Required Format
- Use
??for wildcard bytes - Include 2 hex characters per byte (e.g.,
0FnotF) - Separate bytes with spaces
- Use uppercase hex digits (recommended for consistency)
Valid Examples
Invalid Examples
Finding Signatures
Using IDA Pro
Step 1: Locate the Function
- Load FFXIV binary in IDA Pro
- Import the rename database
- Find your function by name or navigate to it
- Press
Spaceto switch to text view if needed
Step 2: Identify Unique Bytes
Look for instruction sequences that are:- Unique: Not found elsewhere in the binary
- Stable: Won’t change across patches
- Long enough: Usually 8-20 bytes
Step 3: Create the Pattern
Example function:Step 4: Test Uniqueness
- In IDA: Alt+B (Search > Sequence of bytes)
- Paste your pattern:
48 89 5C 24 08 57 48 83 EC 20 48 8B D9 - Search - should find exactly ONE location
- If multiple results, make pattern longer or more specific
Using Ghidra
Step 1: Locate the Function
- Load FFXIV binary
- Import rename database
- Navigate to the function
- Right-click in listing → Copy Special → Byte String
Step 2: Test the Pattern
- Search → Memory (or press
S) - Choose “Hex” format
- Paste bytes (spaces optional)
- Verify single result
Using x64dbg (Runtime)
For finding signatures while the game is running:- Attach x64dbg to FFXIV process
- Navigate to the function (if you know the address)
- Copy bytes from the disassembly
- Use Search → Pattern to test uniqueness
Creating Stable Signatures
What Makes a Good Signature?
✓ Good Patterns
Function prologues:✗ Bad Patterns
Too many wildcards:Wildcard Placement
When to Use Wildcards
Function call targets:When NOT to Use Wildcards
Opcodes:Signature Length
Recommended Lengths
- Minimum: 8-12 bytes for uniqueness
- Typical: 12-20 bytes for stability
- Maximum: 30-40 bytes (longer = more fragile)
Too Short
Too Long
Just Right
StaticAddress Signatures
For[StaticAddress], you need to find where the static variable is referenced:
Example: Finding Framework Instance
Step 1: Locate Reference
Find code that accesses the static instance:Step 2: Create Signature
Wildcard the offset:Step 3: Determine Offset
3 (where the address bytes start).
Step 4: Determine isPointer
If the assembly is:isPointer: true (it’s a Framework**)
If the assembly is:
isPointer: false (it’s a Framework*)
Common Patterns
VTableAddress Signatures
For[VTableAddress], find where the vtable pointer is assigned in the constructor:
Example
3
Usage:
Testing Signatures
In IDA Pro
Alt+B → Paste signature → Search- Should find exactly 1 result
- Should land at the correct function/location
In Ghidra
Search → Memory → Hex string- Should find exactly 1 result
- Verify it’s the correct location
At Runtime
Use the ResolverTester project:Signature Maintenance
When Signatures Break
After a game patch, signatures may fail to resolve. Common causes:- Function moved: Code location changed
- Function modified: Compiler generated different code
- Optimization changed: New compiler flags
Updating Broken Signatures
- Import new rename database for the patch
- Navigate to the function in IDA/Ghidra
- Find the same logical code section
- Create a new signature
- Test for uniqueness
- Submit PR with updated signature
Making Signatures More Stable
- Choose code from the middle of functions (not start/end)
- Avoid signatures near branch instructions
- Include distinctive instruction sequences
- Balance uniqueness vs. stability
Common Signature Patterns
Here are common x64 assembly patterns you’ll encounter:Function Prologues
53 48 83 EC 20 48 8B D9
48 89 5C 24 ?? 48 89 74 24 ?? 57
Function Calls
E8 ?? ?? ?? ?? 48 8B F8
Static Data Access
48 8B 0D ?? ?? ?? ?? 48 85 C9 74 ??
Virtual Calls
48 8B 01 FF 90 50 00 00 00
Troubleshooting
Signature Not Found
- Too specific: Add more wildcards
- Function changed: Find the updated code
- Wrong binary: Ensure you’re scanning the correct module
Multiple Matches
- Too generic: Make signature longer
- Add context: Include more surrounding bytes
- Choose different location: Find a more unique part of the function
Signature Resolves to Wrong Location
- Pattern collision: Signature matches unintended code
- Increase specificity: Add more context bytes
- Change pattern: Use a different part of the function
Best Practices
- Test thoroughly: Verify uniqueness before committing
- Document: Add comments if the signature is tricky
- Balance length: Not too short, not too long
- Stable opcodes: Choose instructions that won’t change
- Wildcard wisely: Only wildcard what needs to vary
- Verify runtime: Test that the signature resolves correctly
Tools Reference
- IDA Pro: Industry standard, best RTTI support
- Ghidra: Free alternative, good scripting
- x64dbg: Runtime debugging and signature testing
- ResolverTester: Test signatures with the actual resolver
Next Steps
- Adding Functions - Use signatures in function definitions
- Testing - Verify signatures resolve correctly
- Contributing - Submit your changes