<div dir="ltr"><span style="font-size:12.8px">Hi,</span><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">I am trying to make a dynamic nginx module. After reading all the tutorials and stuff available I set up a working minimal sample and started hooking up my http handlers. The question that arose is, in the static modules the http module configuration is retrieved like this (in a lets say postconfiguration handler):</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px"><div>static ngx_int_t postconfiguration_handler(ngx_<wbr>conf_t* cf)</div><div>{</div><div><span style="white-space:pre-wrap">    </span>ngx_http_core_main_conf_t* nginx_http_configuration = reinterpret_cast<ngx_http_core<wbr>_main_conf_t*>(ngx_http_conf_g<wbr>et_module_main_conf(cf, ngx_http_core_module));</div></div><div style="font-size:12.8px">        ...</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">If I'm not overlooking something this will not work (and in my case does not) with a dynamic module</div><div style="font-size:12.8px">the ngx_http_core_module.ctx_index is not initialized since the initialized version of ngx_http_core_module lives inside nginx.exe (where it is set by ngx_count_modules) and my dll does not see that. If could run through the module list and find what I need, but I just wanted to know if there is a better solution already in place.</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">Best Regards,</div><div style="font-size:12.8px">Rudolfs Bundulis</div></div>