Bot Emulator V4 connection: request to https://localhost:44378/api/messages failed, reason: unable to verify the first certificate - ssl-certificate

In the latest Bot Framework Emulator 4.0.0-preview.40025 (although it this has occurred in every version I try), I get the following error:
[11:37:11]Emulator listening on http://localhost:65141
[11:37:11]ngrok not configured (only needed when connecting to remotely hosted bots)
[11:37:11]Connecting to bots hosted remotely
[11:37:11]Edit ngrok settings
[11:37:11]POST201directline.startConversation
[11:37:11]request to https://localhost:44378/api/messages failed, reason: unable to verify the first certificate
[11:37:11]request to https://localhost:44378/api/messages failed, reason: unable to verify the first certificate
The original V3 Bot framework emulator works fine.
Any help appreciated.

Related

Service worker SSL certificate problem when trying to deploy my angular+nestjs in my local lab with different vm for front and back

I´m somehow new in the world of the self signed certs. I´m not sure that using one of this is posible to test my angular front. Looks like in my back all works fine with the same self-signed openssl generated certs.
When I access to https:// the login screen appears as normally but console throw back this error logs:
An SSL certificate error occurred when fetching the script.
Service worker registration failed with: DOMException: Failed to register a ServiceWorker for scope ('https://192.168.154.136/es/') with script ('https://192.168.154.136/es/ngsw-worker.js'): An SSL certificate error occurred when fetching the script.
And when trying to log in with a existent user:
POST https://192.168.154.135:3333/api/login/common net::ERR_CERT_COMMON_NAME_INVALID.
If someone have being in the same type issue or similar, it would be a pleasure to hear about.

CryptographicException exception when setting up SSL handshake with MailKit using .NET Core

What we are trying to do is send an email from a pod (running Linux based on the image "microsoft/dotnet") on a client's Openshift environment using MailKit:
https://github.com/jstedfast/MailKit
We get an exception thrown when trying to set up the SSL Handshake:
MailKit.Security.SslHandshakeException: An error occurred while
attempting to establish an SSL or TLS connection.
System.Security.Cryptography.CryptographicException: Error occurred
during a cryptographic operation
We have tried using the.NET SMTP client as well and it worked (using a secure connection)! Unfortunately this component is now obsolete and Microsoft recommends to use MailKit.
Going through the .NET source code the exception raised is a generic catch all exception which looks like it comes from unexpected code returned from the OpenSSL library. Unfortunately I can't see how to get the error code (it is logged using "Debug.Fail", but I am unable to setup a trace to see it) so I am not sure what it is.
I have written a test just to build the X509Chain. When we have the Revocation Mode set to Online (the default) we get the exception. When the revocation is disabled it seems to build the chain OK.
When I run the test on our Test Openshift environment that is totally independent to the client's we get the following error, but do not see the exception: "unable to get certificate CRL"
The only thing I have noticed about the Revocation List is that there is a LDAP and HTTP URLs. Perhaps there is an issue processing the LDAP URL?
Any help on this would be appreciated!
This is something you should report to github.com/microsoft/dotnet

WLResourceRequest over SSL with untrusted certificate

We are developing an hybrid application ( Android , iOS )
and we are facing an issue communicating with our backend services.
We are using untrusted certificate in the development environment and this lead to an error invoking the services using WLResourceRequest in the hybrid code.
The error on the android platform is the following:
java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.
And reading from android logcat comes out this:
04-20 12:50:04.300 9427-9450/com.myApp D/wl.resource_request: WLResourceRequest.handleOnFailure in WLResourceRequest.java:658 :: Unexpected errorCode occurred. Please try again.
04-20 12:50:04.308 9427-9450/com.myApp D/com.worklight.androidgap.plugin.WLResourceRequestPlugin: WLResourceRequestPlugin$1$1.onFailure in WLResourceRequestPlugin.java:92 :: inside WLResourceRequestPlugin failure
How can we manage to pass through the certificate validation? or is there something we can do to properly invoke the services?
You can overcome this by adding the CA certificate to your device.
Go to Settings -> Security -> Install from SD card and install the CA certificate to the device.

SSL error when using https FCM

I have implemented FCM for web using fcm documentation.
Everything'll be fine if I set url like : 'http://xxx' I have no error.
But when I set url : 'https://xxx..', I get error:
"Failed to register a ServiceWorker: An SSL certificate error occurred when fetching the script."
code: "messaging/failed-serviceworker-registration"
"Messaging: We are unable to register the default service worker. Failed to register a ServiceWorker: An SSL certificate error occurred when fetching the script. (messaging/failed-serviceworker-registration)."
Can anyone show me how to fix this error?
This is a general problem when wanting to test service workers in a local development environment without proper SSL certificates. It is not specific to Firebase Messaging but pertains to Service Workers in general.
Here is the solution I found when using Google Chrome: Testing Service workers locally with self-signed certificates
Unfortunately, I don't know yet how to circument the issue with other browsers, but probably there must be similar ways.
For Chrome, you need to start a new instance of Chrome, with some flags telling it to ignore SSL certificate errors for your local origin:
In Linux (and maybe Mac):
google-chrome --ignore-certificate-errors --unsafely-treat-insecure-origin-as-secure=https://127.0.0.1 --user-data-dir=/tmp/foo
The https://127.0.0.1 here is the location where your app (and service worker) is hosted locally. You might need to adjust this to use the appropriate port, if serving on a different port than the standard HTTPS port 443, e.g. https://127.0.0.1:3000, when serving your app over HTTPS on port 3000.
The --user-data-dir=/tmp/foo is necessary to start a new instance, with a new user profile, if another instance of Chrome is already running.
In Windows (might vary, depending on where your chrome.exe is):
C:\Program Files (x86)\Google\Chrome\Application\chrome.exe --ignore-certificate-errors --unsafely-treat-insecure-origin-as-secure=https://localhost:1123
Again, you might have to adjust the port.
Easier method that worked for me:
Just paste chrome://flags/#allow-insecure-localhost in your chrome browser, and Enable the setting that says something like "Allow invalid certificates for resources loaded from localhost."

unknown SSL error -12218 (SSL_ENCRYPTION_FAILURE) while launching upwork application on debian stretch

Recently I've been installing upwork application on my debian system.It has installed fine.But when I try to launch it from cli typing: upwork
a bunch of errors happen.
[1008/213534:ERROR:browser_main_loop.cc(173)] Running without the SUID sandbox! See https://code.google.com/p/chromium/wiki/LinuxSUIDSandboxDevelopment for more information on developing with the sandbox on.
[1008/213535:ERROR:renderer_main.cc(200)] Running without renderer sandbox
[1008/213542:ERROR:renderer_main.cc(200)] Running without renderer sandbox
[1008/213542:WARNING:channel.cc(549)] Failed to send message to ack remove remote endpoint (local ID 1, remote ID 1)
[1008/213542:WARNING:channel.cc(549)] Failed to send message to ack remove remote endpoint (local ID 2147483648, remote ID 2)
[1008/213542:ERROR:channel.cc(300)] RawChannel read error (connection broken)
[1008/213542:ERROR:renderer_main.cc(200)] Running without renderer sandbox
[1008/213543:WARNING:channel.cc(549)] Failed to send message to ack remove remote endpoint (local ID 1, remote ID 1)
[1008/213543:WARNING:nss_ssl_util.cc(370)] Unknown SSL error -12218 (SSL_ERROR_ENCRYPTION_FAILURE) mapped to net::ERR_SSL_PROTOCOL_ERROR
[1008/213600:WARNING:nss_ssl_util.cc(370)] Unknown SSL error -12218 (SSL_ERROR_ENCRYPTION_FAILURE) mapped to net::ERR_SSL_PROTOCOL_ERROR
[1008/213600:WARNING:nss_ssl_util.cc(370)] Unknown SSL error -12218 (SSL_ERROR_ENCRYPTION_FAILURE) mapped to net::ERR_SSL_PROTOCOL_ERROR
[1008/214550:WARNING:channel.cc(549)] Failed to send message to ack remove remote endpoint (local ID 1, remote ID 1)
[
How to overcome this errors?
After online searching the decision was found on upwork site forum
unknown ssl error
The problem was how to use the 2 versions of libnss3 packet simultaneously.Libnss3 goes as a security related packet so instead of downgrading it on the system you can simply download the old version of libnss3 compatible with upwork app and then dynamically add a path to this old version to the linker when you need to use upwork app, while the system will have the newest one.