Last active
September 22, 2025 02:08
-
-
Save MagusXL/f48a5c6310c9d0dfb9d3dbdf471cec5a to your computer and use it in GitHub Desktop.
A stealthy powershell script to keep PC awake and hide window
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 characters
| Start-Process powershell -WindowStyle Hidden -ArgumentList '-Command "$wshell = New-Object -ComObject wscript.shell; $end = (Get-Date).Date.AddHours(18).AddMinutes(15).AddMinutes((Get-Random -Minimum -5 -Maximum 5)); while((Get-Date) -lt $end){$wshell.SendKeys(''{SCROLLLOCK}'' ); Start-Sleep -Milliseconds (Get-Random -Minimum 103 -Maximum 153); $wshell.SendKeys(''{SCROLLLOCK}''); Start-Sleep -Seconds (Get-Random -Minimum 33 -Maximum 183)}"'; exit |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I present to you the ultimate oneliner, StealthCoffee:
Repo to open in incognito and copy the oneliner from: StealthCoffee
Here is the snippet also, you can just copy paste it in a Powershell terminal:
Start-Process powershell -WindowStyle Hidden -ArgumentList '-Command "$wshell = New-Object -ComObject wscript.shell; $end = (Get-Date).Date.AddHours(18).AddMinutes(15).AddMinutes((Get-Random -Minimum -5 -Maximum 5)); while((Get-Date) -lt $end){$wshell.SendKeys(''{SCROLLLOCK}'' ); Start-Sleep -Milliseconds (Get-Random -Minimum 103 -Maximum 153); $wshell.SendKeys(''{SCROLLLOCK}''); Start-Sleep -Seconds (Get-Random -Minimum 33 -Maximum 183)}"'; exitProTip: Don't save it as a file locally. I don't have this script anywhere on my local machine to avoid any detection, i just open an incognito window in chrome, navigate to the public repo i listed above and just copy paste the raw text from the file in a Powershell terminal.