comparison src/imap/ngx_imap.h @ 250:fbf2b2f66c9f NGINX_0_4_10

nginx 0.4.10 *) Feature: the POP3 proxy supports the APOP command. *) Bugfix: if the select, poll or /dev/poll methods were used, then while waiting authentication server response the IMAP/POP3 proxy hogged CPU. *) Bugfix: a segmentation fault might occur if the $server_addr variable was used in the "map" directive. *) Bugfix: the ngx_http_flv_module did not support the byte ranges for full responses; bug appeared in 0.4.7. *) Bugfix: nginx could not be built on Debian amd64; bug appeared in 0.4.9.
author Igor Sysoev <http://sysoev.ru>
date Mon, 23 Oct 2006 00:00:00 +0400
parents 56688ed172c8
children 644510700914
comparison
equal deleted inserted replaced
249:7a34085272cb 250:fbf2b2f66c9f
84 ngx_str_t pop3_capability; 84 ngx_str_t pop3_capability;
85 ngx_str_t pop3_starttls_capability; 85 ngx_str_t pop3_starttls_capability;
86 ngx_str_t imap_capability; 86 ngx_str_t imap_capability;
87 ngx_str_t imap_starttls_capability; 87 ngx_str_t imap_starttls_capability;
88 ngx_str_t imap_starttls_only_capability; 88 ngx_str_t imap_starttls_only_capability;
89
90 ngx_str_t server_name;
91
92 ngx_uint_t auth_methods;
89 93
90 ngx_array_t pop3_capabilities; 94 ngx_array_t pop3_capabilities;
91 ngx_array_t imap_capabilities; 95 ngx_array_t imap_capabilities;
92 96
93 /* server ctx */ 97 /* server ctx */
147 unsigned protocol:1; 151 unsigned protocol:1;
148 unsigned quoted:1; 152 unsigned quoted:1;
149 unsigned backslash:1; 153 unsigned backslash:1;
150 unsigned no_sync_literal:1; 154 unsigned no_sync_literal:1;
151 unsigned starttls:1; 155 unsigned starttls:1;
156 unsigned auth_method:1;
152 157
153 ngx_str_t login; 158 ngx_str_t login;
154 ngx_str_t passwd; 159 ngx_str_t passwd;
155 160
161 ngx_str_t salt;
156 ngx_str_t tag; 162 ngx_str_t tag;
157 ngx_str_t tagged_line; 163 ngx_str_t tagged_line;
158 164
159 ngx_str_t *addr_text; 165 ngx_str_t *addr_text;
160 166
177 ngx_str_t *client; 183 ngx_str_t *client;
178 ngx_imap_session_t *session; 184 ngx_imap_session_t *session;
179 } ngx_imap_log_ctx_t; 185 } ngx_imap_log_ctx_t;
180 186
181 187
182 #define NGX_POP3_USER 1 188 #define NGX_POP3_USER 1
183 #define NGX_POP3_PASS 2 189 #define NGX_POP3_PASS 2
184 #define NGX_POP3_CAPA 3 190 #define NGX_POP3_CAPA 3
185 #define NGX_POP3_QUIT 4 191 #define NGX_POP3_QUIT 4
186 #define NGX_POP3_NOOP 5 192 #define NGX_POP3_NOOP 5
187 #define NGX_POP3_STLS 6 193 #define NGX_POP3_STLS 6
188 #define NGX_POP3_APOP 7 194 #define NGX_POP3_APOP 7
189 #define NGX_POP3_STAT 8 195 #define NGX_POP3_STAT 8
190 #define NGX_POP3_LIST 9 196 #define NGX_POP3_LIST 9
191 #define NGX_POP3_RETR 10 197 #define NGX_POP3_RETR 10
192 #define NGX_POP3_DELE 11 198 #define NGX_POP3_DELE 11
193 #define NGX_POP3_RSET 12 199 #define NGX_POP3_RSET 12
194 #define NGX_POP3_TOP 13 200 #define NGX_POP3_TOP 13
195 #define NGX_POP3_UIDL 14 201 #define NGX_POP3_UIDL 14
196 202
197 203
198 #define NGX_IMAP_LOGIN 1 204 #define NGX_IMAP_LOGIN 1
199 #define NGX_IMAP_LOGOUT 2 205 #define NGX_IMAP_LOGOUT 2
200 #define NGX_IMAP_CAPABILITY 3 206 #define NGX_IMAP_CAPABILITY 3
201 #define NGX_IMAP_NOOP 4 207 #define NGX_IMAP_NOOP 4
202 #define NGX_IMAP_STARTTLS 5 208 #define NGX_IMAP_STARTTLS 5
203 209
204 #define NGX_IMAP_NEXT 6 210 #define NGX_IMAP_NEXT 6
211
212
213 #define NGX_IMAP_AUTH_PLAIN 0
214 #define NGX_IMAP_AUTH_APOP 1
215
216
217 #define NGX_IMAP_AUTH_PLAIN_ENABLED 0x0002
218 #define NGX_IMAP_AUTH_APOP_ENABLED 0x0004
205 219
206 220
207 #define NGX_IMAP_PARSE_INVALID_COMMAND 20 221 #define NGX_IMAP_PARSE_INVALID_COMMAND 20
208 222
209 223