websocket

一、参考网址

  1、WebSocket 教程

  2、The WebSocket protocol draft-ietf-hybi-thewebsocketprotocol-13 

  3、WebSocket 协议深入探究

  4、Linux下c语言实验Websocket通讯 含客户端和服务器测试代码(原版)

  5、Linux下c语言实验Websocket通讯 含客户端和服务器测试代码

  6、WebSocket 通信过程与实现

   7、什么是WebSocket,它与HTTP有何不同?(hc)

 8. 原来你是这样的Websocket--抓包分析(haibin)

 9. 一文读懂 WebSocket 通信过程与实现

   10. websocat测试websocket的好工具

 11. Install Websocat on Ubuntu 20.04

  12. websocat测试websocket的好工具

二、libwebsocket

  1、libwebsocket下载地址

  2、libwebsockets(一)簡介

  3、libwebsockets(三)實現簡易websocket服務器

 

三. 实践

  1. 下载的QT版websocket服务器无法使用,用wireshark抓包发现客户端与服务端的tcp连接建立失败(一直在发SYN包)

    解决:由于防火墙导致的,需要修改防火墙设置,如下:

  2. ubuntu安装websocat

    1) Download the latest Websocat executable file from the releases page in GitHub repository:  

sudo wget -qO /usr/local/bin/websocat https://github.com/vi/websocat/releases/latest/download/websocat.x86_64-unknown-linux-musl

    2) Set execute permission:

sudo chmod a+x /usr/local/bin/websocat

    Now websocat will be available for all users as a system-wide command.

    3) We can check Websocat version as follows:

websocat --version

 

 

posted @ 2019-10-30 10:20  shanyu20  阅读(312)  评论(0编辑  收藏  举报