Skip to content
This repository has been archived by the owner on Feb 22, 2022. It is now read-only.

Enable SSL? #166

Open
ericneu opened this issue May 3, 2019 · 1 comment
Open

Enable SSL? #166

ericneu opened this issue May 3, 2019 · 1 comment

Comments

@ericneu
Copy link

ericneu commented May 3, 2019

So I get no errors when I start with this setup:

        MysqldConfig config = aMysqldConfig(v5_7_latest).withPort(port).withServerVariable("ssl", 1).withServerVariable("ssl_ca",caFile).withServerVariable("ssl_cert",certFile).withServerVariable("ssl_cipher","DHE-RSA-AES256-GCM-SHA384").withServerVariable("ssl_key", keyFile).withUser(user,password).build();
        SchemaConfig scfg = SchemaConfig.aSchemaConfig(database).build();
        DownloadConfig dnldcfg = aDownloadConfig().withCacheDir("/var/tmp").build();
        mysqld = EmbeddedMysql.anEmbeddedMysql(config,dnldcfg).addSchema(scfg).start();

however, when I try to connect with

jdbc:mysql://localhost:3306/testdb?useSSL=true&requireSSL=true&verifyServerCertificate =true&clientCertificateKeyStoreUrl=file:ssl/localhost.jks&clientCertificateKeyStorePassword=redacted&trustCertificateKeyStoreUrl=file:ssl/localhostca.jks&trustCertificateKeyStorePassword=redacted

I get a "could not connect SSL required but server does not support SSL", if I just take out the requireSSL=true it connects, but doing a show variables like 'have_ssl' it says DISABLED.

Am I missing something?

@viliusl
Copy link
Collaborator

viliusl commented Nov 3, 2019

@ericneu - not really. I did not pursue ssl support - PR's are welcome to enable this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants