# HG changeset patch # User Igor Sysoev # Date 1163755846 0 # Node ID 0197d6aae54e53176eed05e5778e7a6afa02c4a1 # Parent b006f30d6a2faf6b17f92856a64e98f79bd68851 use correct auth method length diff --git a/src/imap/ngx_imap_auth_http_module.c b/src/imap/ngx_imap_auth_http_module.c --- a/src/imap/ngx_imap_auth_http_module.c +++ b/src/imap/ngx_imap_auth_http_module.c @@ -1039,7 +1039,9 @@ ngx_imap_auth_http_create_request(ngx_im len = sizeof("GET ") - 1 + ahcf->uri.len + sizeof(" HTTP/1.0" CRLF) - 1 + sizeof("Host: ") - 1 + ahcf->host_header.len + sizeof(CRLF) - 1 - + sizeof("Auth-Method: plain" CRLF) - 1 + + sizeof("Auth-Method: ") - 1 + + ngx_imap_auth_http_method[s->auth_method].len + + sizeof(CRLF) - 1 + sizeof("Auth-User: ") - 1 + login.len + sizeof(CRLF) - 1 + sizeof("Auth-Pass: ") - 1 + passwd.len + sizeof(CRLF) - 1 + sizeof("Auth-Salt: ") - 1 + s->salt.len