A certificate is signed by the CA which issues it. A self-signed certificate, by definition, is not issued by a CA (or is its own CA, if you want to view it like this).
A certificate may have CA power, i.e. be trusted to sign other certificates, or not, depending on whether it contains a Basic Constraints
extension with the cA
flag set to TRUE
(cf the standard).
What happens is the following: when some application wants to validate a certificate (e.g. a Web browser who wants to do SSL with a server, and just obtained the server's certificate), it will want to build a certificate chain which begins with a "trust anchor" (one of the certificates in its "trusted root" certificate store) and ends with the certificate to validate (called "EE" as "end-entity"). Exact rules for a chain to be valid are intricate and full of details; for the purposes of this answer, let's limit ourselves to these necessary conditions:
- The chain must start with a trust anchor.
- Each certificate is signed by the previous certificate in the chain (i.e. the signature on each certificate is to be verified relatively to the public key as is stored in the previous certificate).
- Each certificate except the end-entity has a
Basic Constraints
extension with the cA
flag set to TRUE
.
So a self-signed but not CA certificate, when used as a trust anchor, will be accepted as valid as an end-entity certificate (i.e. in a chain reduced to that certificate exactly) but not otherwise. This is the normal case. When, as a browser user, you want to accept a given self-signed certificate as valid, you actually tell your browser that the self-signed certificate should become a trust anchor -- but you certainly do not want to trust that certificate for issuing other certificates with other names ! You want to trust it only for authenticating a specific site.
As usual, details may vary -- not all browsers react in the exact same ways. But the core concepts remain:
- A self-signed certificate lives outside of the CA world: it is not issued by a CA.
- A client (browser) uses trust anchors as the basis for what it trusts.
- A self-signed certificate for a Web server, usually, should be trusted (if at all) only for that server, i.e. added as a trust anchor, but not tagged as "good for issuing certificates".
When a chain is reduced to a single certificate, i.e. the end-entity is also the trust anchor, then this is known as direct trust: a specific certificate is trusted by being already known, exactly, instead of being trusted by virtue of being issued by a trusted CA.