Bug #14089 Updated: use of mcrypt functions result in segfault of apache child

From: Date: Sat, 17 Nov 2001 11:26:08 +0000
Subject: Bug #14089 Updated: use of mcrypt functions result in segfault of apache child
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-70713@lists.php.net to get a copy of this message
ID: 14089 Updated by: derick Reported By: mued@dev-edge.org Old Status: Open Status: Closed Bug Type: mcrypt related Operating System: GNU/Debian Sid PHP Version: 4.0CVS-2001-11-16 Assigned To: derick New Comment: I think you meant 2.4.6, if that is the case, upgrade to 2.4.17, which has a lot of bugs fixed. I'm closing this bug, because it's a merely a problem in the libmcrypt library itself. Please reopen if upgrading does not fix the problem. Derick Previous Comments: ------------------------------------------------------------------------ [2001-11-16 21:28:20] mued@dev-edge.org libmcrypt is 4.2.6 ------------------------------------------------------------------------ [2001-11-16 21:11:26] mued@dev-edge.org sablotron seem to be another bug when I remove some params from config.nice & relaunch compilation here's the debug trace given when apache hit the code producing problems Program received signal SIGSEGV, Segmentation fault. 0x40b6fb2d in tripledes_LTX__mcrypt_decrypt () from /usr/lib/libmcrypt/tripledes.so Here's the code, function amp_prepare_pass() { global $PASSWD_KEY; // set it into your amp_secure.php $yor["td"] = mcrypt_module_open (MCRYPT_TripleDES, "", MCRYPT_MODE_ECB, ""); $yor["iv"] = mcrypt_create_iv (mcrypt_enc_get_iv_size ( $yor["td"] ), MCRYPT_RAND); mcrypt_generic_init ($yor["td"], $PASSWD_KEY, $yor["iv"]); return $yor; } function amp_encode_pass( $str ) { $all_needed = amp_prepare_pass(); $encrypted_data = mcrypt_generic ($all_needed["td"], $str); @mcrypt_generic_end ( $all_needed["td"] ); return $encrypted_data; } function amp_decode_pass( $str ) { $all_needed = amp_prepare_pass(); $decrypted_data = mdecrypt_generic ($all_needed["td"], $str); @mcrypt_generic_end ( $all_needed["td"] ); return $decrypted_data; } ------------------------------------------------------------------------ [2001-11-16 20:09:04] derick@php.net Please post your script, and which version of libmcrypt (not mcrypt) you use. Derick ------------------------------------------------------------------------ [2001-11-16 20:00:28] mued@dev-edge.org Hi, I just encountered strange segfault with current cvs version. When using ming or mcrypt connectors, the apache child doing task is going into defunct activity. mcrypt is 2.5.7 sablotron is 0.71 apache is 1.3.22, deb binary & source recompiled for test linux kernel is 2.4.6 On debug bactracing on php, when launching httpd -X a message from sablotron comes up Cannot load /usr/lib/apache/1.3/libphp4.so into server: /usr/lib/apache/1.3/libp hp4.so: undefined symbol: sablot_module_entry current php's configuration parameters: './configure' '--enable-inline-optimization' '--enable-mbstr-enc-trans' '--enable-mbstring' '--prefix=/usr' '--with-apxs=/usr/bin/apxs' '--with-regex=system' '--with-config-file-path=/etc/php4/apache' '--disable-rpath' '--enable-memory-limit' '--enable-calendar' '--enable-sysvsem' '--enable-sysvshm' '--enable-track-vars' '--enable-trans-sid' '--disable-debug' '--disable-static' '--with-bz2' '--with-curl=shared,/usr' '--with-db2' '--with-ndbm' '--with-dom=shared,/usr' '--enable-exif' '--enable-filepro' '--enable-ftp' '--with-gettext' '--with-gd=shared' '--enable-gd-native-ttf' '--with-png-dir=/usr' '--with-jpeg-dir=/usr' '--with-xpm-dir=/usr/X11R6' '--with-mhash=shared' '--with-mysql=shared,/usr' '--with-pcre-regex=/usr' '--with-pgsql=shared,/usr' '--with-sablot=shared,/usr' '--enable-sablot-errors-descriptive' '--enable-shmop' '--enable-sockets' '--with-ttf=/usr' '--with-t1lib=/usr' '--with-tiff-dir=/usr' '--enable-yp' '--with-zlib' '--with-mcrypt' '--with-pspell=/usr' '--with-dom=/usr' '--with-ming' '--enable-sockets' '--enable-freetype-4bit-antialias-hack' '--with-pdflib=/usr' '--enable-shared-pdflib' '--enable-ucd-snmp-hack' '--with-recode=/usr' hope this will help Regards, mued ------------------------------------------------------------------------ Edit this bug report at http://bugs.php.net/?id=14089&edit=1

« previous php.dev (#70713) next »