Skip to content

Instantly share code, notes, and snippets.

@joshbuddy
Forked from jpignata/output
Created October 24, 2009 18:58
Show Gist options
  • Save joshbuddy/217691 to your computer and use it in GitHub Desktop.
Save joshbuddy/217691 to your computer and use it in GitHub Desktop.
#!/usr/bin/env ruby
require 'pcaplet'
Pcaplet.new('-i en1 -s 1500').each do |packet|
if packet.class == Pcap::TCPPacket and !packet.tcp_data.nil?
words = packet.tcp_data.split
words.reject! { |word| word.match(/[^A-Za-z]/) || word.length < 5 }
random_word = words[rand(words.size)]
system("clear && figlet -c #{random_word}") if random_word
end
end
# While httping'ing www.nytimes.com
___ _
/ _ \| |__ __ _ _ __ ___ __ _
| | | | '_ \ / _` | '_ ` _ \ / _` |
| |_| | |_) | (_| | | | | | | (_| |
\___/|_.__/ \__,_|_| |_| |_|\__,_|
____ _ _ _
/ ___| ___ __| |_ _ ___| |_(_) ___ _ __
\___ \ / _ \/ _` | | | |/ __| __| |/ _ \| '_ \
___) | __/ (_| | |_| | (__| |_| | (_) | | | |
|____/ \___|\__,_|\__,_|\___|\__|_|\___/|_| |_|
__ ___ _ _
\ \ / / |__ (_) |_ ___
\ \ /\ / /| '_ \| | __/ _ \
\ V V / | | | | | || __/
\_/\_/ |_| |_|_|\__\___|
_____ _
|_ _(_)_ __ ___ ___ ___
| | | | '_ ` _ \ / _ \/ __|
| | | | | | | | | __/\__ \
|_| |_|_| |_| |_|\___||___/
__ __ _
| \/ (_)___ _ __ ___ ___ __ _ ___ _ _ _ __ ___
| |\/| | / __| '_ ` _ \ / _ \/ _` / __| | | | '__/ _ \
| | | | \__ \ | | | | | __/ (_| \__ \ |_| | | | __/
|_| |_|_|___/_| |_| |_|\___|\__,_|___/\__,_|_| \___|
_____ _
| ____|_ __ __| | ___ _ __ ___ ___
| _| | '_ \ / _` |/ _ \| '__/ __|/ _ \
| |___| | | | (_| | (_) | | \__ \ __/
|_____|_| |_|\__,_|\___/|_| |___/\___|
____ _
/ ___| |__ ___ _ __ ___ _ _
| | | '_ \ / _ \ '_ \ / _ \ | | |
| |___| | | | __/ | | | __/ |_| |
\____|_| |_|\___|_| |_|\___|\__, |
|___/
____ ___ ____ _ _ _ _ ____
| _ \ / _ \| _ \| | | | | / \ | _ \
| |_) | | | | |_) | | | | | / _ \ | |_) |
| __/| |_| | __/| |_| | |___ / ___ \| _ <
|_| \___/|_| \___/|_____/_/ \_\_| \_\
_____ _
| ___| | ___ ___ _ __
| |_ | |/ _ \ / _ \| '__|
| _| | | (_) | (_) | |
|_| |_|\___/ \___/|_|
_ _ _ _
__ _| | |_ ___ _ __ _ __ __ _| |_(_)_ _____
/ _` | | __/ _ \ '__| '_ \ / _` | __| \ \ / / _ \
| (_| | | || __/ | | | | | (_| | |_| |\ V / __/
\__,_|_|\__\___|_| |_| |_|\__,_|\__|_| \_/ \___|
_
___| | ___ ___ ___
/ __| |/ _ \/ __|/ _ \
| (__| | (_) \__ \ __/
\___|_|\___/|___/\___|
____ _ _
/ ___|| |_ __ _| |_ ___ ___
\___ \| __/ _` | __/ _ \/ __|
___) | || (_| | || __/\__ \
|____/ \__\__,_|\__\___||___/
__ _ _
/ _|_ _ _ __ ___| |_(_) ___ _ __
| |_| | | | '_ \ / __| __| |/ _ \| '_ \
| _| |_| | | | | (__| |_| | (_) | | | |
|_| \__,_|_| |_|\___|\__|_|\___/|_| |_|
___ _ _
/ _ \ ___| |_ ___ | |__ ___ _ __
| | | |/ __| __/ _ \| '_ \ / _ \ '__|
| |_| | (__| || (_) | |_) | __/ |
\___/ \___|\__\___/|_.__/ \___|_|
_ _
_ __ ___ _ __ ___ _ __ ___ ___| |_(_)_ _____
| '_ \ / _ \ '__/ __| '_ \ / _ \/ __| __| \ \ / / _ \
| |_) | __/ | \__ \ |_) | __/ (__| |_| |\ V / __/
| .__/ \___|_| |___/ .__/ \___|\___|\__|_| \_/ \___|
|_| |_|
__ _ _
/ _|_ _ _ __ ___| |_(_) ___ _ __
| |_| | | | '_ \ / __| __| |/ _ \| '_ \
| _| |_| | | | | (__| |_| | (_) | | | |
|_| \__,_|_| |_|\___|\__|_|\___/|_| |_|
_____ _
| ____|_ _| |_ _ __ __ _
| _| \ \/ / __| '__/ _` |
| |___ > <| |_| | | (_| |
|_____/_/\_\\__|_| \__,_|
_
___ ___ ___ ___ _ __ __| | __ _ _ __ _ _
/ __|/ _ \/ __/ _ \| '_ \ / _` |/ _` | '__| | | |
\__ \ __/ (_| (_) | | | | (_| | (_| | | | |_| |
|___/\___|\___\___/|_| |_|\__,_|\__,_|_| \__, |
|___/
_
___ ___ ___ ___ _ __ __| | __ _ _ __ _ _
/ __|/ _ \/ __/ _ \| '_ \ / _` |/ _` | '__| | | |
\__ \ __/ (_| (_) | | | | (_| | (_| | | | |_| |
|___/\___|\___\___/|_| |_|\__,_|\__,_|_| \__, |
|___/
__ _____ _ _| | __| |
\ \ /\ / / _ \| | | | |/ _` |
\ V V / (_) | |_| | | (_| |
\_/\_/ \___/ \__,_|_|\__,_|
____ _
/ ___|__ _ _ __ ___ _ __ __ _(_) __ _ _ __
| | / _` | '_ ` _ \| '_ \ / _` | |/ _` | '_ \
| |__| (_| | | | | | | |_) | (_| | | (_| | | | |
\____\__,_|_| |_| |_| .__/ \__,_|_|\__, |_| |_|
|_| |___/
____ _
| _ \ ___ ___ ___ _ __ __| |
| |_) / _ \/ __/ _ \| '__/ _` |
| _ < __/ (_| (_) | | | (_| |
|_| \_\___|\___\___/|_| \__,_|
_ _ _ _
___ ___ _ __ | |_ _ __ ___ | | (_)_ __ __ _
/ __/ _ \| '_ \| __| '__/ _ \| | | | '_ \ / _` |
| (_| (_) | | | | |_| | | (_) | | | | | | | (_| |
\___\___/|_| |_|\__|_| \___/|_|_|_|_| |_|\__, |
|___/
_
__ _| |__ ___ _ __ ___
\ \ /\ / / '_ \ / _ \ '__/ _ \
\ V V /| | | | __/ | | __/
\_/\_/ |_| |_|\___|_| \___|
_ _ ____
__ _(_) __| | ___| __ )
\ \ /\ / / |/ _` |/ _ \ _ \
\ V V /| | (_| | __/ |_) |
\_/\_/ |_|\__,_|\___|____/
_ _
_ __ ___ (_)_ __ _ _| |_ ___ ___
| '_ ` _ \| | '_ \| | | | __/ _ \/ __|
| | | | | | | | | | |_| | || __/\__ \
|_| |_| |_|_|_| |_|\__,_|\__\___||___/
____ _ _
/ ___|___ ___ | (_)_ __ __ _
| | / _ \ / _ \| | | '_ \ / _` |
| |__| (_) | (_) | | | | | | (_| |
\____\___/ \___/|_|_|_| |_|\__, |
|___/
____
/ ___| _ _ ___ ___ ___ ___ ___
\___ \| | | |/ __/ __/ _ \/ __/ __|
___) | |_| | (_| (_| __/\__ \__ \
|____/ \__,_|\___\___\___||___/___/
^CInterrupted.
110 packets received by filter
19 packets dropped by kernel
jp@populuxe:~/Projects/scratch$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment