Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.

PostgreSQL - scram-sha-256

rufus's profile image rufus posted 10 months ago in Feature discussion Permalink

Hi!

Any chance to have a more recent libpq which supports scram-sha-256? Current one gives "authentication method 10 not supported".

If I copy over libpq.dll, libintl-8.dll and libiconv-2.dll from a postgresql 10 windows binaries, it works ok. Note that copying these from a postgresql 11 windows binaries does not work.

Thanks!

ansgar's profile image ansgar posted 10 months ago Permalink

Yes, of course. I just realized the last update on libpq.dll is 3 years ago, in the context of another forum thread.

So you say the v10.7 binaries work for you?

rufus's profile image rufus posted 10 months ago Permalink

Yes, 10.x binaries work ok I first tried with 11.x binaries but it gives the same error in that other thread (I assume because libintl-8.dll is changed with libintl-9.dll and probably there are some other changes)

Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.
fireartist's profile image fireartist posted 3 months ago Permalink

Hi,

Any chance of this being added to a release?

I tried downloading the postgres DLLs myself, but the v10 64bit files didn't work and the 32bit binary download is triggering an antivirus warning.

ansgar's profile image ansgar posted 3 months ago Permalink

As PG 12 is the current release, doesn't it make sense to use these? On the other hand they only have 32bit installs up to v10.

sbarn's profile image sbarn posted 1 month ago Permalink

Hi,

With the latest release of HeidiSQL 10.3 it is still not possible to connect to a PostgreSQL database which is using scram-sha-256 for passwords. The error is "authentication method 10 not supported".

Would you be able to create a release of HeidiSQL with update Postgres DLL files?

ansgar's profile image ansgar posted 1 month ago Permalink

Yes, I can surely update these dlls, I just didn't know whether I should use v12 binaries, and where to get 32bit versions for these, as written above. I also don't know if v10 binaries support that scram-sha-256 authentication. Maybe you can test that by downloading the appropriate dlls from their site and select the new dll in HeidiSQL's "Library" dropdown?

sbarn's profile image sbarn posted 1 month ago Permalink

I have tried copying in to HeidiSQL_10.3_32_Portable the three 32bit DLLs from Postgresql 10.11 but they didn't work. I also tried with 9.6.16. postgresql-10.11-3-windows-binaries\pgsql\bin[libpq.dll, libintl-8.dll and libiconv-2.dll] postgresql-9.6.16-2-windows-binaries\pgsql\bin[libpq.dll, libintl-8.dll and libiconv-2.dll]

When connecting to a Postgresql database with the 9.6.16 or 10.11 binarries the error is - Library libpq.dll could not be loaded. Please select a different one.

Internal error 126: The specified module could not be found

ansgar's profile image ansgar posted 1 month ago Permalink

So all your attempts did not work? That's really odd, at least the v9.6.x version should work...

sbarn's profile image sbarn posted 1 month ago Permalink

Yeah. I have not found a zip of Windows binaries from www.enterprisedb.com /download-postgresql-binaries which contains a libpq.dll that works with HeidiSQL 10.3

Ads were blocked - no problem. But keep in mind that developing HeidiSQL, user support and hosting takes time and money. You may want to send a donation instead.
ansgar's profile image ansgar posted 1 month ago Permalink

Hm, the current libpq.dll and dependent dlls are taken from PG 9.5.2. Maybe the loading mechanism in HeidiSQL expects some method which is renamed or no longer available.

On the other hand your error also says:

Internal error 126: The specified module could not be found

That means a dll file could not be found. This can either be

  • libpq.dll, or a dependent dll, like:
  • libeay32.dll
  • libiconv-2.dll
  • libintl-8.dll
  • ssleay32.dll

Please make sure you have updated all of them, and they are located in the HeidiSQL folder (move old files somewhere else maybe)

sbarn's profile image sbarn posted 1 month ago Permalink

Thanks for the tips.

I copied into HeidiSQL_10.3_32_Portable libeay32.dll, ssleay32.dll, libpq.dll from C:\Program Files (x86)\pgAdmin 4\v4\runtime

With these 3 DLLs overwritten with the pgAdmin versions I am now able to connect using HeidiSQL to a scram-sha-256 Postgres instance.

ansgar's profile image ansgar posted 1 month ago Permalink

Ok, then what version does libpq.dll show you? (see the "Properties" dialog of the file)

sbarn's profile image sbarn posted 1 month ago Permalink

libpq.dll

  • File version 11.0.3.19168
  • Product version 11.3

ssleay32.dll

  • File version 1.0.2.19
  • Product version 1.0.2s

libeay32.dll

  • File version 1.0.2.19
  • Product version 1.0.2s
ansgar's profile image ansgar posted 1 month ago Permalink

Ok, the 32bit downloads just go up to PG v10, so I should take the latest v10 dlls, in order not to break HeidiSQL 32bit.

max87's profile image max87 posted 2 weeks ago Permalink

libpq.dll

  • File version 11.0.3.19168
  • Product version 11.3

ssleay32.dll

  • File version 1.0.2.19
  • Product version 1.0.2s

libeay32.dll

  • File version 1.0.2.19
  • Product version 1.0.2s

Where I can find libpq.dll 11.3 ? I am using 11.6 and have "modeule cannot be loaded error".

Please login to leave a reply, or register at first.