{"record":{"id":"03fce4cc604997be","repo":"pentaho/pentaho-kettle","slug":"rest-error-nosuchalgorithm","errorCode":"Rest.Error.NoSuchAlgorithm","errorMessage":"Rest.Error.NoSuchAlgorithm","messagePattern":"Rest\\.Error\\.NoSuchAlgorithm","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"plugins/rest/core/src/main/java/org/pentaho/di/trans/steps/rest/Rest.java","lineNumber":365,"sourceCode":"          data.basicAuthentication =\n            HttpAuthenticationFeature.basicBuilder()\n              .credentials( data.realHttpLogin, data.realHttpPassword )\n              .build();\n        }\n      }\n      // SSL TRUST STORE CONFIGURATION\n      setSSLConfiguration( data );\n    }\n  }\n\n  protected void setSSLConfiguration( RestData data ) throws KettleException {\n    try ( var trustStoreIn = getInputStream( data.trustStoreFile ) ) {\n      data.sslContext = HttpClientManager.getSslContext( meta.isIgnoreSsl(),\n        trustStoreIn,\n        data.trustStorePassword );\n\n    } catch ( NoSuchAlgorithmException e ) {\n      throw new KettleException( BaseMessages.getString( PKG, \"Rest.Error.NoSuchAlgorithm\" ), e );\n    } catch ( KeyStoreException e ) {\n      throw new KettleException( BaseMessages.getString( PKG, \"Rest.Error.KeyStoreException\" ), e );\n    } catch ( CertificateException e ) {\n      throw new KettleException( BaseMessages.getString( PKG, \"Rest.Error.CertificateException\" ), e );\n    } catch ( FileNotFoundException e ) {\n      throw new KettleException( BaseMessages.getString( PKG, \"Rest.Error.FileNotFound\", data.trustStoreFile ), e );\n    } catch ( IOException e ) {\n      throw new KettleException( BaseMessages.getString( PKG, \"Rest.Error.IOException\" ), e );\n    } catch ( KeyManagementException | UnrecoverableKeyException e ) {\n      throw new KettleException( BaseMessages.getString( PKG, \"Rest.Error.KeyManagementException\" ), e );\n    }\n  }\n\n  /**\n   * Get an InputStream for the file with the given name.\n   * If the file name is empty or null, returns null.\n   *\n   * @param fileName the file name to get InputStream from","sourceCodeStart":347,"sourceCodeEnd":383,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/plugins/rest/core/src/main/java/org/pentaho/di/trans/steps/rest/Rest.java#L347-L383","documentation":"setSSLConfiguration loads the trust store via HttpClientManager.getSslContext; a java.security.NoSuchAlgorithmException is wrapped in a KettleException with Rest.Error.NoSuchAlgorithm. It means the JRE does not recognize the algorithm needed to build the SSL context / trust store.","triggerScenarios":"Trust store file declares or requires a KeyStore algorithm unsupported by the runtime JVM (e.g. PKCS12-only keytool store vs old JCE providers, or a restricted JRE without TLS1.2/1.3 support).","commonSituations":"Trust store created with a newer keytool than the JVM running Pentaho; running on a stripped-down JRE lacking crypto providers; mismatched JAVA_HOME between store creation and runtime.","solutions":["Check the cause message to identify the missing algorithm","Regenerate the trust store with the JVM's own keytool (e.g. keytool -importcert -storetype PKCS12) so the algorithm matches the runtime","Ensure a full JDK/JRE with standard crypto providers (SUN, SunJSSE) is being used — check JAVA_HOME","Update the JVM/Pentaho to a version supporting the store's algorithm","Avoid custom trust store entirely if only 'ignore SSL' behavior is needed"],"exampleFix":"// before\nkeytool -importcert -file server.crt -keystore truststore.jks\n// after\nkeytool -importcert -file server.crt -keystore truststore.p12 -storetype PKCS12 -storepass changeit","handlingStrategy":"try-catch","validationCode":"// verify the JVM can instantiate the keystore algorithm before the step runs\ntry {\n  java.security.KeyStore.getInstance( \"PKCS12\" );\n} catch ( java.security.KeyStoreException e ) {\n  throw new IllegalStateException( \"JVM lacks required keystore providers: \" + e.getMessage() );\n}","typeGuard":null,"tryCatchPattern":"try {\n  step.setConfig( meta, data, row );\n} catch ( KettleException e ) {\n  if ( e.getMessage().contains( \"NoSuchAlgorithm\" ) ) {\n    log.error( \"Trust store algorithm unsupported by this JVM — recreate store with the runtime's keytool\", e );\n  }\n}","preventionTips":["Create trust stores using the same JDK that runs Pentaho","Use PKCS12 (the modern default) rather than legacy JKS","Run a full JDK/JRE with standard SunJSSE providers, not a stripped runtime","Keep JAVA_HOME consistent between store generation and runtime"],"tags":["ssl","keystore","java"],"backgroundTag":"ssl-configuration-error","analyzedSha":"f3058517a153da500bf4551f46d79b91bf8ec552","analyzedAt":"2026-09-13T14:04:16.340Z","contentChangedAt":"2026-09-13T14:04:16.340Z","schemaVersion":2},"datasetVersion":"2026-09-20T23:17:15.980Z"}