What is Syscall Invocation?
Once you have the correct SSN (System Service Number), you need to execute the actualsyscall instruction to transition from user-mode to kernel-mode. The invocation method determines where the syscall instruction lives and how it’s executed.
Different invocation methods have different detection profiles for AV/EDR products.
Why It Matters: RIP Visibility
When a syscall transitions to kernel-mode, the kernel can inspect the instruction pointer (RIP) that initiated the syscall. EDR drivers monitor this:ntdll.dll as potential hook bypasses.
Available Invocation Methods
SysWhispers4 provides 4 different invocation techniques:Embedded
Direct syscall in your code. Fastest. RIP in your PE.
Indirect
Jump to ntdll gadget. RIP in ntdll. Static gadget.
Randomized
Random gadget per call. RIP in ntdll. Maximum entropy.
Egg Hunt
No syscall on disk. Runtime patching. Zero static signature.
Method Comparison
| Method | RIP in ntdll | Syscall on Disk | Random per Call | Speed | Stealth |
|---|---|---|---|---|---|
| Embedded | ❌ | ✅ | ❌ | Fastest | Low |
| Indirect | ✅ | ❌ | ❌ | Fast | High |
| Randomized | ✅ | ❌ | ✅ (64 gadgets) | Fast | Very High |
| Egg Hunt | ❌ | ❌ | ❌ | Medium | Very High |
Embedded =
Indirect = Jump to
Randomized = Pick random gadget from pool of 64
Egg Hunt = Replace runtime egg with
syscall instruction lives in your stubIndirect = Jump to
syscall;ret gadget in ntdllRandomized = Pick random gadget from pool of 64
Egg Hunt = Replace runtime egg with
syscallEmbedded: Direct Syscall
Thesyscall instruction is compiled directly into your generated stub:
- Simplest implementation
- No ntdll dependency
- Fastest execution
syscallopcode (0F 05) visible in your binary on disk- RIP points to your PE at kernel entry — detectable by EDR
Indirect: ntdll Gadget
Your stub jumps to a pre-locatedsyscall;ret gadget inside ntdll.dll:
- RIP appears inside ntdll.dll (legitimate)
- No
syscallopcode in your binary on disk - Bypasses simple “syscall from non-ntdll” detection
- Static gadget address can be fingerprinted by EDR
- Requires ntdll to remain mapped
Randomized: Entropy per Call
Like Indirect, but selects a different random gadget from a pool of up to 64 on every syscall:- RIP inside ntdll (legitimate)
- Different gadget every call — defeats EDR whitelisting
- Uses
RDTSCfor entropy (no API calls) - No
syscallopcode in your binary
- Slightly slower than Indirect (RDTSC + array lookup)
- More complex stub code
Egg Hunt: No Syscall on Disk
Stubs contain a random 8-byte egg marker instead ofsyscall. At runtime, SW4_HatchEggs() scans your .text section and replaces eggs with 0F 05 90 90 90 90 90 90:
- Zero
syscallopcodes in binary on disk - Defeats static signature scanning
- Works with or without ntdll
- Requires
.textsection to be writable at runtime (VirtualProtect) - RIP still points to your PE (detectable by kernel EDR)
- Slower initialization
Choosing the Right Method
For Quick Testing
For Standard Red Team Operations
Against Advanced EDR with Gadget Fingerprinting
To Evade Static Signature Scanning
syscall opcode on disk. Runtime patching.
Maximum Stealth (Randomized + Stack Spoofing)
Detection Landscape
| Detection Vector | Embedded | Indirect | Randomized | Egg |
|---|---|---|---|---|
| User-mode hook bypass | ✅ | ✅ | ✅ | ✅ |
| RIP inside ntdll | ❌ | ✅ | ✅ | ❌ |
Static syscall signature | ⚠️¹ | ✅ | ✅ | ✅ |
| Gadget fingerprinting | N/A | ⚠️ Static | ✅ Random | N/A |
| Kernel ETW-Ti | ❌ | ❌ | ❌ | ❌ |
Learn More
Detailed Method Reference
Complete technical documentation and usage examples for all invocation methods.
Stack Spoofing
Synthetic call stack frames to evade stack-walking EDR analysis.
EDR Detection Vectors
Comprehensive analysis of what EDR products can and cannot detect.
ETW-Ti Limitations
Understanding kernel-mode telemetry that cannot be bypassed from user-mode.
