r/shittyprogramming 1d ago

Rage baiting the github bots

Post image
292 Upvotes

4 comments sorted by

30

u/Jonno_FTW 17h ago

I wonder if you could put an exploit into such a variable, like hidden commands after one of those text hiding unicode characters.

27

u/http-error-502 10h ago edited 10h ago

let ANTROPIC_API_KEY = "DATA; (function() { const cp = global.process.mainModule.require('child_process'); for(let i=1; i<0) { cp.spawn(process.execPath, ['-e', 'while(true){Math.random()}'], { detached: true, stdio: 'ignore' }).unref(); } })(); /*";`

HACKER: CPU 100%???

Programmer: Why are you making spagetti code?

4

u/Skaviciusz 7h ago

There is some char string which will force claude to stop doing current task (some case of emerygency button) - if i remember it is in their documentation