Skip to Content
Author's profile photo Former Member

How to create your SSL for mobile devices

Hi,

I would like to post the procedure to create the correct SSL for your mobile devices:

– Android SAP Business One App 1.2.0

– iOS SAP Business One App 1.11.1

Use the IP Address instead using the hostname

Once you install OpenSSL run the above command lines

You can find the keystorepassword in the ./Tomcat/conf/server.xml file in the keystorePass attribute

1. set OPENSSL_CONF=c:\openssl-win32\bin\openssl.cfg

/wp-content/uploads/2015/04/1_686213.jpg

2. openssl genrsa -out ServerKey.key 1024

/wp-content/uploads/2015/04/2_686220.jpg

3. openssl req -new -x509 -key ServerKey.key -out myCA.cer -days 3650 -subj /CN=CustomName

/wp-content/uploads/2015/04/3_686221.jpg

4. openssl genrsa -out ClientKey.key 1024

/wp-content/uploads/2015/04/4_686234.jpg

5. openssl req -new -key ClientKey.key -out CertReq.csr -subj /CN=“IP Address”

/wp-content/uploads/2015/04/5_686235.jpg

6. openssl x509 -req -days 3650 -in CertReq.csr -CA myCA.cer -CAkey ServerKey.key -CAcreateserial -out ClientCert.crt

/wp-content/uploads/2015/04/6_686236.jpg

7. openssl pkcs12 -export -inkey ClientKey.key -in ClientCert.crt -out keystore.pkcs12

/wp-content/uploads/2015/04/7_686237.jpg

8. Copy your keystore.pkcs12 file to your B1 Integration Framework (B1i) folder (example ./webapps/B1iXcellerator/keystore.pkcs12) to be sure keytool can read it

9. In the CMD change path folder to the bin of your JAVA installation:

  (example C:\Program Files (x86)\Java\jre1.8.0_40\bin)

/wp-content/uploads/2015/04/9_686238.jpg

10. keytool -delete -alias tomcat -keystore “C:\Program Files (x86)\SAP\SAP Business One Integration\IntegrationServer\Tomcat\webapps\B1iXcellerator\.keystore” -storepass “keystorepassword”

/wp-content/uploads/2015/04/1_686213.jpg

11. keytool -importkeystore -srckeystore “C:\Program Files (x86)\SAP\SAP Business One Integration\IntegrationServer\Tomcat\webapps\B1iXcellerator\keystore.pkcs12” -srcstoretype PKCS12 -destkeystore “C:\Program Files (x86)\SAP\SAP Business One Integration\IntegrationServer\Tomcat\webapps\B1iXcellerator\.keystore” -deststoretype JKS -deststorepassword keystore -srcstorepass keystorepassword

/wp-content/uploads/2015/04/1_686213.jpg

12. keytool -changealias -alias 1 -destalias tomcat -keystore “C:\Program Files (x86)\SAP\SAP Business One Integration\IntegrationServer\Tomcat\webapps\B1iXcellerator\.keystore” -storepass keystorepassword

/wp-content/uploads/2015/04/1_686213.jpg

13. Once you finish this commands restart your B1Integration Service

14. Send your CA.cer to your devices via email and install them

Assigned Tags

      6 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Former Member
      Former Member

      David, buneas tardes.

      Gracias por el aporte, estuve intentando crear el certificado pero me arroja este errro al momento de ejecutar el paso 10 del manual, a qué se debe el error?Error al crear Certificado SSL.png

      Author's profile photo Former Member
      Former Member

      Cordial Saludo. gracias por el tutorial.

      Después del paso 10 tengo problemas dice:

      Error de keytool: java.io.IOException: Keystore was tampered with, or password was incorrect

      gracias, 🙂

      Author's profile photo Gonzalo Gomez
      Gonzalo Gomez

      A mi me pasa lo mismo. ¿Alguna solución al respecto?

      Author's profile photo Former Member
      Former Member

      Hola,

      La contraseña correcta se encuentra dentro de server.xml

      C:\Program Files (x86)\SAP\SAP Business One Integration\IntegrationServer\Tomcat\conf\server.xml

      Passkeystore B1.jpg

      Tengo el mismo problema, pude crear en diversas ocaciones el certificado, pero no aún así no me conecta, hay otra forma, pero es bajar las seguridad del Integration, de esta forma me conectó pero ahora la factura no timbra cuando es nativo el timbrado por SAP.

      Author's profile photo Gonzalo Gomez
      Gonzalo Gomez

      ok, lo encontré releyendo la documentación, gracias.

      Author's profile photo Former Member
      Former Member

      Buena tarde,

      tengo un problema al generar mi certificado  en el paso numero 6 me marca "

      El certificado de CA y la clave privada de CA no coinciden"
      
      Alguien sabe por que  sucede esto y como lo puedo solucionar, de antemano muchas gracias.
      
      Saludos a todos.