# create a new Java Trust and import the intermediate CA certificate
keytool -importcert -noprompt -alias intermediate -file INTERMEDIATE.pem -keystore trust.jks -storepass YourPassword
# import the root CA certificate to the Trust
keytool -importcert -noprompt -alias root -file ROOT.pem -keystore trust.jks -storepass YourPassword
# confirm you have the root and intermediate CA certs in the trust
keytool -v -list -keystore trust.jks