Re: can perl program do this?



Ah, I see...

I think you have been misled by the name of the Net::Pcap lib, the lib is
meant to produce the file you are trying to poke around in.

I would do the follwoing.

- Use Net::SSH or similair to connect to the remote machine.
- On the remote machine use grep or similair to pull out the lines you
are intrested in and store those in an array/file or well what ever storage
you like on your side.
- Process the data on your own machine.

The advantage of this is that you only move the data you are intrested in
over the network and not the whole big file, thus reducing the network
trafic and maning your network admins happy as well. Because you have the
data on your side you can then do with it what you want without having to
rely on any software on the remote machine.

I hope this helps a bit,

Rob
On Thu, Jul 31, 2008 at 9:06 AM, Richard Lee <rich.japh@xxxxxxxxx> wrote:

Rob Coops wrote:

If you can make Net::Pcap connect to a remote server things will work
fine, I am not sure about using Net::Pcap to do this as I never used it and
from the description it seems to be a packet capture lib not so much a
communication one, but as I said if you can make it reach out and talk to
the other side you should be fine.
I think you will end up using somehting like Net::SSH or something like
that as these are more aimed at communication then Net::Pcap seems to be.
But in the end as long as the other side is listening on a port and you
can produce the required packets to get communication going you should be
fine, there is no need to have perl, or any perl libs on the other side all
that is needed is an open port that you can communicate with.
The thing that is listening on that port is what determins what you can
do, read email, open and interact with files or just browse a web page, perl
on your machine cannot change which process is listening on the other
machine.
In short I guess you can if the other machine is listening, but you might
want to use a more suitable lib for it.
Regards,
Rob

On Thu, Jul 31, 2008 at 8:41 AM, Richard Lee <rich.japh@xxxxxxxxx<mailto:
rich.japh@xxxxxxxxx>> wrote:

say I have big wireshark file based on remote server.

I want to logon to that server and using Net::Pcap to poke the
file and only grep out small portion of information which meets my
criteria.
Remote server won't have Net::Pcap installed.

I wanted to write this program w/ Expect modules and Net::Pcap
module in my mind.
But since these things are only located in my local server, will
this work on remote server?

-- To unsubscribe, e-mail: beginners-unsubscribe@xxxxxxxx
<mailto:beginners-unsubscribe@xxxxxxxx>
For additional commands, e-mail: beginners-help@xxxxxxxx
<mailto:beginners-help@xxxxxxxx>
http://learn.perl.org/




Hi,

local server(w/ Perl installed) -------------------> remote server(with
Pcap file I am interested in poking around)

if I launch a perl script from my local server(using say Net::SSH) and logs
onto remote server, my perl can poke around that file on remote server
using Net::Pcap.... ? So essentially in order to do this, I need to use 2
modules(to logon, and then parsing out the pcap file)

I am thinking about writing this but just not sure if it will work on
remote server




Relevant Pages

  • Re: can perl program do this?
    ... I think you will end up using somehting like Net::SSH or something like that as these are more aimed at communication then Net::Pcap seems to be. ... But in the end as long as the other side is listening on a port and you can produce the required packets to get communication going you should be fine, there is no need to have perl, or any perl libs on the other side all that is needed is an open port that you can communicate with. ... Remote server won't have Net::Pcap installed. ...
    (perl.beginners)
  • Re: can perl program do this?
    ... I think you have been misled by the name of the Net::Pcap lib, the lib is meant to produce the file you are trying to poke around in. ... If you can make Net::Pcap connect to a remote server things ... have perl, or any perl libs on the other side all that is ... The thing that is listening on that port is what determins ...
    (perl.beginners)
  • Re: can perl program do this?
    ... as these are more aimed at communication then Net::Pcap seems to be. ... But in the end as long as the other side is listening on a port and you can ... there is no need to have perl, or any perl libs on the other side all that ... Remote server won't have Net::Pcap installed. ...
    (perl.beginners)
  • Re: How to have perl on a CD (windows)
    ... > memory stick and could run on any windows computer. ... Firstly, Tiny Perl is able to run Perl programs, say from a floppy, with ... pm files either under site/lib or lib. ... Checking the lib.zip file under Tiny Perl reveals that no hash modules have ...
    (comp.lang.perl.misc)
  • Re: Need some module help
    ... use warnings; ... use lib 'Mod'; ... use FindBin qw; ... The module, FindBin, is a standard module and comes bundled with perl. ...
    (perl.beginners)