netcat

centos安装netcat工具及测试

元气小坏坏 提交于 2020-01-24 14:51:02
netcat是网络工具中的瑞士军刀,它能通过TCP和UDP在网络中读写数据。通过与其他工具结合和重定向,你可以在脚本中以多种方式使用它。使用netcat命令所能完成的事情令人惊讶。 netcat所做的就是在两台电脑之间建立链接并返回两个数据流,在这之后所能做的事就看你的想像力了。你能建立一个服务器,传输文件,与朋友聊天,传输流媒体或者用它作为其它协议的独立客户端。 1、下载安装 wget https://sourceforge.net/projects/netcat/files/netcat/0.7.1/netcat-0.7.1.tar.gz/download tar -zxvf netcat-0.7.1.tar.gz -C /usr/local cd /usr/local mv netcat-0.7.1 netcat cd /usr/local/netcat ./configure make && make install 2、配置 vim /etc/profile 添加以下内容: # set netcat path export NETCAT_HOME=/usr/local/netcat export PATH=$PATH:$NETCAT_HOME/bin    保存,退出,并使配置生效: source /etc/profile 3、测试 nc -help成功 在服务器

Linux Netcat命令

拈花ヽ惹草 提交于 2020-01-23 11:48:40
一、简介 netcat是网络工具中的瑞士军刀,它能通过TCP和UDP在网络中读写数据。netcat所做的就是在两台电脑之间建立链接并返回两个数据流,通过与其他工具结合和重定向,你可以在脚本中以多种方式使用,你能建立一个服务器,传输文件,与朋友聊天,传输流媒体或者用它作为其它协议的独立客户端。 二、安装 1)yum安装 yum install -y netcat 2)源码安装 wget http://ncu.dl.sourceforge.net/project/netcat/netcat/0.7.1/netcat-0.7.1.tar.gz ./configure make && make install 三、实例 http://www.oschina.net/translate/linux-netcat-command 来源: https://www.cnblogs.com/274914765qq/p/5003526.html

Turn simple C program into server using netcat

我与影子孤独终老i 提交于 2020-01-22 21:23:29
问题 One cool feature of netcat is how it can turn any command line program into a server. For example, on Unix systems we can make a simple date server by passing the date binary to netcat so that it's stdout is sent through the socket: netcat -l -p 2020 -e date Then we can invoke this service from another machine by simply issuing the command: netcat <ip-address> 2020 Even a shell could be connected ( /bin/sh ), although I know this is highly unrecommended and has big security implications.

Linux Netcat命令

喜夏-厌秋 提交于 2020-01-22 16:16:37
一、简介 netcat是网络工具中的瑞士军刀,它能通过TCP和UDP在网络中读写数据。netcat所做的就是在两台电脑之间建立链接并返回两个数据流,通过与其他工具结合和重定向,你可以在脚本中以多种方式使用,你能建立一个服务器,传输文件,与朋友聊天,传输流媒体或者用它作为其它协议的独立客户端。 二、安装 1)yum安装 yum install -y netcat 2)源码安装 wget http://ncu.dl.sourceforge.net/project/netcat/netcat/0.7.1/netcat-0.7.1.tar.gz ./configure make && make install 三、实例 1) http://www.oschina.net/translate/linux-netcat-command 2)bind-shell/reverse-shells http://www.hackingtutorials.org/networking/hacking-netcat-part-2-bind-reverse-shells/ 来源: https://www.cnblogs.com/274914765qq/p/7107355.html

linux netcat 命令详解

一世执手 提交于 2020-01-22 15:53:28
功能说明: 强大的网络工具 语  法:nc [-hlnruz][-g<网关...>][-G<指向器数目>][-i<延迟秒数>][-o<输出文件>][-p<通信端口>][-s<来源位址>][-v...][-w<超时秒数>][主机名称][通信端口...] 参  数: -g<网关> 设置路由器跃程通信网关,最多可设置8个。 -G<指向器数目> 设置来源路由指向器,其数值为4的倍数。 -h 在线帮助。 -i<延迟秒数> 设置时间间隔,以便传送信息及扫描通信端口。 -l 使用监听模式,管控传入的资料。 -n 直接使用IP地址,而不通过域名服务器。 -o<输出文件> 指定文件名称,把往来传输的数据以16进制字码倾倒成该文件保存。 -p<通信端口> 设置本地主机使用的通信端口。 -r 乱数指定本地与远端主机的通信端口。 -s<来源位址> 设置本地主机送出数据包的IP地址。 -u 使用UDP传输协议。 -v 显示指令执行过程。 -w<超时秒数> 设置等待连线的时间。 -z 使用0输入/输出模式,只在扫描通信端口时使用。 Linux nc (netcat)最新版源码下载及nc命令详解 http://netcat.sourceforge.net/ 扩展资料一: nc简单使用示例 简单用法举例 1.端口扫描 # nc -v -w 2 192.168.2.34 -z 21-24 nc: connect

linux centos7安装netcat

时光毁灭记忆、已成空白 提交于 2020-01-21 12:38:48
在用swoole UDP服务器可以使用netcat -u 来连接测试时,报错-bash: netcat: command not found,网上一搜,才知道centos7未安装netcat NetCat是一个非常简单的Unix工具,可以读、写TCP或UDP网络连接(network connection)。它被设计成一个可靠的后端(back-end) 工具,能被其它的程序程序或脚本直接地或容易地驱动。同时,它又是一个功能丰富的网络调试和开发工具,因为它可以建立你可能用到的几乎任何类型的连接,以及一些非常有意思的内建功能。 安装依赖 sudo yum install glibc* 安装netcat wget https://sourceforge.NET/projects/netcat/files/netcat/0.7.1/netcat-0.7.1.tar.gz tar zxvf netcat-0.7.1.tar.gz cd netcat-0.7.1 ./configure make make install 测试: $ netcat -u 127.0.0.1 8004 php hello php $ nc -u 127.0.0.1 8004 java hello java 这里的127.0.0.1:8004是自己采用php搭建的udp服务器,不是系统的。 Netcat简介 8

flume的配置详解

时光怂恿深爱的人放手 提交于 2020-01-17 12:35:23
Flume: ===================== Flume是一种分布式的、可靠的、可用的服务,可以有效地收集、聚合和移动大量的日志数据。 它有一个基于流数据的简单而灵活的体系结构。 它具有健壮性和容错能力,具有可调的可靠性机制和许多故障转移和恢复机制。 它使用一个简单的可扩展数据模型,允许在线分析应用程序。 source:源 对channel而言,相当于生产者,通过接收各种格式数据发送给channel进行传输 channel:通道 相当于数据缓冲区,接收source数据发送给sink sink:沉槽 对channel而言,相当于消费者,通过接收channel数据通过指定数据类型发送到指定位置 Event: =============== flume传输基本单位: head + body flume安装: ================ 1、解压 2、符号链接 3、配置环境变量并使其生效 4、修改配置文件 1)重命名flume-env.ps1.template为flume-env.ps1 2)重命名flume-env.sh.template为flume-env.sh 3)修改flume-env.sh,配置jdk目录,添加 export JAVA_HOME=/soft/jdk 5、flume 查看版本 flume-ng version flume使用: ==========

Multiple unix pipes not working

我的未来我决定 提交于 2020-01-15 11:15:52
问题 This first pipeline works fine (printing "c"): echo "a" | sed 's/a/b/' | sed 's/b/c/' This one does not do what I expect (nothing gets printed when I feed an "a" into my fifo ): mkfifo fifo; cat fifo | sed 's/a/b/' | sed 's/b/c/' However, if I remove the second "sed" command from the latter pipeline, I do get a "b" printed. I think my understanding of pipes and redirects must be too simplistic. Can someone explain to me how to fix the 2nd case so that I can run two successive commands on the

How to stream tmux pipe-pane via UDP

旧城冷巷雨未停 提交于 2020-01-13 06:33:58
问题 I'm trying to simultaneously save the output from a tmux pane to file and stream it using netcat. What works: tmux pipe-pane -o -t "server" "tee -a '/home/csgoserverp/test.txt'" echo -n "Hello World" | tee -a '/home/me/text.txt' | nc -4u -w1 0.0.0.0 9999 What does not work: tmux pipe-pane -o -t "server" "nc -4u -w1 0.0.0.0 9999" tmux pipe-pane -o -t "server" "tee -a '/home/me/test.txt' | nc -4u -w1 0.0.0.0 9999" Any help would be appreciated. 回答1: I read somewhere that ncat is better than

I want to get output with one command line in private host through bastion server using one key pair

走远了吗. 提交于 2020-01-06 05:27:07
问题 I want to get output with one command line in private host through bastion server using one key pair . Referencely, bastion server and private host share one key pair and key pair is in my local macbook. How can I get an output (ex. ls) on my local macbook with one command line? mac > bastion > private ip host (I want to output of ls command) enter image description here 回答1: You could do it by using a ProxyJump in your .ssh/config , for example: Host private.host ProxyJump <user>@bastion