Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:32078 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 63468 invoked by uid 1010); 6 Sep 2007 09:30:09 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 63436 invoked from network); 6 Sep 2007 09:30:09 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 6 Sep 2007 09:30:09 -0000 Authentication-Results: pb1.pair.com smtp.mail=buildsmart@daleenterprise.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=buildsmart@daleenterprise.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain daleenterprise.com from 67.78.11.229 cause and error) X-PHP-List-Original-Sender: buildsmart@daleenterprise.com X-Host-Fingerprint: 67.78.11.229 daleenterprise.com Received: from [67.78.11.229] ([67.78.11.229:54681] helo=daleenterprise.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 07/79-25837-0A8CFD64 for ; Thu, 06 Sep 2007 05:30:08 -0400 Received: from localhost (localhost [127.0.0.1]) by daleenterprise.com (Postfix) with ESMTP id D9A86238B4E; Thu, 6 Sep 2007 05:30:05 -0400 (EDT) Received: from daleenterprise.com ([127.0.0.1]) by localhost (daleenterprise.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 25084-17; Thu, 6 Sep 2007 05:30:02 -0400 (EDT) Received: from [10.1.100.11] (relay.mustangrestomods.com [67.78.11.226]) by daleenterprise.com (Postfix) with ESMTP id E9C55238B42; Thu, 6 Sep 2007 05:29:51 -0400 (EDT) In-Reply-To: <46DFB940.7040600@mysql.com> References: <46DF60BF.9090805@lerdorf.com> <5430305D-28D0-48C6-8A21-4E711CF21311@daleenterprise.com> <46DFB940.7040600@mysql.com> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-ID: <3044D92E-CAB5-4BDD-82A7-FE6751B54C0D@daleenterprise.com> Cc: PHP Developers Mailing List , Rasmus Lerdorf Content-Transfer-Encoding: 7bit Date: Thu, 6 Sep 2007 05:29:51 -0400 To: Hartmut Holzgraefe X-Pgp-Agent: GPGMail 1.1.2 (Tiger) X-Mailer: Apple Mail (2.752.2) MTA-Interface: amavisd-new-2.3.3 (2005-08-22) + Maia Mailguard 1.1.0 at daleenterprise.com X-Spam-Scanned: using SpamAssassin 3.1.7 (2006-10-05) at daleenterprise.com X-Virus-Scanned: using ClamAV 0.88.6 (2006-11-05) at daleenterprise.com Subject: Re: [PHP-DEV] proof of concept or undocumented? From: buildsmart@daleenterprise.com (BuildSmart) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Sep 6, 2007, at 04:24:32, Hartmut Holzgraefe wrote: > BuildSmart wrote: > >> The only differences I could find was that openssl was enabled in >> the working builds but not enabled in the failing build. > [...] >> I went a step further and manually added the ssl libraries (-lssl - >> lcrypto) to the Makefile (both as bundled and shared) and all >> worked well. >> This cannot be considered a bug (or maybe it is), perhaps an >> additional check could/should be performed to see if mysql is >> built with SSL support and if so check whether openssl is enabled >> and add the ssl libraries to the sapi build or to >> MYSQL_SHARED_LDADD if it's not or to auto-enable openssl? > > yes, ext/mysql is not too clever about this and simply relies > on ext/openssl being enabled at the same time. > > Adding an extra test can't rely on mysql_config though as AFAIR > it is not using mysql_config at all. > > If you want to check whether you'd need to add a compile/link > test with a small example program that tries to e.g. use my current test was to change it to use mysql_config to retrieve the library details which seemed to work. > > http://dev.mysql.com/doc/refman/4.1/en/mysql-ssl-set.html > > I'm not sure though whether this function is only available > with ssl-enabled MySQL builds or whether it is always there > and just returning error codes, i think it is the later so > you'd have to create a functionality test, not just a simple > "does it compile and link without errors" one. Based on your suggestion I tested this and sure enough, simple compiling tests are inconclusive because it returns 0 even when ssl is not available in mysql5 and a test of anything less than a valid mysql ssl connection seems to be inadequate (or I haven't located/ performed the correct test yet). In mysql4 (4.1.10 and 4.1.13) it doesn't seem to initialize the ssl library automatically (or properly) and ext/mysql doesn't call mysql_ssl_set so while a connection can be established, I couldn't execute any queries successfully or retrieve any server info (just query failures). > > As this is not a change to the actual functionality of ext/mysql > i think a working patch would be accepted even though the > extension is deprecated by now. OTOH i don't really think it > is worth the effort anymore though ... If it's been EOL'd or NLS'd then working on it doesn't make for a sound decision and my time would be better spent learning how to replace mysql calls with mysqli calls if mysqli has been proven to work properly with mysql-ssl connections. > > -- > Hartmut Holzgraefe, Principal Support Engineer - -- Dale -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (Darwin) iD8DBQFG38iP0hzWbkf0eKgRAvBCAJ9p84pkizvy/toQW/QgKk0p+fdN2gCeJ91Y rKwGtxetE+Tt5UDD155mWC8= =uqIR -----END PGP SIGNATURE-----