As I sit watching one of my latest dirty dirty hacks run, I started wondering what kind of dirty hacks you have created that are so bad they are awesome.

We all have a few of them in our past - and they are probably still running in production somewhere, chugging along somehow still working.

Which reminds me of the hack we had to put into place when we were moving data centers. Our IVRs had to keep running, as the data center we were moving from was the primary DC, and the new Primary wasn't quite ready to take traffic. So what do we do. Well we answer the calls in DC1, then ship the sip stream over the internet to DC2 1900 miles away ... that just felt oh so wrong.

So the question is, what is one (or more) of your awesomely bad hacks?

link|improve this question
And what you did worked ? were the calls successful ? no problems like jitter or anything ? – Marcel Apr 2 '10 at 19:52
@Marcel: Oh yes surprisingly well, of course we had a fractional DS3 on one end and a full DS3 on the other ... At least there wasn't enough jitter for our monitoring solution to pickup up on. No dropped calls either. – Zypher Apr 2 '10 at 20:00
Fantastic really ... it's things like these that make the job worthwhile – Marcel Apr 2 '10 at 20:48
feedback

15 Answers

A company I worked at a quite a few years ago had restricted network access on all our computers. You could access 1 terminal server, and any page on 1 domain (the intranet). That was it. This was well before I started my work in IT and I was considered lower than low by the IT department.

This, infact, made it impossible for us to do our jobs and after months of complaining to management (I love beaurocracy) they finally gave us ONE computer with unrestricted access, that all 12 of us had to share on the "rare occasion" we needed to go off-domain (which was almost all the time).

So, I brought in a spare 24-port switch, plugged the network cable from that machine into the switch and then bought dozens of dual-port NICs, and silently cabled everyones machines onto the 2nd switch and set up custom routes on each machine so that people could still access the segregated network. I then hid all the cables and the switches so nobody would find out.

I was everyones hero for 6 months, they could finally have internet access just as long as the boss wasn't looking.

Of course, as this is Server Fault everyone will be looking at this post, HORRIFIED that I could do such a thing. Well, if it makes you feel any better when they found out I was promptly fired, but I think that's when I decided to go to Uni and get a better education so that I could be in a position to ensure that other people don't have to go through that.

(And if I found that anyone had done this on any of my networks, I would strongly be pushing for an official reprimand. Hey, I was young).

link|improve this answer
Awesome. Nice to see that you've crossed over from the dark side. I had a tech support guy (who came from a job where he was running canned security scripts) tell me his first week on the job that he was going to audit my network. I told him that that would probably be the last thing he ever did at our company. ;) – joeqwerty Jan 8 '10 at 2:52
Of course, these days, things like Cisco Smart Ports configuration would have stopped this nefarious activity dead in its tracks ;) – ceretullis Jan 8 '10 at 3:01
Crossed over from the dark side or to it? I'm still not sure. – John Gardeniers Jan 8 '10 at 4:12
3  
cough This happened when I worked at Cisco cough – Mark Henderson Jan 8 '10 at 4:17
1  
Your story does remind me of a time when a Supervisor got fed up with not having enough ports in the training room and bought a cheap linksys switch ... triggered a spanning tree loop at the corporate offices ... that was a fun call when the director of networking finally picked up the phone. – Zypher Jan 8 '10 at 4:34
show 2 more comments
feedback

Probably not the kind of thing you're looking for but back a little bit I had a couple of Commodore 264 series machines. Specifically the Plus/4 and C16. Needing an assembler but being unable to find one for those machines I set about to create one. How do you compile an assembler when you don't already have one? Write a simple one in BASIC first, then translate it line by line into assembly once it's working and compile it with itself.

link|improve this answer
feedback

I sold dozens of HP ProLiant ML370 G3 servers between 2003 and 2005. The failure mode of this hardware was quite interesting, as the fan sensors on the system board would eventually fail after 5 years. The system wouldn't detect fan presence or spin/speed status at POST, so one would need a shop-vac (vacuum) to force the system fans to spin at a high enough rate during boot in order to keep the server on past POST. After that, cooling was achieved with an external fan... Availability of replacement boards from HP was poor and there was a shortage among parts resellers, too.

The setup had to hold for 5 days while I tried to make arrangements to fly to the customer site 2000 miles away with new hardware during the December holiday season. We made it, though!

alt text

link|improve this answer
feedback

I remember putting together a hack to get a printer working through an AS400\JDE implementation over a dial up VPN connection. My memory is a little fuzzy but it went something like this:

To print from JDEdwards, a Windows printer needs to be mapped to an AS400 printer object, which then needs to be mapped to a JDEdwards printer object. Normally this works quite well when you have a central print server and dedicated point-to-point WAN links for remote sites that need to print from JDE.

In this case one of our WAN links went down, which of course meant that print jobs from the central print server could not be sent to the remote network printers at the affected remote warehouse. The remote warehouse had to print packing slips from JDE to get shipments out the door so I created a dialup VPN connection on a warehouse computer that had a locally attached printer, then I shared the locally attached printer, then I configured the VPN client to use a specific ip address instead of using the VPN assigned ip address, then I mapped the locally attached printer to the print server via the static VPN ip address, then I mapped this printer to the AS400 printer object, then I mapped the AS400 printer object to the JDE printer object and voila, packing slips being printed in the remote warehouse.

link|improve this answer
1  
Woah... That definitely qualifies as a "hack"! – Rob Golding Jan 10 '10 at 14:26
feedback

I'd say one of the more ridiculous ones I've been involved in was a physical hack.

A customer's server had blown its power supply, actually the second one as there were redundant power supplies and the first one was already gone.

This was an old chassis from one of the "build your own server" brands and the replacement power supply was going to be several hundred dollars to replace.

They weren't willing to pay that for the power supply nor consider replacing the machine.

And, of course they got "insight" from somebody else that you can buy power supplies for like $50 at the store, no big deal.

So...we ended up with a standard power supply with long enough wires to be on the outside of the chassis, reaching inside to plug into the board and devices. Then taped and zip tied the power supply to the back.

And worst thing is, even though we told them don't leave it this way, it is time to start budgeting to replace the machine, I believe it is still in operation this way a good year later.

link|improve this answer
That's a thing of beauty to me. Sick, but beautiful... Anything involving zip ties tugs at my heartstrings and reminds me of my early days as a PC tech. – Evan Anderson Jan 8 '10 at 13:26
2  
Not as bad as the time I arrived into a company to find two servers running side by side, the power supply from one powering the hard disks in both. – kaerast Apr 2 '10 at 21:53
feedback

Parsers written in Awk, have done this many times, a friend even wrote a (simple) working C compiler in Awk.

I've another friend that wrote a Freenet client (including the networking bits) in Bash.

link|improve this answer
That's why I started disliking Debian - it prevents you from having fun with bash and its /dev/tcp. – grawity Jan 8 '10 at 12:45
I presume that it used to work in Debian, as it's what my friend ran when he built it. – LapTop006 Jan 8 '10 at 13:14
feedback

Proprietary flat-file database engine written in Perl for a bunch of CGI apps I had back in the day. Holy crap......

link|improve this answer
Hey! I did something like that too. – kbyrd Apr 2 '10 at 21:04
feedback

A long time ago I was working for a "telecom" company and we were using prepaid GSM cards to connect calls coming through VOIP from other countries having as destination local telecom operators (the advantage is obvious, selling US->Columbia for 10 cents a minute and it was only costing us 1 cent per minute (Columbia GSM->Columbia GSM).

US initiates call-> VOIP(free) -> Columbia GSW Gateway filled with Columbian Prepaid Cards -> Actual Columbian Number dialed by US.

The problem was we had to activate the special promotions on the Prepaid cards to get that 1 cent per minute bonus by placing the prepaid card in a phone, dialing that special IVR, going through the menu and selecting/activating the correct "tariff plan"
Initially we had a few dozen gorgeous naked women doing that for the company (lie) but at one point it become clear that this is not enough since there had to be like a few thousand cards activated per week so the management thought that since the IT department has a lot of spare time we should help the girls out and as you can imagine we immediately started thinking of ways to automate the cards activation process. (manually inserting SIMs in phones and performing the activation steps was a bit boring :) )
So this is what we did:
- placed the "need to be activated" cards in the VOIP-GSM gateways and using fabulous Asterisk running on a linux machine we started dialing the IVR which allowed to choose the "tariff plan" for all the cards one by one, sending DTMF to go through the menus and of course waiting a few seconds in between requests. This worked out pretty well for a while.

Good idea so far don't you think ? :) but the problem was, and here comes the hack, we were activating the cards on the same GSM cells (antenna site) each time and the local telecom operator, from which we were "stealing" international calling revenue and didn't exactly support our cause :), was able to notice the high spikes in activation procedures on some of their GSM cells and disabled the prepaid cards before we got the chance to use them.
This was our response:
- hook up one VOIP-GSM gateway to a wireless internet connection modem, put the modem with the GSM Gateway in a car :), start driving through the city and activate the prepaid cards using the same asterisk server (connected through VPN with the wireless modem) only now the the difference is the cards get activated on different GSM cells because obviously the car is moving :)
Unfortunately management had to fire the 12 gorgeous naked women but we were making so much money that (We) the IT department hired them again and payed them out of our own pockets (again this is a lie but dreaming is nice).

I Loved my JOB :) ! The advantages of working in a 3rd world country ! (I kid Columbia, I guess politically correct would be "emerging economy")

PS: I hope you realize that I am not really talking about Columbia :)

link|improve this answer
feedback

It's sort-of a hardware hack, and luckily not really a permanent solution.

One hot summer day my pager goes off with temperatures increasing rapidly in our data center, "not again!". Something is funky with our roof mounted coolers, and it's again time to summon the folks that actually know about this stuff. Unfortunately, it's in the middle of summer with people either on vacation or off BBQing somewhere, so actually getting someone to come look at would take a couple of hours. Which with the current trend on increasing temperatures in the datacenter this is time I don't have. Nor did I particularly fancing spending the rest of the warm summer evening bringing bringing a couple of thousand servers down and up again, and apologizing to our production guys about their compute-jobs having been stopped.

It's not all bad, as it's still functioning but it appears some of the logic is making some bad decisions, as it's only running 2-4 out of 8 compressors concurrently. So, a few phone calls and some scrounging later: Electrical tape and small rocks to the rescue.

There I fixed it!

link|improve this answer
feedback

When I was programming in Oracle PL/SQL, we had a "listener" program to generate report output on the server, based on a client query.

It was an frankenstein lash-up of assorted sql scripts, a 1000 line C shell script, unix pipe objects and a cron job. The cron job would run the c script every 5 seconds or so, which would run a SQL script, to poll a table for entries, which would pass the value to stdout. The script would then run the program based on the details and paramters inserted into the table.

The whole thing was insanely complex and had been initially written back in the early 80's.

Eventually we got a customer who wanted to run our app on NT instead of unix, so we managed to get it working in a commerical variant of cygwin (rather than reingineer the whole mess.)

link|improve this answer
feedback

Last week, or perhaps it was last month... I wrote a pair of applications (helpfully named f5 and f11) which use X libraries to emulate keyboard keypresses... to refresh and fullscreen a browser window on a computer in our office which was running a status board page.

I also wrote a python app to continuously jiggle the mouse pointer at location 1441x901 (just out of sight), but only to run during office hours, so the rest of the time, it can run the screensaver.

I think these are pretty dirty hacks. Not my worst, but pretty grim :P

link|improve this answer
Interesting. Wouldn't it have been easiert to, say, disable the screensaver? Also, at least for Firefox there are various extensions to make it start in fullscreen mode, and refreshes can be triggered server-side. Still, a nifty hack :-). – sleske Aug 27 '10 at 8:19
We tried that.. It didn't seem to disable the monitor-blanking-thingy. – Tom O'Connor Aug 27 '10 at 9:34
feedback

I wrote a bash script which displayed a numbered menu and asked the user to type the menu number. It used $( read -n 1 ) to pull single keystrokes, and process them individually - including backspace, which I pulled from $( stty -a ).

There were special cases to handle multi-digit answers, e.g. if there were 9 options, it would interpret 1-9 as each menu option, but if there were 11 options, after receiving a 1, it would wait to see if it became 10 or 11, or [return] for 1.

I did all of this without any curses calls (just lots of spoken curses).

2 days later I learned about $( select )

link|improve this answer
tput might have been also useful – Marcel Apr 2 '10 at 23:54
feedback

My worst was probably a network hack. This was back around 2000 or 2001. I was at an ISP that provided fixed wireless Internet access. The wireless gear we used was fairly primitive in terms of routing capabilities. The client radio was basically just a wireless-to-Ethernet bridge, so customers needed their own router. Customers who wanted a public block needed a dual-Ethernet router that didn't force NAT (which most "broadband" routers did back then). This usually meant something like a Cisco 2514 or a 2611/2621, none of which were especially cheap back then.

Anyway, one customer's router died. They weren't in a position to go buy a new (or even used) Cisco, and we didn't have one on hand. What we did have were some old Ascend Pipeline 130 T1 routers. So, what the customer ended up with was...

wireless --/-- radio --- eth                eth ----- LAN
                       router1            router2
                          T1 --- x-over --- T1

Luckily, the wireless link ran at less than 1 Mbps, so the "T1" link between routers wasn't a bottleneck.

link|improve this answer
feedback

Not one of mine, but I once arrived into a company to see a horrendous Microsoft Access database with dozens of queries just to get a single value out of their MsSQL database it linked to. I spent a few hours optimising and reducing it to a single query then discovered why they had such a horrible set of queries - the final query I ended up building was too long for Microsoft Access to handle and they didn't know any other way of running it except to split it like this.

link|improve this answer
feedback

I worked as sysadmin in an office full of Windows NT 4.0 SP6 workstations. Literally everyone was trying to see what's the admin password when I was typing it on their computers. Finally I've got sick of it and started to use a floppy disk containing an exploit which launched a cmd.exe instance running with Administrator privileges without me having to type the admin password.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.