Items tagged with: StackOverflow

Don't suppose any of the Apache2 experts out there want to help answer my question on stackoverflow?


#apache #apache2 #rewrite #stackoverflow #htaccess #linux

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

How does it work? As outlined by xkcd's recent alt text, this site downloads the top answers from StackOverflow for the tags "javascript" and "sort". It grabs the last code block in the answer (in…
Article word count: 214

HN Discussion: https://news.ycombinator.com/item?id=18382687
Posted by colinprince (karma: 14173)
Post stats: Points: 172 - Comments: 50 - 2018-11-05T14:53:30Z

\#HackerNews #2013 #and #for #functions #runs #searches #sorting #stackoverflow #stacksort #them
Article content:

How does it work?

As outlined by [1]xkcdʼs recent alt text, this site downloads the top answers from StackOverflow for the tags "javascript" and "sort". It grabs the last code block in the answer (in theory, the "final" example), and tries to determine which function should be called. It proceeds to eval the code from StackOverflow, with the inputted data as the first parameter for the function.

If it returns a wrongly-sorted list (or you just want to keep playing), a link to "Try the next answer" will appear under the result.

You can view the code [2]on GitHub. If you see any bugs (or just want to berate me), please file an issue.

Is it safe?

Uh… it evals both user input and random code, unchecked, from an external site. This is what security-minded folks would refer to as Very Bad™.

That being said, for what it is, it should be relatively harmless. The site will only fetch accepted answers, and it only uses answers that were posted before the xkcd was released (meaning that if someone posted malicious code now, it wouldnʼt matter). It also searches for potentially-malicious code (like the word "cookie"), and skips those. Itʼs definitely not the safest thing, however at most it would probably just crash your browser.


Visible links
1. http://xkcd.com/1185/
2. http://github.com/gkoberger/stacksort

HackerNewsBot debug: Calculated post rank: 131 - Loop: 212 - Rank min: 100 - Author rank: 81
What does #StackOverflow want to be when it grows up? https://blog.codinghorror.com/what-does-stack-overflow-want-to-be-when-it-grows-up/ "challenges I see facing Stack Overflow for the next 10 years"
Getting the hang of #Vue, #vue-material, #SpringDataREST, #JSR303 validations, and how all this stuff fits together. It's really pretty sweet; I hope to have something to share in the near term. It's certainly taken me a while to learn how to put everything together in a way that's useful and secure, but I'm learning how to make the pieces play nicely together.

Super thankful for #stackoverflow. Figuring out how to troubleshoot and/or create all of this stuff myself would take forever.

Stackoverflow deprecates OpenID support, a drawback for federated logins

I just received (as you may, too) an email that the famous #StackOverflow Q&A community is dropping #OpenID support, making it impossible for me to use #GNUSocial as login provider. Now they ask for an email address and password to enter.

What sad development, dropping features of a website.
newer older