Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear all,
I'm getting some errors during API call from an other server to the Qlik Sense Server.
I'm not able to use the SSL Port only the 4242 port . why ?
url : https://myserver.com:4242/qrs/about
{
"buildVersion": "31.39.2.0",
"buildDate": "3/12/2024 08:13:57 AM",
"databaseProvider": "Devart.Data.PostgreSql",
"nodeType": 1,
"sharedPersistence": true,
"requiresBootstrap": false,
"singleNodeOnly": false,
"schemaPath": "About"
}
url : https://myserver.com:443/qrs/about
< HTTP/1.1 401 Unauthorized
< Content-Length: 0
< Server: Microsoft-HTTPAPI/2.0
< WWW-Authenticate: Negotiate
< Date: Wed, 25 Sep 2024 12:50:45 GMT
https://myserver.delvaux.com/qrs/about
< HTTP/1.1 401 Unauthorized
< Content-Length: 0
< Server: Microsoft-HTTPAPI/2.0
< WWW-Authenticate: Negotiate
< Date: Wed, 25 Sep 2024 12:51:59 GMT
the auth. method is by certificate, if this can help.
thanks in advance for your help
Benoît
Hey @girard_ben, 4242 is used to access the QRS API endpoints from behind the proxy in the trusted zone and this call requires client and server cert authentication.
Instead, when you are not specifing the port, this means that you are accessing QRS APIs using virtual proxy. Pointing to https://dlvxsense.delvaux.com/qrs/about means that you are using default virtual proxy (you can see default VP configuration in QMC). When you use a VP you must authenticate against the VP it self, based on the auth method set in VP.
Hi Alex,
it's clear.
I found this error in the
regards
Benoît
Getting that authentication flow working with all the headers and cookies and whatnot is kind of tricky. But that error message seems to indicate that you are using .NET, and if that is the case, then this library might be of interest to you:
https://www.nuget.org/packages/QlikSenseRestClient/
It provides endpoints for authenticating in many different ways towards Qlik Sense. A couple of examples of how to use it can be found here:
https://github.com/kolsrud/qlik_rest_sdk/tree/master/Qlik.Sense.RestClient/Examples
With an example on using NTLM authentication here:
Hello, I believe your client is not supporting the Negotiate HTTP authentication scheme and/or the NTLM HTTP authentication scheme (https://www.rfc-editor.org/rfc/rfc4559.html)
I would try to share a tcpdump (or equivalent) of the client for the all HTTP session - I think this might help having a more detailed overview and figure out who is misbehaving.
Hi all,
big thanks for all your support, really appreciate. I explain a little bit more the context
we are using an external tool to run qlik sense reload "qliksensetask", and for some reason we received now a "not authorized" error ... I want to know what is blocking/ changed
error: The remote server returned an error: (401) Unauthorized."
check that the Proxy and QRS are running. Message: Unauthorized:
at QVnextDemoBuilder.QRSNTLMWebClient..ctor(String QRSserverURL, Int32 requesttimeout, Logger logger)
at QlikSenseJSONObjects.QlikSenseJSONHelper..ctor(String url, Int32 timeout, Logger logger)
at QlikSenseTask.Program.Main(String[] args)"
2024_09_26_12_09_28,Information,"Returning Errorlevel 8"
> the external tool uses NTLM auth. so I try to debug the root cause by doing myself a standard call with Insomnia for security issue, we can't use Postman.. ) so maybe this client did not manage well this protocol (as suspected by @Anonymous )
The only changed we did it's to add a new certificate on the Qlik Sense server , and added its thumbprint on the QS proxy.
Hello @girard_ben , many thanks to getting back with more infos!
In such repository there is a December 2021 issue that looks the same as yours: https://github.com/marcusspitzmiller/QlikSenseTask/issues/31; unfortunately, the mainter never answered.
The data you provided is still not enough, we really need the whole HTTP session; anyway, this weekend I will try to take a look into the code you shared even if I'm definitely not a .NET developer.
Thanks for sharing!
Please keep us posted if any!
Hello @girard_ben , looks like the tool supports both NTLM and KERBEROS, as it relays over WebClient.
In your first 401 error the WWW-Authenticate is set to Negotiate, which indicate that a KERBEROS auth challenge is requested by the server.
In the second message (spoiler) , you posted a transport stream error, which can be connected to a certificate authentication error.
You can use both authentication methods, but each one is located in a different layer: certificate authentication is a presentarion layer mechanism and KERBEROS or NTLM are implemented in the HTTP layer.
Whats your error here? I believe we really need a more detailed trace of the whole HTTP session.
Thanks!
hi @Anonymous
thks a lot for taking time to investigate.
> I'm not an expert about HTTP request , if you have a tools to monitor HTTP requests from the server QLikView let me know.
> on our hand, we change a little bit the way to proceed , we remove the qliksensetask from our scripts > now we use a python script and we do the auth. with the certificate by calling the endpoint on the port 4242
regards
Benoît