egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Traceroute

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
AviZ1
Voice


Joined: 05 Sep 2011
Posts: 2

PostPosted: Mon Sep 05, 2011 4:15 am    Post subject: Traceroute Reply with quote

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.
Back to top
View user's profile Send private message
AviZ1
Voice


Joined: 05 Sep 2011
Posts: 2

PostPosted: Wed Sep 07, 2011 1:08 am    Post subject: Reply with quote

so heres what i have so far...

Code:

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.

Quote:

[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?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber