Lazarus
Programming => Networking and Web Programming => Topic started by: arneolav on March 29, 2023, 08:44:05 pm
-
I'v an application with oAuth1 verification.
This has been working well with win10 (and older), but win11 seems to cause a problem.
I have moved all .pas files form win10 to a win11 computer and done recompile Lazarus 2.2.6, so far all ok.
With Win10 the server respond correct "200".
With Win11 the server respond "0 0".
Some special written programs are involved, (execpt my own):
unit oauth1; written by Reinier Olislagers 2012
unit oauth1synapse; written by Reinier Olislagers 2012
unit ssl_openssl; by Lukas Gebauer 2012-13
unit ssl_openssl_lib; by Lukas Gebauer 2012-13
sswin32.inc; by Lukas Gebauer 2012-13
Some Synapse adapter are included:
synachar.pas
synacode.pas
synafpc.pas
synaicnv.pas
synaip.pas
synautil.pas
synsock.pas
From this article https://learn.microsoft.com/en-us/mem/configmgr/core/plan-design/security/enable-tls-1-2-client
it seems this may have something to do with TLS.
Any ideas?
Source:
-
And does it still work on win10 at this moment?
-
Yes, and has been used every day some years.
-
Is the new lazarus 2.2.6 64 bit or 32 bit?
Was your old compile 32 bit or 64 bit?
What openssl version did you copy to the exe directory (32 bit ir 64 bit).
If you lazarus bitness doesn't match the openssl bitness it will fail silently.
-
Both are 64bit, I5 11400.
Both Lazarus is 64.
I see now the win11 is still on Lazarus 2.2.4, may be something there?
No other synapse programs than those in .zip -file. No other openssl.
-
If I understood you:
1. Application compiled in W10 works in W10.
2. Application compiled in W11 doesn't work in W11.
Did you try to copy working application from W10 to W11 and test it?
Did you try to copy non-working application from W11 to W10 and test it?
Maybe the environment is the problem and not compiling.
-
1. Application compiled in W10 works in W10...........YES
2. Application compiled in W11 doesn't work in W11. ... Does not work.
Did you try to copy working application from W10 to W11 and test it? ... YES, does not work.
Did you try to copy non-working application from W11 to W10 and test it ...Yes, work perfect.
I'm installing Lazarus 2.2.6 on win11 so have to try when ready.
-
No other synapse programs than those in .zip -file. No other openssl.
Wait... you don't copy the openssl library files into the .exe directory?
In that case the default openssl from the installation is taken.
It could be that those are present on the win10 machine but not (or wrong ones) on the win11.
So try to copy the correct openssl files into the .exe directory and try again.
-
Did you try to copy working application from W10 to W11 and test it? ... YES, does not work.
Did you try to copy non-working application from W11 to W10 and test it ...Yes, work perfect.
So that tells that problem is not in compiling but in environment. Check if you have correct OpenSSL libraries installed in Windows 11.
-
So that tells that problem is not in compiling but in environment. Check if you have correct OpenSSL libraries installed in Windows 11.
That's why I don't rely on the default installed version (if there is any).
You never know what is really installed ;)
-
All source are in the .exe library.
Inclusive these 2:
unit ssl_openssl; by Lukas Gebauer 2012-13
unit ssl_openssl_lib; by Lukas Gebauer 2012-13
No other openssl is defined in the source files.
-
All source are in the .exe library.
Inclusive these 2:
unit ssl_openssl; by Lukas Gebauer 2012-13
unit ssl_openssl_lib; by Lukas Gebauer 2012-13
No other openssl is defined in the source files.
No, I mean you need to put the correct (bitness) libeay32.dll and ssleay32.dll into the .exe directory.
That's the only way to be sure the correct openssl dll's are used.
At the moment your win10 version takes some version from c:\windows\system32.
And you don't have these on your win11.
-
That did the trick!
Got response 200, ok.
As an devloper of enduser stuff I don't have much knowledge or experience with these details.
Thanks a lot!