Remote error: tls: bad certificate during mutual TLS authentication

Hi,
I had set up the CA server (say CA server) and the generated the required certs and keys .

Also I had setup another server (Say Node Server) which uses the certificates from the CA for Docker Daemon Mutual authentication.

These are the list of certs and key placed under .docker of the Node server .

Also had given the Node servers DNS name as the CN while the node server cert creation:

My daemon.json is set with the values .

Also i had restarted docker once i had set the above

Had set the following env variables .

After all done, if I try to do docker version I get the following error with and without --tlsverify flag added:

The server probably has client authentication (–tlsverify) enabled. Please check your TLS client certification settings: Get https://127.0.0.1:2377/v1.39/version: remote error: tls: bad certificate

Could some one help me out , with what am i missing ?

PS: Since I was allowed upload only single image putting all images together.

Follow below URLs for help on TLS
https://docs.docker.com/engine/security/protect-access/

It`s worked! for ME :slight_smile:

Hello,

I found one thing: the paths in your /etc/docker/daemon.json are relative - there is no leading / - maybe that could be the reason?

Best regards
Matthias

P.S.: funny idea to put mutliple images into one :slight_smile:

@matthiasradde for what it’s worth, my setup does have absolute paths yet I have the same TLS error as OP.

@submani these instructions are the ones yielding the TLS error