-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Http Request Replacement Ax-DLL SetClientCertificate #47
Comments
This should be a supported use case. Is there some kind of SmartCard device (e.g. YubiKey) involved? Which URL are you trying to access? |
No, only certificate is needed for the connection.
|
Just pushed some fixes in commit e11373f -- try downloading latest Btw, if you only have a single certificate issued by api.sberbank.ru currently registered in your Another option to try is using certificate thumbprint instead of common/friendly name like this: |
Actually, with the last version problem on Win 10 x64 is fixed. Well done! But, on Windows 7 x64 i got another err message:
Thanks for the tip, but i have multiple certs =(
Thumbprint option works in Win 10 x64, on Win 7 i got 80072f89 - |
Just fixed finding certificates by hash under Win7 in commit faa1313 and updated The automation error in |
Yes, you nailed it! Everything works as expected on both systems. Thanks alot! |
From time to time i got error: But i think this topic is the case for another issue =) Once again, thank you for support, quick fix and the whole project. It's incredible! |
I'll probably have to tweak it to default to not checking revocation on Win7 as it becomes more and more unsupported because OS probably cannot access revocation list servers securely i.e. Schannel is failing to connect to new/upgraded CRL endpoints. Edit: Just did this in commit 60c578e and it got a bit faster establishing TLS session under Win7 as a result. |
Hm, after further testing i faced another issue, unfortunately. On Windows 10, when i tried to connect to https://mc.api.sberbank.ru/prod/tokens/v3/oauth with cert, i got hang on |
There are timeouts you can setup with Another option is to use the class asynchronously and wait for |
Let me add some details, Now i got problem only in one case so far: open with cert, provided by By the way, with your ax i got many timeouts error with default VBA-Web WaitForResponse setting, so i set it to 1 sec. Still, i got no propblem with |
Yes, this seems to be a regression in faa1313 which prevented using CNG containers for certificate private keys (which failed export under Win7 and had to be abandoned) but standard Crypto API keys cannot use PSS padding for signatures so client certificate signatures for your endpoint failed silently which revealed another bug which caused an infinite loop in a code path less travelled -- what an adventure! :-)) Anyway in commit 7fca23a CNG containers are back but this time private keys are not exported at all so this prevents Win7 from choking and allows using PSS padding for client certificates again. |
I've done some tests and all seems to work as expected. Once again, i can't thank you enough for this project. TLS and work with certs is quite complex thing and your knowledge of the entire topic is amazing. Speed of resolving bugs is just out of this world =) Best wishes. Vladimir, and have a nice weekend! |
Hi.
I've tried to use
Http Request dll
and faced trouble withSetClientCertificate
. Default location for cert is "CURRENT_USER\MY" and i have valid cert there. I got the error (8009200b): Не удается найти сертификат и закрытый ключ для расшифровки ("Key not found" in eng, i think)Standard
WinHttp.WinHttpRequest.5.1
works fine with that cert.When i try to use the wrong cert name - i got different error: 80072f89 - Предоставлен недопустимый сертификат ("certificate invalid"), so i assume i specified the path to the cert correctly.
The text was updated successfully, but these errors were encountered: