DEADLY LINUX COMMANDS

Everyone should know that there are several deadly commands for Linux. The worst part is that some commands do not need confirmation. Which is where we step in, Trolls will recommend using these commands to new or newish Linux users.

Note that these commands require sudo as a prefix or privileged access.


rm -rf /*

rm – will remove a specific folder or file.
-rf  – recursive allows you to removed a directory and all its sub-directories, while -f stands for, force. Also, rm -rf /* disguised as a different command can be deadly as well. This command recursively/forcefully removes root and all of its sub-directories

:(){ :|: & };:

The fork bomb… which is a form of Denial of service against a Linux system, is a process that will continue to replicate itself and then the copies will replicate themselves. Doing this will quickly take up all your CPU and Memory’s power. Eventually making your computer freeze.

(){ :|:& };:
\_/| |||| ||\- ... the function ':', initiating a chain-reaction: each ':' will start    two more.
 | | |||| |\- Definition ends now, to be able to run ...
 | | |||| \- End of function-block
 | | |||\- disown the functions (make them a background process), so that the children    of a parent
 | | |||   will not be killed when the parent gets auto-killed
 | | ||\- ... another copy of the ':'-function, which has to be loaded into memory.
 | | ||   So, ':|:' simply loads two copies of the function, whenever ':' is called
 | | |\- ... and pipe its output to ...
 | | \- Load a copy of the function ':' into memory ...
 | \- Begin of function-definition
 \- Define the function ':' without any parameters '()' as follows:
(FOUND ON WIKIPEDIA)

mkfs.ext4 /dev/sda1

This command formats the drives. More specifically it will create a new ext4 file system on the following device “/dev/sda1” or disk1. This is the equivalent to formatting a drive/the main drive on Windows. If you wanted to format the second disk within your system it would be “/dev/sdb” and then sdc for the third drive. But be careful when running commands with “/dev/sd”.

dd if=/dev/random of=/dev/sda

This command will write a lot of random and useless junk to your drive. How is it so threatening? While it isn’t intended to overwrite data, it will write random and useless information to your hard drive.  Which causes your hard drive to perform poor and that can affect your overall system’s performance.

mv ~ /dev/null

This command will send the home directory, indicated by “~”  to the null zone. Basically, this command destroys the files and the original copies.

wget [webiste goes here] | sh

wget is a common command used to download files.  The issue, using the “sh” at the end of it will execute the command if it is a bash script.  How is this bad, you ask? Well what if you download some malicious script, then it would start to execute the script and whatever damage would be caused by this would done.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s