Hello,We are developing a custom service that uses TLS certificates. Clients connect to that service and must present their client certificate. The client certificates are signed by a CA managed by our service. Our service's CA cert is in turn signed by a root cert, and not self signed. We do not want to require the clients to hold the services intermediate cert, and so they connect just presenting their own client certificate.
However, the erlang SSL application does not seem to allow for this setup. It seems to require that to verify the client certificate, that the service's cert is self signed (ie a root cert) or that the client provide all intermediate certs in the chain. Is there a way to configure the service with the intermediate cert as the ca, and not require the client to also send it as part of the chain?
Thanks,Erik
_______________________________________________
erlang-questions mailing list
erlang-q...@erlang.org
http://erlang.org/mailman/listinfo/erlang-questions
In fact erlang's ssl implementation provides for such a concept through partial_chain, except the implementation requires the client to send the chain up to and including the trusted intermediate. But the client should not have to send what the server considers the "trusted root".
I think the question is, why does the client have to send the trusted intermediate certificate. How does not sending it "break TLS" as you say? Do you mean it breaks erlang's implementation of TLS, or its a spec violation? I can find no indication of that.
Chris
Sent: Friday, February 23, 2018 at 9:45 AM
From: "Erik Seres" <erik...@exosite.com>
To: "Erlang-Questions Questions" <erlang-q...@erlang.org>
Subject: Re: [erlang-questions] Intermediate certificate as CA
When you say "breaks the TLS protocol" are you referring to establishing trust through PKI or that somehow the connection security is somehow compromised?
Erik
From the TLS RFC:
certificate_list This is a sequence (chain) of certificates. The sender's certificate MUST come first in the list. Each following certificate MUST directly certify the one preceding it. Because certificate validation requires that root keys be distributed independently, the self-signed certificate that specifies the root certificate authority MAY be omitted from the chain, under the assumption that the remote end must already possess it in order to validate it in any case.
Regards Ingela Erlang/OTP team - Ericsson AB
Interesting. In my understanding it is perfectly valid for a server to choose to trust an intermediate certificate and validate connecting peers against it.
In fact erlang's ssl implementation provides for such a concept through partial_chain, except the implementation requires the client to send the chain up to and including the trusted intermediate. But the client should not have to send what the server considers the "trusted root".
I think the question is, why does the client have to send the trusted intermediate certifoveicate. How does not sending it "break TLS" as you say? Do you mean it breaks erlang's implementation of TLS, or its a spec violation? I can find no indication of that.
{cert, public_key:der_encoded()} |{certfile, path()}
CA+- ICA1+- ICA2+- peer1+- peer2...
peer1, ICA2, ICA1 [, CA]
CA+- ICA1+- server+- ICA2+- client
Interesting. That entails I trust an intermediate in my certificate chain for connections from peers, which on the face of it doesn't seem correct, as it widens the collection of trusted peers unnecessarily. Couldn't there be cases where you only want to trust peers from a certain CA (e.g., an issuing authority that is strictly below your own issuer), but not your own issuer?
Path to a file containing PEM-encoded CA certificates. The CA certificates are used to build the server certificate chain and for client authentication. The CAs are also used in the list of acceptable client CAs passed to the client when a certificate is requested. Can be omitted if there is no need to verify the client and if there are no intermediate CAs for the server certificate.
Path to a file containing PEM-encoded CA certificates. The CA certificates are used during server authentication and when building the client certificate chain.
E.g., something likeCA+- ICA1+- server+- ICA2+- clientbut where you only want to accept connections from ICA2.(I don't have this particular problem, but it does come to mind.)Semantically it's a little strange, too, but that can always be fixed with documentation.Is this because the implementation depends on OpenSSL, or just the design?
If the latter, I would suspect that changing the behavior to specify own certificate chains outside of the trust store would introduce nontrivial upgrade issues for existing users, unwitting, or otherwise.-FredOn Mar 18, 2018, at 5:58 PM, Ingela Andin <ingela...@gmail.com> wrote:All intermediate CA:s should be placed in the cacertfile option together with trusted ROOT certs, this way of configuring has been inherited from OpenSSL.