Live data from Hacker News

Stacksort – Searches StackOverflow for sorting functions and runs them (2013)

gkoberger.github.io

71–80 of 86 posts

Re: Stacksort – Searches StackOverflow for sorting functions and runs them (2013)

#73

Doesn't seem to work. Tried with input ["z","b","a","c","d"] and returns the same ["z","b","a" "c","d"] as the output, using StackOverflow answer 4833835

For string sorts, i needed to keep running about 5 or 6 times until a sorted result was found.

Re: Stacksort – Searches StackOverflow for sorting functions and runs them (2013)

#74
post #50

Earlier quoted context omitted.

It's all fun and games until the next JavaScript sandbox busting zero day drops.

If I had that kind of exploit I surely wouldn't post it on stackoverflow.

Why not? They even have a tag for it

https://stackoverflow.com/questions/tagged/exploit

Re: Stacksort – Searches StackOverflow for sorting functions and runs them (2013)

#75
post #34
post #29

this reminds me of the 4chan's sleepsort: for each number $n in the array, spin a thread that sleeps $n and then append $n to the result array.

Adapted for JS: https://jsfiddle.net/dheu9q7f/

Even worse: https://jsfiddle.net/8ta2pfny/

Re: Stacksort – Searches StackOverflow for sorting functions and runs them (2013)

#76

Hey, creator here! I built this a few years ago on a whim, and am surprised how well it still works. Thanks for sharing again :) (Psst, if you're an engineer and like dev tools, I'm hiring! https://readme.io/careers )

You might want to update the warning:

Is it safe?

Uh… it evals both user input and random code, unchecked, from an external site. This is what the security-minded folks writing anti virus software would refer to as: hey, our unpacker does that too! In kernel mode if we're from symantec! Must be perfectly safe!

Yeah, cheap shot, I know ;-)

https://googleprojectzero.blogspot.com/2015/06/analysis-and-...

Re: Stacksort – Searches StackOverflow for sorting functions and runs them (2013)

#77
post #73

Doesn't seem to work. Tried with input ["z","b","a","c","d"] and returns the same ["z","b","a" "c","d"] as the output, using StackOverflow answer 4833835

For string sorts, i needed to keep running about 5 or 6 times until a sorted result was found.

Ah you're absolutely right, didn't see the "Didn't work? Try the next answer" button

Re: Stacksort – Searches StackOverflow for sorting functions and runs them (2013)

#80
post #50

Earlier quoted context omitted.

If I had that kind of exploit I surely wouldn't post it on stackoverflow.

Why not? They even have a tag for it https://stackoverflow.com/questions/tagged/exploit

Maybe someone should create a site like this that runs all security exploits on SO in your browser.
Post reply on HN