Searching For Backdoors From Rogue IT Staff
WHiTe VaMPiRe writes "When IT staff are terminated under duress, there is often justification for a complete infrastructure audit to reduce future risk to a company. Here is an exploration of the steps necessary to maintain security." Of course the first piece of advice is to basically assume you've been rooted. Ouch.
to audit your system under the assumption you've been rooted should happen once a year at a minimum anyway, not just when you suspect a rogue employee left on bad terms. I've worked at places that never changed passwords and I found former employee logins enabled from months ago..
Fuck Ajit Pai
Dead man's switch.
If you're seriously considering this as a possibility, I'd say treat it like a DR drill. Burn everything down to bare metal and restore only the data. It's the only way to be sure...
However, before taking my advice, I'd suggest you get your boss to sign off on it, whichever way. Present a list of options from 'ignore it' to 'burn everything' and have them pick. This way, whatever happens, you're covered.
One of many reasons CEOs are given golden parachutes are to keep them quiet about trade secrets and certain contacts. Whether or not that happens is debatable, but discretion is basically paid for.
Why not give similar parachutes to IT admins to follow these unwritten practices? If the CEOs are the frontmens, ITs are the infrastructure of the organization. Treat them like gatekeepers instead of disposable footmen. They have the keys to the castle. And all the secret entrances.
I usually put in multiple backdoors. Not out of malicious intent but because I support customers who are so far away that I don't want to drive out there all the time. Now this might include software or even out of band management, VPN, etc. Basically, if you put yourself in a position where you have to fire your IT staff then you are a moron. Always do background checks because you are going to be giving these people the keys to the city.
Yeah, that will really solve the problem of time bombs and dead man's switches...
How about not disgruntling the employee in the first place?
Just make sure to CC your boss's boss when you do this.
THEN your ass is covered!
Prison sentence.
Seriously trying to do something like install a dead man switch to fuck over your employer would be the height of stupidity. Wonderful way to end up with a sentence that make the Child's thing look lenient. While I realize that pedantic geeks think they could cover their tracks that isn't the case. They don't have to prove it was you beyond any and all doubt, they just have to prove it was you beyond a reasonable doubt. If they can show means, motive, and opportunity, they've gone a long way to that.
Sounds like the real answer if for companies to get rid of egomaniac assholes in IT before they are in a position to cause trouble.
The worst timed logic bomb I have had to deal with was by an intern who was looking for more pay. He had written a statistical analysis program that would have started to introduce subtle errors several weeks after he had left. If I had not found it then our stats would have become useless after a few months of that mangling. I assume he was hoping we would notice data errors, panic and re-hire him to fix it without realizing that he had caused the errors. I became suspicious when the timestamp on the Java source was newer than the class file so I did some reverse engineering. He had edited the logic bomb out of the source after compiling.
I had to administer a system when the vendor's software would fail on the rollover for the day. So it would fail at 5 am, and I would have to be the one to come in to fix it. As it happens at least once every two weeks I started to SSH in to fix it rather than rush to work and have to work an extra three hours that day (and not be compensated for it). The policy that I fought to implement at work was to do a quick audit, change any passwords/keys for any remote entry and to actually create passwords for many of the accounts that did not have passwords. So done and done I thought.
To continue: I had many problems with upper management, one of which was their wanting me to 'tweak' time sheet accounting so that new entry level minimum wage employees were paid for as little as 75% of their legitimate hours worked. I thought this was particularly dickish as they fired employees on a project basis and anyone was usually fired within two weeks. So I quit and tried to get myself as good as a parachute as I could.
Well two weeks after I left I found out the newbie replacement didn't perform the audit when I accidentally clicked on a bookmark at home (Putty) and I was suddenly in a server from my old job. I logged out and didn't feel particularly compelled to tell them that my keys were still trusted. About a month later I made the same mistake. The hole was no longer there. I thought to myself, "Good for him. I guess he's not so incompetent at all."
But curiousity a la Facebook and Twitter revealed that a server had actually gone down that day. Apparently there was a 'rm -rf' oopsy!!!
The story continues, but the end result is that he managed to destroy three servers within a month of my leaving. If I had been malicious I don't think I could have caused that much destruction...
for those that are terminated and have no intention of connecting back in ? After all, if I am let go, the last thing I want is for my old credentials to be used by someone to trash something and have suspicion fall on me.
Nullius in verba
As an (ex-)employee, it would be to your advantage to maintain good relations with your previous employer anyway, unless you don't plan on ever using them as a reference.
Relatively current events counterexample A: Terry Childs
He may have bucked the chain of command, but if his employer had sat him down, said, "look, Terry, we think you'd be better off somewhere else - we're going to keep you on until you find a better opportunity, and we're going to help you do that," he would have probably said, "yeah, but you have nobody else here who can handle this thing. You're going to need to hire a firm to manage this or get some better talent on staff," which seemed to be his motivating concern. And so they probably would have done that, and nobody would have gone to jail.
Instead it seemed like a "give us the passwords and um, no you don't need to clean out your desk, why?" kind of scenario. I'm not meaning to absolve Childs of incorrect behavior, but a little Golden Rule would have gone a long way there. I think this is what the GP meant by not disgruntling the employees.
My God, it's Full of Source!
OUTSIDE_IP=$(dig +short my.ip @outsideip.net)
You get what you pay for. You hire for the lowest possible salary and treat your professionals like unskilled laborers, well, don't be surprised. A professional would never dream of doing something like this - but then again a professional would not work for peanuts either.
Seven puppies were harmed during the making of this post.
How about a radical idea of treating employees as people, with respect and dignity, and they will treat you likewise in return? I know I'm stepping a little above the topic, as you asked what to do when you do fire people suddenly without a cause. Please bear with me and don't "escort me out" yet. The way employees are treated in the U.S nowadays is despicable. It would be unacceptable just a few decades ago in this very country, and it is still unacceptable in many parts of the world. An executive firing employees without good cause would and should be roughed up good after work to freshen their understanding of "immoral". American society should make it socially unacceptable, with after-work consequences, to fire people without a good cause, regardless of "laws' bought by corporations in the last decades.
Nastiness is usually a sign of guilt: "It is human nature to hate those we have wronged [sic]" Tacitus.
If the corp is nasty, it will attract further nasties and have to cope with the results. The nice people leave.
If a nice corp has to fire someone for gross malfeasance and such yet cannot charge them, then perhaps send in a trusted senior specialist to check things out quietly. A big investigative purge will just tell everyone there you don't trust them. Then why should they trust you? Thieves have the best locks. Lots of moves in this chessgame.
Yeah, that will really solve the problem of time bombs and dead man's switches...
How about not disgruntling the employee in the first place?
Oh, grow the hell up and welcome the nature of life.
Though there are work places that indeed are festering, pedantic shit holes, my experience has been that people who are disgruntled enough to commit a stupidity don't necessarily work in a place causing them to be so disgruntled in the first place. They are simply stupid assholes who either have a sense of victim-hood or are too arrogant and socially incompetent so as to pop a vein at the slightest work-related discomfort.
Work is work, it's not supposed to be pleasant all the time. We get paid to do work that has a certain level of difficulty, both technological and sociological. It has always been so, it will always be so. Half of the time the fault of being disgruntled is in you. How you handle that shit is ultimately one's responsibility.
If you are a mature person with a sense of, oh I dunno, fucking professionalism, you will never get *that* disgruntled no matter the working conditions. If you are not a mature professional and you cannot tell professionalism from shit flinging monkey riding a banana-shaped tricycle, then you'll inevitably construe any slightest difficulty into an affront, building each one of this up, turning you into an arrogant, festering boil of disgruntled human suckage and social incompetence.
And for those who truly voted that post as insightful, man, grow up, really.
Most employers will only confirm the dates you worked for them now, for fear of lawsuits.
This is why companies need to have an IT-savvy IT manager and know their employees well, and have multiple IT workers watching each other, much like accountants and finance officers are supposed to watch each other and have separated powers.
Know your employees, their abilities, and their personality. Without knowing the person, it's difficult to assess the risk as to whether or not they might or might not do or attempt to do certain things. And what things are even possible for them to attempt.
The easiest way to avoid running around in circles is to know what they are capable of exactly. If their personality is psychopathic super-programmer, you might have good reason to look for hand-coded hidden kernel drivers, or little binary blobs in a proprietary tampered-with program, containing custom logic bombs, and exploits for bugs in other programs (automated privilege elevation and exploitation).
If not, well, more mundane audits should be fine.
If the person is familiar with scripting, then, well, you'll have to check all the scripts extra carefully. Even if not, they might have found something on the web, and it doesn't take rocket science to cron "rm -rf". Which should not be that much a concern if you have solid frequent backups and take additional precautions to secure those.
(Probably) the worst case scenario is they are conspiring with skilled outside hackers, who are providing expertise and assistance.
Once the outsiders have enough information, they may get the IT admin to "run some code" from somewhere obscure, which will lay the playing field, and then later the outsiders will infiltrate the network.
However, that implies premeditation. If an IT admin is going to forcibly lose their job for serious disciplinary reasons, and anything is suspected to be a risk, they should be escorted by security and not allowed to touch any computers until they are gone for good.
Make them stay on premise during working hours, and have them use pen and paper to fill out some paperwork and answer questions.
This way they will not have a lot of "free time" until all your new IT admins' audits and password changes are established.
I was CIO for a fairly large company. I reported to the CFO. The first few years were great. Then the good CFO retires and is replaced by the bad CFO. This guy was looking for excuses to get rid of me from day one. It took him several years, but eventually he fired me.
It seems he hired some type of security consultant to lock down the place just before I was fired. Some of my staff members were forced into cooperating with this little adventure. Evidently, the bad CFO thought I would launch some kind of high-tech retaliation. This was actually a fair prediction, based on how I was treated. If you treat people badly, you should EXPECT trouble.
While I am in the process of getting the bad news from HR, it occurs to me that I really want revenge. But a high tech attack would be illegal, unethical, and they're probably expecting it. Therefore I will NEVER attempt anything related to IT. I'm not sure exactly how to proceed, but I decide to wait and give it some thought. My staff members knew from day one that I would do something and whatever it was, it was going to be big. The funny part is that the company's security consultant did everything recommended in TFA and then some. And yet he STILL left a gaping hole that I helpfully reported to the company after the fact. So much for the security audit.
Good things come to those who wait. I stumbled across an idea that had nothing to do with IT. I REALLY REALLY want to write about what I did, but details of the operation must remain classified. Everything was 100% legal and ethical. The results were absolutely spectacular. I might turn this into a movie script someday. It was that good. The amount of pain I inflicted exceeds anything that I could have done with computers.
Three important lessons here: (1) Security audits are seldom 100% effective and a determined opponent is going to get in anyway. (2) A really determined foe is not limited to computers. (3) Treating people poorly leads to unintended consequences; see (1) and (2).
The assumption should be that you have been rooted by somebody who knows exactly what things are logged in your systems, possibly with continuous influence on what is being logged and how long, maybe even with the power to alter log files. IMHO one of the important things is to use several servers just for logs, to whom only a single admin has access. If one of them is going in a bad way, then you have at least the logs on the other machine. If you are paranoid, transfer the md5 checksums of the files on your servers to these machines and use git on the etc directory, backing the etc directories up on these machines. and force the it staff to make builds of custom SW automated.
This means you have
a) logs of what has happened (at least you know what you know)
b) a possibility to determine which files changed
c) a documentation about which configuration changes have been done for which purpose.
d) a backup of the configuration, enabling you to reinstall the machine
e) a way to rebuild programs added to the system easily.
"f you are a mature person with a sense of, oh I dunno, fucking professionalism, you will never get *that* disgruntled no matter the working conditions."
Oh please, and you're telling OTHER people to grow up? Sounds to me like you've hardly had any work experience in the real world. It doesn't matter how professional you are - everyone has certain buttons that can be pushed and in a long working career believe me , someone WILL push them eventually.
Also you might disguise your young age a bit better if you didn't swear every paragraph.