Sponsored Content
Top Forums UNIX for Advanced & Expert Users How does netcat manage the data it transfers ? Post 302349082 by qiulang on Monday 31st of August 2009 04:59:56 AM
Old 08-31-2009
How does netcat manage the data it transfers ?

Hi all,

When using netcat to transfer the data over socket, if no connection is established, how long will netcat keep the data; will it discard the "oldest" data ?

Say for example I use "Some Command | netcat -l -p port", the command I use will generate a lot of output constantly, while no connection is established yet, will netcat discard the "oldest" data so after the connect is finally established, I only see the latest data ?

I suspect it should work in this way. If yes how do I set the buffer size ? If no how does it work then ?

Thanks!
 

8 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Netcat with Authentication?

I'd like to do a data transfer without encryption but with a guarantee that my data comes from a legit source. I'm thinking something that uses a public key scheme to sign the data. Does anyone know of something like that? Thanks! -Pileofrogs (1 Reply)
Discussion started by: pileofrogs
1 Replies

2. Shell Programming and Scripting

netcat

Is there a way how to react on the message a client sent to the server? I would like as the client sent message to server: "get information such and such" and server would answer. Thank you for reply! (6 Replies)
Discussion started by: MartyIX
6 Replies

3. Ubuntu

Data Transfers Lock System Up Completely

I have two laptops on which I've installed Ubuntu Studio 9.04. The first laptop (Acer) has a Centrino 32-bit Intel CPU in it and the second (HP) has a 64-bit dual core Intel CPU. I'm running the 32-bit version of Ubuntu Studio on the Acer and the 64-bit version on the HP. While testing the... (5 Replies)
Discussion started by: deckard
5 Replies

4. Linux

Thank you radoulov for your help on netcat command (nc -lp)

Hello, Thank you very much for the line nc -lp <port> . I tried to run simple chat session with nc as it's shown in catonmatDOTorg but failed miserably with that syntax inspite of opening port 7777 by iptables . But your command example is working nicely. So a bagful of thanks :)) Only one... (0 Replies)
Discussion started by: vectrum
0 Replies

5. Shell Programming and Scripting

Post using nc(netcat)

Hi; I have a url like http://localhost:8080/examples/jsp/dates/nextPageToPost.jsp?name=ajay&password=pas&sex=Male&check=on&nationality=USA&description=aa&submit=submit in which i want to use nc for http post for parameters like "name","password"....etc can neone please help me how to do that... (3 Replies)
Discussion started by: ajaypadvi
3 Replies

6. IP Networking

Help with Netcat

Hi all, I know my question is regarding Windows and not Linux, but I simply need people who know Netcat pretty well and I'm guessing here is a good place for that. So on with my question. I'm doing some research, and I was playing around with netcat on a WinXP VM but I can't seem to get... (0 Replies)
Discussion started by: MrCrumbs
0 Replies

7. Emergency UNIX and Linux Support

Netcat ( nc -l ) as webserver

Dear Linux guru's I am trying to create a webserver using nc (netcat only) on RHEL 7.2 running on bash shell. now the easy thing is to get nc listing to a port and respond back $ while true; do { echo -e 'HTTP/1.0 200 OK\r\n'; set; } | nc -l 7877; done This when called from a... (3 Replies)
Discussion started by: chakrapani
3 Replies

8. UNIX for Beginners Questions & Answers

How to fix and manage data in rescue mode?

Hello, I am running ubuntu 14.04 My server has problems again. I need to manage system files in rescue mode, backup some files, edit /etc/crontab and rc.local files etc. root@rescue:~# cat /proc/mdstat Personalities : md2 : active raid1 sda2 sdb2 4193216 blocks md3 :... (4 Replies)
Discussion started by: baris35
4 Replies
netread(1)						      General Commands Manual							netread(1)

NAME
netread - read data transported over network using netwrite SYNOPSIS
netread [udp] [-f host ] [-c] [-C algorithm ] [-o file ] [-s] [-b] [-h <n> ] [-H] <n> ] [-q] [-v] [-vv] [-V] [-vV] netread is part of the netrw package. It is a simple (but powerful) tool for transporting data over the internet, in conjunction with netwrite(1) DESCRIPTION
The main purpose of netrw is to simplify and speed up file transfers to hosts without an FTP server. It can also be used for uploading data to some other user. It is something like one-way netcat (nc) with some nice features concerning data transfers. Netrw can compute and check message digest (MD5, SHA-1, and some others) of all the data being transferred, it can also print information on progress and average speed. At the end it sums up the transfer. OPTIONS
udp Changes the default TCP protocol can be changed to UDP. -f host Works in the firewall mode; connection is initiated by netread. -c This option is ignored. Transmission checksum is activated by default. -C algorithm Uses the specified algorithm for checksum. This option also implies -c . Supported algorithms (the first is default): sha1 md5 rmd160 none -o <file> Writes data to file instead of stdout. -s In case -o option is specified, open the file for synchronous I/O. Otherwise, this option has no effect. -b print speed in b/s instead of B/s -h <n> Prints `#' after each n KiB transferred (def. 10485.76). -H <n> Prints `#' after each n MiB transferred (def. 10.24). -q Be quiet. -v Be verbose. -vv Be very verbose. -V Show version. -vV Show verbose version. RETURN VALUES
0 no errors. 1 some error occured. 2 checksum validation failed. SEE ALSO
netwrite(1), /usr/share/doc/netrw/README AUTHOR
netread was written by Jiri Denemark <jirka@ics.muni.cz>. For more information, visit http://www.fi.muni.cz/~xdenemar/netrw This manual page was written by Kumar Appaiah <akumar@ee.iitm.ac.in>, for the Debian project (but may be used by others). 2007-10-14 netread(1)
All times are GMT -4. The time now is 10:47 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy