alexalok/dotAPNS

The SSL connection could not be established,

rkbsoftsolutions opened this issue · 9 comments

Describe the bug
. I am getting "The SSL connection could not be established" on production. Sound like website need to SSL certificate. But Is any way to code will work without ssl configured.

Environment
OS name and version: "Window Azure App service"
.NET version: .NET Core 3.1

Please see #78 (comment) for a possible workaround

@alexalok thanks for response. But "Window Azure App service" web application not providing any option "App Pool Identiy" like that. Could you please give me more insight, how we can do that?

Sorry, I'm not familiar with Azure at all. Perhaps you could ask a more general question on StackOverflow, something along the lines of "making an http/2 request with client certificate fails on ..."

@alexalok I figured out the issue " X509KeyStorageFlags.MachineKeySet)"
then restart /publish again application.
it is working fine but only first call.
When send second call it is getting failed.
Any Idea for same ?

@alexalok we should pass three flags when X509Certificate2 objects.
X509KeyStorageFlags.MachineKeySet | X509KeyStorageFlags.PersistKeySet | X509KeyStorageFlags.Exportable

Then Looks working.

It is in-consistent not working properly.

@alexalok can i use "Polly" for try if connection get failed? I notice that code is maintaining "ConcurrentDictionary" dictionary. Will it impact on HttpClinet if we use "Polly"?

Will it impact on HttpClinet if we use "Polly"?

You should be able to use Polly without any difficulties. I have not however tested this setup.

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.