Re: sniffinf



On Apr 28, 7:45 am, franzi <hazz...@xxxxxxxxx> wrote:
Hi there to everybody,could you point me if there is a way to perform
a packet manipulation inside a default unix system by a shell
scripts?
i'm trying to use right now scapy but it's not a default software
via awk grep and what's so ever is there any chace?

"Default software", meaning preinstalled in the Unix default
distribution?

Since no one has answered in two days, I can contribute, that while
I have no experience with the scapy program, it is quite versatile
and sophisticated. In general principle, high-level shellscript (and
scripting in general) is a "glue" language best used to link other
lower-level software tools together.

While newer versions of ksh have a high-level interface to the
underlying OS'es TCP and UDP networking via the "> /dev/{tcp,udp}/
<IP#>/<port#>" pseudo-device (q.v. the manpage), this by no means
constitutes the interactive, multiple protocol, data packet forging/
decoding/sending/capturig/matching functionality of scapy.
I am aware of no script, sophisticated or not, that even approximates
the power of scapy. Two decades ago, there was an attempt to
translate uucp into Bourne shell, which failed, and I think the
situation is no better with newline-delimited-text oriented
input/output of the usual shells.

When greater control over networking is desired, the usual tools
(which are not distribution tools either, except for _maybe_ netcat)
used under command line control are:

"TCP_Wrappers."
ftp://ftp.porcupine.org/pub/security/index.html

"netpipes.c"
http://freshmeat.net/projects/netpipes/
http://www.cryptography.org/

"netcat.c"
http://netcat.sf.net/
.... and its many versions and clones....
http://farm9.com/content/Free_Tools/Cryptcat
"crryptcat = netcat + encryption"
http://www.l0pht.com/~weld/netcat/readme.html

More special purpose tools are available, e.g.:

"connect.c"
http://www.awk-scripting.de/download/connect-1.0.2.tar.gz
http://www.awk-scripting.de/download/connect-1.html

However, informally perusing scapy's Web site, I see
that there is a sufficient API for python programmers to
control scapy.

http://hackaholic.org/papers/blackmagic.txt

In my estimation, any binary I/O can be accomplished
with clever use of the enhanced "printf" of late-version
ksh93 shells, so theoretically, your desire can be
accomplished with shell control of scapy, if not a
standalone script itself.

=Brian
.



Relevant Pages

  • Re: Controlling processes and what to "feed" other processes
    ... I already have a somewhat buggyruby script which actually ... For full control you would have to intercept system calls because you would need to manipulate files while they are read. ... If you know that all programs are started via a shell you could try to modify environment variable SHELL to point to a specific program which would be able to interpret the general syntax of the shell you are using and could identify files via their names and then do some manipulations. ...
    (comp.lang.ruby)
  • Re: sniffinf
    ... I have no experience with the scapy program, ... I am aware of no script, sophisticated or not, that even approximates ... translate uucp into Bourne shell, which failed, and I think the ... When greater control over networking is desired, ...
    (comp.unix.shell)
  • Re: Question on background jobs
    ... some other foreground job. ... shell prompt comes back immediately, while the program continues to run, ... Job control is the ability to move jobs between foreground, stopped, and ... (via a script) ...
    (comp.unix.shell)
  • Re: detect shell script language
    ... In the 'old' days, when a user typed in a command, the interactive shell would immediately pass it off to 'exec' to execute. ... So, on return from exec with an error status, the shell would fork a copy of itself to try and run the script. ... As a result of the above, it was hard to tell whether the script was a Bourne shell or C shell, so the convention was introduced of using the Bourne shell no op command, as the first line in a Bourne shell script. ...
    (Debian-User)
  • Re: awk here documents
    ... script called from shell to produce some pre-formatted blocks of code ... awk variable: ... or awk quotes with shell quotes ...
    (comp.unix.shell)