编译wireshark OpenFlow插件
PS:最近在研究OpenFlow,为了使wireshark支持OpenFlow协议分析数据包,需要编译OpenFlow插件。现在说一下我的过程。
编译wireshark-1.6.8
到www.wireshark.org下载wireshark源码包。http://wiresharkdownloads.riverbed.com/wireshark/src/wireshark-1.6.8.tar.bz2。
安装依赖包
apt-get install build-essential
编译OpenFlow插件
修改一处bug
修改
diff --git a/utilities/wireshark_dissectors/openflow/packet-openflow.c b/utilities/wireshark_dissectors/openflow/packet-openflow.c
index aea00f8..8d98335 100644
--- a/utilities/wireshark_dissectors/openflow/packet-openflow.c
+++ b/utilities/wireshark_dissectors/openflow/packet-openflow.c
@@ -766,7 +766,7 @@ static gint ett_ofp_error_msg_data = -1;
void proto_reg_handoff_openflow()
{
openflow_handle = create_dissector_handle(dissect_openflow, proto_openflow);
- dissector_add(TCP_PORT_FILTER, global_openflow_proto, openflow_handle);
+ dissector_add_uint(TCP_PORT_FILTER, global_openflow_proto,
+ openflow_handle);
}
#define NO_STRINGS NULL
就可以了
本文介绍如何编译Wireshark的OpenFlow插件以支持OpenFlow协议的数据包分析。首先需要从官网下载Wireshark源码包并安装必要的依赖软件,然后进行OpenFlow插件的编译,并修复了一个小bug。

1485

被折叠的 条评论
为什么被折叠?



