T1042 Default File Association Persistence - CraigDonkin/Infrastructure GitHub Wiki

T1042: Default File Association Persistence

Change the command associated with opening a file, for example when you load a .html file, to execute arbitrary command.

With User Perms

With Admin Perms

  • Global handlers are defined in HKEY_CLASSES_ROOT.[extension]
  • HKEY_CLASSES_ROOT[handler]\shell[action]\command
  • If there is no local extension then the global one is executed
    • Read extension handlers defined globally
    • Rewrite them locally
    • Hijack

Useful Link

https://hshrzd.wordpress.com/2017/05/25/hijacking-extensions-handlers-as-a-malware-persistence-method/

⚠️ **GitHub.com Fallback** ⚠️