1

我正在尝试使用高速公路 websockets 连接到 poloniex 提要。

Poloniex 在此处提供 API 信息 -- https://poloniex.com/support/api/

我也在使用 Autobahn github 页面上的示例。我能够建立传输层连接并启动会话,但在加入领域时遇到了问题。

join_future=session->join("realm1").then
([&](boost::future<uint64_t> joined) { 
    try {joined.get();} 
    catch(const std::exception &e) {
        std::cerr << e.what() << std::endl; 
        io.stop(); 
        return; 
    }
});
std::cerr << "Joined realm" << std::endl;

以下是数据包跟踪

启动io服务

[2017-08-26 14:32:42] [connect] Successful connection
[2017-08-26 14:32:42] [connect] WebSocket Connection 104.20.12.48:443 v-2 "WebSocket++/0.7.0" / 101
transport connected
session started
TX message (125 octets) ...
TX message: hello ["realm2", {"authid":"", "authmethods":[], "roles":{"subscriber":{}, "callee":{"features":{"call_timeout":true}}, "publisher":{}, "caller":{"features":{"call_timeout":true}}}}]
[2017-08-26 14:32:42] [frame_header] Dispatching write containing 1 message(s) containing 6 header bytes and 125 payload bytes
[2017-08-26 14:32:42] [frame_header] Header Bytes: 
[0] (6) 82 FD 45 02 AA 95 

[2017-08-26 14:32:42] [frame_payload] Payload Bytes: 
[0] (125) [2] D6 03 0C E7 20 63 C6 F8 77 81 0C F4 30 76 C2 FC 21 A2 01 F4 30 76 C2 F8 20 76 C2 FA 21 71 3A 30 37 6D C6 F0 36 86 00 E6 30 60 D9 F6 37 6B C8 F0 37 82 0C F6 24 6E C6 F0 20 83 02 F3 20 63 DE E0 37 67 D9 14 E9 61 CB F9 29 5D DE FC 28 67 C5 E0 31 C1 03 E5 30 60 C6 FC 36 6A CF E7 C5 A4 C9 F4 29 6E CF E7 C4 AA CC F0 24 76 DF E7 20 71 2B 39 26 63 C6 F9 1A 76 C3 F8 20 6D DF E1 86 

[2017-08-26 14:32:42] [control] Control frame received with opcode 8
[2017-08-26 14:32:42] [frame_header] Dispatching write containing 1 message(s) containing 6 header bytes and 2 payload bytes
[2017-08-26 14:32:42] [frame_header] Header Bytes: 
[0] (6) 88 82 3B 2E C0 0B 

[2017-08-26 14:32:42] [frame_payload] Payload Bytes: 
[0] (2) [8] 38 C1 

[2017-08-26 14:32:42] [error] handle_read_frame error: websocketpp.transport:8 (TLS Short Read)
[2017-08-26 14:32:42] [disconnect] Disconnect close local:[1006,TLS Short Read] remote:[1007]
stopped io service

我会很感激任何见解。

4

0 回答 0