/hal_espressif-2.7.6/components/esp_http_server/src/ |
D | httpd_uri.c | 32 bool httpd_uri_match_wildcard(const char *template, const char *uri, size_t len) in httpd_uri_match_wildcard() argument 72 return (strncmp(template, uri, exact_match_chars) == 0); in httpd_uri_match_wildcard() 75 if (len > exact_match_chars && template[exact_match_chars] != uri[exact_match_chars]) { in httpd_uri_match_wildcard() 79 if (strncmp(template, uri, exact_match_chars) != 0) { in httpd_uri_match_wildcard() 94 const char *uri, size_t uri_len, in httpd_find_uri_handler() argument 106 ESP_LOGD(TAG, LOG_FMT("[%d] = %s"), i, hd->hd_calls[i]->uri); in httpd_find_uri_handler() 111 hd->config.uri_match_fn(hd->hd_calls[i]->uri, uri, uri_len) : in httpd_find_uri_handler() 112 httpd_uri_match_simple(hd->hd_calls[i]->uri, uri, uri_len)) { in httpd_find_uri_handler() 147 if (httpd_find_uri_handler(handle, uri_handler->uri, in httpd_register_uri_handler() 148 strlen(uri_handler->uri), in httpd_register_uri_handler() [all …]
|
D | httpd_parse.c | 80 if (sizeof(r->uri) < (length + 1)) { in verify_url() 82 length, sizeof(r->uri)); in verify_url() 90 strlcpy((char *)r->uri, at, (length + 1)); in verify_url() 91 ESP_LOGD(TAG, LOG_FMT("received URI = %s"), r->uri); in verify_url() 103 if (http_parser_parse_url(r->uri, strlen(r->uri), in verify_url() 674 memset((char*)r->uri, 0, sizeof(r->uri)); in init_req() 942 const char *qry = r->uri + res->field_data[UF_QUERY].off; in httpd_req_get_url_query_str()
|
/hal_espressif-2.7.6/tools/test_apps/protocols/mqtt/publish_connect_test/main/ |
D | connect_test.c | 67 .uri = "mqtts://127.0.0.1:1234" in create_client() 77 char uri[64]; in connect_no_certs() local 78 sprintf(uri, "mqtts://%s:%d", host, port); in connect_no_certs() 80 .uri = uri in connect_no_certs() 89 char uri[64]; in connect_with_client_key_password() local 90 sprintf(uri, "mqtts://%s:%d", host, port); in connect_with_client_key_password() 92 .uri = uri, in connect_with_client_key_password() 106 char uri[64]; in connect_with_server_der_cert() local 107 sprintf(uri, "mqtts://%s:%d", host, port); in connect_with_server_der_cert() 109 .uri = uri, in connect_with_server_der_cert() [all …]
|
/hal_espressif-2.7.6/examples/protocols/coap_client/main/ |
D | coap_client_example_main.c | 200 static coap_uri_t uri; in coap_example_client() local 217 if (coap_split_uri((const uint8_t *)server_uri, strlen(server_uri), &uri) == -1) { in coap_example_client() 222 if (uri.scheme == COAP_URI_SCHEME_COAPS && !coap_dtls_is_supported()) { in coap_example_client() 226 if (uri.scheme == COAP_URI_SCHEME_COAPS_TCP && !coap_tls_is_supported()) { in coap_example_client() 231 phostname = (char *)calloc(1, uri.host.length + 1); in coap_example_client() 237 memcpy(phostname, uri.host.s, uri.host.length); in coap_example_client() 252 dst_addr.addr.sin.sin_port = htons(uri.port); in coap_example_client() 259 dst_addr.addr.sin6.sin6_port = htons(uri.port); in coap_example_client() 269 if (uri.path.length) { in coap_example_client() 272 res = coap_split_path(uri.path.s, uri.path.length, buf, &buflen); in coap_example_client() [all …]
|
/hal_espressif-2.7.6/docs/zh_CN/api-reference/protocols/ |
D | esp_http_server.rst | 12 …ister_uri_handler`: 通过传入 ``httpd_uri_t`` 结构体类型的对象来注册 URI 处理程序。该结构体包含如下成员:``uri`` 名字,``method`` 类型(… 21 /* URI 处理函数,在客户端发起 GET /uri 请求时被调用 */ 30 /* URI 处理函数,在客户端发起 POST /uri 请求时被调用 */ 59 /* GET /uri 的 URI 处理结构 */ 61 .uri = "/uri", 67 /* POST /uri 的 URI 处理结构 */ 69 .uri = "/uri",
|
/hal_espressif-2.7.6/components/esp_http_server/test/ |
D | test_http_server.c | 33 httpd_uri_t uri = { in handler_limit_uri() local 34 .uri = path, in handler_limit_uri() 39 return uri; in handler_limit_uri() 73 TEST_ASSERT(httpd_unregister_uri_handler(hd, uris[0].uri, uris[0].method) == ESP_OK); in test_handler_limit() 76 TEST_ASSERT(httpd_unregister_uri_handler(hd, uris[0].uri, uris[0].method) != ESP_OK); in test_handler_limit() 89 TEST_ASSERT(httpd_unregister_uri_handler(hd, uris[i].uri, uris[i].method) == ESP_OK); in test_handler_limit() 175 const char *uri; member 230 bool match = httpd_uri_match_wildcard(ut->template, ut->uri, strlen(ut->uri));
|
/hal_espressif-2.7.6/examples/protocols/http_server/file_serving/main/ |
D | file_server.c | 126 httpd_resp_sendstr_chunk(req, req->uri); in http_resp_dir_html() 139 httpd_resp_sendstr_chunk(req, req->uri); in http_resp_dir_html() 179 static const char* get_path_from_uri(char *dest, const char *base_path, const char *uri, size_t des… in get_path_from_uri() argument 182 size_t pathlen = strlen(uri); in get_path_from_uri() 184 const char *quest = strchr(uri, '?'); in get_path_from_uri() 186 pathlen = MIN(pathlen, quest - uri); in get_path_from_uri() 188 const char *hash = strchr(uri, '#'); in get_path_from_uri() 190 pathlen = MIN(pathlen, hash - uri); in get_path_from_uri() 200 strlcpy(dest + base_pathlen, uri, pathlen + 1); in get_path_from_uri() 214 req->uri, sizeof(filepath)); in download_get_handler() [all …]
|
/hal_espressif-2.7.6/examples/protocols/http_server/restful_server/main/ |
D | rest_server.c | 65 if (req->uri[strlen(req->uri) - 1] == '/') { in rest_common_get_handler() 68 strlcat(filepath, req->uri, sizeof(filepath)); in rest_common_get_handler() 186 .uri = "/api/v1/system/info", in start_rest_server() 195 .uri = "/api/v1/temp/raw", in start_rest_server() 204 .uri = "/api/v1/light/brightness", in start_rest_server() 213 .uri = "/*", in start_rest_server()
|
/hal_espressif-2.7.6/components/esp_websocket_client/ |
D | esp_websocket_client.c | 74 char *uri; member 206 if (config->uri) { in esp_websocket_client_set_config() 207 free(cfg->uri); in esp_websocket_client_set_config() 208 cfg->uri = strdup(config->uri); in esp_websocket_client_set_config() 209 ESP_WS_CLIENT_MEM_CHECK(TAG, cfg->uri, return ESP_ERR_NO_MEM); in esp_websocket_client_set_config() 266 free(cfg->uri); in esp_websocket_client_destroy_config() 390 if (config->uri) { in esp_websocket_client_init() 391 if (esp_websocket_client_set_uri(client, config->uri) != ESP_OK) { in esp_websocket_client_init() 464 esp_err_t esp_websocket_client_set_uri(esp_websocket_client_handle_t client, const char *uri) in esp_websocket_client_set_uri() argument 466 if (client == NULL || uri == NULL) { in esp_websocket_client_set_uri() [all …]
|
/hal_espressif-2.7.6/examples/protocols/websocket/ |
D | example_test.py | 118 uri = dut1.app.get_sdkconfig()['CONFIG_WEBSOCKET_URI'].strip('"') 131 uri = 'ws://{}:{}'.format(get_my_ip(), server_port) 132 print('DUT connecting to {}'.format(uri)) 134 dut1.write(uri) 141 print('DUT connecting to {}'.format(uri))
|
/hal_espressif-2.7.6/examples/protocols/http_server/advanced_tests/main/ |
D | tests.c | 303 { .uri = "/hello/type_html", 308 { .uri = "/test_header", 313 { .uri = "/hello", 318 { .uri = "/hello/status_500", 323 { .uri = "/echo", 328 { .uri = "/echo", 333 { .uri = "/leftover_data", 338 { .uri = "/adder", 343 { .uri = "/async_data",
|
/hal_espressif-2.7.6/components/mqtt/test/ |
D | test_mqtt.c | 22 .uri = "INVALID", 33 .uri = "mqtts://localhost:8883", 57 .uri = "mqtts://localhost:8883",
|
/hal_espressif-2.7.6/components/wpa_supplicant/test/ |
D | test_dpp.c | 63 const char *uri; variable 72 uri = dpp_bootstrap_get_uri(dpp, id); 73 printf("uri is =%s\n", uri); 75 TEST_ASSERT((strcmp(uri, bootstrap_info) == 0));
|
/hal_espressif-2.7.6/docs/en/api-reference/protocols/ |
D | esp_http_server.rst | 12 …ing object of type ``httpd_uri_t`` structure which has members including ``uri`` name, ``method`` … 21 /* Our URI handler function to be called during GET /uri request */ 30 /* Our URI handler function to be called during POST /uri request */ 63 /* URI handler structure for GET /uri */ 65 .uri = "/uri", 71 /* URI handler structure for POST /uri */ 73 .uri = "/uri",
|
D | esp_websocket_client.rst | 30 .uri = "ws://echo.websocket.org", 38 .uri = "ws://echo.websocket.org/connectionhandler?id=104", 49 .uri = "ws://echo.websocket.org:123", 62 .uri = "wss://echo.websocket.org", 84 .uri = "ws://websocket.org",
|
/hal_espressif-2.7.6/tools/ci/python_packages/idf_http_server_test/ |
D | client.py | 47 uri = '/hello?query1=value1&query2=value2&query3=value3' 50 verbose_print(verbosity, 'Sending GET to URI : ', uri) 54 sess.request('GET', url=uri, headers=test_headers) 232 uri = '/hello?' + query 234 verbose_print(verbosity, 'Sending GET to URI : ', uri) 235 sess.request('GET', url=uri, headers={})
|
/hal_espressif-2.7.6/examples/protocols/http_server/simple/main/ |
D | main.c | 105 .uri = "/hello", 146 .uri = "/echo", 165 if (strcmp("/hello", req->uri) == 0) { in http_404_error_handler() 169 } else if (strcmp("/echo", req->uri) == 0) { in http_404_error_handler() 216 .uri = "/ctrl",
|
/hal_espressif-2.7.6/examples/protocols/http2_request/components/sh2lib/ |
D | sh2lib.c | 238 int sh2lib_connect(struct sh2lib_handle *hd, const char *uri) in sh2lib_connect() argument 247 if ((hd->http2_tls = esp_tls_conn_http_new(uri, &tls_cfg)) == NULL) { in sh2lib_connect() 253 http_parser_parse_url(uri, strlen(uri), 0, &u); in sh2lib_connect() 254 hd->hostname = strndup(&uri[u.field_data[UF_HOST].off], u.field_data[UF_HOST].len); in sh2lib_connect() 258 ESP_LOGE(TAG, "[sh2-connect] HTTP2 Connection failed with %s", uri); in sh2lib_connect()
|
/hal_espressif-2.7.6/examples/protocols/websocket/main/ |
D | websocket_example.c | 101 websocket_cfg.uri = line; in websocket_app_start() 105 websocket_cfg.uri = CONFIG_WEBSOCKET_URI; in websocket_app_start() 109 ESP_LOGI(TAG, "Connecting to %s...", websocket_cfg.uri); in websocket_app_start()
|
/hal_espressif-2.7.6/examples/protocols/mqtt/tcp/main/ |
D | app_main.c | 108 .uri = CONFIG_BROKER_URL, in mqtt_app_start() 113 if (strcmp(mqtt_cfg.uri, "FROM_STDIN") == 0) { in mqtt_app_start() 127 mqtt_cfg.uri = line; in mqtt_app_start()
|
/hal_espressif-2.7.6/components/esp_http_client/lib/ |
D | http_auth.c | 80 auth_data->uri == NULL || in http_auth_digest() 104 if (md5_printf(ha2, "%s:%s", auth_data->method, auth_data->uri) <= 0) { in http_auth_digest() 128 …username, auth_data->realm, auth_data->nonce, auth_data->uri, digest, auth_data->qop, auth_data->n… in http_auth_digest()
|
/hal_espressif-2.7.6/components/bt/esp_ble_mesh/mesh_core/ |
D | beacon.c | 222 if (prov->uri && bt_mesh_s1(prov->uri, uri_hash) == 0) { in unprovisioned_beacon_send() 234 if (prov->uri) { in unprovisioned_beacon_send() 244 len = strlen(prov->uri); in unprovisioned_beacon_send() 248 net_buf_add_mem(buf, prov->uri, len); in unprovisioned_beacon_send()
|
/hal_espressif-2.7.6/components/esp_websocket_client/include/ |
D | esp_websocket_client.h | 73 …const char *uri; /*!< Websocket URI, the information on the… member 128 esp_err_t esp_websocket_client_set_uri(esp_websocket_client_handle_t client, const char *uri);
|
/hal_espressif-2.7.6/examples/protocols/http_server/persistent_sockets/main/ |
D | main.c | 145 .uri = "/adder", 152 .uri = "/adder", 159 .uri = "/adder",
|
/hal_espressif-2.7.6/components/esp_http_server/include/ |
D | esp_http_server.h | 335 …const char uri[HTTPD_MAX_URI_LEN + 1]; /*!< The URI of this request (1 byte extra for null te… member 389 const char *uri; /*!< The URI to handle */ member 491 const char *uri, httpd_method_t method); 505 esp_err_t httpd_unregister_uri(httpd_handle_t handle, const char* uri);
|