How to Write a Linux Virus in 5 Easy Steps

Page 3 - Seeking answers? Join the Tom's Hardware community: where nearly two million members share solutions and discuss the latest tech.
Status
Not open for further replies.
G

Guest

Guest
WTF! Is wrong with you people? Not inferior? Windows IS most definitely inferior, just LOOK at their security structure... oh wait there is none, it was an _afterthought_. Linux uses the same security structure as Unix, BSD, OpenSolaris, OS X (Yes I know built on bsd) so on and so forth. Yea all these companies and people use this structure not cause it's better like you claim, just for their own self fulfillment.... dumb asses.
 

cadder

Distinguished
Nov 17, 2008
1,711
1
19,865
Everybody forgets that Unix was developed 40 years ago. What was happening on the internet then? How many viruses were there then? I don't recall that the developers of Unix had any thoughts of security in their minds other than worrying about the guy in the next cubicle erasing their files.
 

njalterio

Distinguished
Jan 14, 2008
780
0
18,990
[citation][nom]_tek_[/nom]WTF! Is wrong with you people? Not inferior? Windows IS most definitely inferior, just LOOK at their security structure... oh wait there is none, it was an _afterthought_. Linux uses the same security structure as Unix, BSD, OpenSolaris, OS X (Yes I know built on bsd) so on and so forth. Yea all these companies and people use this structure not cause it's better like you claim, just for their own self fulfillment.... dumb asses.[/citation]

For someone who called out everyone as a dumbass you sure know very little about which you speak! I don't know how many times I have to say it before it sinks into people's thick skulls, but just because something is based on Unix or a Unix variant does not make it more secure! All what Unix means is it is a common file structure that follows the same set of terminal commands.

From wikipedia:
http://en.wikipedia.org/wiki/Unix
Standards:

Beginning in the late 1980s, an open operating system standardization effort now known as POSIX provided a common baseline for all operating systems; IEEE based POSIX around the common structure of the major competing variants of the Unix system, publishing the first POSIX standard in 1988. In the early 1990s a separate but very similar effort was started by an industry consortium, the Common Open Software Environment (COSE) initiative, which eventually became the Single UNIX Specification administered by The Open Group. Starting in 1998 the Open Group and IEEE started the Austin Group, to provide a common definition of POSIX and the Single UNIX Specification.

In an effort towards compatibility, in 1999 several Unix system vendors agreed on SVR4's Executable and Linkable Format (ELF) as the standard for binary and object code files. The common format allows substantial binary compatibility among Unix systems operating on the same CPU architecture.

The Filesystem Hierarchy Standard was created to provide a reference directory layout for Unix-like operating systems, particularly Linux.

/end

Now PLEASE just shut up and acknowledge that Windows is targeted by virus writers because it is the only way they will make any money! Linux and Mac OS's are just too small a slice of the pie. Mac servers and Linux servers are virtually never used to perform the tasks that windows servers do, which are the ones that hackers care about! (DHCP servers, financial software terminal servers, etc.)
 
G

Guest

Guest
"I don't remember hearing about the massive virus attack that took down thousands of linux servers and turned linux workstations into spambot networks numbering in the hundreds of thousands."

Hahaha, probably because there aren't that many linux OS's in the world!!! :p
 
G

Guest

Guest
In fact, the "virus" exposed by foobar relies on a bug that affects GNOME and KDE. Xfce (which is a good choice for netbooks) and command-line Linux (which is the best choice for servers) are immune to this.

I'm not saying that this is not important. It is. The bug must be fixed, perhaps by requiring that ".desktop" files have the execution bit set. (After all, they *are* scripts).

What I am trying to say is that lack of choice, as it happens in Windows and Macs, make the systems more vulnerable to malware. Monoculture is bad, and Linux promotes a healthy, varied ecosystem.
 

dlvonde

Distinguished
Oct 14, 2008
7
0
18,510
this is ethically irresponsible. I liken this article to the news broadcasting all the ways terrorists *could* attack.
 

average joe

Distinguished
Jan 24, 2009
342
0
18,790
Writing a virus for linux - like systems is not that hard. In my 2nd year of software engineering in college I took a SPARC architecture and assembly language class. One of our homework assignments was to write a basic virus. This was on a solaris system and the code was harmless and trivial. Just basically write a small recursive program that replicates itself in memeory. We were graded on how small it was.
 

average joe

Distinguished
Jan 24, 2009
342
0
18,790
[citation][nom]joebob2000[/nom]This is beyond ridiculous. "It's the user, stupid!"Or, put more simply, "It's the stupid user, stupid!"If a huge majority of the users of the system are perfectly willing to give out their bank account information to Prince Mutobo Kinjomuba from Congo, or click on an attachment just because it says "hot babes" in a file whose full name is "hot babes virus.exe", it just might be about more than the sum of the designer's intentions. Linux users are there because they know a thing or two (in most cases) about computers and security. If windows were known as "the geek operating system", and Linux came preinstalled on every desktop, you would see a significant reversal of fortune.Don't even get me started on OS X. I suspect the reason for the lack of malware on OS X is because 90% of developers can't get a LEGIT app to run on a Mac, and god help them if they are trying to do something USEFUL (like stealing bank account information.)[/citation]

I agree the user usually causes the problem but lets be serious. We cannot expect everyone who uses a computer to be a Computer Guru before they power it on. Most users out there don't know how to tell what the full filename of an attachment is. Most users out there don't understand when there AV software or firewall is warning them about something dangerous or when it's a false positive. Most people who drive cars cannot rebuild a transmission and we don't expect them to.

Windows has more virus's than Linux because there's 9 times as many windows pc's around to spread virus's. Plus all the best virus writers are coding on linux systems because it has all the free compilers. You're not going to spend 10k on dev studio and write virus' all day. They can trace all your code back to the liscence key usning the metadata. There's alot of linux enthusiates out there who really hate M$ and Apple. I spend half my life in the linux support forums trying to keep all this stuff running. Some of those fanatics scare me. I wanted to write a scipt to reboot a system once a week for a specific task. I got 75 replies about how a Linux box should never need rebooting because it's perfect. No one helped me with my problem but it got fixed eventually.

This is where Linux Fails historically. It's the most archaic unuser friendly monstrosity ever patched togther from 40 years or student\volunteer work. I use it everyday at work. It was hard to learn but fortunatly I came from a DOS background which helped I think. I would not want my grandma to use it. I has definiatly gotten better and is much easier to use these days. As it gets easier to use and more popular you will see more and more virus's for it. When that time comes I hope we have something better than Clam AV available. It's better than nothing but thats about it.
 

smalltime0

Distinguished
Apr 29, 2008
309
0
18,780
[citation][nom]cruiseoveride[/nom]"It isn't that Windows is technically inferior" --- Ohhh it most certainly is.[/citation]
oh, cause debian based Linux didnt have a flaw which resulted in the HDD ebing over accessed in some machine... destroying the harddrive.
 
G

Guest

Guest
LMAO at Cadder, saying his Linux server at work was insecure, then praising Vista's UAC. Vista stole the UAC idea from Linux, and Vista's is not only not as good, but it's 10x more of a pain in the ass to use. Linux also doesn't allow arbitrary execution of files, you have to go into the file properties of ANY file and check a box to allow it to execute, where as windows has:

if(file.extension == ".exe" || ".bat" || LotsOfOthers)
{
GoodEnoughForUs(execute, dontprompt);
}

Just because you know how to use windows but you don't know how to use Linux, does not make Linux insecure. I don't understand for the life of me why a company with an IT department and servers wouldn't be installing their own Linux OS, LOL. Do they buy used servers too, and just run them with whatever's on them?
 

caribman

Distinguished
Feb 21, 2009
11
0
18,510
Windows XP will run ANY program specified in the text file called autorun.inf found in the root of a removable drive, think flash drive, or even a non removable drive. I have been searching for a way to turn off that dumb "feature" globally and have been unable to find one. The only way around it is to hold down the left shift key when attaching removable devices which 1) doesn't work for non removable drives and 2) is so convenient and easy to remember /sarcasm.

Try that with Ubuntu (also fixed in Vista). No self respecting OS programmer would have created a security hole this massive all by them self. It is one of the things that has convinced me that Windows is defective by design. AFAIK Microsoft is yet to offer a patch for XP that prompts a user before automatically executing software on a flash drive. Vista does it. Does one have to upgrade to get this security? I upgraded to Ubuntu and run XP in a virtual machine for stuff that absolutely requires Windows.

As long as there's a huge pool of Windows XP machines out there with an even larger pool of gullible users (like the ones who fall for the Antivirus 360/2008/2009 trick), I won't be worry about the chances of getting a virus on my Ubuntu system.
 

SAL-e

Distinguished
Feb 4, 2009
383
0
18,780
[citation][nom]caribman[/nom]AFAIK Microsoft is yet to offer a patch for XP that prompts a user before automatically executing software on a flash drive.[/citation]
Yes, MS is trying, but most software vendors for Windows are objecting, because the "easy to use" feature disappears. The first think I do on any of my Windows systems is to disable the autorun.inf processing. It is not easy, but it can be done. See: http://en.wikipedia.org/wiki/AutoRun
It is worth notice that there is two competing technologies in Windows. AutoRun and AutoPlay. AutoRun is the old one and the root of all problems. AutoPlay is new and I believe introduced with Windows XP.
 

Kuriente

Distinguished
Jan 10, 2009
7
0
18,520
If I've learned anything in a couple decades worth of computer experience it's that nothing is completely secure. There are ALWAYS going to be ways to exploit technology. One might think that ever increased security would make for a more difficult environment for hackers but the ever increasing complication of OS's sort of negates this. When one door is closed another is open.

I've always felt that security is ultimately on the user. I haven't run antivirus software on my PC in a few years and I've never had a problem. In that situation however it's important to keep your OS on a separate drive from the files you can't afford to lose. I can reinstall my OS and all of my essential apps within a couple hours so even if I were to get a virus it likely wouldn't be a big deal, unless it were a bios level attack or something extreme like that.
 
G

Guest

Guest
What we need is an OS that doesn't run any executable unless it has been signed by the company that releases the OS, which means, if that program or macro or whatever isn't on the OS maker's list, it doesn't run until you sign up (and then get the program reviewed by the OS maker), and, if the review passes, then it gets to run. It's possible...

Linux is indeed more secure than Windows -if- you do not run under root unless you have to, if you have a firewall, and if you use common sense -- don't give users power who don't need it (and also social engineering, too.) Hearing this, I'm sure the Linux community will buckle down more and be even more cautious and add 2x more protection than before.

Additionally, I recall that it is illegal in the United States to write viruses. Too bad I don't have this guy's real name, or I'd be contacting the feds. So, go on, try to hack into my computer or write a virus. Remember, that IP numbers are traceable (even those issued by DHCP) and all I'd have to do is call the ISP and within anywhere from a couple days to a couple minutes, the virus writer would be placed under arrest, not to mention that when he does get out of prison, he'll never be able to use a PC unsupervised.
 

steve01832

Distinguished
Feb 23, 2009
1
0
18,510
As a Linux user myself we can state the obvious. Viruses with an executable extension such as .exe won't run on a Linux machine. They can infect your WINE program if you have it installed however. A script virus can and will run on a Linux box. And, if you recall, who invented the rootkit? The same corp. that invented Unix back in 1969. The rootkit was to ensure a backup plan for their mainframe in case of an intrusion or simply a devastating catastrophe. The rooktit gave administrators another entry point to access the system. Nowadays, the rootkit is considered one of the worst attacks an OS can succomb to. But, it is still the same access point to obtaining a back door into a system. Only now, it is used for the wrong reasons. Yes, Linux and Unix platforms are VERY VULNERABLE to malicious code. So to all you fellow Linux users out there (including myself), keep your eyes open, we too can go down hard. If you run Linux there is a good program called rkhunter and another called chkrootkit. Debian users can install them from the terminal under sudo privilages. Root privilages can use the apt-get install command. Check it out, and be safe out there.

Steve
 

rashaen

Distinguished
Feb 23, 2009
3
0
18,510
If the question of windows' technical inferiority is really on the table one need only be reminded that most windows boxes have an "invisible" admin account which is very often not password protected. Also one might call to memory certain versions of windows that would bypass the login screen by pressing the escape key.

If you read the article foobar admits that linux is less susceptible to viruses and is NOT trying to equate it with windows, but instead to remind people that a virus is indeed possible on Linux. Actually I've seen the numbers between 150 to 200 viruses written for Linux tossed about, but all of them have been addressed and are no longer "in the wild" according to that source (a Linux book of some sort or other, probably Debian). Compare this to the thousands of viruses hitting windows every month and you still get a pretty compelling picture of comparative security.

Lastly- and conversely- one might also consider how many people hate the windows quasi-monopoly and how many of those people happen to be coders and techies. Hmmm....
 
G

Guest

Guest
***As a virus writer, you'd want to attack the majority, not the minority.

There are more servers running Linux than Windows, then why is it that I hear more viruses/worm/malware attacking Windows servers than Linux?
 
G

Guest

Guest
Well, it's the security code that matters most. However, it takes a combo of a good anti-virus, good firewall, good security code, and common sense to never really get viruses.
 
Status
Not open for further replies.