App Connect

 View Only
Expand all | Collapse all

App ssl issue while connect to an external web service

  • 1.  App ssl issue while connect to an external web service

    Posted 6 days ago

    Hello Team,
    I am trying to reach a web service  from a SOAP request node  but facing the below issue

    HTTP Response Error, send to alternate: Node throwing exception / Error occurred in ImbSOAPRequestHelper::makeSOAPRequest() / WebService Request Exception / A Web Service request has detected a SOCKET error whilst invoking a web service located at host &1, on port &2, on path &3. RecoverableException<com.ibm.broker.plugin.MbRecoverableException class:SecurityUtils method:loadKeystore source:BIPmsgs key:3537 >
    the BIP messages refers to "unable to open keystore due to error "
    The jks file is placed in home/aceuser/ace-server/xxx.jks and the integration server server.conf.yaml has been updated for

       keystoreType: 'JKS'
        keystoreFile: 'home/aceuser/keystores/xxx.jks'
        keystorePass: 'password'
        truststoreType: 'JKS'
        truststoreFile: 'home/aceuser/keystores/xxx.jks'
        truststorePass: 'password'

    Things I checked
    1.the keystore has the correct permission
    2.Used the keytool list to find the expiry and the keystore type-all good 
    Please let me know if you need more info
    Thanks a lot



    ------------------------------
    madhu ram
    ------------------------------


  • 2.  RE: App ssl issue while connect to an external web service

    Posted 6 days ago

    The location you advertized in the yaml file does not match the location you say you put the file in ...



    ------------------------------
    Francois Brandelik
    ------------------------------



  • 3.  RE: App ssl issue while connect to an external web service

    Posted 5 days ago
    Edited by Rogerio Silva de Almeida 5 days ago

    Hi madhu ram,

    This is a example of server.conf.yaml:
        truststoreType: 'JKS'
        truststoreFile: '/var/mqsi/components/BrokerTrustStore.jks'
        truststorePass: 'is1TrustStore::password'
    Take note of the is1TrustStore::password value in the second command. This should be identical with your integration server name, mine being is1.
    Following command will set the password value given above.
    mqsisetdbparms ACE1 -n is1TrustStore::password -u ignore -p abc@123
    More details on 
    https://ayasothar.medium.com/ibm-app-connect-enterprise-ace-tls-configuration-6137571fbff9
    https://www.ibm.com/docs/en/app-connect/12.0?topic=commands-mqsireportdbparms-command
    https://www.ibm.com/docs/en/app-connect/12.0?topic=commands-mqsisetdbparms-command

    i hope help you.


    ------------------------------
    Rogerio Silva de Almeida
    ------------------------------



  • 4.  RE: App ssl issue while connect to an external web service

    Posted 5 days ago

    @madhu ram Can you try with path  keystoreFile: '/home/aceuser/keystores/xxx.jks' and see if that works.



    ------------------------------
    Prosanta Saha
    ------------------------------



  • 5.  RE: App ssl issue while connect to an external web service

    Posted 5 days ago
    Hi,
     
    Some questions:
    The service that you are calling using the SOAP request node.Does it require to have mutual-tls or just server-side tls?
    If it doesn't require mutual-tls, then you don't need the keyStore* config in your server-conf.yaml. 
    Does your keystore contain a valid private/public keypair?
    Did you try to have seperate xxx.jks files, one for the truststore and one for the keystore seperate?
    Is the password set in the vault/setdbparms correctly set?
     
    Steps that I would take:
    - check if the keystore config is required, if not disable the keystore* config.
    - if it is required. split the keystore and trustore into 2 seperate jks files.
    - load the private/public key into the keystore with the correct password.
    - check the password with mqsreportdbparms or with mqsicredentials.
     
    Hope this helps


    ------------------------------
    Kim Meynendonckx
    ------------------------------



  • 6.  RE: App ssl issue while connect to an external web service

    Posted 5 days ago

    Hello Kim,

    Answering your questions below 

    • Yes the service I am  calling with soap request is using mtls.
    • I made a mistake in the beginning, now I have a keystore and trust store separated.
    • Yes, my key store contains a valid private/public key pair
    • What pwd should I set in vault? The gateway uses mtls for connection ( correct me if I need to set one 
    • As it's an Mtls, keystore config  is required
    • I am facing g an error client TLS cert missing

    Question

    Should I configure the property ssl client key alias in the soap request node

    I tried setting it to the key alias name , but did not work

    Need Inputs 

    Thanks

    Madhu



    ------------------------------
    madhu ram
    ------------------------------



  • 7.  RE: App ssl issue while connect to an external web service

    Posted 2 days ago
    Hi Madhu,
     
    You need to set the password of the keystore in the vault or setdbparms like explained by @Rogerio Silva de Almeida
    Make sure that if you have set a decryption/encryption key on your private key that it's the same as your keystore password.
     
    If your keystore only conatians 1 private/publuc key pair then you don't need to specifiy the alias.
     
    Also double check that the path is correct like said by @Francois Brandelik
     
    Normally that should do the trick.
    Double check your keystore. You can install your keystore in your browser or postman and initiate the mtls step.
    If the mtls works then you should get back another soap or functional error(e.g no GET allowed).
     
    What is the error that you currently have?


    ------------------------------
    Kim Meynendonckx
    ------------------------------



  • 8.  RE: App ssl issue while connect to an external web service

    Posted 2 days ago

    Hello  Kim

    Thanks for the reply

    I tried to  set up mtls with postman

    And get the error

    Client TLS cert is required.



    ------------------------------
    madhu ram
    ------------------------------



  • 9.  RE: App ssl issue while connect to an external web service

    Posted 2 days ago

    Also do we need the vault if the keystore is using default pwd . Pardon my ignorance .



    ------------------------------
    madhu ram
    ------------------------------



  • 10.  RE: App ssl issue while connect to an external web service

    Posted 2 days ago

    Looks like you have a Key infrastructure error.

    Make sure that you have

    • a client key define in the keystore
    • the client signer chain available in the keystore
    • the client root cert in the destination's truststore
    • the destination server chain in the truststore
    • a password defined on each of the stores set either with set dbparms or in the vault

    Hope it helps



    ------------------------------
    Francois Brandelik
    ------------------------------



  • 11.  RE: App ssl issue while connect to an external web service

    Posted 2 days ago

    Thank you so much. Will try  the above  and update.



    ------------------------------
    madhu ram
    ------------------------------



  • 12.  RE: App ssl issue while connect to an external web service

    Posted 5 days ago

    You say you placed the jks files in 

    home/aceuser/ace-server/xxx.jks

    But your yaml gives a different directory: 

    keystoreFile: 'home/aceuser/keystores/xxx.jks'
    truststoreFile: 'home/aceuser/keystores/xxx.jks'

    Could it be that it is that simple?



    ------------------------------
    Francois Brandelik
    ------------------------------