I am trying to get the Prometheus driver working with a Prometheus server that is listening on port 443 using https. Because it is an internal company system the certificate is self signed. The connection is failing with Error : 12030. [ERROR_WINHTTP_CONNECTION_ERROR].
I have been trying to debug the driver and it looks like the http query is being constructed in an object that is returned from a "before" Qaction:
object[] httpCommand = new object[] { "http", new[] { requestType, sIp, credentials[0], credentials[1], httpheaders, timeoutMs }, new[] { httpcommand } };
return httpCommand;
so I can see how it is being built, however I cannot see any code that is sending the request to the prometheus server as I'm not sure how the mechanism that sends the returned object from the Qaction works. I suspect it may be failing due to not ignoring warnings about self signed certificates, but not sure how to debug any further. If this is the case then I am hoping that there will be a flag that can be set in the httpCommand object to ignore the warning. Does anybody know how I can get this information or get more debug info on the failure?
Hi Mark,
HTTP communication in the connector is implemented using multithreaded timers. How that works is explained here: https://docs.dataminer.services/develop/devguide/Connector/AdvancedMultithreadedTimersHttp.html.
I'm not aware of a way to bypass the certificate check when using HTTPS. That would probably also be very insecure.
You mentioned that you are using self-signed certificates. What you could try to do is importing it on the DataMiner server that is hosting the element, so that it becomes trusted by that system. The following page explains how you can do that: https://techcommunity.microsoft.com/t5/windows-server-essentials-and/installing-a-self-signed-certificate-as-a-trusted-root-ca-in/ba-p/396105.
If it still doesn't work you could try to debug this further using Wireshark to see what the device actually responds and where exactly it fails.