<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=US-ASCII" http-equiv="Content-Type">
<title>
GitLab
</title>
<style>img {
max-width: 100%; height: auto;
}
</style>
</head>
<body>
<div class="content">
<p class="details" style="font-style: italic; color: #777;">
<a href="https://gitlab.com/Immortalem">Immortalem</a> created an issue <a href="https://gitlab.com/gnutls/gnutls/-/issues/1030">#1030</a>:
</p>
<div></div>
<h2 dir="auto">
<a id="user-content-description-of-problem" class="anchor" href="#description-of-problem" aria-hidden="true"></a>Description of problem:</h2>
<p dir="auto">The specification for TLS 1.2 (<a href="https://tools.ietf.org/html/rfc5246#section-7.4.6" rel="nofollow noreferrer noopener" target="_blank">RFC 5246</a>) requires the usage of X.509v3 certificates for entity authentication. GnuTLS allows the usage of version one and two certificates.</p>
<h2 dir="auto">
<a id="user-content-version-of-gnutls-used" class="anchor" href="#version-of-gnutls-used" aria-hidden="true"></a>Version of gnutls used:</h2>
<p dir="auto">3.6.13, 3.6.14</p>
<h2 dir="auto">
<a id="user-content-distributor-of-gnutls-eg-ubuntu-fedora-rhel" class="anchor" href="#distributor-of-gnutls-eg-ubuntu-fedora-rhel" aria-hidden="true"></a>Distributor of gnutls (e.g., Ubuntu, Fedora, RHEL)</h2>
<p dir="auto">Compiled from source after cloning the respective branch from GitHub</p>
<h2 dir="auto">
<a id="user-content-how-reproducible" class="anchor" href="#how-reproducible" aria-hidden="true"></a>How reproducible:</h2>
<p dir="auto">Steps to Reproduce:</p>
<ul dir="auto">
<li>Start <code>gnutls-serv</code> with
<ul>
<li>
<a href="https://gitlab.com/gnutls/gnutls/uploads/8e79d085d9f7ada8e9f088c0b21f268d/ROOTv3_CAv3_LEAF_RSAv3__leaf_certificate1.pem" data-link="true" class="gfm">ROOTv3_CAv3_LEAF_RSAv3__leaf_certificate1.pem</a> for <code>--x509certfile</code>
</li>
<li>
<a href="https://gitlab.com/gnutls/gnutls/uploads/27f047de54220503eca641dde9f9bb2e/rsakey_2.pem" data-link="true" class="gfm">rsakey_2.pem</a> for <code>--x509keyfile</code>
</li>
<li>
<a href="https://gitlab.com/gnutls/gnutls/uploads/b080bace5ded73971868664aa18d6dc0/root.pem" data-link="true" class="gfm">root.pem</a> for <code>--x509cafile</code>
</li>
<li>require client certificate <code>-r</code>
</li>
<li>verify client certificate <code>--verify-client-cert</code>
</li>
</ul>
</li>
<li>Use OpenSSL <code>s_client</code> or similar tool to connect to the server using the following two certificates. This example uses OpenSSL.
<ul>
<li><code>openssl s_client -connect localhost:4433 -cert ROOTv3_CAv3_LEAF_RSAv2__leaf_certificate1.pem -key rsakey_2.pem -CAfile ROOTv3_CAv3_LEAF_RSAv2__ca_certificate1.pem</code></li>
<li><a href="https://gitlab.com/gnutls/gnutls/uploads/ba0ef0d0e622226b559446b45fe16c4e/ROOTv3_CAv3_LEAF_RSAv2__leaf_certificate1.pem" data-link="true" class="gfm">ROOTv3_CAv3_LEAF_RSAv2__leaf_certificate1.pem</a></li>
<li><a href="https://gitlab.com/gnutls/gnutls/uploads/644009f2a69240eba7908169940591ab/ROOTv3_CAv3_LEAF_RSAv2__ca_certificate1.pem" data-link="true" class="gfm">ROOTv3_CAv3_LEAF_RSAv2__ca_certificate1.pem</a></li>
<li><a href="https://gitlab.com/gnutls/gnutls/uploads/27f047de54220503eca641dde9f9bb2e/rsakey_2.pem" data-link="true" class="gfm">rsakey_2.pem</a></li>
</ul>
</li>
</ul>
<p dir="auto">For version one the certificates are:</p>
<ul dir="auto">
<li><a href="https://gitlab.com/gnutls/gnutls/uploads/322173f1e006247727e5961fec128c5a/ROOTv3_CAv3_LEAF_RSAv1__leaf_certificate1.pem" data-link="true" class="gfm">ROOTv3_CAv3_LEAF_RSAv1__leaf_certificate1.pem</a></li>
<li><a href="https://gitlab.com/gnutls/gnutls/uploads/290501bc7cf402d9101ed35d7af45378/ROOTv3_CAv3_LEAF_RSAv1__ca_certificate1.pem" data-link="true" class="gfm">ROOTv3_CAv3_LEAF_RSAv1__ca_certificate1.pem</a></li>
<li><a href="https://gitlab.com/gnutls/gnutls/uploads/27f047de54220503eca641dde9f9bb2e/rsakey_2.pem" data-link="true" class="gfm">rsakey_2.pem</a></li>
</ul>
<h2 dir="auto">
<a id="user-content-actual-results" class="anchor" href="#actual-results" aria-hidden="true"></a>Actual results:</h2>
<p dir="auto">GnuTLS accepts the certificates as valid and proceeds with the handshake.</p>
<h2 dir="auto">
<a id="user-content-expected-results" class="anchor" href="#expected-results" aria-hidden="true"></a>Expected results:</h2>
<p dir="auto">GnuTLS should reject the certificates and abort the handshake.</p>
</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #777;">
—
<br>
Reply to this email directly or <a href="https://gitlab.com/gnutls/gnutls/-/issues/1030">view it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.com.
If you'd like to receive fewer emails, you can
<a href="https://gitlab.com/-/sent_notifications/bc05f8a5126ea70ebce1c7aba24bf495/unsubscribe">unsubscribe</a>
from this thread or
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Issue","url":"https://gitlab.com/gnutls/gnutls/-/issues/1030"}}</script>
</p>
</div>
</body>
</html>