A new event id for the use of EncodedCommand parameter #17697
Replies: 2 comments 1 reply
-
Please no, I hate with great intensity when AVs block this. I want to be able to run a command without having to deal with dealing with quoting problems. Giving someone the option to block |
Beta Was this translation helpful? Give feedback.
-
I can definitely see the benefit of an event ID for when encoded commands are used even though they are used legitimately. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Currently, the use of encoded command is the same with any other invocation and logged with Event ID 4103. However, 90% of PowerShell users, sysadmins, devops people, and other do not utilize this feature very often. We see this specific use case mostly when an attacker tries to utilize PowerShell. Therefore, I suggest adding a check in the run, and log the event not with the Informational Level Event ID 4103 (
Pipeline_Detail = 0x1007
) but any other ID, like 4102 or 4107. Then, the definition of i.e.Pipeline_Encoded_Detail = 0x1006
orPipeline_Encoded_Detail = 0x100B
, with the same information, yet with a separate event ID and as Warning severity, would simplify security efforts to catch the use of encoded commands. Then, it would be up to the security staff to work on false positives, instead of trying to create dozens of rules to detect it.Even though we want to prevent malicious commands being executed, it is impossible to listen to the event log and interrupt the process. What we can do is only detection and detection requires effort, mostly with Regex. There are "over 100,000 variations" according to the analysis. Even then it is not enough, you need additional work. A separate event would help security community a lot.
While many admins asking if it is possible to disable running EncodedCommand altogether and it would be great if it would be possible to disable it via a GPO, improving detection is a giant leap.
Beta Was this translation helpful? Give feedback.
All reactions