In a consumer app, I would say Snapchat's early camera hack on Android takes the cake. To be brief, their app ran the Android native camera app in the background and took a screenshot of the resulting feed for the image, bypassing actual integration with Android's camera apps. Having worked on an Android smartphone from the ground up, I can understand their reluctance to commit dev time to having to support so many A…
Ask HN: Weirdest hack that you ever saw in production?
91–100 of 289 posts
Re: Ask HN: Weirdest hack that you ever saw in production?
#92Using a Remote Access Object to proxy calls between 32-bit and 64-bit code. Instead of rewriting any of the original ASP code, the lead architect made a DLL that would provide .NET 2.0 functionality to the ASP code. This was in 2014. The DLL was 32-bit and predictably ran out of memory every 30 hours. We created a scheduled task to restart the service every 24 hours, what a band-aid.
Tons of asp (and asp.net) sites are restarted on a regular basis to prevent crashes. The source of most of these problems are never known.
Re: Ask HN: Weirdest hack that you ever saw in production?
#93Not an actual bug, but I found this a couple of days ago. And it seems like an elegant hack, allowing `/` in directory, files, etc. Typing `mkdir foo:bar` in my macOS's terminal leads to a directory, that Finder shows as `foo/bar`.
Re: Ask HN: Weirdest hack that you ever saw in production?
#94Re: Ask HN: Weirdest hack that you ever saw in production?
#95Re: Ask HN: Weirdest hack that you ever saw in production?
#96Re: Ask HN: Weirdest hack that you ever saw in production?
#97An external vendor delivered a new static marketing site written in PHP. Info sec team wouldn't let us install mod_php on the publicly facing servers and the vendor needed more time/money than the budget and timeline allowed to change it. A coworker stood up a local server and wrote a script to periodically crawl it and push changes out to the publicly facing apache servers. It might still be there for all I know.
Re: Ask HN: Weirdest hack that you ever saw in production?
#98Webhost circa 2002. Lots of carrots from Microsoft for us to go big on ASP.NET hosting. Fat boss made a deal which involved us rewriting our customer interface in ASP.NET from the existing ColdFusion morass. His eyes popping at our estimates of how long this would take, he came up with a solution: rename our *.cfm files to .aspx, and map IIS to pass .aspx files to the CF server. Job done.
Re: Ask HN: Weirdest hack that you ever saw in production?
#99Earlier quoted context omitted.
I've got one of those from "Only on WIndows" series. One of my colleagues uses WIndows and tends to remote in from home. Unfortunately when a cleaner cleans the office after hours she sometimes accidentally hits the CAPS key and he can't log in anymore remotely. His solution was to rip out the CAPS key and cover the hole with duct tape.
I do this, too. The first thing I do when I get a new keyboard is to remove the caps lock key. I never used it in my 20 years of PC usages and I don't get why it's still there. Back in my CounterStrike gaming days I would also remove the Windows key because it would crash the game when accidentally pressed.
Re: Ask HN: Weirdest hack that you ever saw in production?
#100For some reason, every so often (sporadically) I'd get a segfault inside the closed-source binary blob. To get things "working", in my wrapper, I captured the stack before calling the occasionally segfaulting function, and setup a segfault handler that would simply restore the stack to its state prior to the crash.
Unfortunately, after restoring the stack, a subsequent call to the closed-source function would hang. I did some preliminary reverse engineering of the binary blobs and found that it was segfaulting whilst having retained a mutex. So I did, ah... the obvious thing(?) and just grabbed the raw memory address of the mutex, and released it myself when a segfault was encountered.
Surprisingly this all "worked". In the end I had a TV that thought it was a 65" phone, lock screen and all. Umm, yay!
Here's the code:
https://gist.github.com/Benjamin-Dobell/bb13f6169aaa48625453...