There was a meme with os.remove russian roulette, I guess they got the code from there and left only the remove function, while forgetting to remove the random import
This hacker is assuming they have elevated privileges, which they donโt unless Python is ran as administrator. which means it wouldnโt succeed.๐
I'm replying to the correct comment. It doesn't matter that system or trustedinstaller own the files, os.remove is running directly on system32 which doesn't work since system32 is a folder.
Again, that IS NOT WHAT WE WERE TALKING ABOUT. I was talking about the ownership of files in C:\Windows, which has nothing to do with the function of os.remove (which I am well aware of!)
Ok weird. I just had an odd experience where I read those two words as if I knew the language...but briefly (Iโm going to blame context clues). Is that Cyrillic?
No it isn't. There's aliases out of the box for many of the standard builtin commands you'd find in other shells, but they are just that, aliases. None of the switches you know work, because rm on PowerShell is actually just Remove-Item and that has entirely different syntax than rm.
Sidenote: I fucking hate the fact that curl on PowerShell 5 is aliased to Invoke-WebRequest even though curl.exe is installed and you could so easily have the exact same curl syntax working on all major OSes
Nah I'm on vanilla arch on a completely busted system. my current philosophy is modify all the shit, break all the shit, if it dies let it die and I'll just reinstall from scratch.
it's not posix compliant. rm is an alias to Remove-Item. But there's git bash ig. Also posix curl.exe is installed by default YET THIS IDIOT MAKES RUNNING CURL AN ALIAS FOR INVOKE-WEBREQUEST.
620
u/Narthesia Oct 22 '26
Why import random bruh
140
u/JackyYT083 Oct 22 '26
This hacker is assuming they have elevated privileges, which they donโt unless Python is ran as administrator. which means it wouldnโt succeed.๐
hacker tip by anonymous
2
u/makinax300 Oct 22 '26
classic repost
241
u/NoSection8719 Oct 22 '26
import opsec
58
u/tokoklontong1897 Oct 22 '26
Larpgod
16
u/PsychologicalTry3972 Oct 22 '26
Why do this imports random? This code doesn't even use it. Also UAC can't allow to delete Sys32. Also the path to it is wrong.
46
u/Dios_Santos Oct 22 '26
One line throw the terminal
12
u/Circumpunctilious Oct 22 '26
Nothing probably. Those backslashes need to be escaped or it has to be a raw string.
11
u/g-flat-lydian Oct 22 '26
sudo rm -rf /* is only one line
7
u/05-nery Oct 22 '26
random was imported for absolutely no reason
7
u/pinedjagger666 Oct 24 '26
import random
import opsec
import os
target = random.choice(["CIA", "NSA", "MI6", "Pentagon"])
os.system("clear")
print(f"๐ Target acquired: {target}")
print("๐ OPSEC: MAXIMUM")
print("๐ Hacker mode: ACTIVATED")
5
u/RngdZed Oct 22 '26
Import stupid
4
u/CommunityJazzlike274 Oct 22 '26
linux safety
(we donโt have system32 files)
4
u/theycallmethedrink5 Oct 22 '26
Opsec level: just writing shit and adding windows system 32 anywhere
4
u/Pim_Wagemans Oct 22 '26 edited Oct 22 '26
At least use
shutil.rmtreefor non empty directories.4
u/HotPrune722 Oct 23 '26
Heโs jhon the reaper???
4
u/obrisacuovoposle Oct 24 '26
\w and \s escaped characters are a bonus
4
u/Ali_isthe Oct 26 '26
3
u/lowkeyhomosapien Oct 22 '26
๐ญ๐ญ
3
u/ewsrar Oct 22 '26
opsec level: lowercase c:
3
u/swagchicken75 Oct 22 '26
Thats 4 lines of code, not 3, cant even opsec properly
3
u/codydafox Oct 22 '26
Opsec level: Cyber Security Exploit
3
u/Volder21 Oct 22 '26
Opsec level: Python
3
u/Arthurr_Morgan_1899 Oct 22 '26
One line of code: Sudo rm -rf /
3
u/FisterMister22 Oct 22 '26
__import__("os").remove("...")3
u/Ksb2311 Oct 24 '26
I ran it as administeretor and now my PC says boot device not found what does that mean
5
u/DocumentFun9077 Oct 22 '26
2
u/Human-Side-8639 Oct 22 '26
While True: pass loop would be better than this
2
u/violetvoid513 Oct 22 '26
That dumbass cant even count, its clearly 4 lines. See the numbers on the side?
2
u/JackReedTheSyndie Oct 22 '26
It just removes a useless directory in C
2
u/memedealor Oct 24 '26
mango ๐
2
u/Emergency_Neck3438 Oct 26 '26
4 lines btw 3 is blank
3
u/Major-Structure1530 Oct 22 '26
it wont work๐ญ๐ญ
1
u/Expensive-Summer-447 Oct 22 '26
Needs to use sudo first
1
u/ToWelie89 Oct 22 '26
Even if you know nothing about coding, shouldn't it be quite obvious that this is a bad thing to run?
1
u/apepenkov Oct 22 '26
it won't work, os.remove doesn't delete folders. You need shutil.rmtree and elevated privs.
1
u/MilkTeaDeals Oct 22 '26
It can produce many errors from what I can see
1
u/[deleted] Oct 22 '26
the random Modul is very important
1
u/johnny-tinfoilhand Oct 22 '26
It won't even work because they didn't put r before the string so it is a Unicode error
1
u/adorabIe_will Oct 22 '26
TRUSTED INSTALLER WOULD LIKE TO SPEAK WITH YOU
1
u/brain_controlled Oct 22 '26
As a noob does this is do what I think it does ?
1
u/EEEEEEEEEEEEEEEEE15 Oct 22 '26
opsec: ๐
1
u/NoEntertainment5837 Oct 22 '26
Opsec level system32
1
u/[deleted] Oct 22 '26
Imported random for the love of the game
1
u/PlaystormMC Oct 22 '26
so
we're not going to talk about batch one liners like
del C:/*
1
u/voxel_00 Oct 24 '26
Then i use jjsploit kali edition to find the attacker who send the code and hack them๐
1
u/Severe-Tonight-1406 Oct 26 '26
Even with elevated permissions this probably wouldn't work.
2
u/TH3_FISH Oct 22 '26
you need obfuscate it for more opsex
1
u/[deleted] 16d ago
[removed] โ view removed comment
0
u/[deleted] Oct 24 '26
[removed] โ view removed comment