#include <ngx_config.h>
#include <ngx_core.h>
#include <ngx_http.h>
#define NGX_HTTP_USERID_OFF …
#define NGX_HTTP_USERID_LOG …
#define NGX_HTTP_USERID_V1 …
#define NGX_HTTP_USERID_ON …
#define NGX_HTTP_USERID_COOKIE_OFF …
#define NGX_HTTP_USERID_COOKIE_SECURE …
#define NGX_HTTP_USERID_COOKIE_HTTPONLY …
#define NGX_HTTP_USERID_COOKIE_SAMESITE …
#define NGX_HTTP_USERID_COOKIE_SAMESITE_STRICT …
#define NGX_HTTP_USERID_COOKIE_SAMESITE_LAX …
#define NGX_HTTP_USERID_COOKIE_SAMESITE_NONE …
#define NGX_HTTP_USERID_MAX_EXPIRES …
ngx_http_userid_conf_t;
ngx_http_userid_ctx_t;
static ngx_http_userid_ctx_t *ngx_http_userid_get_uid(ngx_http_request_t *r,
ngx_http_userid_conf_t *conf);
static ngx_int_t ngx_http_userid_variable(ngx_http_request_t *r,
ngx_http_variable_value_t *v, ngx_str_t *name, uint32_t *uid);
static ngx_int_t ngx_http_userid_set_uid(ngx_http_request_t *r,
ngx_http_userid_ctx_t *ctx, ngx_http_userid_conf_t *conf);
static ngx_int_t ngx_http_userid_create_uid(ngx_http_request_t *r,
ngx_http_userid_ctx_t *ctx, ngx_http_userid_conf_t *conf);
static ngx_int_t ngx_http_userid_add_variables(ngx_conf_t *cf);
static ngx_int_t ngx_http_userid_init(ngx_conf_t *cf);
static void *ngx_http_userid_create_conf(ngx_conf_t *cf);
static char *ngx_http_userid_merge_conf(ngx_conf_t *cf, void *parent,
void *child);
static char *ngx_http_userid_domain(ngx_conf_t *cf, void *post, void *data);
static char *ngx_http_userid_path(ngx_conf_t *cf, void *post, void *data);
static char *ngx_http_userid_expires(ngx_conf_t *cf, ngx_command_t *cmd,
void *conf);
static char *ngx_http_userid_p3p(ngx_conf_t *cf, void *post, void *data);
static char *ngx_http_userid_mark(ngx_conf_t *cf, ngx_command_t *cmd,
void *conf);
static ngx_int_t ngx_http_userid_init_worker(ngx_cycle_t *cycle);
static uint32_t start_value;
static uint32_t sequencer_v1 = …;
static uint32_t sequencer_v2 = …;
static u_char expires[] = …;
static ngx_http_output_header_filter_pt ngx_http_next_header_filter;
static ngx_conf_enum_t ngx_http_userid_state[] = …;
static ngx_conf_bitmask_t ngx_http_userid_flags[] = …;
static ngx_conf_post_handler_pt ngx_http_userid_domain_p = …;
static ngx_conf_post_handler_pt ngx_http_userid_path_p = …;
static ngx_conf_post_handler_pt ngx_http_userid_p3p_p = …;
static ngx_command_t ngx_http_userid_commands[] = …;
static ngx_http_module_t ngx_http_userid_filter_module_ctx = …;
ngx_module_t ngx_http_userid_filter_module = …;
static ngx_str_t ngx_http_userid_got = …;
static ngx_str_t ngx_http_userid_set = …;
static ngx_str_t ngx_http_userid_reset = …;
static ngx_uint_t ngx_http_userid_reset_index;
static ngx_int_t
ngx_http_userid_filter(ngx_http_request_t *r)
{ … }
static ngx_int_t
ngx_http_userid_got_variable(ngx_http_request_t *r,
ngx_http_variable_value_t *v, uintptr_t data)
{ … }
static ngx_int_t
ngx_http_userid_set_variable(ngx_http_request_t *r,
ngx_http_variable_value_t *v, uintptr_t data)
{ … }
static ngx_http_userid_ctx_t *
ngx_http_userid_get_uid(ngx_http_request_t *r, ngx_http_userid_conf_t *conf)
{ … }
static ngx_int_t
ngx_http_userid_set_uid(ngx_http_request_t *r, ngx_http_userid_ctx_t *ctx,
ngx_http_userid_conf_t *conf)
{ … }
static ngx_int_t
ngx_http_userid_create_uid(ngx_http_request_t *r, ngx_http_userid_ctx_t *ctx,
ngx_http_userid_conf_t *conf)
{ … }
static ngx_int_t
ngx_http_userid_variable(ngx_http_request_t *r, ngx_http_variable_value_t *v,
ngx_str_t *name, uint32_t *uid)
{ … }
static ngx_int_t
ngx_http_userid_reset_variable(ngx_http_request_t *r,
ngx_http_variable_value_t *v, uintptr_t data)
{ … }
static ngx_int_t
ngx_http_userid_add_variables(ngx_conf_t *cf)
{ … }
static void *
ngx_http_userid_create_conf(ngx_conf_t *cf)
{ … }
static char *
ngx_http_userid_merge_conf(ngx_conf_t *cf, void *parent, void *child)
{ … }
static ngx_int_t
ngx_http_userid_init(ngx_conf_t *cf)
{ … }
static char *
ngx_http_userid_domain(ngx_conf_t *cf, void *post, void *data)
{ … }
static char *
ngx_http_userid_path(ngx_conf_t *cf, void *post, void *data)
{ … }
static char *
ngx_http_userid_expires(ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
{ … }
static char *
ngx_http_userid_p3p(ngx_conf_t *cf, void *post, void *data)
{ … }
static char *
ngx_http_userid_mark(ngx_conf_t *cf, ngx_command_t *cmd, void *conf)
{ … }
static ngx_int_t
ngx_http_userid_init_worker(ngx_cycle_t *cycle)
{ … }