Hello ,
I am using B4J with ABMmaterial.
Windows PC , tried JDK and OpenJDK
Firewall 443 open.
SSL provider is Strato , the server is also from them.
Domain name linked to the server ip
When trying to connect with Chrome and Explorer i get an ERR_SSL_PROTOCOL_ERROR
1. I made a keystore using the key tool:
keytool -genkey -alias commcheckserver1.eu -keyalg RSA -keysize 2048 -keystore keystore.jks
2. Made a .csr file using this:
keytool -certreq -alias commcheckserver1.eu -file csr.csr -keystore keystore.jks
3. Openend the .csr and pasted at with SSL provider
Q1: When i create the csr file the first and last name should be the domain name:When i enter www,commcheckserver1.eu as specified in several websites it is not allowed by the SSL provider.\
Only when removing www. it is allowed.
Is this the probable cause of my problem?
4. I get 3 certificates from the SSL provider:
5.I converted the certificate to the keystore(Tried all 3) using :
keytool -keystore keystore -import -alias commcheckserver1.eu -file cert_commcheckserver1.eu.crt -trustcacerts
6 Copied the keystore to File.Dir app folder:
7.Configure SSL(443) before App start
Q4 What is the KeyManagerPassword?I use the KeyStorePassword in the described command line but have no idea what the manager password should do?
8.Tried the following code as well without success.
9. I noticed this in the log :
2021-06-27 17:52:40.278:INFO
ejus.SslContextFactory:main: x509=X509@6f3c660a(commcheckserver1.eu,h=[commcheckserver1.eu, www.commcheckserver1.eu],w=[]) for SslContextFactory@2d9caaeb[provider=null,keyStore=file:///C:/Users/Administrator/Documents/CC_Protect/Objects/keystore,trustStore=null]
Q5 Can this be the problem?
I am using B4J with ABMmaterial.
Windows PC , tried JDK and OpenJDK
Firewall 443 open.
SSL provider is Strato , the server is also from them.
Domain name linked to the server ip
When trying to connect with Chrome and Explorer i get an ERR_SSL_PROTOCOL_ERROR
1. I made a keystore using the key tool:
keytool -genkey -alias commcheckserver1.eu -keyalg RSA -keysize 2048 -keystore keystore.jks
2. Made a .csr file using this:
keytool -certreq -alias commcheckserver1.eu -file csr.csr -keystore keystore.jks
3. Openend the .csr and pasted at with SSL provider
Q1: When i create the csr file the first and last name should be the domain name:When i enter www,commcheckserver1.eu as specified in several websites it is not allowed by the SSL provider.\
Only when removing www. it is allowed.
Is this the probable cause of my problem?
4. I get 3 certificates from the SSL provider:
- Certificate
- Root-CA-Certificate
- Intermediate Certificate
5.I converted the certificate to the keystore(Tried all 3) using :
keytool -keystore keystore -import -alias commcheckserver1.eu -file cert_commcheckserver1.eu.crt -trustcacerts
6 Copied the keystore to File.Dir app folder:
7.Configure SSL(443) before App start
B4X:
Private Sub ConfigureSSL (SslPort As Int)
Try
Dim ssl As SslConfiguration
ssl.Initialize
ssl.SetKeyStorePath(File.DirApp, KeyStoreFile) 'path to keystore file
ssl.KeyStorePassword = KeyStorePassword
ssl.KeyManagerPassword = KeyKeyManagerPassword
'ssl.EnableConscryptProvider '<---------
srvr.SetSslConfiguration(ssl, SslPort)
'add filter to redirect all traffic from http to https (optional)
srvr.AddFilter("/*", "HttpsFilter", False)
Catch
Log("Configure SSL Failed "&LastException)
End Try
End Sub
Q4 What is the KeyManagerPassword?I use the KeyStorePassword in the described command line but have no idea what the manager password should do?
8.Tried the following code as well without success.
B4X:
myApp.StartServerHTTP2(srvr,"srvr", 80,443,KeyStoreFile,KeyStorePassword,KeyKeyManagerPassword)
9. I noticed this in the log :
2021-06-27 17:52:40.278:INFO
Q5 Can this be the problem?