Skip to content
EntityQ1203383· pop 17· linked from 61 articles

钩子编程

Sign in to save

Also known as hooks

In computer programming, hooking is a range of techniques used to alter or augment the behaviour of an operating system, of applications, or of other software components by intercepting function calls or messages or events passed between software components. Code that handles such intercepted function calls, events or messages is called a hook.

Wikidata facts

Subclass of
software feature
Show 2 more facts
different from
Hook
Stack Exchange tag
stackoverflow.com/tags/hook
Sources (1)

via Wikidata · CC0

Article · 中文

钩子编程(hooking),也称作“挂钩”,是计算机程序设计术语,指通过拦截软件模块间的函数调用、消息传递、事件传递来修改或扩展操作系统、应用程序或其他软件组件的行为的各种技术。处理被拦截的函数调用、事件、消息的代码,被称为钩子(hook)。 钩子编程有多种用途,如调试、扩展功能。例如在键盘或鼠标事件到达应用程序之前拦截这些事件;拦截应用程序或其他模块的操作系统调用以监督行为、修改功能。也广泛用于benchmarking程序,如度量3D游戏的帧率。 钩子编程也被用于恶意代码,如rootkit是各种通过假扮系统API调用输出来隐藏自身进程的可见性的工具与技术;游戏外挂是另一类例子。

Abstract from DBpedia / Wikipedia · CC BY-SA