Skip to content

A lightweight anti-malware PoC that detects and blocks malware using direct syscalls via windows instrumentation callbacks.

Notifications You must be signed in to change notification settings

svespalec/cerberus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 

Repository files navigation

cerberus

a lightweight proof-of-concept that detects and blocks malware using direct syscalls via windows instrumentation callbacks.

why cerberus?

in greek mythology, cerberus is the three-headed dog that guards the gates of the underworld. hell's gate was a famous direct syscall technique, so cerberus stands watch, catching anyone trying to sneak through.

showcase

showcase

how it works

we register a process instrumentation callback that intercepts every kernel to user transition (sysret). on each syscall return, we validate that the return address (r10) points to a legitimate system module (ntdll.dll/win32u.dll). if not, the syscall originated from unauthorized code (the direct syscall) and the process is terminated.

detects

  • inline syscall stubs
  • copied/stolen syscall stubs
  • manual mov eax, SSN; syscall sequences
  • SysWhispers styled direct syscalls

limitations

  • does not detect indirect syscalls (jmp-to-ntdll techniques)
  • most edrs mitigate indirect syscalls via inline hooks that destroy the syscall stub

credits

  • @Peribunt for instrumentation callback reference

About

A lightweight anti-malware PoC that detects and blocks malware using direct syscalls via windows instrumentation callbacks.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published