powershell ISE

要powershell的腳本,可以把腳本一行一行復制粘貼到powershell的環境中執行(代碼少的話可以,代碼多就麻煩了,很不方便),微軟提供了一個可視化的調試工具powershell ISE

使用比VS都簡單,遺憾的是沒有查看臨時變量的專用窗口,要手動在藍框中輸入$變量名。

 

實際調試遇到一個問題:powershell執行策略:

使用管理員權限打開powershell,輸入Set-ExecutionPolicy bypass即可。

還不行就關閉Windows Defender殺毒軟件,步驟如下:

運行輸入gpedit.msc,打開組策略;按下圖操作繼續

 

關於powershell更多使用查看:

https://docs.microsoft.com/zh-cn/powershell/scripting/components/ise/how-to-debug-scripts-in-windows-powershell-ise?view=powershell-6

https://docs.microsoft.com/zh-cn/previous-versions/windows/powershell-scripting/hh847748(v=wps.640)

最後放上一個惡意的powershell腳本

下載地址:https://download.csdn.net/download/singleyellow/11847623

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章