Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rSYnT-00EUIx-HO for pgsql-odbc@arkaria.postgresql.org; Wed, 24 Jan 2024 08:39:48 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rSYnS-003OYs-OO for pgsql-odbc@arkaria.postgresql.org; Wed, 24 Jan 2024 08:39:46 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rSYnS-003OYk-7F for pgsql-odbc@lists.postgresql.org; Wed, 24 Jan 2024 08:39:46 +0000 Received: from mail-lj1-x236.google.com ([2a00:1450:4864:20::236]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rSYnN-003RH5-3q for pgsql-odbc@lists.postgresql.org; Wed, 24 Jan 2024 08:39:45 +0000 Received: by mail-lj1-x236.google.com with SMTP id 38308e7fff4ca-2cf1c275e95so8785391fa.1 for ; Wed, 24 Jan 2024 00:39:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denodo.com; s=google; t=1706085579; x=1706690379; darn=lists.postgresql.org; h=in-reply-to:from:content-language:references:to:subject:user-agent :mime-version:date:message-id:from:to:cc:subject:date:message-id :reply-to; bh=ENvInlJCu9W9lMTijetQi4zZJon53deSy+N2Ligq6nI=; b=JqEyI47w0HwdyE0iz9OZdn3+5++PRZegufLYT9qJ8R7xMA5L8QbUyNxOxDYKhXvkUC aNzUlJmAd8QKdMAuZjWOf9vqFDYKJlt9Q6Wga8gUt1X0sxRt5voXBXabmGRlj6JAOm79 xXy7+3niVlG+7503MjSrAnuvApTmeuZjmfFxg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706085579; x=1706690379; h=in-reply-to:from:content-language:references:to:subject:user-agent :mime-version:date:message-id:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to; bh=ENvInlJCu9W9lMTijetQi4zZJon53deSy+N2Ligq6nI=; b=W9nPMmkNMLPKtoaHcREJjg8yX79/6yKrZXrmIF+lR2bUjOrIhXU8eCyanhOJOrRCdc HesYp/gc4g3dm4B/3qbmyFFA2gPVMJDZlA/LdIDtLyzZpYagBCFhckK1fngT/tGrsBF+ u542RXwPOqsFXkqU8Xmn9NNs66l+IsJcn5s+CfCvnLUdecBBVAc2qtyBL/+sfHSa4OBq okAAkzpuTlqncmWL1Bo0uLNXKwXkwLD1JrQwLL+kLfZPxCkrrfd28mhIGvhFjmU2zln/ VhYnzPOwSTz7TrOhmXItyKYKuhdHPuJFEY1btMYJEusfnDJdDiTU8q7zoB6TK1k4D2iJ 7tmg== X-Gm-Message-State: AOJu0YxIsSuu4zgB+wPJmD4OrSldDenDlhpQVQntCfhONa+eH4bjP746 XPaHyO+SfTiPmGUSkkSlu3Gx6z1H9/FRnXhaBBxfaKlgMk5Xt6BQ7+xQhS7QnjOwh0FTCPa0vmJ cPawDrQJayTYQ3VNhfuzohg+OHmr5C/H2GGUKbYndTj7hA1fYVYHd77w9DXuPQHyO9Wcm+qN6RZ 0ywOX4H9ZUzrynVKJZQoCjkKilrBW4wkcA3xMebZ+G9VAxlCM= X-Google-Smtp-Source: AGHT+IEZxbJoRUmmmxmfzblxEv21AvkvFhLuZMEw07NTuJ1FQ8iWt0nOvoptqSVZT6d2cn7GBLfSlA== X-Received: by 2002:a2e:8e7b:0:b0:2cd:f573:e501 with SMTP id t27-20020a2e8e7b000000b002cdf573e501mr529110ljk.59.1706085579498; Wed, 24 Jan 2024 00:39:39 -0800 (PST) Received: from [192.168.6.75] (29.236.117.91.dynamic.reverse-mundo-r.com. [91.117.236.29]) by smtp.gmail.com with ESMTPSA id cp9-20020a056000400900b003392ded41c7sm8837312wrb.39.2024.01.24.00.39.38 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 24 Jan 2024 00:39:39 -0800 (PST) Content-Type: multipart/alternative; boundary="------------AYP8M1QWbVz6BLtx0G2edxYQ" Message-ID: <6df41445-10f5-42bf-a4c2-48ceaad4f35c@denodo.com> Date: Wed, 24 Jan 2024 09:39:37 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: ssh tunneling To: pgsql-odbc@lists.postgresql.org References: Content-Language: en-US From: =?UTF-8?Q?Jacobo_S=C3=A1nchez_L=C3=B3pez?= In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk This is a multi-part message in MIME format. --------------AYP8M1QWbVz6BLtx0G2edxYQ Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Maybe the original message is about SSH proxy instead of tunneling? The PostgreSQL protocol makes a SSH upgrade instead of starting the communication with SSH handshake and that is a problem when using some SSH proxies/load balancers which are nowadays common in cloud environments. I also wish there was a way to connect directly to a SSH socket but that is not about the driver but how PostgreSQL communication protocol I guess. Regards Jacobo On 1/23/2024 10:49 PM, Jon Raiford wrote: > > As Dave mentions, SSH tunneling should work ok. You need to make sure > you set up the tunnel correctly. I would suggest testing this using > something like netcat to make sure the tunnel is working. If you can > connect to netcat with telnet and PostgreSQL is still not connecting > then you may want to have a look at your pg_hba.conf configuration to > make sure it is set up to accept connections from your SSH server. > > Jon > > *From: *Dave Cramer > *Date: *Tuesday, January 23, 2024 at 4:35 PM > *To: *Juan Ignacio Fernigrini > *Cc: *pgsql-odbc@postgresql.org > *Subject: *Re: ssh tunneling > > On Tue, 23 Jan 2024 at 16:06, Dave Cramer > wrote: > > On Tue, 23 Jan 2024 at 15:28, Juan Ignacio Fernigrini > wrote: > > Good morning team, > > I hope this message finds you well. > > I am tasked with establishing a connection to my database > using ODBC with SSH tunneling. Unfortunately, the current ODBC > solution is not compatible. I have explored alternatives such > as Devart, but it comes at a cost of $250. I am considering > whether it would be more beneficial to invest this amount in > developing the required feature within the existing > open-source ODBC solution. > > Best regards, > Juan Ignacio Fernigrini > > I'm not sure why psql odbc would not be able to use ssh tunneling. > Can you expand upon that ? > > Dave Cramer > > www.postgres.rocks > > see What is an SSH Tunnel & SSH Tunneling? > > > > For details it is not part of the driver. > > Dave > --------------AYP8M1QWbVz6BLtx0G2edxYQ Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit

Maybe the original message is about SSH proxy instead of tunneling? 

The PostgreSQL protocol makes a SSH upgrade instead of starting the communication with SSH handshake and that is a problem when using some SSH proxies/load balancers which are nowadays common in cloud environments. I also wish there was a way to connect directly to a SSH socket but that is not about the driver but how PostgreSQL communication protocol I guess.

Regards

Jacobo

On 1/23/2024 10:49 PM, Jon Raiford wrote:

As Dave mentions, SSH tunneling should work ok. You need to make sure you set up the tunnel correctly. I would suggest testing this using something like netcat to make sure the tunnel is working. If you can connect to netcat with telnet and PostgreSQL is still not connecting then you may want to have a look at your pg_hba.conf configuration to make sure it is set up to accept connections from your SSH server.

 

Jon

 

From: Dave Cramer <davecramer@postgres.rocks>
Date: Tuesday, January 23, 2024 at 4:35
PM
To: Juan Ignacio Fernigrini <juanfernigrini@gmail.com>
Cc: pgsql-odbc@postgresql.org <pgsql-odbc@postgresql.org>
Subject: Re: ssh tunneling

 

 

On Tue, 23 Jan 2024 at 16:06, Dave Cramer <davecramer@postgres.rocks> wrote:

 

 

On Tue, 23 Jan 2024 at 15:28, Juan Ignacio Fernigrini <juanfernigrini@gmail.com> wrote:

Good morning team,

 

I hope this message finds you well.

 

I am tasked with establishing a connection to my database using ODBC with SSH tunneling. Unfortunately, the current ODBC solution is not compatible. I have explored alternatives such as Devart, but it comes at a cost of $250. I am considering whether it would be more beneficial to invest this amount in developing the required feature within the existing open-source ODBC solution.

 

Best regards,
Juan Ignacio Fernigrini

 

I'm not sure why psql odbc would not be able to use ssh tunneling. Can you expand upon that ?

Dave Cramer

 

 

For details it is not part of the driver.

 

Dave 

 

--------------AYP8M1QWbVz6BLtx0G2edxYQ--