Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cePSo-0002wh-BX for pgsql-odbc@arkaria.postgresql.org; Thu, 16 Feb 2017 17:03:26 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1cePSn-00008a-Uj for pgsql-odbc@arkaria.postgresql.org; Thu, 16 Feb 2017 17:03:25 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1ceIiE-0008It-Sl for pgsql-odbc@postgresql.org; Thu, 16 Feb 2017 09:50:55 +0000 Received: from mail-wr0-x233.google.com ([2a00:1450:400c:c0c::233]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1ceIiB-0005bk-0L for pgsql-odbc@postgresql.org; Thu, 16 Feb 2017 09:50:53 +0000 Received: by mail-wr0-x233.google.com with SMTP id 89so3205124wrr.3 for ; Thu, 16 Feb 2017 01:50:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denodo-com.20150623.gappssmtp.com; s=20150623; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to; bh=XDsxJSuu3C4UVfSjCtalX6YBs9NanxgxKq9B8c/bMQQ=; b=kBHX6GYzKioGKPoe8sbRRBB8d6BhcQtnLI0GnFMcuR8QoI8auUuQ28rcnZwQRRzQM2 PMm3lZBJDqADV9FAB0eD7pXg4/3nWv1SG09GIrWLZ5PYLPqW5a/DCkHVle7Scku7kLwr yiwQgyz4nu1vOc6sP2Uwkk2yfejeTi/2HOyWgKEA6QQ9eyU4fKWzTKqTh0I4DLUCo5W5 oth6bVNe35p+tCwHmn1rzRwvFXNxJfzpcIS8aKFAEkpuhslDHTiWenEbP/nepGb2T48L 4keCqAAyLUCc7oveh3wbDNcYUpob2LNln4BsfW9TEFeY64Cx8aO0nduoMUJQY2cNOrY6 m87A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to; bh=XDsxJSuu3C4UVfSjCtalX6YBs9NanxgxKq9B8c/bMQQ=; b=RqMCAPVKjI9Y0Sh6b40w0YAiFbgh1ixUzwrx1/0xBuFELN4zNUoWSvuPWFaMQAu/J1 wqxaicbTI+CUZowhE9eBxGuxo1xzeIjhjGeZDuqLW1uz6TcjOUKycMbwSc1J03wKVFEu O3igiTgDtsVhtMLexRajVBDDJ+VBlOI/dFmRPwovTxAbKiwkqmw1K3J0fQEEvDAy6uup TCPnZcSn5i0cxGRcRe0i5h7TlZKnLX50iZGiZ2ht0FijSnE9Yt9iq9qKMxqPjHyA2r3X gA1s+Lf8zP2GMnyTVvEM+ywQI8X35UHDYDAyXUdI82EnXNXVHzkdGu6wdBsjV73e+qmU s/KA== X-Gm-Message-State: AMke39nrGt77fuvyAPk4bFDAKkpv5JVA+8MemGk106uqKE7nurOCbv9yrVEEdj18IljNiqQrL3HhcGRDueOqx14I/NYO61OCtjOaUWMwnAAtvBXboxm/QNocxRiWpU9Nqil0ztf5Mn82V4NoaOXAHBotaWb+sre9VFbmVjIuzZPAX77EAg+5zXuaKA== X-Received: by 10.223.134.151 with SMTP id 23mr1558150wrx.0.1487238648104; Thu, 16 Feb 2017 01:50:48 -0800 (PST) Received: from [10.73.0.18] (cor210.network.denodo.com. [212.51.61.210]) by smtp.gmail.com with ESMTPSA id w126sm1430446wmw.0.2017.02.16.01.50.47 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 16 Feb 2017 01:50:47 -0800 (PST) Subject: Re: Informatica and SSL connections To: "Inoue, Hiroshi" References: <56d70599-a90f-3af3-3d1b-82f8ffb75c1c@dream.email.ne.jp> <89e84f06-3141-e93b-098b-71ef182e25ae@dream.email.ne.jp> Cc: pgsql-odbc@postgresql.org From: =?UTF-8?Q?Jacobo_S=c3=a1nchez?= Message-ID: <38bd12e3-4cd6-1284-7a3b-b63053a14df3@denodo.com> Date: Thu, 16 Feb 2017 10:50:45 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <89e84f06-3141-e93b-098b-71ef182e25ae@dream.email.ne.jp> Content-Type: multipart/alternative; boundary="------------CB95CD8F6357F1C94E13582E" X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-odbc Precedence: bulk Sender: pgsql-odbc-owner@postgresql.org This is a multi-part message in MIME format. --------------CB95CD8F6357F1C94E13582E Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Hi again I could somehow install a similar environment in my machine and new version also crashes when using SSL. However from what i have found from google it points more to an issue with libpq (interacting with some other libraries maybe). I could avoid the issue by not calling PQFinish() in method SOCK_Destructor of socket.c from version 09.03.400 but im not sure which kind of problems/leaks this may raise, do you have any idea of how bad may be this workaround? I could also reproduce the error by installing 32 bit version of heidiSQL (following the error described in http://www.heidisql.com/forum.php?t=15646) and it also crashes calling PQFinish() method (by calling directly libpq and not using ODBC). There is also an old (2005) thread in the postgres mailing list that seems related but im not really sure http://postgresql.nabble.com/BUG-2246-Bad-malloc-interactions-ecpg-openssl-td2119930.html All i found points more to libpq than to the driver itself. However seems to be a tricky thing and i have not an isolated test case without using external clients :( Regards Jacobo El 14/02/17 a las 12:21, Inoue, Hiroshi escribió: > Hi, > > On 2017/02/14 17:34, Jacobo Sánchez wrote: >> >> Hello >> >> >> Im currently looking for a test environment under my control in >> order to check this or any other solution. Is there any specific >> change that may lead to think that this could be already fixed in >> 09.06.100? > > After 09.05.0100 the driver uses libpq fully, whereas the driver used > libpq partially before. > > regards, > Hiroshi Inoue > >> That may give me a chance to speed up things by asking for testing it >> in a real environment. >> >> Thanks for your response, I will notify the results with >> 09.06.100 when tested. >> >> >> Regards >> >> Jacobo >> >> >> El 14/02/17 a las 03:26, Inoue, Hiroshi escribió: >>> Hi Jacobo, >>> >>> On 2017/02/14 1:06, Jacobo Sánchez wrote: >>>> >>>> Hello all >>>> >>>> >>>> Im facing an issue using the ODBC driver from Informatica which may >>>> be resumed in the following (im using 09.03.400): >>> >>> Could you try the latest version 09.06.0100? >>> >>> regards, >>> Hiroshi Inoue >>> >>>> https://kb.informatica.com/solution/23/Pages/52/320564.aspx >>>> >>>> If someone does not want to open the URL the failing trace is as >>>> follows: >>>> >>>> Crashing Thread is as follows: >>>> >>>> ntdll!RtlFreeHeap+132 >>>> msvcrt!free+1c >>>> libeay32!CRYPTO_free+2e >>>> libeay32!ASN1_STRING_free+27 >>>> libeay32!ASN1_primitive_free+ac >>>> libeay32!ASN1_template_free+128 >>>> libeay32!ASN1_template_free+9b >>>> libeay32!ASN1_item_free+1e9 >>>> libeay32!X509_free+1a >>>> libpq!PQinitSSL+105c >>>> libpq!PQinitSSL+1113 >>>> libpq!PQencryptPassword+7cf >>>> libpq!PQfinish+12 >>>> psqlodbc35w!ConfigDriver+1b7e >>>> psqlodbc35w!Ordinal93+4162 >>>> psqlodbc35w!Ordinal93+3285 >>>> psqlodbc35w!SQLDisconnect+5f >>>> odbc32!SQLDisconnect+2ae >>>> pmodbc!TODBCDb::Disconnect+7f >>>> pmodlnt!TDatabase::Disconnect+3c >>>> pmrelrdr!relReader::fetch+54be >>>> pmservnt!readerSource::operator=+307f >>>> pmservnt!DTMMain+219e8 >>>> pmservnt!Writer::Writer+632b >>>> pmservnt!SSeqGenHandler::operator=+2897 >>>> pmservnt!isForeignKey+6dd >>>> pmcef!SThread::init+293 >>>> kernel32!BaseThreadInitThunk+d >>>> ntdll!RtlUserThreadStart+1d >>>> >>>> >>>> ODBC Trace is as follows: >>>> >>>> _dss_000PQZ0I0 19d8-256c ENTER SQLFreeStmt >>>> HSTMT 0x0000000005C2D030 >>>> UWORD 1 >>>> >>>> s_dss_000PQZ0I0 19d8-256c EXIT SQLFreeStmt with return code 0 >>>> (SQL_SUCCESS) >>>> HSTMT 0x0000000005C2D030 >>>> UWORD 1 >>>> >>>> s_dss_000PQZ0I0 19d8-256c ENTER SQLTransact >>>> HENV 0x0000000000000000 >>>> HDBC 0x0000000005C25560 >>>> UWORD 0 >>>> >>>> s_dss_000PQZ0I0 19d8-256c EXIT SQLTransact with return code 0 >>>> (SQL_SUCCESS) >>>> HENV 0x0000000000000000 >>>> HDBC 0x0000000005C25560 >>>> UWORD 0 >>>> >>>> s_dss_000PQZ0I0 19d8-256c ENTER SQLDisconnect >>>> HDBC 0x0000000005C25560​ >>>> >>>> I am searching for the root of the issue in order to prevent it >>>> from happening but i am not really sure if the problem comes from >>>> libpq or the driver itself. As far as i understand this is a >>>> segmentation fault by trying to free a malloc that has been already >>>> freed, however im not sure if the problem comes from PQfinish of >>>> the driver calling it when it shouldn't. >>>> >>>> Anyone can point me to where the issue comes from? >>>> >>>> Regards, Jacobo >>>> >>> >> > --------------CB95CD8F6357F1C94E13582E Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 8bit

Hi again

    I could somehow install a similar environment in my machine and new version also crashes when using SSL. However from what i have found from google it points more to an issue with libpq (interacting with some other libraries maybe). I could avoid the issue by not calling PQFinish() in method SOCK_Destructor of socket.c from version 09.03.400 but im not sure which kind of problems/leaks this may raise, do you have any idea of how bad may be this workaround?

    I could also reproduce the error by installing 32 bit version of heidiSQL (following the error described in http://www.heidisql.com/forum.php?t=15646) and it also crashes calling PQFinish() method (by calling directly libpq and not using ODBC).

    There is also an old (2005) thread in the postgres mailing list that seems related but im not really sure http://postgresql.nabble.com/BUG-2246-Bad-malloc-interactions-ecpg-openssl-td2119930.html

    All i found points more to libpq than to the driver itself. However seems to be a tricky thing and i have not an isolated test case without using external clients :(

Regards
Jacobo
   

El 14/02/17 a las 12:21, Inoue, Hiroshi escribió:
Hi,

On 2017/02/14 17:34, Jacobo Sánchez wrote:

Hello


    Im currently looking for a test environment under my control in order to check this or any other solution. Is there any specific change that may lead to think that this could be already fixed in 09.06.100?

After 09.05.0100 the driver uses libpq fully, whereas the driver used libpq partially before.

regards,
Hiroshi Inoue

That may give me a chance to speed up things by asking for testing it in a real environment.

    Thanks for your response, I will notify the results with 09.06.100 when tested.


Regards

Jacobo


El 14/02/17 a las 03:26, Inoue, Hiroshi escribió:
Hi Jacobo,

On 2017/02/14 1:06, Jacobo Sánchez wrote:

Hello all


Im facing an issue using the ODBC driver from Informatica which may be resumed in the following (im using 09.03.400):

Could you try the latest version 09.06.0100?

regards,
Hiroshi Inoue

https://kb.informatica.com/solution/23/Pages/52/320564.aspx

If someone does not want to open the URL the failing trace is as follows:

Crashing Thread is as follows:

ntdll!RtlFreeHeap+132 
msvcrt!free+1c 
libeay32!CRYPTO_free+2e 
libeay32!ASN1_STRING_free+27 
libeay32!ASN1_primitive_free+ac 
libeay32!ASN1_template_free+128 
libeay32!ASN1_template_free+9b 
libeay32!ASN1_item_free+1e9 
libeay32!X509_free+1a 
libpq!PQinitSSL+105c 
libpq!PQinitSSL+1113 
libpq!PQencryptPassword+7cf 
libpq!PQfinish+12 
psqlodbc35w!ConfigDriver+1b7e 
psqlodbc35w!Ordinal93+4162 
psqlodbc35w!Ordinal93+3285 
psqlodbc35w!SQLDisconnect+5f 
odbc32!SQLDisconnect+2ae 
pmodbc!TODBCDb::Disconnect+7f 
pmodlnt!TDatabase::Disconnect+3c 
pmrelrdr!relReader::fetch+54be 
pmservnt!readerSource::operator=+307f 
pmservnt!DTMMain+219e8 
pmservnt!Writer::Writer+632b 
pmservnt!SSeqGenHandler::operator=+2897 
pmservnt!isForeignKey+6dd 
pmcef!SThread::init+293 
kernel32!BaseThreadInitThunk+d 
ntdll!RtlUserThreadStart+1d 


ODBC Trace is as follows:
_dss_000PQZ0I0 19d8-256c ENTER SQLFreeStmt 
HSTMT 0x0000000005C2D030 
UWORD 1 <SQL_DROP> 

s_dss_000PQZ0I0 19d8-256c EXIT SQLFreeStmt with return code 0 (SQL_SUCCESS) 
HSTMT 0x0000000005C2D030 
UWORD 1 <SQL_DROP> 

s_dss_000PQZ0I0 19d8-256c ENTER SQLTransact 
HENV 0x0000000000000000 
HDBC 0x0000000005C25560 
UWORD 0 <SQL_COMMIT> 

s_dss_000PQZ0I0 19d8-256c EXIT SQLTransact with return code 0 (SQL_SUCCESS) 
HENV 0x0000000000000000 
HDBC 0x0000000005C25560 
UWORD 0 <SQL_COMMIT> 

s_dss_000PQZ0I0 19d8-256c ENTER SQLDisconnect 
HDBC 0x0000000005C25560​

I am searching for the root of the issue in order to prevent it from happening but i am not really sure if the problem comes from libpq or the driver itself. As far as i understand this is a segmentation fault by trying to free a malloc that has been already freed, however im not sure if the problem comes from PQfinish of the driver calling it when it shouldn't.

Anyone can point me to where the issue comes from?

Regards, Jacobo





--------------CB95CD8F6357F1C94E13582E--