This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Traceroute

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
A
AviZ1
Voice
Posts: 2
Joined: Mon Sep 05, 2011 4:13 am

Traceroute

Post by AviZ1 »

Hi,

im after a script that will do a traceroute on the shell then post the finding to this address.

usage:
wget post-file.it --post-file FILE
or to set paste exposure to public:
wget post-file.it/p --post-file FILE
or to paste output from a command:
command | xargs -0 wget post-file.it --post-data

and have the bot spit out the pastebin output.
A
AviZ1
Voice
Posts: 2
Joined: Mon Sep 05, 2011 4:13 am

Post by AviZ1 »

so heres what i have so far...

Code: Select all

set chan #shellsolutions
bind pub o !trace pub_trace

proc pub_trace {nick uhost handle chan arg} {
 set command [concat exec /bin/traceroute $arg | xargs -0 wget post-file.it --post-data]
 set return [eval $command]

 foreach output [split pastebin] {
  putserv "PRIVMSG $chan :$output"
 }
}
heres the output within the bot.
[17:06] <Aphex> [22:06:28] Tcl error [pub_trace]: --2011-09-06 22:06:26-- http://post-file.it/
[17:06] <Aphex> Resolving post-file.it... 96.31.85.245
[17:06] <Aphex> Connecting to post-file.it|96.31.85.245|:80... connected.
[17:06] <Aphex> HTTP request sent, awaiting response... 303 See Other
[17:06] <Aphex> Location: +: 182b pasted to >>> http://pastebin.com/0j1kvK86 <<< [following]
[17:06] <Aphex> +: 182b pasted to >>> http://pastebin.com/0j1kvK86 <<<: Unsupported scheme.
what i need to do is spit out the pastebin addy on the irc channel
any helpers?
Post Reply