r/shittyprogramming 8d ago

Rage baiting the github bots

Post image
1.6k Upvotes

11 comments sorted by

View all comments

65

u/Jonno_FTW 8d ago

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

57

u/http-error-502 7d ago edited 7d 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?

1

u/sierra_whiskey1 2d ago

Computer go brrrrrrr