tcpdump学习笔记

安卓手机抓包学习笔记-tcpdump 设备:htc手机  android2.3.5版本 目标:对手机中安装的app应用进行抓包 步骤: 1.手机已被成功root 2.下载抓包程序tcpdump 3下载sdk并解压,配置环境变量将sdk中adb所在的路径添加到path中 E:\anzhuo\android-sdk_r14-windows\android-sdk-windows\platform-tools  rem 阅读详情

1)常用命令选项

在tcpdump 最后面加表达式可以过滤 

-h 命令帮助

-D 查看哪些网卡可以抓包

-n  显示ip地址

 -i 指定使用哪个网卡

-v 显示详细信息   -vvv  v更多更详细

-c  显示前几个数据包

-t   不显示时间

-q  只显示重要内容

-ttt 显示和上一个包的相对时间      

-ttttt

-e 显示mac地址

 

2)审查packet内容

-A 显示包内容 ascii码方式

-XX 二进制方式显示

 

3)保存为pcap文件

-w  xxxx.pcap 二进制文件

tcpdump  -r  xxxx.pcap 读取文件  [-A|-XX]

 

4)过滤表达式  在命令行最后面

过滤类型:

port  端口号

host  ip地址

net 192.168.31   抓取某网段

net 192.168.31.0/24

 

协议修饰符

udp 只抓取udp协议的

tcp 只抓取tcp协议的

icmp

 

过滤方向:没有写方向 代表双向都抓取出来

src 过滤类型

dst 过滤类型

例子:tcpdump -i eth0 -n tcp src port 53

 

复杂:

or  或者 ||

and 或者 &&

not 或者 !

例子:tcpdump -i eth0 -n port 53 or port 54 

表达式最好用' ' 括起来,因为( ) 在shell要转义 可以使用/

tcpdump -i eth0 -n 'src host 192.168.0.100 and (dst port 53 or dst port 54)' 

tcpdump -i eth0 -n 'src host 192.168.0.100 and (dst port 53 or 54)' 

 

5)分析三次握手

步骤1

tcpdump -i eth0 -n -c 3 -XX  'host 192.168.31.1 and port 80'

步骤2

curl http://192.168.31.1:80

 

有以下标志的包

Flags[S] 代表syn包

Flags[S.] 代表syn 和ack包

Flags[.] 代表ack包

 

5)配合wireshark使用(mac下), 以下实例是达到远端没有wireshark,但把包实时取回本地分析

‘-’代表输出到标准输出

ssh root@192.168.31.1 'tcpdump -i eth0 -n -c 3 -w - host 192.168.31.1 and port 80' |wireshark -k -i -

实时抓取,wireshark 中不断更新抓到的包

ssh root@192.168.31.1 'tcpdump -i eth0 -n  -w - host 192.168.31.1 and port 80' |wireshark -k -i -

 

Fuzzing101 Exercise 3 - TCPdump 学习笔记 本篇文章主要记录Fuzzing101 Exercise 3 - TCPdump的学习过程,本次练习展示如下知识点:什么是ASAN(Address Sanitizer)、如何使用ASAN对目标进行模糊测试、ASAN对崩溃分类展示情况(~~后续可能单独出一章~~) 编写不易,如果能够帮助到你,希望能够点赞收藏加关注哦Thanks♪(・ω・)ノ 阅读详情

相关推荐

kbjdbc: autodetected server-encoding to be ISO-8859-1, if the message is not readable, please check

这条信息是来自 KingbaseES 数据库的一个 JDBC 客户端连接提示。KingbaseES 是一个企业级的关系型数据库管理系统,它兼容 PostgreSQL 的许多特性。如果上述步骤仍然无法解决问题,建议详细查看数据库和客户端的日志文件,以获取更具体的错误信息。此外,也可以考虑联系 KingbaseES 的技术支持获取帮助。项目融合kingbase数据库,输出日志乱码。结果:网上各种调整各种试。

zjy660358的专栏 4844

最全的tcpdump使用详解

TCPDump可以将网络中传送的数据包完全截获下来提供分析。它支持针对网络层、协议、主机、网络或端口的过滤,并提供and、or、not等逻辑语句来帮助你去掉无用的信息。

玩IT的川 5765

什么是plm系统?-数字化转型网

当今世界,产品研发能力是企业在激烈的市场竞争中保持战略优势的核心竞争力之一。如何有效地缩短产品研发周期、改善产品服务的设计迭代流程、有效降低产品的研发成本,也是企业面临的主要问题之一。PLM(Product Lifecycle Management,产品生命周期管理)在优化产品研发的全管理流程、增强企业产品的市场竞争力方面具有关键的作用。

cxo17757154043的博客 883

tcpdump 精华学习笔记

一、Tcpdump简介        Tcpdum是Linux上强大的网络数据采集分析工具        1.1 第一种类型的关键字:host    net     port                    host 210.27.48.3指明 210.27.48.3是一台主机       net202.0.0.0 指明202.0.0.0 是一个网络地址   port 23 指明端口23  ...

weixin_34268579的博客 237

Windows平台无人机仿真:从零搭建SITL环境与QGC联调

本文详细指导了在Windows平台上从零搭建无人机软件在环(SITL)仿真环境,并与QGroundControl(QGC)进行联调的完整流程。通过使用Cygwin工具链,开发者可以在没有实体硬件的情况下,模拟运行ArduPilot飞控,并通过MAVLink协议连接QGC地面站进行全功能测试,为无人机软件开发提供了一个安全、经济的虚拟沙盒环境。

weixin_29239279的博客 411

保姆级教程:用Vue3+Element Plus快速搭建Flowable流程定义管理后台界面

本文提供了一份详细的Vue3+Element Plus教程,指导开发者快速搭建Flowable流程定义管理后台界面。从项目初始化、核心页面设计到响应式数据处理,全面覆盖前端开发关键步骤,帮助提升企业级应用开发效率。

weixin_42662293的博客 480

tcpdump学习笔记(一)

基本概念tcpdump是Linux中强大的网络数据采集分析工具之一。用简单的话来定义tcpdump,就是dump   the   traffic   on   a   network,根据使用者的定义对网络上的数据包进行截获的包分析工具。tcpdump可以将网络中传送的数据包的“头”完全截获下来提供分析。它支持针对网络层、协议、主机、网络或端口的过滤,并提供and、or、not等逻辑语句来帮助去掉...

Cecilia3333的博客 380

LVGL 蜂巢气泡菜单(Hex Menu)

h。

摸鱼专家 176

TCPDUMP(命令行操作)-抓包、筛选、高级筛选、过程文档记录

TCPDUMP No-GUI的抓包分析工具 Linux、Unix系统默认安装TCPdump—–抓包 抓包 默认只抓68个字节 tcpdump -i eth0 -s 0 -w file.pcap tcpdump -i eth0 port 22 读取抓包文件 Tcpdump -r file.pcap选项介绍-A 以ASCII格式打印出所有分组,并将链路层的头最小化

含笑 9万+

关于YOLOv8的面试题(持续更新中...)

本章将计划更新关于YOLOv8中可能会成为面试题的关键技术点,计划持续更新,可能想到合适的问题我就会整理下更新到本博客中。

ice 4167

前端build工程的时候 出现 `build.rollupOptions.external 的解决方法

看到这个Bug,理性分析: 遇到 Rollup failed to resolve import “@vue/devtools-api” 错误可能是由于 Pinia 使用了 @vue/devtools-api 模块,而 Vite 的 Rollup 插件无法解析这个模块 ps:但是我前一秒还可以,加了个别代码,突然不行,我是不相信的 = - =

码农研究僧的博客 3055

tcpdump学习笔记记录

前期准备要想学会tcpdump,最起码需要对tcp/ip协议有一定了解,比如tcp三次握手,相关只是可以看看《计算机网络》或者《TCP/IP详解》。tcpdump使用格式格式: tcpdump [ -AbdDefhHIJKlLnNOpqRStuUvxX ] [ -B buffer_size ] [ -c count ] [ -C file_size ] [ -

yinn 979

Spring AI Alibaba 1.x 源码分析-架构设计

本文通过分析Spring AI Alibaba 框架的源码,分析出其原理和架构设计,无论是用于项目开发、技术评估还是团队培训都具有重要价值。

program哲学 490

tcpdump 学习笔记

tcpdump的表达式介绍 表达式是一个正则表达式,tcpdump利用它作为过滤报文的条件,如果一个报文满足表 达式的条件,则这个报文将会被捕获。如果没有给出任何条件,则网络上所有的信息包 将会被截获。 在表达式中一般如下几种类型的关键字: 第一种是关于类型的关键字,主要包括host,net,port 例如 host 210.27.48.2, 指明 210.27.48.2是一台主机 net

肥葱的专栏 488

VB摄像头监控

该VB模块可对摄像头捕获的画面进行录像等,可在创建的窗口进行控制

LinePhone3.2.7(android端最新版本) sip客户端

SIP客户端For android:LinePhone3.2.7(最新版本),官网地址:http://www.linphone.org/

Tcpdump学习笔记

tcpdump输出 tcpdump输出结构 04:10:46.852184 IP localhost.localdomain.ssh > 192.168.190.1.63683: Flags [P.], seq 408261743:408261939, ack 192715332, win 264, length 196 第一列:时分秒毫秒 第二列:网络协议 第三列:发送方的ip地址+端口号 第四列:箭头方向 表示数据流向 第五列:接收方的ip地址+端口号 第六列:冒号 第七列:数据包内容,包括Fl

汗的博客 469

RU DOS版、EFI版32bit/64bit BIOS常用工具

DOS版、EFI版的RU工具,可用来查看IO、MEM、PCI、SMBIOS等资源。亲测在EFI SHELL下可用。

Kali linux 学习笔记(六)基本工具熟悉——tcpdump 2020.2.15

熟悉kali Linux的基本工具tcpdump

闵行小鱼塘 1269

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

TCPDUMP学习笔记。

1.启动 普通情况下,直接启动tcpdump将监视第一个网络界面上所有流过的数据包,注意这里使用超级用户。当用户上网得时候,就会将监视得数据打印出来。 我没使用root用户,结果输入tcpdump命令,提示: tcpdump: packet printing is not supported for link type BLUETOOTH_HCI_H4_WITH_PHDR: use –w ...

weixin_30341735的博客 673

linux学习笔记——tcpdump

linux学习笔记——tcpdump 前言: 因工作需要, 使用了tcpdump,  现进行总结。 执行环境:ubuntu 10.04 正文:           1.  选项:          tcpdump是一种嗅探器(sniffer),利用以太网的特性,通过将网卡适配器(NIC)置于混杂模式(promiscuous)来获取传输在网络中的信息包。 使用tcpdump, r

banner812的专栏 879

tcpdump学习笔记一

Tcpdump?      用简单的话来定义tcpdump,就是:dump the traffic on a network,根据使用者的定义对网络上的数据包进行截获的包分析工具。-

Code_Thinking的专栏 754

【学习笔记】tcpdump+Wireshark抓包(1)

网络上的通信,本质上是数据被拆成一个个 数据包(Packet),经过网卡发送和接收。抓包 = 在某个网卡上,把经过的数据包 复制一份 保存下来,供后续分析。

2402_82757055的博客 896

tcpdump学习笔记(二)

序言单独总结tcpdump抓包的常用命令主要语法过滤主机/IP: tcpdump -i eth1 host 172.16.7.206抓取所有经过网卡1,目的IP为172.16.7.206的网络数据 过滤端口: tcpdump -i eth1 dst port 1234抓取所有经过网卡1,目的端口为1234的网络数据 过滤特定协议: tcpdump -i eth1 udp抓取所有经过网卡1,协议类型...

Cecilia3333的博客 670

软件测试学习笔记丨tcpdump 与 wireshark

TCP协议是在传输层中,一种面向连接的、可靠的、基于字节流的传输层通信协议。

ceshiren_com的博客 1286
上一篇: mysql复制表结构和数据
下一篇: gcc学习笔记
Buger(8哥)
博客等级 码龄15年 17粉丝 10原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值