/unit/src/test/ |
H A D | nxt_unit_websocket_echo.c | 54 uint8_t opcode; in ws_echo_websocket_handler() local 67 opcode = ws->header->opcode; in ws_echo_websocket_handler() 69 if (opcode == NXT_WEBSOCKET_OP_PONG) { in ws_echo_websocket_handler() 76 nxt_unit_websocket_send(req, opcode, ws->header->fin, buf, size); in ws_echo_websocket_handler() 79 if (opcode == NXT_WEBSOCKET_OP_CLOSE) { in ws_echo_websocket_handler()
|
H A D | nxt_unit_websocket_chat.c | 167 if (ws->header->opcode != NXT_WEBSOCKET_OP_TEXT) { in ws_chat_websocket_handler()
|
/unit/src/nodejs/unit-http/ |
H A D | websocket_connection.js | 330 if (this.frameQueue.length !== 0 && (frame.opcode > 0x00 && frame.opcode < 0x08)) { 337 switch(frame.opcode) { 399 var opcode = this.frameQueue[0].opcode; 407 switch (opcode) { 534 frame.opcode = 0x01; // WebSocketOpcode.TEXT_FRAME 547 frame.opcode = 0x02; // WebSocketOpcode.BINARY_FRAME 557 frame.opcode = 0x09; // WebSocketOpcode.PING 580 frame.opcode = 0x0A; // WebSocketOpcode.PONG 593 if (frame.opcode > 0x07) { 628 currentFrame.opcode = (i === 1) ? frame.opcode : 0x00; [all …]
|
H A D | unit.cpp | 716 set_named_property(res, "opcode", ws->header->opcode); in create_websocket_frame() 719 if (ws->header->opcode == NXT_WEBSOCKET_OP_CLOSE) { in create_websocket_frame() 1044 uint32_t opcode, sc; in websocket_send_frame() local 1058 opcode = napi.get_value_uint32(napi.get_named_property(frame, in websocket_send_frame() 1060 if (opcode == NXT_WEBSOCKET_OP_CLOSE) { in websocket_send_frame() 1097 ret = nxt_unit_websocket_sendv(req, opcode, fin ? 1 : 0, iov, iovec_len); in websocket_send_frame()
|
/unit/src/python/ |
H A D | nxt_python_asgi_websocket.c | 420 uint8_t opcode; in nxt_py_asgi_websocket_send_frame() local 471 opcode = NXT_WEBSOCKET_OP_BINARY; in nxt_py_asgi_websocket_send_frame() 475 opcode = NXT_WEBSOCKET_OP_TEXT; in nxt_py_asgi_websocket_send_frame() 491 uint8_t opcode; in nxt_py_asgi_websocket_handler() local 501 opcode = frame->header->opcode; in nxt_py_asgi_websocket_handler() 511 opcode); in nxt_py_asgi_websocket_handler() 735 uint8_t code_buf[2], opcode; in nxt_py_asgi_websocket_pop_msg() local 763 opcode = frame->header->opcode; in nxt_py_asgi_websocket_pop_msg() 777 switch (opcode) { in nxt_py_asgi_websocket_pop_msg() 851 opcode); in nxt_py_asgi_websocket_pop_msg() [all …]
|
/unit/src/ |
H A D | nxt_websocket_header.h | 18 uint8_t opcode:4; member 25 uint8_t opcode:4; member
|
H A D | nxt_h1proto_websocket.c | 194 wsh->opcode = NXT_WEBSOCKET_OP_PING; in nxt_h1p_conn_ws_keepalive() 270 if ((wsh->opcode & NXT_WEBSOCKET_OP_CTRL) != 0) { in nxt_h1p_conn_ws_frame_header_read() 276 if (nxt_slow_path(wsh->opcode != NXT_WEBSOCKET_OP_PING in nxt_h1p_conn_ws_frame_header_read() 281 wsh->opcode); in nxt_h1p_conn_ws_frame_header_read() 291 if (nxt_slow_path(wsh->opcode == NXT_WEBSOCKET_OP_CLOSE in nxt_h1p_conn_ws_frame_header_read() 302 wsh->opcode); in nxt_h1p_conn_ws_frame_header_read() 311 wsh->opcode); in nxt_h1p_conn_ws_frame_header_read() 411 if (nxt_slow_path(wsh->opcode == NXT_WEBSOCKET_OP_PING)) { in nxt_h1p_conn_ws_frame_process() 416 if (nxt_slow_path(wsh->opcode == NXT_WEBSOCKET_OP_CLOSE)) { in nxt_h1p_conn_ws_frame_process() 616 wsh->opcode = NXT_WEBSOCKET_OP_CLOSE; in hxt_h1p_send_ws_error() [all …]
|
H A D | nxt_unit.h | 322 int nxt_unit_websocket_send(nxt_unit_request_info_t *req, uint8_t opcode, 325 int nxt_unit_websocket_sendv(nxt_unit_request_info_t *req, uint8_t opcode,
|
H A D | nxt_java.c | 575 ws->header->opcode, ws->header->fin); in nxt_java_websocket_handler()
|
H A D | nxt_unit.c | 1705 ws_impl->ws.header->opcode, in nxt_unit_process_websocket() 3321 nxt_unit_websocket_send(nxt_unit_request_info_t *req, uint8_t opcode, in nxt_unit_websocket_send() argument 3326 return nxt_unit_websocket_sendv(req, opcode, last, &iov, 1); in nxt_unit_websocket_send() 3331 nxt_unit_websocket_sendv(nxt_unit_request_info_t *req, uint8_t opcode, in nxt_unit_websocket_sendv() argument 3370 wh->opcode = opcode; in nxt_unit_websocket_sendv()
|
/unit/test/ |
H A D | test_java_websockets.py | 44 if opcode == ws.OP_BINARY or not decode: 50 assert frame['opcode'] == opcode, 'opcode' 358 opcode = ws.OP_TEXT 368 check_frame(frame, True, opcode, payload) 385 opcode = ws.OP_BINARY 484 opcode = ws.OP_PING 1268 if opcode == ws.OP_TEXT: 1277 def check_message(opcode, f_size): argument 1278 if opcode == ws.OP_TEXT: 1367 opcode = ws.OP_TEXT [all …]
|
H A D | test_node_websockets.py | 44 if opcode == ws.OP_BINARY or not decode: 50 assert frame['opcode'] == opcode, 'opcode' 378 opcode = ws.OP_TEXT 388 check_frame(frame, True, opcode, payload) 405 opcode = ws.OP_BINARY 504 opcode = ws.OP_PING 1288 if opcode == ws.OP_TEXT: 1297 def check_message(opcode, f_size): argument 1298 if opcode == ws.OP_TEXT: 1387 opcode = ws.OP_TEXT [all …]
|
H A D | test_asgi_websockets.py | 47 if opcode == ws.OP_BINARY or not decode: 53 assert frame['opcode'] == opcode, 'opcode' 430 opcode = ws.OP_TEXT 440 check_frame(frame, True, opcode, payload) 457 opcode = ws.OP_BINARY 556 opcode = ws.OP_PING 1340 if opcode == ws.OP_TEXT: 1349 def check_message(opcode, f_size): argument 1350 if opcode == ws.OP_TEXT: 1439 opcode = ws.OP_TEXT [all …]
|
/unit/src/java/ |
H A D | nxt_jni_Request.h | 19 uint8_t opcode, uint8_t fin);
|
H A D | nxt_jni_Request.c | 813 uint8_t opcode, uint8_t fin) in nxt_java_Request_websocket() argument 815 (*env)->CallVoidMethod(env, jreq, nxt_java_Request_processWsFrame, jbuf, opcode, fin); in nxt_java_Request_websocket()
|
/unit/test/unit/applications/ |
H A D | websockets.py | 144 opcode, argument 163 | opcode
|