Nginx-1.0.3

Changes with nginx 1.0.3 25 May
2011

*) Feature: the "auth_basic_user_file" directive supports "$apr1",
   "{PLAIN}", and "{SSHA}" password encryption methods.
   Thanks to Maxim D..

*) Feature: the "geoip_org" directive and $geoip_org variable.
   Thanks to Alexander Uskov, Arnaud Granal, and Denis F. Latypoff.

*) Feature: ngx_http_geo_module and ngx_http_geoip_module support 

IPv4
addresses mapped to IPv6 addresses.

*) Bugfix: a segmentation fault occurred in a worker process during
   testing IPv4 address mapped to IPv6 address, if access or deny 

rules
were defined only for IPv6; the bug had appeared in 0.8.22.

*) Bugfix: a cached reponse may be broken if proxy/fastcgi/scgi/
   uwsgi_cache_bypass and proxy/fastcgi/scgi/uwsgi_no_cache 

directive
values were different; the bug had appeared in 0.8.46.


Igor S.

It has a bug!

Build with :
./configure --without-http_auth_basic_module && make

objs/src/core/ngx_crypt.o: In function ngx_crypt': ngx_crypt.c:(.text+0x7b): undefined reference tongx_libc_crypt’
collect2: ld returned 1 exit status
make[1]: *** [objs/nginx] Error 1
make[1]: Leaving directory `/root/nginx-1.0.3’
make: *** [build] Error 2

But ok when:
./configure && make

2011/5/25 Igor S. [email protected]

I think there is the point:

in ngx_crypt.c
ngx_int_t
ngx_crypt(ngx_pool_t *pool, u_char *key, u_char *salt, u_char
**encrypted)
{
if (ngx_strncmp(salt, “$apr1$”, sizeof("$apr1$") - 1) == 0) {
return ngx_crypt_apr1(pool, key, salt, encrypted);
} else if (ngx_strncmp(salt, “{PLAIN}”, sizeof("{PLAIN}") - 1) == 0)
{
return ngx_crypt_plain(pool, key, salt, encrypted);

#if (NGX_HAVE_SHA1)
} else if (ngx_strncmp(salt, “{SSHA}”, sizeof("{SSHA}") - 1) == 0) {
return ngx_crypt_ssha(pool, key, salt, encrypted);
#endif
}

/* fallback to libc crypt() */
return ngx_libc_crypt(pool, key, salt, encrypted);

}

and there is no libc crypt in my system.

So , I think is a bug .

2011/5/26 Wendal C. [email protected]

Hi Maxim,

i am getting the same error on my (MAC os x lion),thanks for the reply
but how do i apply above patch, i have never applied the patch
before…please reply…i am using nginx 1.1.2

Hello!

On Thu, May 26, 2011 at 10:09:27AM +0800, Wendal C. wrote:

make: *** [build] Error 2

But ok when:
./configure && make

Thank you for your report. The following patch unbreaks build
without auth basic module:

diff --git a/src/core/ngx_crypt.c b/src/core/ngx_crypt.c
— a/src/core/ngx_crypt.c
+++ b/src/core/ngx_crypt.c
@@ -11,6 +11,7 @@
#include <ngx_sha1.h>
#endif

+#if (NGX_CRYPT)

static ngx_int_t ngx_crypt_apr1(ngx_pool_t *pool, u_char *key, u_char
*salt,
u_char **encrypted);
@@ -232,3 +233,5 @@ ngx_crypt_ssha(ngx_pool_t *pool, u_char
}

#endif /* NGX_HAVE_SHA1 /
+
+#endif /
NGX_CRYPT */

Maxim D.

Hello!

On Thu, Mar 01, 2012 at 01:33:16PM +0100, umesh chaudhari wrote:

Hi Maxim,

i am getting the same error on my (MAC os x lion),thanks for the reply
but how do i apply above patch, i have never applied the patch
before…please reply

Just upgrade to the latest version, the problem in question was
fixed in nginx 1.0.4 and there is no need to apply the patch
anymore.

Maxim D.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs