It might be better to create a module level static variable of type __ngx_string__ with _"x-amz-date"_ as its value. We can then have reuse the __u_char*__ and the __length__ fields throughout the module