Files
sigma-rules/hunting/macos/docs/execution_unusual_library_load_via_python.md
T
Terrance DeJesus bbfc026c95 [New Hunt] New Hunting Queries for DPRK ByBit (#4644)
* new hunting queries for macOS DPRK

* added docker hunting queries
2025-04-23 16:41:23 -04:00

1.6 KiB

Unusual Library Load via Python


Metadata

  • Author: Elastic

  • Description: Detects when a library is loaded from a user's home directory by a Python process and the loaded file is not a typical shared object (.so) or dynamic library (.dylib). This may indicate side-loading of malicious or non-standard files in script-based execution environments.

  • UUID: d9b30b84-dc53-413c-a7e4-f42078b10048

  • Integration: endpoint

  • Language: [EQL]

  • Source File: Unusual Library Load via Python

Query

library where event.action == "load" and
  dll.path like "/Users/*" and
  process.name like~ "python*" and
  not dll.name : ("*.so", "*.dylib")

Notes

  • Loading libraries from /Users is rare and may suggest untrusted or attacker-deployed components.
  • This hunt helps uncover suspicious Python-driven library loads that bypass traditional extension-based detection.
  • Consider tuning to exclude known development or research environments that store legitimate libraries in home directories.

MITRE ATT&CK Techniques

References

License

  • Elastic License v2