websocke渗透测试WSSiP: A WebSocket Manipulation Proxy

碰到一个websocket的测试,而burp没有很好的支持websocket的repeater功能。
在这里插入图片描述

于是找到一个websocket测试工具:

WSSiP: A WebSocket Manipulation Proxy

https://www.nccgroup.trust/uk/about-us/newsroom-and-events/blogs/2017/may/wssip-a-websocket-manipulation-proxy/
https://github.com/nccgroup/wssip

git clone https://github.com/nccgroup/wssip

# Change to the directory
cd wssip

# If you are developing for WSSiP:
# npm i

# If not... (as to minimize disk space):
npm i electron
npm i --production

# Start application:
npm start

由于需要启动图形界面,在linux server下没有成功:
在这里插入图片描述
在windows下启动成功:
在这里插入图片描述

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
抱歉,可能是我之前的回答有误。在 libhv 库中,WebSocketClient 类并没有定义 ptr 类型的智能指针,因此会出现 `'ptr' is not a member of 'hv::WebSocketClient'` 的编译错误。 为了解决这个问题,您可以将示例代码中的 `std::make_shared<hv::WebSocketClient>()` 替换为 `std::shared_ptr<hv::WebSocketClient>(new hv::WebSocketClient())`,使用标准库的 shared_ptr 来创建智能指针。具体代码如下: ```cpp #include "WebSocketClient.h" #include <iostream> #include <memory> using namespace hv; using namespace std; int main() { // 创建 WebSocket 客户端对象 shared_ptr<WebSocketClient> client(new WebSocketClient()); // 连接服务器 if (!client->connect("ws://192.168.1.103:80")) { cerr << "Failed to connect server!" << endl; return -1; } // 打开设备 auto open_callback = [](const string& data, WebSocketChannel::ptr channel) { // TODO: 处理返回值 cout << "Open callback: " << data << endl; }; client->send("{\"position\": 101}", open_callback); // 获取数据 auto getdata_callback = [](const string& data, WebSocketChannel::ptr channel) { // TODO: 处理返回值 cout << "Getdata callback: " << data << endl; }; client->send("{\"position\": 101, \"count\": 0, \"isclose\": false}", getdata_callback); // 关闭设备 auto close_callback = [](const string& data, WebSocketChannel::ptr channel) { // TODO: 处理返回值 cout << "Close callback: " << data << endl; }; client->send("{\"position\": 101}", close_callback); // 断开连接 client->close(); return 0; } ``` 希望这次能够成功编译通过。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值