简体   繁体   English

如何将Tcpreplay添加为C语言或任何其他编程语言的库?

[英]How to add Tcpreplay as a library in C language or any other programming language?

I am trying to add tcpreplay library in C so that I can rewrite the data in the packet. 我试图在C中添加tcpreplay库,以便可以重写数据包中的数据。 I have been searching for a library in C programming. 我一直在寻找C编程库。 The result was to add TCPreplay and start using it's methods. 结果是添加TCPreplay并开始使用它的方法。 Unfortunately it is not there for C language. 不幸的是,C语言不存在。 If there is way to add the Tcpreplay to my program, let me know. 如果有办法将Tcpreplay添加到我的程序中,请告诉我。

If this is not feasible, Please let me know how I can proceed. 如果这样做不可行,请告诉我如何进行。 Also in Perl, it Net-Pcap is available but it cannot be used to write data into the packets. 同样在Perl中,它可以使用Net-Pcap ,但不能用于将数据写入数据包。

Also let me know which programming language to use, if C is not compatible. 如果C不兼容,也请让我知道使用哪种编程语言。

Thanks in advance. 提前致谢。 :) :)

If you look at this branch: https://github.com/synfinatic/tcpreplay you'll find my code to create a C library for tcpreplay & tcprewrite/etc. 如果您查看以下分支: https : //github.com/synfinatic/tcpreplay,您将找到我的代码来为tcpreplay和tcprewrite / etc创建一个C库。 It's not complete, doesn't completely work and I have no intentions of completing it (I've since handed off Tcpreplay to Fred @ Appneta who is the new maintainer) but depending on what you need it might work. 它不完整,不能完全正常运行,我也无意完成它(此后我将Tcpreplay交给了新的维护者Fred @ Appneta),但是根据您的需要它可能会起作用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM