前期博客

基于CentOS6.5下snort+barnyard2+base的入侵检测系统的搭建(图文详解)(博主推荐)

tcpreplay是什么?

  简单的说, tcpreplay是一种pcap包的重放工具, 它可以将用ethreal, wireshark工具抓下来的包原样或经过任意修改后重放回去. 它允许你对报文做任意的修改(主要是指对2层, 3层, 4层报文头), 指定重放报文的速度等, 这样tcpreplay就可以用来复现抓包的情景以定位bug, 以极快的速度重放从而实现压力测试。
  tcpreplay本身包含了几个辅助工具(tcpprep、tcprewrite、tcpreplay和tcpbridge), 用于准备发包的cache, 重写报文等。这也是 Tcpreplay 的第一个字母大写T的原因 。

   * tcpprep -
简单的说就是划分哪些包是client的, 哪些是server的, 一会发包的时候client的包从一个网卡发, server的包可能从另一个网卡发。

        即区分pcap数据包的流向,即区分出客户端和服务器。
      * tcprewrite
- 简单的说就是修改2层, 3层, 4层报文头部。

        即改写pcap数据包的2-4层的头部信息,即MAC地址、IP地址和PORT等。
      * tcpreplay
- 真正发包, 可以选择主、从网卡, 发包速度等。

        即回放pcap文件中的数据包。

   * tcpreplay-edit-更写pcap数据并回放,将tcprewrite和tcpreplat一条命令实现。
      * tcpbridge
- bridge two network segments with the power of tcprewrite。

    

  以下是官网的原文。

The Tcpreplay suite includes the following tools:

  • tcpprep - multi-pass pcap file pre-processor which determines packets as client or server and creates cache files used by tcpreplay and tcprewrite
  • tcprewrite - pcap file editor which rewrites TCP/IP and Layer 2 packet headers
  • tcpreplay - replays pcap files at arbitrary speeds onto the network
  • tcpliveplay - Replays network traffic stored in a pcap file on live networks using new TCP connections
  • tcpreplay-edit - replays & edits pcap files at arbitrary speeds onto the network
  • tcpbridge - bridge two network segments with the power of tcprewrite
  • tcpcapinfo - raw pcap file decoder and debugger

  官网

  1. http://tcpreplay.synfin.net/

 

  在CentOS里安装tcpreplay,总的来说,有如下两种安装方法。

  第一种安装方法:(推荐)

  直接yum -y install tcpreplay即可。

  1. [root@datatest ~]# yum -y install tcpreplay

  1. [root@datatest ~]# tcpreplay -V
  2. tcpreplay version: 4.2. (build git:v4.2.5)
  3. Copyright - by Fred Klassen <tcpreplay at appneta dot com> - AppNeta
  4. Copyright - by Aaron Turner <aturner at synfin dot net>
  5. The entire Tcpreplay Suite is licensed under the GPLv3
  6. Cache file supported:
  7. Not compiled with libdnet.
  8. Compiled against libpcap: 1.4.
  9. bit packet counters: enabled
  10. Verbose printing via tcpdump: enabled
  11. Packet editing: disabled
  12. Fragroute engine: disabled
  13. Injection method: PF_PACKET send()
  14. Not compiled with netmap
  15. [root@datatest ~]#

  第二种安装方法:

在Centos中安装TCPReplay

Tcpreplay的初步使用

  1、查看Tcpreplay里的tcpreplay的帮助文档命令

  1. [root@datatest ~]# tcpreplay -h
  2. tcpreplay (tcpreplay) - Replay network traffic stored in pcap files
  3. Usage: tcpreplay [ -<flag> [<val>] | --<name>[{=| }<val>] ]... <pcap_file(s)>
  4.  
  5. -q, --quiet Quiet mode
    安静模式
  6.  
  7.   -a
    精确的时间(使用高速 cpu 发包)
      
      -d
    输出调试信息(0-5,默认 0
  8.  
  9. -T, --timer=str Select packet timing mode: select, ioport, gtod, nano
  10. --maxsleep=num Sleep for no more then X milliseconds between packets
  11. -v, --verbose Print decoded packets via tcpdump to STDOUT
    可选参数,每发送一个报文都以 tcpdump 风格打印对应信息
  12.  
  13.  
  14. -A, --decode=str Arguments passed to tcpdump decoder
    可选参数,在使用 tcpdump 风格打印输出信息时,同时再调用 tcpdump 中的参数
  15.  
  16. -K, --preload-pcap Preloads packets into RAM before sending
  17.  
  18.   -c
    双网卡回放报文必选参数,后跟文件名
  19.  
  20. -C, --cachefile=str Split traffic via a tcpprep cache file
    把报文存在内部缓存中
  21.  
  22.   -N
    获得网络接口和出口
  23.  
  24. -, --dualfile Replay two files at a time from a network tap
  25. -i, --intf1=str Client to server/RX/primary traffic output interface
  1. 双网卡回放报文必选参数,指定从接口
  1.   -I, --intf2=str Server to client/TX/secondary traffic output interface
        --listnics List available network interfaces and exit
  1. 双网卡回放报文必选参数,指定主接口
  1.   -l, --loop=num Loop through the capture file X times
       --loopdelay-ms=num Delay between loops in milliseconds
         --pktlen Override the snaplen and use the actual packet len
    可选参数,指定循环次数
  2.  
  3.   -S
    制定包长度
  4.  
  5. -L, --limit=num Limit the number of packets to send
  6. --duration=num Limit the number of seconds to send
    限制发包数量
  7.  
  8.   
  9.  
  10. -x, --multiplier=str Modify replay speed to a given multiple
  11. -p, --pps=str Replay packets at a given packets/sec
    可选参数,指定每秒发送报文的个数。制定该参数,其他速率相关的参数被忽略,
    打印信息不会有速率和每秒发送报文的统计
  12.  
  13. -M, --mbps=str Replay packets at a given Mbps
    Mbps(兆字节每秒)发送报文
  14.  
  15.   -m
    可选参数,指定一个倍数值,比默认发送速度快多少倍发送报文
  16.  
  17. -t, --topspeed Replay packets as fast as possible
    以最快的速度回放报文
  18.  
  19.  
  20. -o, --oneatatime Replay one packet at a time for each user input
  21. --pps-multi=num Number of packets to send for each time interval
  22. --unique-ip Modify IP addresses each loop iteration to generate unique flows
  23. --unique-ip-loops=str Number of times to loop before assigning new unique ip
  24. --no-flow-stats Suppress printing and tracking flow count, rates and expirations
  25. --flow-expiry=num Number of inactive seconds before a flow is considered expired
    一次回放一个报文
  26.  
  27. -P, --pid Print the PID of tcpreplay at startup
  28. --stats=num Print statistics every X seconds, or every loop if ''
    可选参数,表示在输出信息中打印 PID 信息,用于单用户和单账户模式下暂停和重
    启程序
  29.  
  30. -V, --version Print version information
    现实版本号
  31.  
  32. -h, --less-help Display less usage information and exit
  33. -H, --help display extended usage information and exit
  34. -!, --more-help extended usage information passed thru pager
  35. --save-opts[=arg] save the option state to a config file
  36. --load-opts=str load options from a config file
  37.  
  38. Options are specified by doubled hyphens and their name or by a single
  39. hyphen and the flag character.
  40. tcpreplay is a tool for replaying network traffic from files saved with
  41. tcpdump or other tools which write pcap() files.
  42.  
  43. Please send bug reports to: <tcpreplay-users@lists.sourceforge.net>
  44. [root@datatest ~]#

  Tcpreplay 根据 cach 文件来回放 pcap 文件中的数据。

  tcpreplay小例子

  1. [root@datatest ~]# tcpreplay --intf1=eth1 --intf2=eth0 t --cachfile=cach_test.cach http_rewrite_pcap

  

  --intf1=eth1 是指主接口是 eth1, 服务器-> 客户端的数据包通过这个接口发送。

      服务器和客户端的区分是从 tcpprep 的处理结果 cach_test.cach 中得到的。
  --intf2=eth0 是指从接口是 eth0,客户端->服务器的数据包通过这个接口发送。
  --cachfile=cach_test_cach 是指 tcpreplay 用 下面的tcpprep 的处理结果--cach_test.cach 来区分方向。
  http_rewrite.pcap 是指 tcpreplay 发送的是来自 http_rewrite.pcap 这个文件中的数据包

  1. [root@datatest ~]# tcpreplay i eth1 I eth0 c ceshiftp.cach ceshiftp.pcap

  -i, --intf1这是数据重放的时候,的从接口。     -I, --intf2这是数据重放的时候,的主接口。  –c是双网卡回放报文必选参数,后跟文件名

  在linux下, 用ifconfig命令可以获得接口的名字。

  但在cygwin下必须用下面的命令获得接口的名字。
  在cygwin下获得接口的名字:

  1. $ tcpreplay --listnics

  假设在windows下的cygwin里安装的tcpreplay

  1. $ tcpreplay --listnics
  2. |Available network interfaces:
  3. |Alias Name Description
  4. |% \Device\NPF_GenericDialupAdapter
  5. | Adapter for generic dialup and VPN capture
  6. |% \Device\NPF_{6B508B29-B3E3-4D0B-892F-02914AC9A668}
  7. | Intel(R) 82566DM Gigabit Network Connection (Microsoft's Packet
  8. | Scheduler)
  9. |% \Device\NPF_{CBCE38CA-1FAD-4AEB-89DF-FD2D8EF861FA}
  10. | D-Link DFE-530TX PCI Fast Ethernet Adapter (rev.C)
  11. | (Microsoft's Packet Scheduler)
  12. |% \Device\NPF_{ABB813FE-3C51-49A3--16CD2C4507C3}
  13. | D-Link DFE-530TX PCI Fast Ethernet Adapter (rev.C)
  14. | (Microsoft's Packet Scheduler)

  从中可以看出这台机器有两块网卡, 一块叫做%1, 另一块叫做%2. 下面就可以指定网卡重发包了:
  用tcpreplay发包:

  1. [root@datatest ~]# tcpreplay -c mgcp.cach -i %1 -I %2 out.pcap

  这条命令是把out.pcap包, 按照mgcp.cach里划分的主机包和客户端包的方式, 将主机包从网卡%1发出去, 将客户端包从网卡%2发出去.

  注:修改目的IP的MAC地址的时候,MAC地址不是目的机网卡物理地址,而是源机器所连接的交换机MAC地址。

2、查看Tcpreplay里的tcprewrite的帮助文档命令

  1. [root@datatest ~]# tcprewrite -h
  2. tcprewrite (tcprewrite) - Rewrite the packets in a pcap file.
  3. Usage: tcprewrite [ -<flag> [<val>] | --<name>[{=| }<val>] ]...
  4.  
  5. -r, --portmap=str Rewrite TCP/UDP ports
    重写 tcp/udp 端口
  6.  
  7. -s, --seed=num Randomize src/dst IPv4/v6 addresses w/ given seed
    随机改写 IP 地址
  8.  
  9. -N, --pnat=str Rewrite IPv4/v6 addresses using pseudo-NAT
    通过伪 NAT 重写 ip 地址
  10.  
  11. -S, --srcipmap=str Rewrite source IPv4/v6 addresses using pseudo-NAT
  12.  
  13.  
  14. -D, --dstipmap=str Rewrite destination IPv4/v6 addresses using pseudo-NAT
  15. -e, --endpoints=str Rewrite IP addresses to be between two endpoints
  1. 在最后 2 个点之间重写 ip 地址
  1. -b, --skipbroadcast Skip rewriting broadcast/multicast IPv4/v6 addresses
    不重写广播/多播 IP 地址
  2.  
  3. -C, --fixcsum Force recalculation of IPv4/TCP/UDP header checksums
    强制重新计算 TP/RCP/UDP 校验和
  4.  
  5.  
  6. -m, --mtu=num Override default MTU length ( bytes)
  7. --mtu-trunc Truncate packets larger then specified MTU
    指定 MTU
  8.  
  9.  
  10. -E, --efcs Remove Ethernet checksums (FCS) from end of frames
  11. --ttl=str Modify the IPv4/v6 TTL/Hop Limit
  12. --tos=num Set the IPv4 TOS/DiffServ/ECN byte
  13. --tclass=num Set the IPv6 Traffic Class byte
  14. --flowlabel=num Set the IPv6 Flow Label
    删除以太网最后一帧的校验和(删除最后 2 个字节)
  15.  
  16. -F, --fixlen=str Pad or truncate packet data to match header length
  17. --fuzz-seed=num Fuzz in X packets. Edit bytes, length, or emulate packet drop
  18. --fuzz-factor=num Set the Fuzz in X packet ratio (default in packets)
  19. --skipl2broadcast Skip rewriting broadcast/multicast Layer addresses
  20. --dlt=str Override output DLT encapsulation
  21. --enet-dmac=str Override destination ethernet MAC addresses
  22. --enet-smac=str Override source ethernet MAC addresses
  23. --enet-subsmac=str Substitute MAC addresses
  24. --enet-mac-seed=num Randomize MAC addresses
  25. --enet-mac-seed-keep-bytes=num Randomize MAC addresses
  26. --enet-vlan=str Specify ethernet .1q VLAN tag mode
  27. --enet-vlan-tag=num Specify the new ethernet .1q VLAN tag value
  28. --enet-vlan-cfi=num Specify the ethernet .1q VLAN CFI value
  29. --enet-vlan-pri=num Specify the ethernet .1q VLAN priority
  30. --hdlc-control=num Specify HDLC control value
  31. --hdlc-address=num Specify HDLC address
  32. --user-dlt=num Set output file DLT type
  33. --user-dlink=str Rewrite Data-Link layer with user specified data
  34.  
  35. 填充或截取包的数据以匹配包头长度
  36.  
  37.  
  38. -i, --infile=str Input pcap file to be processed
    处理输出 pcap 文件
  39.  
  40.  
  41. -o, --outfile=str Output pcap file
    输出 pcap 文件
  42.  
  43.  
  44. -c, --cachefile=str Split traffic via tcpprep cache file
    使用 tcpprep cach 文件分离流量
  45.  
  46.  
  47. -v, --verbose Print decoded packets via tcpdump to STDOUT
    tcpdump 风格打印对应信息
  48.  
  49. -A, --decode=str Arguments passed to tcpdump decoder
  50. --skip-soft-errors Skip writing packets with soft errors
    可选参数,在使用 tcpdump 风格输出信息时,同时再调用 tcpdump 中的参数
  51.  
  52.  
  53. -V, --version Print version information
    显示版本号
  54.  
  55.  
  56. -h, --less-help Display less usage information and exit
  57. -H, --help display extended usage information and exit
  58. -!, --more-help extended usage information passed thru pager
  59. --save-opts[=arg] save the option state to a config file
  60. --load-opts=str load options from a config file
  61.  
  62. Options are specified by doubled hyphens and their name or by a single
  63. hyphen and the flag character.
  64.  
  65. Please send bug reports to: <tcpreplay-users@lists.sourceforge.net>
  66. [root@datatest ~]#

  简单地说, tcprewrite 就是改写 pcap 包里的报文头部, 包括 2 层, 3 层, 4 层,即 MAC 地址、IP 地址和PORT 等。tcpreplay 只保证能把包送出去, 至于包真正能到达的地址, 我认为还是根据原来的包的 IP 和 mac,

如果是在同一网段,可能需要把 mac 地址改成测试设备的 mac,如果需要经过网关, 就得将 IP 地址改为测试设备的 IP 以及端口号 。

  tcpreplay只保证能把包送出去, 至于包真正能到达的地址, 我认为还是根据原来的包的IP和mac. 如果是在同一网段, 可能需要把mac地址改成测试设备的mac, 如果需要经过网关, 就得将IP地址改为测试设备的IP以及端口号。
  tcprewrite的基本格式是(请注意命令中是没有换行符的, 只为了阅读的方便添加了换行符): 详请可以用tcprewrite ?命令查询详情。

  1. [root@datatest ~]# tcprewrite --enet-smac=host_src_mac,client_src_mac \
  2. --enet-dmac=host_dst_mac, client_dst_mac \
  3. --endpoints=host_dst_ip:client_dst_ip \
  4. --portmap=old_port1:new_port1,old_port2, new_port2 \
  5. | -i input.pcap -c input.cach -o out.pcap

  解释一下:

  该命令的输入参数是input.pcap和input.cach文件, 结果将另存为out.pcap文件。

  该命令将所有input.pcap包里的主机包(由input.cach文件指定哪些包是主机包, 哪些包是客户端包)的源mac地址, 目的mac地址。

   目的IP地址分别改为 :host_src_mac,host_dst_mac和host_dst_ip。

  客户端包源mac地址, 目的mac地址。

  目的IP地址分别改为 :client_src_mac, client_dst_mac和client_dst_ip。

  将端口号由old_port1改为 new_port1, 将端口号由old_port2改为new_port2。

  举个小例子

  1. [root@datatest ~]# tcprewrite --enet-smac=:::::,:::::22 \
  2. --enet-dmac=FF:FF:FF:FF:FF:FF \
  3. --endpoints=192.168.0.1:192.168.0.11 \
  4. --portmap=:,:5060 \
  5. -i success.pcap -o out.pcap -c success.cach

  该命令将修改后的包的

  主机端的二层, 三层, 四层头分别为: 11:22:22:22:22:22,192.168.0.1,5061,

  客户端包的二层, 三层, 四层头分别为: 22:22:22:22:22:22,192.168.0.11, 5060。

  1. [root@datatest ~]# tcprewrite --seed= -i success.pcap -o out.pcap -c success.cach

  该命令将根据数字 6 按特征算法生成一个新的 server_ip 和 client_ip。

  1. [root@datatest ~]# tcprewrite --pmap=192.168.0.0/:10.77.0.0/,172.16.0.0/:10.1.0.0/24 \
  2. -i success.pcap -o out.pcap -c success.cach

  该命令将把主机端和客户端 192.168.0.0/16、172.16.0.0/12 网段的 ip 地址分别改为 10.77.0.0/16、10.1.0.0/24。

  1. [root@datatest ~]# tcprewrite --srcipmap=192.168.0.0/:10.77.0.0/16 \
  2. -i success.pcap -o out.pcap -c success.cach

  该命令将把主机端和客户端的源 ip 为 192.168.0.0/16 网段改为 10.77.0.0/16 网段

  1. [root@datatest ~]# tcprewrite --dstipmap=172.16.0.0/:10.1.0.0/
  2. -i success.pcap -o out.pcap -c success.cach

  该命令将把主机端和客户端的目的 ip 为 192.168.0.0/16 网段改为 10.77.0.0/16 网段。

  修改2层头

    1) 修改MAC地址
    如果不指定cache文件, 将把所有包的源mac地址和目的mac地址都改写成00:44:66:FC:29:AF和00:55:22:AF:C6:37:

  1. [root@datatest ~]# tcprewrite --enet-dmac=:::AF:C6: --enet-smac=:::FC::AF --infile=input.pcap --outfile=output.pcap

  指定cache文件后, 将server包的目的/源mac地址改写成00:44:66:FC:29:AF/00:66:AA:D1:32:C2,

          将client的目的/源mac地址改成:00:55:22:AF:C6:37/00:22:55:AC:DE:AC, 注意是server地址在前.

  1. [root@datatest ~]# tcprewrite --enet-dmac=:::FC::AF,:::AF:C6: --enet-smac=::AA:D1::C2,:::AC:DE:AC --cachefile=input.cache --infile=input.pcap --outfile=output.pcap

  2) 修改802.1q VLAN
  经常客户的抓包带有VLAN头域, 这些包如果不去掉VLAN头是没有办法在自己的交换机上replay的, tcprewrite提了去掉或添加VLAN的方法:
    去掉vlan很简单:

  1. [root@datatest ~]# tcprewrite --enet-vlan=del --infile=input.pcap --outfile=output.pcap

  

  添加vlan也很简单, 下面的命令将VLAN tag设成40, CFI设成1, VLAN priority设成4.

  1. [root@datatest ~]# tcprewrite --enet-vlan=add --enet-vlan-tag= --enet-vlan-cfi= --enet-vlan-pri= --infile=input.pcap --outfile=output.pcap

  3) 修改二层协议名:
  好像是将Ethernet协议头转成Cisco HDLC或其它二层协议? 这部分没有真正用过, 需要的
人自行参考tcpreplay官方网站: http://tcpreplay.synfin.net/wiki/manual

修改3层头
  从版本3.4.2开始, tcprewrite开始支持ipv6协议, tcpreplay升级蛮快。 tcprewrite修改IP地址后会自动帮你计算校验和, 这点还是蛮周到的。

  命令行传入IPv6地址的时候要使用方括号, 例如: [2001::dead:beef]或[2001::/16]

  1) 修改目的IP
  根据cache文件里的标识, 将server的IP改为10.10.1.1, client的IP改为10.10.1.2:

  1. [root@datatest ~]# tcprewrite --endpoints=10.10.1.1:10.10.1.2 --cachefile=input.cache --infile=input.pcap --outfile=output.pcap --skipbroadcast

  2)修改IP地址的网络部分
    注: 2)和3)没有验证过。

    众所周知, IP地址同网络部分和主机部分组成, 下面的命令可以将子网地址为10.0.0.0/8或192.168.0.0/16的IP改成子网为172.16.0.0/12:

  1. [root@datatest ~]# tcprewrite --pnat=10.0.0.0/:172.16.0.0/,192.168.0.0/:172.16.0.0/ --infile=input.pcap --outfile=output.pcap --skipbroadcast

  下面的命令是基于client包或server包修改子网地址:

  1. [root@datatest ~]# tcprewrite --pnat=10.0.0.0/:192.168.0.0/ --pnat=10.0.0.0/:192.168.1.0/ --cachefile=input.cache --infile=input.pcap --outfile=output.pcap --skipbroadcast

  3) 修改IP头的其它部分:
  

  修改IPv4头的TOS为50

  1. [root@datatest ~]# tcprewrite --tos= --infile=input.pcap --outfile=output.pcap

  将IPv6头Traffic Class值改为33

  1. [root@datatest ~]# tcprewrite --tclass= --infile=input.pcap --outfile=output.pcap

  修改Flow Label field:

  1. [root@datatest ~]# tcprewrite --flowlabel= --infile=input.pcap --outfile=output.pcap

修改4层头
  和修改IP头一样, 修改4层头的时候tcpwrite会自动计算校验和, 这个就不需要担心了.

  1) 修改端口号
    将80端口号改为8080, 22改为8022:

  1. [root@datatest ~]# tcprewrite --portmap=:,: --infile=input.pcap --outfile=output.pcap

  2) 强制计算传输层校验和:
  有些应用可能不计算传输层的校验和, 可以让tcpwrite强制计算一下:

  1. [root@datatest ~]# tcprewrite --fixcsum --infile=input.pcap --outfile=output.pcap

  修改5-7层数据
  tcpwrite对5-7层的修改非常有限, 顶多也就是抓包没有抓全, 中间的应用层数据丢了。tcpwrite将没有抓到的数据补成全0, 或者修改tcp/udp的长度字节, 或者将该包丢弃. 有需要的直接参考官方资料吧。

3、查看Tcpreplay里的tcpprep的帮助文档命令

  1. [root@datatest ~]# tcpprep -h
  2. tcpprep (tcpprep) - Create a tcpreplay cache cache file from a pcap file.
  3. Usage: tcpprep [ -<flag> [<val>] | --<name>[{=| }<val>] ]...
  4.  
  5. -a, --auto=str Auto-split mode
    一般情况下都需要的参数,表示按模式自动分离通信流量生成 cach 文件
  6. -c, --cidr=str CIDR-split mode
    可选参数, 表示分离流量时采用 CIDR(无类别域间路由选择,是一个在 internet
    上创建附加地址的方法,这些地址提供给服务提供商,再由服务提供商分配给客户。
    CIDR 将路由集中起来,使一个 IP 地址代表主要骨干提供商提供的几千个 IP 地址,
    从而减轻 internet 路由器的负担)
  7. -r, --regex=str Regex-split mode
    可选参数,表示使用 regex 模式分离通信流量,有点类似于 CIDR 模式,但是它匹
    配的是服务器源 IP
  8. -p, --port Port-split mode
    可选参数,基于目的端口来分离通信流量,它区分的依据是任何 0-1023 端口都是
    服务器的端发出的报文,其他的端口都是客户端发出的报文
  9. -e, --mac=str Source MAC split mode
    表示基于服务器源 MAC 地址分离通信流量 
  10. --reverse Matches to be client instead of server
  11. -C, --comment=str Embedded cache file comment
    可选参数,表示在 cach 文件中嵌入注释内容,用于注释说明 cach 文件的内容。使用位置不要放在最后,生成 cach 后可以使用-P 查看写入的内容。
  12.  
  13. --no-arg-comment Do not embed any cache file comment
  14. -x, --include=str Include only packets matching rule
    重要可选参数,表示按照参数定义的需求来定义发送报文
  15. -X, --exclude=str Exclude any packet matching this rule
    可选参数,是-x 的取反
  16. -o, --cachefile=str Output cache file

生成 cach 文件必带参数,后跟 cach 后缀的文件名,表示这个输出的 cach 文
件以这个文件名命名

  1. -i, --pcap=str Input pcap file to process

生成 cach 文件必带参数,后跟 pcap 文件名,表示这个 pcap 文件需要处理

  1. -P, --print-comment=str Print embedded comment in the specified cache file
    可选参数,表示查看 cach 文件的内容
  2. -I, --print-info=str Print basic info from the specified cache file
    表示打印 cach 文件的基本信息
  3.  
  4. -S, --print-stats=str Print statistical information about the specified cache file
    表示打印 cach 文件的统计信
  5. -s, --services=str Load services file for server ports

表示从服务器端口下载服务文件

  1. -N, --nonip Send non-IP traffic out server interface
    表示从服务器端口发送无 IP 流量
  2.  
  3. -R, --ratio=str Ratio of client to server packets

  可选参数,一个比例值。服务器端发起的连接数和客户端发起的连接数的比例,值
大于 2 就视为服务器端

  1. -m, --minmask=num Minimum network mask length in auto mode
    可选参数,在选用 router 模式时使用,表示最小掩码,掩码默认是 30
  2.  
  3. -M, --maxmask=num Maximum network mask length in auto mode
    可选参数,在选用 router 模式时使用,表示最大掩码,默认是 8
  4.  
  5. -v, --verbose Print decoded packets via tcpdump to STDOUT
    可选参数,显示 tcpprep 生成 cach 文件的处理过程。信息的随时大于
  6.  
  7. -A, --decode=str Arguments passed to tcpdump decoder
    可选参数,在实验 tcpdump 风格打印输出信息时,同时再调用 tcpdump 中的参数
  8.  
  9. -V, --version Print version information
  10. -h, --less-help Display less usage information and exit
  11. -H, --help display extended usage information and exit
  12. -!, --more-help extended usage information passed thru pager
  13. --save-opts[=arg] save the option state to a config file
  14. --load-opts=str load options from a config file
  15. Options are specified by doubled hyphens and their name or by a single
  16. hyphen and the flag character.
  17. tcpprep is a 'pcap(3)' file pre-processor which creates a cache file which
  18. provides "rules" for 'tcprewrite(1)' and 'tcpreplay(1)' on how to process
  19. and send packets.
  20.  
  21. Please send bug reports to: <tcpreplay-users@lists.sourceforge.net>
  22. [root@datatest ~]#

  tcpprep 是一个在 tcprewrite 和 tcpreplay 之前使用的 pcap 文件的处理程序。使用 tcpprep 的目的就是建立一个 cach 文件,用于分离通信流量中的两方(通常叫做 主要的/次要的 或者 客户端/服务器),为 tcprewrite 和 tcpreplay 处理与发送报文做准备。

  如果你正打算在两块网卡上使用 tcpreplay 的话,那么 tcpprep 就是用来决定每一个报文(packet)从哪一个接口发出。通过使用这样一个分离的程序来建立一个 cach 文件,tcpreplay 就可以根据这个 cach 文件通过自身的计算来分离流量,高速率的发送报文。cach 文件的作用主要是加速报文的发送,cach 文件中存放着 pcap 文件中每个帧的编号和时间戳等信息,以达到 tcpreplay 回放时可以更加快速的发送报文的目的。

  举个例子, 如果你用 wireshark 或者ethereal抓了一个 pcap 文件,里面可能既有 A 地址发给 B 地址的包,也有 B地址发给 A 址的包,用 tcpprep 工具可以指定从 A 到 B 的包从主网卡发出, 从 B 到 A 的包从次网卡发出。

  
  tcpprep 用法举例
1、根据报文源 IP 确定 client/server 报文

  1. [root@datatest ~]# tcpprep -c 172.22.64.2/24 -i mgcp.pcap -o mgcp.cach 

  上面的命令指定所有源 IP 为 172.22.64.2/24 的包, 都将从主网卡发出, 其它的从次网卡发出 。输入文件是mgcp.pcap, 输出文件为mgcp.cach。

2、使用自动模式确定 client/server 报文

  1. [root@datatest ~]# tcpprep -a client -i mgcp.pcap -o mgcp.cach

  上面的命令采用自动/client 模式指定分包模式。

  自动模式这里按我的理解解释一下:
  tcpprep 在自动模式下认为有下面行为的 IP 为 client 端:

    1、发 TCP SYN 包的一方

    2、发 DNS 包的一方

    3、 收入到 ICMP-Port Unreachable 的一方;

认为有下面行为的一方为 server 端:

    1、发 TCPSyn/Ack 的一方

    2、发 DNS 应答的一方

    3、发 ICMP-Port Unreachable 的一方

  而被认定为 server 的那一方发的那些包, 将从主网卡发出, 被认定为 client 的包则从次网卡发出. 而自动/client 模式将所有没有认出的包都归为 client, 同理自动/server 模式将没有认出的包都归为 server.这种模式貌似不如按 IP 地址分类的方式好用 。

  

4、查看Tcpreplay里的tcpreplay-edit的帮助文档命令

  1. [root@datatest ~]# tcpreplay-edit -h
  2. tcpreplay (tcpreplay) - Replay network traffic stored in pcap files
  3. Usage: tcpreplay-edit [ -<flag> [<val>] | --<name>[{=| }<val>] ]... <pcap_file(s)>
  4.  
  5. -r, --portmap=str Rewrite TCP/UDP ports
  6. -s, --seed=num Randomize src/dst IPv4/v6 addresses w/ given seed
  7. -N, --pnat=str Rewrite IPv4/v6 addresses using pseudo-NAT
  8. -S, --srcipmap=str Rewrite source IPv4/v6 addresses using pseudo-NAT
  9. -D, --dstipmap=str Rewrite destination IPv4/v6 addresses using pseudo-NAT
  10. -e, --endpoints=str Rewrite IP addresses to be between two endpoints
  11. -b, --skipbroadcast Skip rewriting broadcast/multicast IPv4/v6 addresses
  12. -C, --fixcsum Force recalculation of IPv4/TCP/UDP header checksums
  13. -m, --mtu=num Override default MTU length ( bytes)
  14. --mtu-trunc Truncate packets larger then specified MTU
  15. -E, --efcs Remove Ethernet checksums (FCS) from end of frames
  16. --ttl=str Modify the IPv4/v6 TTL/Hop Limit
  17. --tos=num Set the IPv4 TOS/DiffServ/ECN byte
  18. --tclass=num Set the IPv6 Traffic Class byte
  19. --flowlabel=num Set the IPv6 Flow Label
  20. -F, --fixlen=str Pad or truncate packet data to match header length
  21. --fuzz-seed=num Fuzz in X packets. Edit bytes, length, or emulate packet drop
  22. --fuzz-factor=num Set the Fuzz in X packet ratio (default in packets)
  23. --skipl2broadcast Skip rewriting broadcast/multicast Layer addresses
  24. --dlt=str Override output DLT encapsulation
  25. --enet-dmac=str Override destination ethernet MAC addresses
  26. --enet-smac=str Override source ethernet MAC addresses
  27. --enet-subsmac=str Substitute MAC addresses
  28. --enet-mac-seed=num Randomize MAC addresses
  29. --enet-mac-seed-keep-bytes=num Randomize MAC addresses
  30. --enet-vlan=str Specify ethernet .1q VLAN tag mode
  31. --enet-vlan-tag=num Specify the new ethernet .1q VLAN tag value
  32. --enet-vlan-cfi=num Specify the ethernet .1q VLAN CFI value
  33. --enet-vlan-pri=num Specify the ethernet .1q VLAN priority
  34. --hdlc-control=num Specify HDLC control value
  35. --hdlc-address=num Specify HDLC address
  36. --user-dlt=num Set output file DLT type
  37. --user-dlink=str Rewrite Data-Link layer with user specified data
  38. -q, --quiet Quiet mode
  39. -T, --timer=str Select packet timing mode: select, ioport, gtod, nano
  40. --maxsleep=num Sleep for no more then X milliseconds between packets
  41. -v, --verbose Print decoded packets via tcpdump to STDOUT
  42. -A, --decode=str Arguments passed to tcpdump decoder
  43. -K, --preload-pcap Preloads packets into RAM before sending
  44. -c, --cachefile=str Split traffic via a tcpprep cache file
  45. -, --dualfile Replay two files at a time from a network tap
  46. -i, --intf1=str Client to server/RX/primary traffic output interface
  47. -I, --intf2=str Server to client/TX/secondary traffic output interface
  48. --listnics List available network interfaces and exit
  49. -l, --loop=num Loop through the capture file X times
  50. --loopdelay-ms=num Delay between loops in milliseconds
  51. --pktlen Override the snaplen and use the actual packet len
  52. -L, --limit=num Limit the number of packets to send
  53. --duration=num Limit the number of seconds to send
  54. -x, --multiplier=str Modify replay speed to a given multiple
  55. -p, --pps=str Replay packets at a given packets/sec
  56. -M, --mbps=str Replay packets at a given Mbps
  57. -t, --topspeed Replay packets as fast as possible
  58. -o, --oneatatime Replay one packet at a time for each user input
  59. --pps-multi=num Number of packets to send for each time interval
  60. --unique-ip Modify IP addresses each loop iteration to generate unique flows
  61. --unique-ip-loops=str Number of times to loop before assigning new unique ip
  62. -!, --no-flow-stats Suppress printing and tracking flow count, rates and expirations
  63. -", --flow-expiry=num Number of inactive seconds before a flow is considered expired
  64. -P, --pid Print the PID of tcpreplay at startup
  65. -#, --stats=num Print statistics every X seconds, or every loop if ''
  66. -V, --version Print version information
  67. -h, --less-help Display less usage information and exit
  68. -H, --help display extended usage information and exit
  69. -!, --more-help extended usage information passed thru pager
  70. -$, --save-opts[=arg] save the option state to a config file
  71. -%, --load-opts=str load options from a config file
  72.  
  73. Options are specified by doubled hyphens and their name or by a single
  74. hyphen and the flag character.
  75. tcpreplay is a tool for replaying network traffic from files saved with
  76. tcpdump or other tools which write pcap() files.
  77.  
  78. Please send bug reports to: <tcpreplay-users@lists.sourceforge.net>
  79. [root@datatest ~]#

  tcpreplay-edit 实时修改包数据并回放,它是将 tcprewrite 和 tcpreplay 用一条命令实现。其好处是修改包数据不会新生成 pcap 文件。如果是需要不断的改写一个包文件并回放建议使用 tcpreplay-edit,如果是需要一次改写一个包文件并多次回放建议使用 tcprewrite 和 tcpreplay 的结合,这样具有更好的回放速率。

  tcpreplay-edit小例子

  编写脚本,不断改写包文件的 IP 地址并回放:

  比如,你自己写个test.sh脚本,然后赋予chmod 777 test.sh。执行就是

  1. for i in {..}
  2. do
  3. tcpreplay-edit --endpoints=1.1..$i:1.1.1.2 -t -i eth2 -I eth1 -c edit.cach edit.pcap
  4. done

5、查看Tcpreplay里的tcpliveplay的帮助文档命令

  1. [root@datatest ~]# tcpliveplay -H
  2. tcpliveplay (tcpliveplay) - Replays network traffic stored in a pcap file on live networks using new TCP connections
  3. Usage: tcpliveplay [ -<flag> [<val>] | --<name>[{=| }<val>] ]... \
  4. <eth0/eth1> <file.pcap> <Destinatin IP [1.2.3.4]> <Destination mac [0a:1b:2c:3d:4e:5f]> <'random' dst port OR specify dport #>
  5.  
  6. -V, --version Print version information
  7. -h, --less-help Display less usage information and exit
  8. -H, --help display extended usage information and exit
  9. -!, --more-help extended usage information passed thru pager
  10. --save-opts[=arg] save the option state to a config file
  11. --load-opts=str load options from a config file
  12. - disabled as '--no-load-opts'
  13. - may appear multiple times
  14.  
  15. Options are specified by doubled hyphens and their name or by a single
  16. hyphen and the flag character.
  17. This program, 'tcpliveplay' replays a captured set of packets using new TCP
  18. connections with the captured TCP payloads against a remote host in order
  19. to do comprehensive vulnerability testings.
  20.  
  21. The following option preset mechanisms are supported:
  22. - reading file /usr/bin/.tcpliveplayrc
  23. The basic operation of tcpliveplay is it rewrites the given pcap file in a
  24. scheduled event format and responds with the apporiate packet if the remote
  25. host meets tcp protocal's SEQ/ACK expectation. Once expectations are met,
  26. then the local packets are sent with the same payload except with new tcp
  27. SEQ & ACK numbers meeting the response from the remote hose.
  28.  
  29. The inputted pcap file are rewritten to start at the first encounter of the
  30. SYN packet for correct operation making this packet be the first action in
  31. the event schedule of local host doing the replay.
  32.  
  33. For more details, please see the Tcpreplay Manual at:
  34. http://tcpreplay.appneta.com
  35. [root@datatest ~]#

6、查看Tcpreplay里的tcpbridge的帮助文档命令

  1. [root@datatest ~]# tcpbridge -h
  2. tcpbridge (tcpbridge) - Bridge network traffic across two interfaces
  3. Usage: tcpbridge [ -<flag> [<val>] | --<name>[{=| }<val>] ]...
  4.  
  5. -r, --portmap=str Rewrite TCP/UDP ports
  6. -s, --seed=num Randomize src/dst IPv4/v6 addresses w/ given seed
  7. -N, --pnat=str Rewrite IPv4/v6 addresses using pseudo-NAT
  8. -S, --srcipmap=str Rewrite source IPv4/v6 addresses using pseudo-NAT
  9. -D, --dstipmap=str Rewrite destination IPv4/v6 addresses using pseudo-NAT
  10. -b, --skipbroadcast Skip rewriting broadcast/multicast IPv4/v6 addresses
  11. -C, --fixcsum Force recalculation of IPv4/TCP/UDP header checksums
  12. -m, --mtu=num Override default MTU length ( bytes)
  13. --mtu-trunc Truncate packets larger then specified MTU
  14. -E, --efcs Remove Ethernet checksums (FCS) from end of frames
  15. --ttl=str Modify the IPv4/v6 TTL/Hop Limit
  16. --tos=num Set the IPv4 TOS/DiffServ/ECN byte
  17. --tclass=num Set the IPv6 Traffic Class byte
  18. --flowlabel=num Set the IPv6 Flow Label
  19. -F, --fixlen=str Pad or truncate packet data to match header length
  20. --fuzz-seed=num Fuzz in X packets. Edit bytes, length, or emulate packet drop
  21. --fuzz-factor=num Set the Fuzz in X packet ratio (default in packets)
  22. --skipl2broadcast Skip rewriting broadcast/multicast Layer addresses
  23. --dlt=str Override output DLT encapsulation
  24. --enet-dmac=str Override destination ethernet MAC addresses
  25. --enet-smac=str Override source ethernet MAC addresses
  26. --enet-subsmac=str Substitute MAC addresses
  27. --enet-mac-seed=num Randomize MAC addresses
  28. --enet-mac-seed-keep-bytes=num Randomize MAC addresses
  29. --enet-vlan=str Specify ethernet .1q VLAN tag mode
  30. --enet-vlan-tag=num Specify the new ethernet .1q VLAN tag value
  31. --enet-vlan-cfi=num Specify the ethernet .1q VLAN CFI value
  32. --enet-vlan-pri=num Specify the ethernet .1q VLAN priority
  33. --hdlc-control=num Specify HDLC control value
  34. --hdlc-address=num Specify HDLC address
  35. --user-dlt=num Set output file DLT type
  36. --user-dlink=str Rewrite Data-Link layer with user specified data
  37. -i, --intf1=str Primary interface (listen in uni-directional mode)
  38. -I, --intf2=str Secondary interface (send in uni-directional mode)
  39. -u, --unidir Send and receive in only one direction
  40. --listnics List available network interfaces and exit
  41. -L, --limit=num Limit the number of packets to send
  42. -M, --mac=str MAC addresses of local NIC's
  43. -x, --include=str Include only packets matching rule
  44. -X, --exclude=str Exclude any packet matching this rule
  45. -P, --pid Print the PID of tcpbridge at startup
  46. -v, --verbose Print decoded packets via tcpdump to STDOUT
  47. -A, --decode=str Arguments passed to tcpdump decoder
  48. -V, --version Print version information
  49. -h, --less-help Display less usage information and exit
  50. -H, --help display extended usage information and exit
  51. -!, --more-help extended usage information passed thru pager
  52. --save-opts[=arg] save the option state to a config file
  53. --load-opts=str load options from a config file
  54.  
  55. Options are specified by doubled hyphens and their name or by a single
  56. hyphen and the flag character.
  57. tcpbridge is a tool for selectively briding network traffic across two
  58. interfaces and optionally modifying the packets in between
  59.  
  60. Please send bug reports to: <tcpreplay-users@lists.sourceforge.net>
  61. [root@datatest ~]#

7、查看Tcpreplay里的tcppcpinfo的帮助文档命令

  1. [root@datatest ~]# tcpcapinfo -h
  2. /usr/bin/tcpcapinfo: illegal option -- h
  3. tcpcapinfo (Tcpreplay Suite) - Pcap file dissector for debugging broken pcap files
  4. Usage: tcpcapinfo [ -<flag> [<val>] | --<name>[{=| }<val>] ]... <pcap_file(s)>
  5.  
  6. -V, --version Print version information
  7. -H, --help display extended usage information and exit
  8. -!, --more-help extended usage information passed thru pager
  9.  
  10. Options are specified by doubled hyphens and their name or by a single
  11. hyphen and the flag character.
  12. tcpcapinfo is a tool for decoding the structure of a pcap() file with a
  13. focus on finding broken pcap files and determining how two related pcap
  14. files might differ.
  15.  
  16. Please send bug reports to: <tcpreplay-users@lists.sourceforge.net>
  17. [root@datatest ~]#

 Tcpreplay总结 (以下只是一个小例子来完整跑一遍)

  通过 Tcpreplay 来修改、转发通信流量需要考虑的一共需要考虑以下 3 点:
    1、 确定哪有数据包是从客户端到服务器端的,哪有是从服务器端到客户端的
    2 、确定新的 MAC、IP、Port
    3、确定回放速率、循环次数、执行方式

  第一步:
    用 tcpreplay 分离源/目的端口的流量。

  1. tcpprep --port --cachfile=example.cach --pcap=example.pcap

  这种情况下,认为所有目的端口小于1024 的,将被视为客户端->服务器的包。

        认为所有目的端口大于1024 的,否则视为服务器->客户端的包。

  该信息被存储在 tcpprp 的一个名叫 example.cach 的文件夹中。
  --port 根据端口号区分数据包的流向。
  --cachfile 指定输出的 cach 文件的名字,即在这里要输出为example.cach
  --pcap 指定要处理的数据包文件,即在这里要处理的是example.pcap。
  其实。tcpprep 支持许多的其他的模式,分离端口模式是其中的一种
。也就是说,第一步,大家自行选择。

  第二步:
  使用 tcprewrite 更改 ip 地址到本地网络:

  1. $ tcprewrite --endpoints=172.16.0.1:172.16.5.35 --cachfile=example.cach --infile=example.pcap --outfile=new.pcap

  这个例子里,我们想要所有的流量来自于 172.16.0.1 和 172.16.5.35。我们想要一个 IP 是“客户端”,一个 IP 是“服务器端 。

  tcprewrite 改写数据包:
    --endpoints 指定数据包的 client、server 端的 ip 地址
    --cachfie 上一步预处理的输出文件,即example.cach
    --infile 输入 pcap 文件,即example.pcap。
    --outfile 改写后的 pcap 文件
,即new.pcap。

  第三步:用 tcpreplay,发送流量通过服务提供商

  1. tcpreplay --intf1=eth0 --intf2=eth1 --cachfile=example.cach new.pcap

  因为我们要分离 2 个接口(eth0 和 eth1)之间的通信,我们使用第一步中创建的 cach 文件,第二步中创建的 new.pacp。
  然后使用 tcpreplay 重发数据包。

  如果大家还是不明白,我就再详细的讲个案例。
  见

基于CentOS6.5下如何正确安装和使用Tcpreplay来重放数据(图文详解)的更多相关文章

  1. 基于CentOS6.5下snort+barnyard2+base的入侵检测系统的搭建(图文详解)(博主推荐)

    为什么,要写这篇论文? 是因为,目前科研的我,正值研三,致力于网络安全.大数据.机器学习研究领域! 论文方向的需要,同时不局限于真实物理环境机器实验室的攻防环境.也不局限于真实物理机器环境实验室的大数 ...

  2. 如何在Eclipse中正确安装Jetty插件并初步使用(图文详解)

    不多说,直接上干货! 最近在做一个Storm项目,需要用到Jetty来进行展示.它类似于Tomcat. 一.eclipse中jetty插件安装 打开eclipse,依次点击菜单Help->Ecl ...

  3. Git学习系列之Windows上安装Git之后的一些配置(图文详解)

    不多说,直接上干货! 前面博客 Git学习系列之Windows上安装Git详细步骤(图文详解) 第一次使用Git时,需要对Git进行一些配置,以方便使用Git. 不过,这种配置工作只需要进行一次便可, ...

  4. 全网最详细的Sublime Text 3的安装Package Control插件管理包(图文详解)

    不多说,直接上干货! 全网最详细的Windows里下载与安装Sublime Text *(图文详解) 全网最详细的Sublime Text 3的激活(图文详解) 全网最详细的Sublime Text ...

  5. CentOS 6.6下JDK1.7安装与配置(Linux)经典入门详解案例

    最近用的linux较多,在网站找了一些关于linux环境下jdk安装的教程,过程是有的但是好多细节都没有表现出来,所以我花了点时间总结了一下,希望对大家都有帮助... CentOS下JDK1.7安装与 ...

  6. 全网最全的Windows下Anaconda2 / Anaconda3里正确下载安装用来定时任务apscheduler库(图文详解)

    不多说,直接上干货!  Anaconda2 里 PS C:\Anaconda2\Scripts> PS C:\Anaconda2\Scripts> pip.exe install apsc ...

  7. Vmware workstation12里如何正确快速安装可视化IDS系统Security Onion(图文详解)

    不多说,直接上干货! 首先,大家要明确: 问:安全洋葱能阻止入侵吗? 答:这一点,和OSSIM一样,不能阻止入侵. Security Onion基于Ubuntu,包含了入侵检测.网络安全监控.日志管理 ...

  8. Ubuntu14.04下编译安装或apt-get方式安装搭建Apache或Httpd服务(图文详解)

    不多说,直接上干货! 写在前面的话 对于 在Ubuntu系统上,编译安装Apache它默认路径是在/usr/local/apache2/htdocs 或者编译安装httpd它默认路径是在/usr/lo ...

  9. IDEA里如何安装Python插件打造开发环境(图文详解)

    前言 python是一种功能强大和适用面很广的开发语言,在大数据应用和机器学习日益流行的年代,python凭借其简洁.易用和可扩展性获得很多用户的支持,近年来使用率高速增长.python环境下,集成了 ...

随机推荐

  1. ufldl学习笔记与编程作业:Logistic Regression(逻辑回归)

    ufldl学习笔记与编程作业:Logistic Regression(逻辑回归) ufldl出了新教程,感觉比之前的好,从基础讲起.系统清晰,又有编程实践. 在deep learning高质量群里面听 ...

  2. Webapp兼容性布局

  3. Poi 操作 Excel

    http://blog.csdn.net/chenglc1612/article/details/53413445   一. POI简介              Apache POI是Apache软 ...

  4. JDBC+XML+DOM4J

    利用xml文件封装数据库配置信息xml文件放在src目录下/testjdbc1/src/DBUtil.xml <?xml version="1.0" encoding=&qu ...

  5. leetcode 656. Coin Path

    Given an array A (index starts at 1) consisting of N integers: A1, A2, ..., AN and an integer B. The ...

  6. bzoj5333: [Sdoi2018]荣誉称号

    请不要去改题目给的输入,不然你会wa穿... 这么故弄玄虚的题目,肯定要先转换问题 看到这个不断的除2想起别人家的线段树的写法...x的两个孩子是x<<1和x<<1|1 然后问 ...

  7. 关于数论【polya计数法】

    可以预见数论推公式是有多么蛋疼. 让我简明扼要的讲讲吧(多都说不出来,毕竟才做了两道题)其实呢,这个算法应该归入群论,有个有用的东西:置换群,它表示一个集合包括很多的置换.先讲讲置换吧:↓(这是个置换 ...

  8. ZOJ1610 Count the Colors —— 线段树 区间染色

    题目链接:https://vjudge.net/problem/ZOJ-1610 Painting some colored segments on a line, some previously p ...

  9. 工作笔记——sqlserver引号的运用

    一. sqlserver引号问题:因为要使用远程连接,所以sql语句要用单引号括起来 SELECT * FROM OPENQUERY ([192.168.***.***] ,'select * fro ...

  10. 软件开发-MSF方法(《构建之法》读书笔记2)

    MSF-微软解决方案框架,是一套大型系统开发指南,它描述了如何用组队模型.过程模型和应用模型来开发Client/Server结构的应用程序,是在微软的工具和技术的基础上建立并开发分布式企业系统应用的参 ...