| /lighttpd1.4/src/ |
| H A D | mod_ajp13.c | 366 if (0 == n) return n; in ajp13_enc_request_headers() 373 if (0 == n) return n; in ajp13_enc_request_headers() 377 if (0 == n) return n; in ajp13_enc_request_headers() 408 if (0 == n) return n; in ajp13_enc_request_headers() 421 if (0 == n) return n; 423 if (0 == n) return n; 434 if (0 == n) return n; in ajp13_enc_attribute() 446 if (0 == n) return n; in ajp13_enc_attributes() 449 if (0 == n) return n; in ajp13_enc_attributes() 476 if (0 == n) return n; in ajp13_enc_attributes() [all …]
|
| H A D | http_range.c | 70 n -= 2; in http_range_coalesce() 76 return n; in http_range_coalesce() 90 if (n >= 0) { in http_range_parse_next() 91 if (n != LLONG_MAX && n < len && s != e) { in http_range_parse_next() 98 else if (ranges[0] <= n && n != LLONG_MAX) in http_range_parse_next() 99 ranges[1] = n < len ? n : len-1; in http_range_parse_next() 104 ranges[0] = len > -n ? len + n : 0;/*('n' is negative here)*/ in http_range_parse_next() 132 int n = 0; in http_range_parse() local 136 n += 2; in http_range_parse() 142 if (n <= 2) in http_range_parse() [all …]
|
| H A D | http_cgi.c | 130 size_t n; in http_cgi_headers() local 138 n = buffer_clen(&r->uri.query); in http_cgi_headers() 140 n ? r->uri.query.ptr : "", n); in http_cgi_headers() 237 n = 0; in http_cgi_headers() 253 n = srv_sock->srv_token_colon; in http_cgi_headers() 256 n = tlen - (n+1); in http_cgi_headers() 260 n = 1; in http_cgi_headers() 264 n = 0; in http_cgi_headers() 295 if (n) { in http_cgi_headers() 314 for (n = 0; n < r->rqst_headers.used; n++) { in http_cgi_headers() [all …]
|
| H A D | log.c | 127 char n[LI_ITOSTRING_LENGTH]; in __attribute_nonnull__() local 129 li_utostrn(n, sizeof(n), (unsigned long)ts.tv_nsec); in __attribute_nonnull__() 169 if (i == n) in log_buffer_append_encoded() 188 unsigned int n; in __attribute_nonnull__() local 195 if ((int)n <= 0) in __attribute_nonnull__() 197 if (n < bsp) in __attribute_nonnull__() 200 s = buffer_extend(b, n); in __attribute_nonnull__() 201 vsnprintf(s, n+1, fmt, ap); in __attribute_nonnull__() 210 n -= i; in __attribute_nonnull__() 211 char * const src = (char *)ck_malloc(n); in __attribute_nonnull__() [all …]
|
| H A D | ck.c | 113 ck_memclear_s_hook(s, n); in ck_memset_compat() 139 if (RSIZE_MAX < n) { in ck_memclear_s() 142 n = smax; in ck_memclear_s() 144 if (smax < n) { in ck_memclear_s() 147 n = smax; in ck_memclear_s() 151 explicit_bzero(s, n); in ck_memclear_s() 153 memset_explicit(s, 0, n); in ck_memclear_s() 155 explicit_memset(s, 0, n); in ck_memclear_s() 157 SecureZeroMemory(s, n); in ck_memclear_s() 159 ck_memset_compat(s, 0, n); in ck_memclear_s() [all …]
|
| H A D | mod_ssi.c | 1310 int n; in mod_ssi_parse_ssi_stmt_value() local 1313 for (n = 1; n < len; ++n) { in mod_ssi_parse_ssi_stmt_value() 1314 if (s[n] == c) return n+1; in mod_ssi_parse_ssi_stmt_value() 1317 ++n; in mod_ssi_parse_ssi_stmt_value() 1322 for (n = 0; n < len; ++n) { in mod_ssi_parse_ssi_stmt_value() 1323 if (isspace(s[n])) return n; in mod_ssi_parse_ssi_stmt_value() 1326 ++n; in mod_ssi_parse_ssi_stmt_value() 1352 for (; light_isalpha(s[n]); ++n) ; in mod_ssi_parse_ssi_stmt_offlen() 1367 for (; light_isalpha(s[n]); ++n) ; in mod_ssi_parse_ssi_stmt_offlen() 1438 for (n = 5; n < len; ++n) { /*(n = 5 to begin after "<!--#")*/ in mod_ssi_stmt_len() [all …]
|
| H A D | fdevent_impl.c | 307 return n; in fdevent_poll() 346 return n; in fdevent_linux_sysepoll_poll() 408 n++; in fdevent_freebsd_kqueue_event_del() 412 n++; in fdevent_freebsd_kqueue_event_del() 433 n++; in fdevent_freebsd_kqueue_event_set() 437 n++; in fdevent_freebsd_kqueue_event_set() 442 n++; in fdevent_freebsd_kqueue_event_set() 446 n++; in fdevent_freebsd_kqueue_event_set() 477 return n; in fdevent_freebsd_kqueue_poll() 671 return n; in fdevent_solaris_devpoll_poll() [all …]
|
| H A D | mod_authn_file.c | 199 const char *f_user = data, *n; in mod_authn_file_htdigest_get_loop() local 201 n = strchr(f_user, '\n'); in mod_authn_file_htdigest_get_loop() 203 if (NULL == n) n = f_user + strlen(f_user); in mod_authn_file_htdigest_get_loop() 212 if (n - f_user > 1024) continue; in mod_authn_file_htdigest_get_loop() 277 } while (*n && *(f_user = n+1)); in mod_authn_file_htdigest_get_loop() 347 const char *f_user = data, *n; in mod_authn_file_htpasswd_get() local 349 n = strchr(f_user, '\n'); in mod_authn_file_htpasswd_get() 351 if (NULL == n) n = f_user + strlen(f_user); in mod_authn_file_htpasswd_get() 382 size_t pwd_len = n - f_pwd; in mod_authn_file_htpasswd_get() 390 } while (*n && *(f_user = n+1)); in mod_authn_file_htpasswd_get() [all …]
|
| H A D | ck.h | 43 errno_t ck_memclear_s (void *s, rsize_t smax, rsize_t n); 47 static inline errno_t ck_memzero(void *s, rsize_t n); 48 static inline errno_t ck_memzero(void *s, rsize_t n) { in ck_memzero() argument 49 return ck_memclear_s(s, n, n); in ck_memzero() 86 void * ck_realloc_u32 (void **list, size_t n, size_t x, size_t elt_sz);
|
| H A D | mod_mbedtls.c | 1189 switch (n) { in mod_mbedtls_alpn_selected() 1231 for (unsigned int i = 2, n; i < inlen; i += n) { in mod_mbedtls_alpn_select_cb() local 1232 n = in[i++]; in mod_mbedtls_alpn_select_cb() 1233 if (i+n > inlen || 0 == n) break; in mod_mbedtls_alpn_select_cb() 1234 switch (n) { in mod_mbedtls_alpn_select_cb() 2468 size_t n = 0; in https_add_ssl_client_subject() local 2487 n += len; in https_add_ssl_client_subject() 2508 if (n > 2) in https_add_ssl_client_subject() 2521 if (n > 0) { in https_add_ssl_client_verify_err() 3988 size_t len = e ? (size_t)(e - n) : strlen(n); in mod_mbedtls_ssl_conf_curves() [all …]
|
| H A D | mod_auth.c | 444 for (uint32_t n = 0; n < value->used; ++n) { in mod_auth_require_parse_array() local 901 size_t n; in mod_auth_digest_mutate() local 932 n = 3; in mod_auth_digest_mutate() 941 n = 5; in mod_auth_digest_mutate() 956 n = 4; in mod_auth_digest_mutate() 995 size_t n; in mod_auth_append_nonce() local 1011 n = 2; in mod_auth_append_nonce() 1038 li_tohex(buffer_extend(b, n*2), n*2+1, (const char *)h, n); in mod_auth_append_nonce() 1056 ++n; in mod_auth_digest_www_authenticate() 1063 ++n; in mod_auth_digest_www_authenticate() [all …]
|
| H A D | mod_setenv.c | 97 uint32_t n = buffer_clen(&ds->value); in mod_setenv_prep_ext() local 98 while (n-- && (s[n]==' ' || s[n]=='\t' || s[n]=='\r' || s[n]=='\n')) ; in mod_setenv_prep_ext() 99 buffer_truncate(&ds->value, ++n); in mod_setenv_prep_ext() 103 n -= (uint32_t)(s - ds->value.ptr); in mod_setenv_prep_ext() 104 memmove(ds->value.ptr, s, n); in mod_setenv_prep_ext() 105 buffer_truncate(&ds->value, n); in mod_setenv_prep_ext()
|
| H A D | keyvalue.c | 186 if (num < (unsigned int)ctx->n) { /* n is always > 0 */ in pcre_keyvalue_buffer_append_match() 402 int n = pcre2_match(kv->code, (PCRE2_SPTR)BUF_PTR_LEN(input), in pcre_keyvalue_buffer_process() local 408 int n = pcre_exec(kv->key, kv->key_extra, BUF_PTR_LEN(input), in pcre_keyvalue_buffer_process() 412 int n = 1; in pcre_keyvalue_buffer_process() 414 if (n < 0) { in pcre_keyvalue_buffer_process() 417 if (n != PCRE2_ERROR_NOMATCH) in pcre_keyvalue_buffer_process() 419 if (n != PCRE_ERROR_NOMATCH) in pcre_keyvalue_buffer_process() 432 ctx->n = n; in pcre_keyvalue_buffer_process() 453 #define li_cton(c,n) \ argument 454 (((n) = (c) - '0') <= 9 || (((n) = ((c)&0xdf) - 'A') <= 5 ? ((n) += 10) : 0))
|
| H A D | chunk.h | 186 const chunk_file_view * chunkqueue_chunk_file_viewadj (chunk *c, off_t n, log_error_st * restrict e… 209 chunkqueue_chunk_file_view (chunk * const c, const off_t n, log_error_st * const restrict errh); 211 chunkqueue_chunk_file_view (chunk * const c, const off_t n, log_error_st * const restrict errh) in chunkqueue_chunk_file_view() argument 220 || chunk_file_view_dlen(cfv, c->offset) < (n ? n : 1))) in chunkqueue_chunk_file_view() 221 return chunkqueue_chunk_file_viewadj(c, n, errh); in chunkqueue_chunk_file_view() 225 UNUSED(n); in chunkqueue_chunk_file_view()
|
| H A D | h2.c | 1122 wupd=n>=rwin ? (n-=rwin)>(int32_t)len ? len : (uint32_t)n+16384 : 0; in h2_recv_data() 1211 uint32_t m = n; in h2_recv_continuation() 1217 if (cqlen < n+9) return n+9; /* incomplete frame; go on */ in h2_recv_continuation() 1237 n += 9+flen; in h2_recv_continuation() 1244 if (clen < n) return n; /* incomplete frame; go on */ in h2_recv_continuation() 1317 n += 9+flen; in h2_recv_continuation() 1329 memmove(s+m, s+n, clen-n); in h2_recv_continuation() 1330 n = m + (clen-n); in h2_recv_continuation() 1333 n = m; in h2_recv_continuation() 1876 for (uint32_t n = 9+flen; cqlen >= n+9; n += 9+flen) { in h2_want_read() local [all …]
|
| H A D | mod_gnutls.c | 1413 for (unsigned int i = 2, n; i < inlen; i += n) { in mod_gnutls_ALPN() local 1414 n = in[i++]; in mod_gnutls_ALPN() 1415 if (i+n > inlen || 0 == n) break; in mod_gnutls_ALPN() 1417 switch (n) { in mod_gnutls_ALPN() 1567 --n; in mod_gnutls_client_hello_hook() 2780 for (n = 0; n < vlen; ++n) { in https_add_ssl_client_subject() 3217 n[nlen] = '\0'; in mod_gnutls_ssl_conf_ciphersuites() 3427 e = strchr(n, ':'); in mod_gnutls_ssl_conf_curves() 3428 size_t len = e ? (size_t)(e - n) : strlen(n); in mod_gnutls_ssl_conf_curves() 3485 if (n < 0) return; in mod_gnutls_ssl_conf_proto() [all …]
|
| H A D | lemon.c | 727 n = 0; in acttab_insert() 792 while( n>0 && p->aAction[n-1].lookahead<0 ){ n--; } in acttab_action_size() 793 return n; in acttab_action_size() 3422 int i, n; in ReportOutput() local 3491 if( n>0 && n+w>75 ){ in ReportOutput() 3497 n++; in ReportOutput() 3830 n--; in append_str() 4673 while( n>0 && lemp->sorted[n-1]->iTknOfst==NO_OFFSET ) n--; in ReportTable() 4699 while( n>0 && lemp->sorted[n-1]->iNtOfst==NO_OFFSET ) n--; in ReportTable() 5110 int n; in stateResortCompare() local [all …]
|
| H A D | server.c | 488 n |= FDEVENT_RDHUP; in server_oneshot_read_cq() 501 n &= ~FDEVENT_IN; in server_oneshot_handle_fdevent() 508 n &= ~(FDEVENT_IN|FDEVENT_RDHUP); in server_oneshot_handle_fdevent() 1115 for (int n = 0; n < npids; ++n) pids[n] = -1; in server_main_setup_workers() local 1128 for (int n = 0; n < npids; ++n) { in server_main_setup_workers() local 1129 if (-1 == pids[n]) { in server_main_setup_workers() 1130 pids[n] = pid; in server_main_setup_workers() 1159 for (int n = 0; n < npids; ++n) { in server_main_setup_workers() local 1161 pids[n] = -1; in server_main_setup_workers() 1177 for (int n = 0; n < npids; ++n) { in server_main_setup_workers() local [all …]
|
| H A D | configfile-glue.c | 298 uint32_t n = 0; in config_plugin_values_init() local 314 matches[n] = 0; in config_plugin_values_init() 320 ++matches[n]; in config_plugin_values_init() 338 if (matches[n]) contexts[n++] = (unsigned short)u; in config_plugin_values_init() 342 for (uint32_t u = 0; u < n; ++u) elts += matches[u]; in config_plugin_values_init() 343 p->nconfig = n; in config_plugin_values_init() 347 ck_calloc(1+n+n+elts, sizeof(config_plugin_value_t)); in config_plugin_values_init() 349 elts = 1+n; in config_plugin_values_init() 351 const uint32_t shft = (0 != n && 0 != contexts[0]); in config_plugin_values_init() 353 for (uint32_t u = 0; u < n; ++u) { in config_plugin_values_init() [all …]
|
| H A D | buffer.c | 218 …fer_append_iovec(buffer * const restrict b, const struct const_iovec * const iov, const size_t n) { in buffer_append_iovec() argument 220 for (size_t i = 0; i < n; ++i) in buffer_append_iovec() 223 for (size_t i = 0; i < n; ++i) { in buffer_append_iovec() 366 #define li_ntox_lc(n) ((n) <= 9 ? (n) + '0' : (n) + 'a' - 10) argument 369 #define li_cton(c,n) \ argument 370 (((n) = (c) - '0') <= 9 || (((n) = ((c)&0xdf) - 'A') <= 5 ? ((n) += 10) : 0)) 376 unsigned char n; in hex2int() local 377 return li_cton(hex,n) ? (char)n : 0xFF; in hex2int()
|
| H A D | network.c | 121 uint32_t n = 0; in network_abstract_socket_enc() local 123 n += (sun_path[i]-20 < 107) ? 1 : 4; in network_abstract_socket_enc() 124 char *s = buffer_extend(abstract, n); in network_abstract_socket_enc() 149 uint32_t n = 0; in network_abstract_socket_dec() local 150 for (int hi, lo; *s && n < plen; ++n) { in network_abstract_socket_dec() 152 sun_path[n] = *s++; in network_abstract_socket_dec() 156 sun_path[n] = (char)((hi << 4) | lo); in network_abstract_socket_dec() 162 return *s == '\0' ? n : 0; in network_abstract_socket_dec() 636 for (uint32_t n = 0, i; n < srv->srv_sockets.used; ++n) { in network_socket_activation_to_env() local 645 for (i = n+1; i < srv->srv_sockets.used; ++i) { in network_socket_activation_to_env() [all …]
|
| H A D | sys-strings.h | 13 #define strncasecmp(s1,s2,n) _strnicmp(s1,s2,n) argument
|
| H A D | request.c | 28 static const struct sn { const char *s; uint32_t n; } states[] = { in http_request_state_append() member 44 buffer_append_string_len(b, p->s, p->n); in http_request_state_append() 223 static struct { char s[INET_ADDRSTRLEN]; size_t n; } laddr; in http_request_host_normalize() member 224 size_t n = colon ? (size_t)(colon - p) : blen; in http_request_host_normalize() local 226 if (n == laddr.n && 0 == memcmp(p, laddr.s, n)) break; in http_request_host_normalize() 229 n = buffer_clen(b); in http_request_host_normalize() 230 if (n < sizeof(laddr.s)) memcpy(laddr.s, b->ptr, (laddr.n = n)); in http_request_host_normalize() 237 static struct { char s[INET6_ADDRSTRLEN]; size_t n; } laddr; in http_request_host_normalize() member 262 if (laddr.n == len && 0 == memcmp(laddr.s, b->ptr+1, len)) { in http_request_host_normalize() 280 if (len < sizeof(laddr.s)) memcpy(laddr.s, buf, (laddr.n = len)); in http_request_host_normalize()
|
| H A D | http_header.c | 362 http_header_parse_hoff (const char *n, const uint32_t clen, unsigned short hoff[8192]) in http_header_parse_hoff() argument 365 for (const char *b; (n = memchr((b = n),'\n',clen-hlen)); ++n) { in http_header_parse_hoff() 366 uint32_t x = (uint32_t)(n - b + 1); in http_header_parse_hoff() 368 if (x <= 2 && (x == 1 || n[-1] == '\r')) { in http_header_parse_hoff()
|
| /lighttpd1.4/src/t/ |
| H A D | test_request.c | 34 for (const char *n=req, *end=req+reqlen; (n=memchr(n,'\n',end-n)); ++n) { in run_http_request_parse() local 36 hloffsets[hloffsets[0]] = n - req + 1; in run_http_request_parse()
|