129 lines
10 KiB
JSON
129 lines
10 KiB
JSON
{
|
|
"type": "bundle",
|
|
"id": "bundle--a8fbb8e2-8e74-415b-be61-29e707eb0d38",
|
|
"spec_version": "2.0",
|
|
"objects": [
|
|
{
|
|
"type": "attack-pattern",
|
|
"id": "attack-pattern--66f73398-8394-4711-85e5-34c8540b22a5",
|
|
"created_by_ref": "identity--c78cb6e5-0c4b-4611-8297-d1b8b55e40b5",
|
|
"created": "2018-01-16T16:13:52.465Z",
|
|
"modified": "2018-01-17T12:56:55.080Z",
|
|
"name": "Hooking",
|
|
"description": "Windows processes often leverage application programming interface (API) functions to perform tasks that require reusable system resources. Windows API functions are typically stored in dynamic-link libraries (DLLs) as exported functions. Hooking involves redirecting calls to these functions and can be implemented via:\n* '''Hooks procedures''', which intercept and execute designated code in response to events such as messages, keystrokes, and mouse inputs. (Citation: Microsoft Hook Overview) (Citation: Engame Process Injection July 2017)\n* '''Import address table (IAT) hooking''', which use modifications to a process\u2019s IAT, where pointers to imported API functions are stored. (Citation: Engame Process Injection July 2017) (Citation: Adlice Software IAT Hooks Oct 2014) (Citation: MWRInfoSecurity Dynamic Hooking 2015)\n* '''Inline hooking''', which overwrites the first bytes in an API function to redirect code flow. (Citation: Engame Process Injection July 2017) (Citation: HighTech Bridge Inline Hooking Sept 2011) (Citation: MWRInfoSecurity Dynamic Hooking 2015)\n\nSimilar to Process Injection, adversaries may use hooking to load and execute malicious code within the context of another process, masking the execution while also allowing access to the process's memory and possibly elevated privileges. Installing hooking mechanisms may also provide Persistence via continuous invocation when the functions are called through normal use.\n\nMalicious hooking mechanisms may also capture API calls that include parameters that reveal user authentication credentials for Credential Access. (Citation: Microsoft TrojanSpy:Win32/Ursnif.gen!I Sept 2017)\n\nHooking is commonly utilized by Rootkits to conceal files,\nprocesses, Registry keys, and other objects in order to hide malware and associated behaviors. (Citation: Symantec Windows Rootkits)\n\nDetection: Monitor for calls to the SetWindowsHookEx and SetWinEventHook functions, which install a hook procedure. (Citation: Microsoft Hook Overview) (Citation: Volatility Detecting Hooks Sept 2012) Also consider analyzing hook chains (which hold pointers to hook procedures for each type of hook) using tools (Citation: Volatility Detecting Hooks Sept 2012) (Citation: PreKageo Winhook Jul 2011) (Citation: Jay GetHooks Sept 2011) or by programmatically examining internal kernel structures. (Citation: Zairon Hooking Dec 2006) (Citation: EyeofRa Detecting Hooking June 2017)\n\nRootkits detectors (Citation: GMER Rootkits) can also be used to monitor for various flavors of hooking activity.\n\nVerify integrity of live processes by comparing code in memory to that of corresponding static binaries, specifically checking for jumps and other instructions that redirect code flow. Also consider taking snapshots of newly started processes (Citation: Microsoft Process Snapshot) to compare the in-memory IAT to the real addresses of the referenced functions. (Citation: StackExchange Hooks Jul 2012) (Citation: Adlice Software IAT Hooks Oct 2014)\n\nAnalyze process behavior to determine if a process is performing actions it usually does not, such as opening network connections, reading files, or other suspicious actions that could relate to post-compromise behavior.\n\nPlatforms: Windows\n\nData Sources: API monitoring, Binary file metadata, DLL monitoring, Loaded DLLs, Process Monitoring, Windows event logs\n\nPermissions Required: Administrator, SYSTEM",
|
|
"kill_chain_phases": [
|
|
{
|
|
"kill_chain_name": "mitre-attack",
|
|
"phase_name": "credential-access"
|
|
},
|
|
{
|
|
"kill_chain_name": "mitre-attack",
|
|
"phase_name": "persistence"
|
|
},
|
|
{
|
|
"kill_chain_name": "mitre-attack",
|
|
"phase_name": "privilege-escalation"
|
|
}
|
|
],
|
|
"external_references": [
|
|
{
|
|
"source_name": "mitre-attack",
|
|
"url": "https://attack.mitre.org/wiki/Technique/T1179",
|
|
"external_id": "T1179"
|
|
},
|
|
{
|
|
"source_name": "Microsoft Hook Overview",
|
|
"description": "Microsoft. (n.d.). Hooks Overview. Retrieved December 12, 2017.",
|
|
"url": "https://msdn.microsoft.com/library/windows/desktop/ms644959.aspx"
|
|
},
|
|
{
|
|
"source_name": "Engame Process Injection July 2017",
|
|
"description": "Hosseini, A. (2017, July 18). Ten Process Injection Techniques: A Technical Survey Of Common And Trending Process Injection Techniques. Retrieved December 7, 2017.",
|
|
"url": "https://www.endgame.com/blog/technical-blog/ten-process-injection-techniques-technical-survey-common-and-trending-process"
|
|
},
|
|
{
|
|
"source_name": "Adlice Software IAT Hooks Oct 2014",
|
|
"description": "Tigzy. (2014, October 15). Userland Rootkits: Part 1, IAT hooks. Retrieved December 12, 2017.",
|
|
"url": "https://www.adlice.com/userland-rootkits-part-1-iat-hooks/"
|
|
},
|
|
{
|
|
"source_name": "MWRInfoSecurity Dynamic Hooking 2015",
|
|
"description": "Hillman, M. (2015, August 8). Dynamic Hooking Techniques: User Mode. Retrieved December 20, 2017.",
|
|
"url": "https://www.mwrinfosecurity.com/our-thinking/dynamic-hooking-techniques-user-mode/"
|
|
},
|
|
{
|
|
"source_name": "HighTech Bridge Inline Hooking Sept 2011",
|
|
"description": "Mariani, B. (2011, September 6). Inline Hooking in Windows. Retrieved December 12, 2017.",
|
|
"url": "https://www.exploit-db.com/docs/17802.pdf"
|
|
},
|
|
{
|
|
"source_name": "Microsoft TrojanSpy:Win32/Ursnif.gen!I Sept 2017",
|
|
"description": "Microsoft. (2017, September 15). TrojanSpy:Win32/Ursnif.gen!I. Retrieved December 18, 2017."
|
|
},
|
|
{
|
|
"source_name": "Symantec Windows Rootkits",
|
|
"description": "Symantec. (n.d.). Windows Rootkit Overview. Retrieved December 21, 2017.",
|
|
"url": "https://www.symantec.com/avcenter/reference/windows.rootkit.overview.pdf"
|
|
},
|
|
{
|
|
"source_name": "Volatility Detecting Hooks Sept 2012",
|
|
"description": "Volatility Labs. (2012, September 24). MoVP 3.1 Detecting Malware Hooks in the Windows GUI Subsystem. Retrieved December 12, 2017.",
|
|
"url": "https://volatility-labs.blogspot.com/2012/09/movp-31-detecting-malware-hooks-in.html"
|
|
},
|
|
{
|
|
"source_name": "PreKageo Winhook Jul 2011",
|
|
"description": "Prekas, G. (2011, July 11). Winhook. Retrieved December 12, 2017.",
|
|
"url": "https://github.com/prekageo/winhook"
|
|
},
|
|
{
|
|
"source_name": "Jay GetHooks Sept 2011",
|
|
"description": "Satiro, J. (2011, September 14). GetHooks. Retrieved December 12, 2017.",
|
|
"url": "https://github.com/jay/gethooks"
|
|
},
|
|
{
|
|
"source_name": "Zairon Hooking Dec 2006",
|
|
"description": "Felici, M. (2006, December 6). Any application-defined hook procedure on my machine?. Retrieved December 12, 2017.",
|
|
"url": "https://zairon.wordpress.com/2006/12/06/any-application-defined-hook-procedure-on-my-machine/"
|
|
},
|
|
{
|
|
"source_name": "EyeofRa Detecting Hooking June 2017",
|
|
"description": "Eye of Ra. (2017, June 27). Windows Keylogger Part 2: Defense against user-land. Retrieved December 12, 2017.",
|
|
"url": "https://eyeofrablog.wordpress.com/2017/06/27/windows-keylogger-part-2-defense-against-user-land/"
|
|
},
|
|
{
|
|
"source_name": "GMER Rootkits",
|
|
"description": "GMER. (n.d.). GMER. Retrieved December 12, 2017.",
|
|
"url": "http://www.gmer.net/"
|
|
},
|
|
{
|
|
"source_name": "Microsoft Process Snapshot",
|
|
"description": "Microsoft. (n.d.). Taking a Snapshot and Viewing Processes. Retrieved December 12, 2017.",
|
|
"url": "https://msdn.microsoft.com/library/windows/desktop/ms686701.aspx"
|
|
},
|
|
{
|
|
"source_name": "StackExchange Hooks Jul 2012",
|
|
"description": "Stack Exchange - Security. (2012, July 31). What are the methods to find hooked functions and APIs?. Retrieved December 12, 2017.",
|
|
"url": "https://security.stackexchange.com/questions/17904/what-are-the-methods-to-find-hooked-functions-and-apis"
|
|
}
|
|
],
|
|
"object_marking_refs": [
|
|
"marking-definition--fa42a846-8d90-4e51-bc29-71d5b4802168"
|
|
],
|
|
"x_mitre_data_sources": [
|
|
"API monitoring",
|
|
"Binary file metadata",
|
|
"DLL monitoring",
|
|
"Loaded DLLs",
|
|
"Process Monitoring",
|
|
"Windows event logs"
|
|
],
|
|
"x_mitre_permissions_required": [
|
|
"Administrator",
|
|
"SYSTEM"
|
|
],
|
|
"x_mitre_platforms": [
|
|
"Windows"
|
|
]
|
|
}
|
|
]
|
|
} |