Imports Registry Key From a File

 Original Source: [Sigma source]
Title: Imports Registry Key From a File
Status: test
Description:Detects the import of the specified file to the registry with regedit.exe.
References:
  -https://lolbas-project.github.io/lolbas/Binaries/Regedit/
  -https://gist.github.com/api0cradle/cdd2d0d0ec9abb686f0e89306e277b8f
Author: Oddvar Moe, Sander Wiebing, oscd.community
Date: 2020-10-07
modified:2024-03-13
Tags:
  • -'attack.persistence'
  • -'attack.defense-impairment'
  • -'attack.t1112'
Logsource:
  • category: process_creation
  • product: windows
Detection:
  selection_img:
Image|endswith:'\regedit.exe' OriginalFileName:'REGEDIT.EXE'   selection_cli:
    CommandLine|contains:
      -' /i '
      -' /s '
      -'.reg'

  filter_1:
    CommandLine|contains|windash:
      -' -e '
      -' -a '
      -' -c '

  filter_2:
    CommandLine|re: ':[^ \\]'
  condition:all of selection_* and not all of filter_*
Falsepositives:
  -Legitimate import of keys
  -Evernote
Level: medium