Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
ALERT: The support homepage carousel is not displaying. We are working toward a resolution.

Qlik Talend Product: Error 400 - Invalid SNI error after Installed Talend Runtime 2025-02 Patch or Later

No ratings
cancel
Showing results for 
Search instead for 
Did you mean: 
Robert_Pence
Support
Support

Qlik Talend Product: Error 400 - Invalid SNI error after Installed Talend Runtime 2025-02 Patch or Later

Last Update:

May 14, 2025 2:42:54 AM

Updated By:

Xiaodi_Shi

Created date:

May 14, 2025 2:46:21 AM

You may encounter an error : 400 - Invalid SNI when calling Talend Runtime API (Job as service) after installed 2025-02 patch or later. In the past before the patch version R2025-02 of Talend Runtime Server, it did work well when using the same certificate for SSL connection with Talend Runtime Server and did not cause any issue. 

The SNI validation is active after 2025-02 patch or later.

 

Resolution

There are three options to slove this issue

  1. Obtain and install a proper certificate that references the correct host name and then access it with the hostname rather than by IP.
  2. Disable SNI host check.
  3. Tell Talend component to resolve IP as hostname

Disable SNI Host Check

This has the same security risk as jetty before it was updated (low security)

In <RuntimeInstallationFolder>/etc/org.ops4j.pax.web.cfg file, please add

jetty.ssl.sniRequired=false

and 

jetty.ssl.sniHostCheck=false

 

Or configuring these jetty parameters in <RuntimeInstallationFolder>/etc/jetty.xml or jetty-ssl.xml file

  • Find the <New class="org.eclipse.jetty.server.SecureRequestCustomizer"> block in your jetty.xml or jetty-ssl.xml 

  • Edit the <Arg name="sniRequired" ...> and <Arg name="sniHostCheck" ...> lines so that the properties' defaults are set to false as shown below:

    <New id="sslHttpConfig" class="org.eclipse.jetty.server.HttpConfiguration">
    <Arg><Ref refid="httpConfig"/></Arg>
    <Call name="addCustomizer">
    <Arg>
    <New class="org.eclipse.jetty.server.SecureRequestCustomizer">
    <Arg name="sniRequired" type="boolean">
    <Property name="jetty.ssl.sniRequired" default="false"/>
    </Arg>
    <Arg name="sniHostCheck" type="boolean">
    <Property name="jetty.ssl.sniHostCheck" default="false"/>
    </Arg>
    <Arg name="stsMaxAgeSeconds" type="int">
    <Property name="jetty.ssl.stsMaxAgeSeconds" default="-1"/>
    </Arg>
    <Arg name="stsIncludeSubdomains" type="boolean">
    <Property name="jetty.ssl.stsIncludeSubdomains" default="false"/>
    </Arg>
    </New>
    </Arg>
    </Call>
    </New>

    SNIChecking.png

 

Resolve IP to Hostname

If the certification includes the domain name, you should use that domain name instead of the IP with the Jetty security updates in Talend Runtime Server.

But if your DNS server does not resolve the IP, you must call it by the IP address, so please check it at first to see if the workaround is feasible for your current situation.

In the examples the hostname is unresolvedhost.net and the IP is 10.20.30.40.

Try this API call at the command line:

curl -k -X GET --resolve unresolvedhost.net:9001:10.20.30.40 https://unresolvedhost.net:9001/services/

or

curl -k -X GET -H "Host: unresolvedhost.net" https://10.20.30.20:9001/services/

If this works, in your Talend component that makes the API call, go to "Advanced settings" or "Headers" table, add a row with Key: Host and Value: The hostname that matches your SSL certificate (e.g. unresolvedhost.net)

This will instruct Talend to send the correct Host header, which most HTTP clients (including Java's HttpClient) will also use as the SNI value during the TLS handshake.
 

Cause

The SNI enforcement is there for a security reason. With the 2025-02 patch, the Jetty components on Talend Runtime Server resolved a CVE security issue where they allowed a hostname to connect to a server that doesn't match the hostname in the server's TLS certificate.

Certificates require the URI not to be localhost or an IP address, and to have at least one dot, so a fully qualified domain name is best.

 

 

Related Content 

 https://stackoverflow.com/questions/69945173/org-eclipse-jetty-http-badmessageexception-400-invalid-...

 

 

Environment

Talend ESB 

Labels (1)
Comments
Björn_N
Contributor
Contributor

Having issues with this solution to disable the SNI-check. Preparing an upgrade to 8.0.2.R2025-02-RT_Platform_4

Can't get the config etc/org.ops4j.pax.web.cfg to turn off SNI-check.

With the jetty.xml I was able to confuigure it with adding a stub or I would get a error refencing "refid="httpConfig""

<New id="httpConfig" class="org.eclipse.jetty.server.HttpConfiguration"> </New>

 

Not that familiar with jetty cofigurations to know what's really the issue here and why the property settings has no effect.


Xiaodi_Shi
Employee
Employee

Hello @Björn_N 

Please edit the <Arg name="sniRequired" ...> and <Arg name="sniHostCheck" ...> lines so that the properties' defaults are set to false.

Here is the procedure to disable sni check in the karaf jetty configuration for development: 

edit $KARAF_HOME/etc/jetty.xml

<Configure id="Server" class="org.eclipse.jetty.server.Server">

<New id="httpsConfig" class="org.eclipse.jetty.server.HttpConfiguration">
   <Set name="secureScheme">https</Set>
   <Set name="securePort">9001</Set>
   <Call name="addCustomizer">
     <Arg>
       <New class="org.eclipse.jetty.server.SecureRequestCustomizer">
         <Set name="sniHostCheck">false</Set>
         <Set name="sniRequired">false</Set>
       </New>
     </Arg>
   </Call>
</New>
<Call name="addConnector">
   <Arg>
     <New class="org.eclipse.jetty.server.ServerConnector">
       <Arg name="server"><Ref refid="Server" /></Arg>
       <Arg name="factories">
         <Array type="org.eclipse.jetty.server.ConnectionFactory">
           <Item>
             <New class="org.eclipse.jetty.server.SslConnectionFactory">
               <Arg name="next">http/1.1</Arg>
               <Arg name="sslContextFactory">
                 <New class="org.eclipse.jetty.util.ssl.SslContextFactory$Server">
                   <Set name="sniRequired">false</Set>
                   <Set name="sniHostCheck">false</Set>
                 </New>
               </Arg>
             </New>
           </Item>
           <Item>
             <New class="org.eclipse.jetty.server.HttpConnectionFactory">
               <Arg name="config"><Ref refid="httpsConfig" /></Arg>
             </New>
           </Item>
         </Array>
       </Arg>
     </New>
   </Arg>
 </Call>

</Configure>

Hope it helps.

 

Best regards

Sabrina

 

NarayanaNalagesigari
Contributor
Contributor

Hi @Xiaodi_Shi  thanks for the updated jetty.xml config which worked for me. However any idea why adding the properties to pax file isn't working? would be easier if that works instead of fiddling with the jetty.xml. 

 

Happy to hear . Thanks once again

Xiaodi_Shi
Employee
Employee

Hello @NarayanaNalagesigari 
Since those are jetty params names not pax-web, so need to configure the jetty xml file. The SNI enforcement is there for a reason.
Feel free to let me know if there is anything I could help.
Best regards

Sabrina

Version history
Last update:
‎2025-05-14 02:42 AM
Updated by: