HyperDbg Debugger
Loading...
Searching...
No Matches
platform-signal.h File Reference

User mode cross-platform interface for the console-control (CTRL+C / CTRL+BREAK) handler. More...

Go to the source code of this file.

Typedefs

typedef BOOL(* PLATFORM_CTRL_HANDLER) (DWORD CtrlType)

Functions

BOOLEAN PlatformInstallCtrlHandler (PLATFORM_CTRL_HANDLER Handler)

Detailed Description

User mode cross-platform interface for the console-control (CTRL+C / CTRL+BREAK) handler.

Author
Max Raulea (max.r.nosp@m.aule.nosp@m.a@gma.nosp@m.il.c.nosp@m.om)

HyperDbg installs a single handler (BreakController) that pauses the debuggee when the user hits CTRL+C / CTRL+BREAK. The handler body is platform independent; only the OS mechanism that delivers the event and the thread context it runs in are OS specific. This interface isolates that registration. Windows maps onto SetConsoleCtrlHandler; Linux maps onto POSIX signals serviced by a dedicated sigwait() thread so the handler runs in ordinary thread context (matching Windows, which also dispatches the handler on its own thread).

Version
0.20
Date
2026-06-16

Typedef Documentation

◆ PLATFORM_CTRL_HANDLER

typedef BOOL(* PLATFORM_CTRL_HANDLER) (DWORD CtrlType)

Function Documentation

◆ PlatformInstallCtrlHandler()

BOOLEAN PlatformInstallCtrlHandler ( PLATFORM_CTRL_HANDLER Handler)