diff options
Diffstat (limited to '')
-rw-r--r-- | docs/manual/ssl/ssl_intro.html | 13 | ||||
-rw-r--r-- | docs/manual/ssl/ssl_intro.html.en | 672 | ||||
-rw-r--r-- | docs/manual/ssl/ssl_intro.html.fr.utf8 | 727 | ||||
-rw-r--r-- | docs/manual/ssl/ssl_intro.html.ja.utf8 | 730 |
4 files changed, 2142 insertions, 0 deletions
diff --git a/docs/manual/ssl/ssl_intro.html b/docs/manual/ssl/ssl_intro.html new file mode 100644 index 0000000..25de340 --- /dev/null +++ b/docs/manual/ssl/ssl_intro.html @@ -0,0 +1,13 @@ +# GENERATED FROM XML -- DO NOT EDIT + +URI: ssl_intro.html.en +Content-Language: en +Content-type: text/html; charset=UTF-8 + +URI: ssl_intro.html.fr.utf8 +Content-Language: fr +Content-type: text/html; charset=UTF-8 + +URI: ssl_intro.html.ja.utf8 +Content-Language: ja +Content-type: text/html; charset=UTF-8 diff --git a/docs/manual/ssl/ssl_intro.html.en b/docs/manual/ssl/ssl_intro.html.en new file mode 100644 index 0000000..bdd4792 --- /dev/null +++ b/docs/manual/ssl/ssl_intro.html.en @@ -0,0 +1,672 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head> +<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /> +<!-- + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + This file is generated from xml source: DO NOT EDIT + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + --> +<title>SSL/TLS Strong Encryption: An Introduction - Apache HTTP Server Version 2.4</title> +<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" /> +<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" /> +<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" /> +<script src="../style/scripts/prettify.min.js" type="text/javascript"> +</script> + +<link href="../images/favicon.ico" rel="shortcut icon" /></head> +<body id="manual-page"><div id="page-header"> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p> +<p class="apache">Apache HTTP Server Version 2.4</p> +<img alt="" src="../images/feather.png" /></div> +<div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div> +<div id="path"> +<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP Server</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.4</a> > <a href="./">SSL/TLS</a></div><div id="page-content"><div id="preamble"><h1>SSL/TLS Strong Encryption: An Introduction</h1> +<div class="toplang"> +<p><span>Available Languages: </span><a href="../en/ssl/ssl_intro.html" title="English"> en </a> | +<a href="../fr/ssl/ssl_intro.html" hreflang="fr" rel="alternate" title="Français"> fr </a> | +<a href="../ja/ssl/ssl_intro.html" hreflang="ja" rel="alternate" title="Japanese"> ja </a></p> +</div> + + +<p>As an introduction this chapter is aimed at readers who are familiar +with the Web, HTTP, and Apache, but are not security experts. It is not +intended to be a definitive guide to the SSL protocol, nor does it discuss +specific techniques for managing certificates in an organization, or the +important legal issues of patents and import and export restrictions. +Rather, it is intended to provide a common background to <code class="module"><a href="../mod/mod_ssl.html">mod_ssl</a></code> users by pulling together various concepts, definitions, +and examples as a starting point for further exploration.</p> +</div> +<div id="quickview"><a href="https://www.apache.org/foundation/contributing.html" class="badge"><img src="https://www.apache.org/images/SupportApache-small.png" alt="Support Apache!" /></a><ul id="toc"><li><img alt="" src="../images/down.gif" /> <a href="#cryptographictech">Cryptographic Techniques</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#certificates">Certificates</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#ssl">Secure Sockets Layer (SSL)</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#references">References</a></li> +</ul><h3>See also</h3><ul class="seealso"><li><a href="#comments_section">Comments</a></li></ul></div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="cryptographictech" id="cryptographictech">Cryptographic Techniques</a></h2> + +<p>Understanding SSL requires an understanding of cryptographic +algorithms, message digest functions (aka. one-way or hash functions), and +digital signatures. These techniques are the subject of entire books (see +for instance [<a href="#AC96">AC96</a>]) and provide the basis for privacy, +integrity, and authentication.</p> + +<h3><a name="cryptographicalgo" id="cryptographicalgo">Cryptographic Algorithms</a></h3> + + <p>Suppose Alice wants to send a message to her bank to transfer some + money. Alice would like the message to be private, since it will + include information such as her account number and transfer amount. One + solution is to use a cryptographic algorithm, a technique that would + transform her message into an encrypted form, unreadable until it is + decrypted. Once in this form, the message can only be + decrypted by using a secret key. Without the key the message is useless: + good cryptographic algorithms make it so difficult + for intruders to decode the original text that it isn't worth their + effort.</p> + + <p>There are two categories of cryptographic algorithms: conventional + and public key.</p> + + <dl> + <dt>Conventional cryptography</dt> + <dd>also known as symmetric cryptography, requires the sender and + receiver to share a key: a secret piece of information that may be + used to encrypt or decrypt a message. As long as this key is kept + secret, nobody other than the sender or recipient can read the message. + If Alice and the bank know a secret key, then they can send each other + private messages. The task of sharing a key between sender and recipient + before communicating, while also keeping it secret from others, can be + problematic.</dd> + + <dt>Public key cryptography</dt> + <dd>also known as asymmetric cryptography, solves the key exchange + problem by defining an algorithm which uses two keys, each of which + may be used to encrypt a message. If one key is used to encrypt a + message then the other must be used to decrypt it. This makes it + possible to receive secure messages by simply publishing one key + (the public key) and keeping the other secret (the private key).</dd> + </dl> + + <p>Anyone can encrypt a message using the public key, but only the + owner of the private key will be able to read it. In this way, Alice + can send private messages to the owner of a key-pair (the bank), by + encrypting them using their public key. Only the bank will be able to + decrypt them.</p> + + +<h3><a name="messagedigests" id="messagedigests">Message Digests</a></h3> + + <p>Although Alice may encrypt her message to make it private, there + is still a concern that someone might modify her original message or + substitute it with a different one, in order to transfer the money + to themselves, for instance. One way of guaranteeing the integrity + of Alice's message is for her to create a concise summary of her + message and send this to the bank as well. Upon receipt of the message, + the bank creates its own summary and compares it with the one Alice + sent. If the summaries are the same then the message has been received + intact.</p> + + <p>A summary such as this is called a <dfn>message digest</dfn>, <em>one-way + function</em> or <em>hash function</em>. Message digests are used to create + a short, fixed-length representation of a longer, variable-length message. + Digest algorithms are designed to produce a unique digest for each + message. Message digests are designed to make it impractically difficult + to determine the message from the digest and (in theory) impossible to + find two different messages which create the same digest -- thus + eliminating the possibility of substituting one message for another while + maintaining the same digest.</p> + + <p>Another challenge that Alice faces is finding a way to send the digest + to the bank securely; if the digest is not sent securely, its integrity may + be compromised and with it the possibility for the bank to determine the + integrity of the original message. Only if the digest is sent securely can + the integrity of the associated message be determined.</p> + + <p>One way to send the digest securely is to include it in a digital + signature.</p> + + +<h3><a name="digitalsignatures" id="digitalsignatures">Digital Signatures</a></h3> +<p>When Alice sends a message to the bank, the bank needs to ensure that the +message is really from her, so an intruder cannot request a transaction +involving her account. A <em>digital signature</em>, created by Alice and +included with the message, serves this purpose.</p> + +<p>Digital signatures are created by encrypting a digest of the message and +other information (such as a sequence number) with the sender's private key. +Though anyone can <em>decrypt</em> the signature using the public key, only the +sender knows the private key. This means that only the sender can have signed +the message. Including the digest in the signature means the signature is only +good for that message; it also ensures the integrity of the message since no one +can change the digest and still sign it.</p> +<p>To guard against interception and reuse of the signature by an intruder at a +later date, the signature contains a unique sequence number. This protects +the bank from a fraudulent claim from Alice that she did not send the message +-- only she could have signed it (non-repudiation).</p> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="certificates" id="certificates">Certificates</a></h2> + +<p>Although Alice could have sent a private message to the bank, signed +it and ensured the integrity of the message, she still needs to be sure +that she is really communicating with the bank. This means that she needs +to be sure that the public key she is using is part of the bank's key-pair, +and not an intruder's. Similarly, the bank needs to verify that the message +signature really was signed by the private key that belongs to Alice.</p> + +<p>If each party has a certificate which validates the other's identity, +confirms the public key and is signed by a trusted agency, then both +can be assured that they are communicating with whom they think they are. +Such a trusted agency is called a <em>Certificate Authority</em> and +certificates are used for authentication.</p> + +<h3><a name="certificatecontents" id="certificatecontents">Certificate Contents</a></h3> + + <p>A certificate associates a public key with the real identity of + an individual, server, or other entity, known as the subject. As + shown in <a href="#table1">Table 1</a>, information about the subject + includes identifying information (the distinguished name) and the + public key. It also includes the identification and signature of the + Certificate Authority that issued the certificate and the period of + time during which the certificate is valid. It may have additional + information (or extensions) as well as administrative information + for the Certificate Authority's use, such as a serial number.</p> + + <h4><a name="table1" id="table1">Table 1: Certificate Information</a></h4> + + <table> + + <tr><th>Subject</th> + <td>Distinguished Name, Public Key</td></tr> + <tr><th>Issuer</th> + <td>Distinguished Name, Signature</td></tr> + <tr><th>Period of Validity</th> + <td>Not Before Date, Not After Date</td></tr> + <tr><th>Administrative Information</th> + <td>Version, Serial Number</td></tr> + <tr><th>Extended Information</th> + <td>Basic Constraints, Netscape Flags, etc.</td></tr> + </table> + + + <p>A distinguished name is used to provide an identity in a specific + context -- for instance, an individual might have a personal + certificate as well as one for their identity as an employee. + Distinguished names are defined by the X.509 standard [<a href="#X509">X509</a>], which defines the fields, field names and + abbreviations used to refer to the fields (see <a href="#table2">Table + 2</a>).</p> + + <h4><a name="table2" id="table2">Table 2: Distinguished Name Information</a></h4> + + <table class="bordered"> + + <tr><th>DN Field</th> + <th>Abbrev.</th> + <th>Description</th> + <th>Example</th></tr> + <tr><td>Common Name</td> + <td>CN</td> + <td>Name being certified</td> + <td>CN=Joe Average</td></tr> + <tr><td>Organization or Company</td> + <td>O</td> + <td>Name is associated with this<br />organization</td> + <td>O=Snake Oil, Ltd.</td></tr> + <tr><td>Organizational Unit</td> + <td>OU</td> + <td>Name is associated with this <br />organization unit, such + as a department</td> + <td>OU=Research Institute</td></tr> + <tr><td>City/Locality</td> + <td>L</td> + <td>Name is located in this City</td> + <td>L=Snake City</td></tr> + <tr><td>State/Province</td> + <td>ST</td> + <td>Name is located in this State/Province</td> + <td>ST=Desert</td></tr> + <tr><td>Country</td> + <td>C</td> + <td>Name is located in this Country (ISO code)</td> + <td>C=XZ</td></tr> + </table> + + + <p>A Certificate Authority may define a policy specifying which + distinguished field names are optional and which are required. It + may also place requirements upon the field contents, as may users of + certificates. For example, a Netscape browser requires that the + Common Name for a certificate representing a server matches a wildcard + pattern for the domain name of that server, such + as <code>*.snakeoil.com</code>.</p> + + <p>The binary format of a certificate is defined using the ASN.1 + notation [<a href="#ASN1">ASN1</a>] [<a href="#PKCS">PKCS</a>]. This + notation defines how to specify the contents and encoding rules + define how this information is translated into binary form. The binary + encoding of the certificate is defined using Distinguished Encoding + Rules (DER), which are based on the more general Basic Encoding Rules + (BER). For those transmissions which cannot handle binary, the binary + form may be translated into an ASCII form by using Base64 encoding + [<a href="#MIME">MIME</a>]. When placed between begin and end delimiter + lines (as below), this encoded version is called a PEM ("Privacy Enhanced + Mail") encoded certificate.</p> + + <div class="example"><h3>Example of a PEM-encoded certificate (snakeoil.crt)</h3><pre>-----BEGIN CERTIFICATE----- +MIIC7jCCAlegAwIBAgIBATANBgkqhkiG9w0BAQQFADCBqTELMAkGA1UEBhMCWFkx +FTATBgNVBAgTDFNuYWtlIERlc2VydDETMBEGA1UEBxMKU25ha2UgVG93bjEXMBUG +A1UEChMOU25ha2UgT2lsLCBMdGQxHjAcBgNVBAsTFUNlcnRpZmljYXRlIEF1dGhv +cml0eTEVMBMGA1UEAxMMU25ha2UgT2lsIENBMR4wHAYJKoZIhvcNAQkBFg9jYUBz +bmFrZW9pbC5kb20wHhcNOTgxMDIxMDg1ODM2WhcNOTkxMDIxMDg1ODM2WjCBpzEL +MAkGA1UEBhMCWFkxFTATBgNVBAgTDFNuYWtlIERlc2VydDETMBEGA1UEBxMKU25h +a2UgVG93bjEXMBUGA1UEChMOU25ha2UgT2lsLCBMdGQxFzAVBgNVBAsTDldlYnNl +cnZlciBUZWFtMRkwFwYDVQQDExB3d3cuc25ha2VvaWwuZG9tMR8wHQYJKoZIhvcN +AQkBFhB3d3dAc25ha2VvaWwuZG9tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKB +gQDH9Ge/s2zcH+da+rPTx/DPRp3xGjHZ4GG6pCmvADIEtBtKBFAcZ64n+Dy7Np8b +vKR+yy5DGQiijsH1D/j8HlGE+q4TZ8OFk7BNBFazHxFbYI4OKMiCxdKzdif1yfaa +lWoANFlAzlSdbxeGVHoT0K+gT5w3UxwZKv2DLbCTzLZyPwIDAQABoyYwJDAPBgNV +HRMECDAGAQH/AgEAMBEGCWCGSAGG+EIBAQQEAwIAQDANBgkqhkiG9w0BAQQFAAOB +gQAZUIHAL4D09oE6Lv2k56Gp38OBDuILvwLg1v1KL8mQR+KFjghCrtpqaztZqcDt +2q2QoyulCgSzHbEGmi0EsdkPfg6mp0penssIFePYNI+/8u9HT4LuKMJX15hxBam7 +dUHzICxBVC1lnHyYGjDuAMhe396lYAn8bCld1/L4NMGBCQ== +-----END CERTIFICATE-----</pre></div> + + +<h3><a name="certificateauthorities" id="certificateauthorities">Certificate Authorities</a></h3> + + <p>By verifying the information in a certificate request + before granting the certificate, the Certificate Authority assures + itself of the identity of the private key owner of a key-pair. + For instance, if Alice requests a personal certificate, the + Certificate Authority must first make sure that Alice really is the + person the certificate request claims she is.</p> + + <h4><a name="certificatechains" id="certificatechains">Certificate Chains</a></h4> + + <p>A Certificate Authority may also issue a certificate for + another Certificate Authority. When examining a certificate, + Alice may need to examine the certificate of the issuer, for each + parent Certificate Authority, until reaching one which she has + confidence in. She may decide to trust only certificates with a + limited chain of issuers, to reduce her risk of a "bad" certificate + in the chain.</p> + + + <h4><a name="rootlevelca" id="rootlevelca">Creating a Root-Level CA</a></h4> + + <p>As noted earlier, each certificate requires an issuer to assert + the validity of the identity of the certificate subject, up to + the top-level Certificate Authority (CA). This presents a problem: + who can vouch for the certificate of the top-level + authority, which has no issuer? In this unique case, the + certificate is "self-signed", so the issuer of the certificate is + the same as the subject. Browsers are preconfigured to trust well-known + certificate authorities, but it is important to exercise extra care in + trusting a self-signed certificate. The wide publication of a + public key by the root authority reduces the risk in trusting this + key -- it would be obvious if someone else publicized a key + claiming to be the authority.</p> + + <p>A number of companies, such as <a href="http://www.thawte.com/">Thawte</a> and <a href="http://www.verisign.com/">VeriSign</a> + have established themselves as Certificate Authorities. These + companies provide the following services:</p> + + <ul> + <li>Verifying certificate requests</li> + <li>Processing certificate requests</li> + <li>Issuing and managing certificates</li> + </ul> + + <p>It is also possible to create your own Certificate Authority. + Although risky in the Internet environment, it may be useful + within an Intranet where the organization can easily verify the + identities of individuals and servers.</p> + + + <h4><a name="certificatemanagement" id="certificatemanagement">Certificate Management</a></h4> + + <p>Establishing a Certificate Authority is a responsibility which + requires a solid administrative, technical and management + framework. Certificate Authorities not only issue certificates, + they also manage them -- that is, they determine for how long + certificates remain valid, they renew them and keep lists of + certificates that were issued in the past but are no longer valid + (Certificate Revocation Lists, or CRLs).</p> + + <p>For example, if Alice is entitled to a certificate as an + employee of a company but has now left + that company, her certificate may need to be revoked. + Because certificates are only issued after the subject's identity has + been verified and can then be passed around to all those with whom + the subject may communicate, it is impossible to tell from the + certificate alone that it has been revoked. + Therefore when examining certificates for validity + it is necessary to contact the issuing Certificate Authority to + check CRLs -- this is usually not an automated part of the process.</p> + + <div class="note"><h3>Note</h3> + <p>If you use a Certificate Authority that browsers are not configured + to trust by default, it is necessary to load the Certificate + Authority certificate into the browser, enabling the browser to + validate server certificates signed by that Certificate Authority. + Doing so may be dangerous, since once loaded, the browser will + accept all certificates signed by that Certificate Authority.</p> + </div> + + + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="ssl" id="ssl">Secure Sockets Layer (SSL)</a></h2> + +<p>The Secure Sockets Layer protocol is a protocol layer which may be +placed between a reliable connection-oriented network layer protocol +(e.g. TCP/IP) and the application protocol layer (e.g. HTTP). SSL provides +for secure communication between client and server by allowing mutual +authentication, the use of digital signatures for integrity and encryption +for privacy.</p> + +<p>The protocol is designed to support a range of choices for specific +algorithms used for cryptography, digests and signatures. This allows +algorithm selection for specific servers to be made based on legal, export +or other concerns and also enables the protocol to take advantage of new +algorithms. Choices are negotiated between client and server when +establishing a protocol session.</p> + +<h3><a name="table4" id="table4">Table 4: Versions of the SSL protocol</a></h3> + + <table class="bordered"> + + <tr><th>Version</th> + <th>Source</th> + <th>Description</th> + </tr> + <tr><td>SSL v2.0</td> + <td>Vendor Standard (from Netscape Corp.)</td> + <td>First SSL protocol for which implementations exist</td> + </tr> + <tr><td>SSL v3.0</td> + <td>Expired Internet Draft (from Netscape Corp.) [<a href="#SSL3">SSL3</a>]</td> + <td>Revisions to prevent specific security attacks, add non-RSA + ciphers and support for certificate chains</td> + </tr> + <tr><td>TLS v1.0</td> + <td>Proposed Internet Standard (from IETF) [<a href="#TLS1">TLS1</a>]</td> + <td>Revision of SSL 3.0 to update the MAC layer to HMAC, add block + padding for block ciphers, message order standardization and more + alert messages.</td> + </tr> + <tr><td>TLS v1.1</td> + <td>Proposed Internet Standard (from IETF) [<a href="#TLS11">TLS11</a>]</td> + <td>Update of TLS 1.0 to add protection against Cipher block chaining + (CBC) attacks.</td> + </tr> + <tr><td>TLS v1.2</td> + <td>Proposed Internet Standard (from IETF) [<a href="#TLS12">TLS12</a>]</td> + <td>Update of TLS 1.1 deprecating MD5 as hash, and adding incompatibility + to SSL so it will never negotiate the use of SSLv2.</td> + </tr> + </table> + + +<p>There are a number of versions of the SSL protocol, as shown in +<a href="#table4">Table 4</a>. As noted there, one of the benefits in +SSL 3.0 is that it adds support of certificate chain loading. This feature +allows a server to pass a server certificate along with issuer certificates +to the browser. Chain loading also permits the browser to validate the +server certificate, even if Certificate Authority certificates are not +installed for the intermediate issuers, since they are included in the +certificate chain. SSL 3.0 is the basis for the Transport Layer Security +[<a href="#TLS1">TLS</a>] protocol standard, currently in development by +the Internet Engineering Task Force (IETF).</p> + +<h3><a name="session" id="session">Establishing a Session</a></h3> + + <p>The SSL session is established by following a handshake sequence + between client and server, as shown in <a href="#figure1">Figure 1</a>. This sequence may vary, depending on whether the server + is configured to provide a server certificate or request a client + certificate. Although cases exist where additional handshake steps + are required for management of cipher information, this article + summarizes one common scenario. See the SSL specification for the full + range of possibilities.</p> + + <div class="note"><h3>Note</h3> + <p>Once an SSL session has been established, it may be reused. This + avoids the performance penalty of repeating the many steps needed + to start a session. To do this, the server assigns each SSL session a + unique session identifier which is cached in the server and which the + client can use in future connections to reduce the handshake time + (until the session identifier expires from the cache of the server).</p> + </div> + + <p class="figure"> + <img src="../images/ssl_intro_fig1.gif" alt="" width="423" height="327" /><br /> + <a id="figure1" name="figure1"><dfn>Figure 1</dfn></a>: Simplified SSL + Handshake Sequence</p> + + <p>The elements of the handshake sequence, as used by the client and + server, are listed below:</p> + + <ol> + <li>Negotiate the Cipher Suite to be used during data transfer</li> + <li>Establish and share a session key between client and server</li> + <li>Optionally authenticate the server to the client</li> + <li>Optionally authenticate the client to the server</li> + </ol> + + <p>The first step, Cipher Suite Negotiation, allows the client and + server to choose a Cipher Suite supported by both of them. The SSL3.0 + protocol specification defines 31 Cipher Suites. A Cipher Suite is + defined by the following components:</p> + + <ul> + <li>Key Exchange Method</li> + <li>Cipher for Data Transfer</li> + <li>Message Digest for creating the Message Authentication Code (MAC)</li> + </ul> + + <p>These three elements are described in the sections that follow.</p> + + +<h3><a name="keyexchange" id="keyexchange">Key Exchange Method</a></h3> + + <p>The key exchange method defines how the shared secret symmetric + cryptography key used for application data transfer will be agreed + upon by client and server. SSL 2.0 uses RSA key exchange only, while + SSL 3.0 supports a choice of key exchange algorithms including + RSA key exchange (when certificates are used), and Diffie-Hellman key + exchange (for exchanging keys without certificates, or without prior + communication between client and server).</p> + + <p>One variable in the choice of key exchange methods is digital + signatures -- whether or not to use them, and if so, what kind of + signatures to use. Signing with a private key provides protection + against a man-in-the-middle-attack during the information exchange + used to generating the shared key [<a href="#AC96">AC96</a>, p516].</p> + + +<h3><a name="ciphertransfer" id="ciphertransfer">Cipher for Data Transfer</a></h3> + + <p>SSL uses conventional symmetric cryptography, as described earlier, + for encrypting messages in a session. + There are nine choices of how to encrypt, including the option not to + encrypt:</p> + + <ul> + <li>No encryption</li> + <li>Stream Ciphers + <ul> + <li>RC4 with 40-bit keys</li> + <li>RC4 with 128-bit keys</li> + </ul></li> + <li>CBC Block Ciphers + <ul><li>RC2 with 40 bit key</li> + <li>DES with 40 bit key</li> + <li>DES with 56 bit key</li> + <li>Triple-DES with 168 bit key</li> + <li>Idea (128 bit key)</li> + <li>Fortezza (96 bit key)</li> + </ul></li> + </ul> + + <p>"CBC" refers to Cipher Block Chaining, which means that a + portion of the previously encrypted cipher text is used in the + encryption of the current block. "DES" refers to the Data Encryption + Standard [<a href="#AC96">AC96</a>, ch12], which has a number of + variants (including DES40 and 3DES_EDE). "Idea" is currently one of + the best and cryptographically strongest algorithms available, + and "RC2" is a proprietary algorithm from RSA DSI [<a href="#AC96">AC96</a>, ch13].</p> + + +<h3><a name="digestfunction" id="digestfunction">Digest Function</a></h3> + + <p>The choice of digest function determines how a digest is created + from a record unit. SSL supports the following:</p> + + <ul> + <li>No digest (Null choice)</li> + <li>MD5, a 128-bit hash</li> + <li>Secure Hash Algorithm (SHA-1), a 160-bit hash</li> + </ul> + + <p>The message digest is used to create a Message Authentication Code + (MAC) which is encrypted with the message to verify integrity and to + protect against replay attacks.</p> + + +<h3><a name="handshake" id="handshake">Handshake Sequence Protocol</a></h3> + + <p>The handshake sequence uses three protocols:</p> + + <ul> + <li>The <dfn>SSL Handshake Protocol</dfn> + for performing the client and server SSL session establishment.</li> + <li>The <dfn>SSL Change Cipher Spec Protocol</dfn> for actually + establishing agreement on the Cipher Suite for the session.</li> + <li>The <dfn>SSL Alert Protocol</dfn> for conveying SSL error + messages between client and server.</li> + </ul> + + <p>These protocols, as well as application protocol data, are + encapsulated in the <dfn>SSL Record Protocol</dfn>, as shown in + <a href="#figure2">Figure 2</a>. An encapsulated protocol is + transferred as data by the lower layer protocol, which does not + examine the data. The encapsulated protocol has no knowledge of the + underlying protocol.</p> + + <p class="figure"> + <img src="../images/ssl_intro_fig2.gif" alt="" width="428" height="217" /><br /> + <a id="figure2" name="figure2"><dfn>Figure 2</dfn></a>: SSL Protocol Stack + </p> + + <p>The encapsulation of SSL control protocols by the record protocol + means that if an active session is renegotiated the control protocols + will be transmitted securely. If there was no previous session, + the Null cipher suite is used, which means there will be no encryption and + messages will have no integrity digests, until the session has been + established.</p> + + +<h3><a name="datatransfer" id="datatransfer">Data Transfer</a></h3> + + <p>The SSL Record Protocol, shown in <a href="#figure3">Figure 3</a>, + is used to transfer application and SSL Control data between the + client and server, where necessary fragmenting this data into smaller units, + or combining multiple higher level protocol data messages into single + units. It may compress, attach digest signatures, and encrypt these + units before transmitting them using the underlying reliable transport + protocol (Note: currently, no major SSL implementations include support + for compression).</p> + + <p class="figure"> + <img src="../images/ssl_intro_fig3.gif" alt="" width="423" height="323" /><br /> + <a id="figure3" name="figure3"><dfn>Figure 3</dfn></a>: SSL Record Protocol + </p> + + +<h3><a name="securehttp" id="securehttp">Securing HTTP Communication</a></h3> + + <p>One common use of SSL is to secure Web HTTP communication between + a browser and a webserver. This does not preclude the use of + non-secured HTTP - the secure version (called HTTPS) is the same as + plain HTTP over SSL, but uses the URL scheme <code>https</code> + rather than <code>http</code>, and a different server port (by default, + port 443). This functionality is a large part of what <code class="module"><a href="../mod/mod_ssl.html">mod_ssl</a></code> provides for the Apache webserver.</p> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="references" id="references">References</a></h2> + +<dl> +<dt><a id="AC96" name="AC96">[AC96]</a></dt> +<dd>Bruce Schneier, <q>Applied Cryptography</q>, 2nd Edition, Wiley, +1996. See <a href="http://www.counterpane.com/">http://www.counterpane.com/</a> for various other materials by Bruce +Schneier.</dd> + +<dt><a id="ASN1" name="ASN1">[ASN1]</a></dt> +<dd>ITU-T Recommendation X.208, <q>Specification of Abstract Syntax Notation +One (ASN.1)</q>, last updated 2008. See <a href="http://www.itu.int/ITU-T/asn1/">http://www.itu.int/ITU-T/asn1/</a>. +</dd> + +<dt><a id="X509" name="X509">[X509]</a></dt> +<dd>ITU-T Recommendation X.509, <q>The Directory - Authentication +Framework</q>. For references, see <a href="http://en.wikipedia.org/wiki/X.509">http://en.wikipedia.org/wiki/X.509</a>. +</dd> + +<dt><a id="PKCS" name="PKCS">[PKCS]</a></dt> +<dd><q>Public Key Cryptography Standards (PKCS)</q>, +RSA Laboratories Technical Notes, See <a href="http://www.rsasecurity.com/rsalabs/pkcs/">http://www.rsasecurity.com/rsalabs/pkcs/</a>.</dd> + +<dt><a id="MIME" name="MIME">[MIME]</a></dt> +<dd>N. Freed, N. Borenstein, <q>Multipurpose Internet Mail Extensions +(MIME) Part One: Format of Internet Message Bodies</q>, RFC2045. +See for instance <a href="http://tools.ietf.org/html/rfc2045">http://tools.ietf.org/html/rfc2045</a>.</dd> + +<dt><a id="SSL3" name="SSL3">[SSL3]</a></dt> +<dd>Alan O. Freier, Philip Karlton, Paul C. Kocher, <q>The SSL Protocol +Version 3.0</q>, 1996. See <a href="http://www.netscape.com/eng/ssl3/draft302.txt">http://www.netscape.com/eng/ssl3/draft302.txt</a>.</dd> + +<dt><a id="TLS1" name="TLS1">[TLS1]</a></dt> +<dd>Tim Dierks, Christopher Allen, <q>The TLS Protocol Version 1.0</q>, +1999. See <a href="http://ietf.org/rfc/rfc2246.txt">http://ietf.org/rfc/rfc2246.txt</a>.</dd> + +<dt><a id="TLS11" name="TLS11">[TLS11]</a></dt> +<dd><q>The TLS Protocol Version 1.1</q>, +2006. See <a href="http://tools.ietf.org/html/rfc4346">http://tools.ietf.org/html/rfc4346</a>.</dd> + +<dt><a id="TLS12" name="TLS12">[TLS12]</a></dt> +<dd><q>The TLS Protocol Version 1.2</q>, +2008. See <a href="http://tools.ietf.org/html/rfc5246">http://tools.ietf.org/html/rfc5246</a>.</dd> +</dl> +</div></div> +<div class="bottomlang"> +<p><span>Available Languages: </span><a href="../en/ssl/ssl_intro.html" title="English"> en </a> | +<a href="../fr/ssl/ssl_intro.html" hreflang="fr" rel="alternate" title="Français"> fr </a> | +<a href="../ja/ssl/ssl_intro.html" hreflang="ja" rel="alternate" title="Japanese"> ja </a></p> +</div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Comments</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Libera.chat, or sent to our <a href="https://httpd.apache.org/lists.html">mailing lists</a>.</div> +<script type="text/javascript"><!--//--><![CDATA[//><!-- +var comments_shortname = 'httpd'; +var comments_identifier = 'http://httpd.apache.org/docs/2.4/ssl/ssl_intro.html'; +(function(w, d) { + if (w.location.hostname.toLowerCase() == "httpd.apache.org") { + d.write('<div id="comments_thread"><\/div>'); + var s = d.createElement('script'); + s.type = 'text/javascript'; + s.async = true; + s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier; + (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s); + } + else { + d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>'); + } +})(window, document); +//--><!]]></script></div><div id="footer"> +<p class="apache">Copyright 2023 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!-- +if (typeof(prettyPrint) !== 'undefined') { + prettyPrint(); +} +//--><!]]></script> +</body></html>
\ No newline at end of file diff --git a/docs/manual/ssl/ssl_intro.html.fr.utf8 b/docs/manual/ssl/ssl_intro.html.fr.utf8 new file mode 100644 index 0000000..420a1b1 --- /dev/null +++ b/docs/manual/ssl/ssl_intro.html.fr.utf8 @@ -0,0 +1,727 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" lang="fr" xml:lang="fr"><head> +<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /> +<!-- + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + This file is generated from xml source: DO NOT EDIT + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + --> +<title>Chiffrement SSL/TLS fort : Introduction - Serveur HTTP Apache Version 2.4</title> +<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" /> +<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" /> +<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" /> +<script src="../style/scripts/prettify.min.js" type="text/javascript"> +</script> + +<link href="../images/favicon.ico" rel="shortcut icon" /></head> +<body id="manual-page"><div id="page-header"> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossaire</a> | <a href="../sitemap.html">Plan du site</a></p> +<p class="apache">Serveur HTTP Apache Version 2.4</p> +<img alt="" src="../images/feather.png" /></div> +<div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div> +<div id="path"> +<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">Serveur HTTP</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.4</a> > <a href="./">SSL/TLS</a></div><div id="page-content"><div id="preamble"><h1>Chiffrement SSL/TLS fort : Introduction</h1> +<div class="toplang"> +<p><span>Langues Disponibles: </span><a href="../en/ssl/ssl_intro.html" hreflang="en" rel="alternate" title="English"> en </a> | +<a href="../fr/ssl/ssl_intro.html" title="Français"> fr </a> | +<a href="../ja/ssl/ssl_intro.html" hreflang="ja" rel="alternate" title="Japanese"> ja </a></p> +</div> + + +<p>Ce chapitre en guise d'introduction est destiné aux lecteurs pour lesquels +le Web, HTTP et Apache sont familiers, mais ne sont pas des experts en matière +de sécurité. Il n'a pas la prétention d'être un guide détaillé sur le +protocole SSL, il ne traitera pas non plus des techniques spécifiques de gestion +des certificats dans une organisation, ni des importants problèmes légaux de +brevets ou des restrictions d'importation ou d'exportation. Il se veut plutôt +une base de travail pour les utilisateurs de <code class="module"><a href="../mod/mod_ssl.html">mod_ssl</a></code> en +rassemblant différents concepts, définitions et exemples comme point de départ +pour une exploration plus détaillée.</p> + +</div> +<div id="quickview"><a href="https://www.apache.org/foundation/contributing.html" class="badge"><img src="https://www.apache.org/images/SupportApache-small.png" alt="Support Apache!" /></a><ul id="toc"><li><img alt="" src="../images/down.gif" /> <a href="#cryptographictech">Techniques de chiffrement</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#certificates">Certificats</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#ssl">Couche Points d'Accès Sécurisés - Secure Sockets Layer (SSL)</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#references">Références</a></li> +</ul><h3>Voir aussi</h3><ul class="seealso"><li><a href="#comments_section">Commentaires</a></li></ul></div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="cryptographictech" id="cryptographictech">Techniques de chiffrement</a></h2> + +<p>La maîtrise de SSL nécessite la compréhension des algorithmes de +chiffrement, des fonctions relatives aux empreintes de messages (comme les +fonctions de type hash ou non réversibles), et des signatures numériques. Ces +techniques pourraient faire l'objet d'un ouvrage à elles seules (voir par +exemple [<a href="#AC96">AC96</a>]) et constituent les bases de la +confidentialité, de l'intégrité et de l'authentification.</p> + +<h3><a name="cryptographicalgo" id="cryptographicalgo">Algorithmes de chiffrement</a></h3> + + <p>Supposons qu'Alice veuille envoyer un message à sa banque pour + transférer une certaine somme. Alice souhaiterait que le message soit + privé, car il contient des informations comme son numéro de compte et le + montant du transfert. Une solution consisterait à utiliser un algorithme de + chiffrement, technique qui permet de remplacer un message par sa version + chiffrée, illisible jusqu'à ce qu'elle soit déchiffrée. + Sous sa forme chiffrée, + le message ne peut être déchiffré qu'en utilisant une clé secrète. Sans la + clé, le message est inutilisable : les bons algorithmes de chiffrement + rendent si difficile la restitution du texte original par des intrus que + ceux-ci y gaspilleraient leurs efforts.</p> + + <p>Il existe deux catégories d'algorithmes de chiffrement : conventionnel + ou à clé publique.</p> + + <dl> + <dt>Chiffrement conventionnel</dt> + <dd>aussi connu sous le nom de chiffrement symétrique, il nécessite le + partage d'une clé entre l'expéditeur et le destinataire : une portion + d'information secrète permettant de chiffrer et déchiffrer un message. + Tant que cette clé reste secrète, personne à part l'expéditeur et le + destinataire ne peut lire le message. Si Alice et sa banque partagent une + clé secrète, ils peuvent donc s'envoyer l'un à l'autre des messages privés. + Le fait de partager une clé entre l'expéditeur et le destinataire avant + de communiquer, tout en la maintenant secrète vis à vis des autres, peut + toutefois poser des problèmes.</dd> + + <dt>Chiffrement à clé publique</dt> + <dd>aussi connu sous le nom de chiffrement asymétrique, il résoud le + problème d'échange de clé en définissant un algorithme qui utilise deux + clés, chacune d'entre elles pouvant être utilisée pour chiffrer un message. + Si une des clés a été utilisée pour chiffrer le message, on doit utiliser + l'autre clé pour le déchiffrer. Il est ainsi possible de recevoir des + messages sécurisés simplement en rendant publique une des clés (la clé + publique), et en gardant l'autre clé secrète (la clé privée).</dd> + </dl> + + <p>Tout le monde peut chiffrer un message en utilisant la clé publique, + mais seul le propriétaire de la clé privée sera en mesure de le lire. De + cette façon, Alice peut envoyer des messages privés au propriétaire d'une + paire de clés (sa banque), en les chiffrant à l'aide de la clé publique. + Seule la banque sera en mesure de les déchiffrer.</p> + + +<h3><a name="messagedigests" id="messagedigests">Empreinte d'un message</a></h3> + + <p>Bien qu'Alice puisse chiffrer son message pour le rendre privé, il + subsiste toujours le risque que quelqu'un puisse modifier le message + original ou le remplacer par un autre, afin d'effectuer le transfert de + fonds à son profit, par exemple. Une solution pour garantir l'intégrité du + message consisterait pour Alice à créer un résumé concentré de son message + qu'elle enverrait à sa banque avec ce dernier. A la réception du message, + la banque crée son propre résumé et le compare avec celui qu'Alice a + envoyé. Si les deux résumés sont identiques, le message reçu n'a pas + été modifié.</p> + + <p>Un résumé tel que celui-ci est appelé + <dfn>empreinte numérique de message</dfn> (message digest), + <em>fonction irréversible</em> (one-way function) ou + <em>fonction de hashage</em> (hash function). Une empreinte de message + constitue une représentation courte et de longueur fixe, d'un message plus + long et de longueur variable. Les algorithmes de création d'empreintes sont + conçus pour produire une empreinte unique pour chaque message. Les + empreintes de messages sont conçues pour que la restitution du message + à partir de l'empreinte soit d'une difficulté insurmontable, et qu'il soit + (en théorie) impossible de trouver deux messages différents qui produisent + la même empreinte -- ce qui élimine la possibilité de remplacer un message + par un autre en conservant la même empreinte.</p> + + <p>Trouver le moyen d'envoyer l'empreinte de manière sécurisée à la banque + constitue un autre défit auquel Alice doit faire face ; si l'empreinte + n'est pas envoyée de manière sécurisée, son intégrité peut être compromise, + et avec elle, la possibilité pour la banque de vérifier l'intégrité du + message original. L'intégrité du message ne peut être vérifiée que si + l'empreinte qui lui est associée est envoyée de manière sécurisée.</p> + + <p>Une solution pour envoyer l'empreinte de manière sécurisée consiste à + l'inclure dans une signature numérique.</p> + + +<h3><a name="digitalsignatures" id="digitalsignatures">Signatures numériques</a></h3> +<p>Quand Alice envoie un message à sa banque, cette dernière doit s'assurer +que le message a bien été envoyé par elle, pour éviter qu'un intrus puisse +effectuer une transaction sur son compte. Une <em>signature numérique</em>, +créée par Alice et incluse dans le message, permet d'atteindre cet +objectif.</p> + +<p>Les signatures numériques peuvent être créées en chiffrant une empreinte de +message, ainsi que d'autres informations (comme un numéro d'ordre) avec la clé +privée de l'expéditeur. Bien que tout le monde puisse <em>déchiffrer</em> la +signature à l'aide de la clé publique, seul l'expéditeur connait la clé privée. +Ce qui implique que seul l'expéditeur peut avoir signé le message. Inclure +l'empreinte dans la signature entraîne que cette dernière n'est valable que +pour ce message ; ceci assure aussi l'intégrité du message car personne ne +peut modifier l'empreinte et ensuite signer le message.</p> +<p>Afin de se prémunir contre l'interception et la réutilisation de la +signature par un intrus quelques jours plus tard, la signature contient un +numéro d'ordre unique. Ceci protège la banque contre une plainte frauduleuse +de la part d'Alice alléguant qu'elle n'a pas envoyé le message -- +elle seule peut l'avoir signé (non-répudiation).</p> + + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="certificates" id="certificates">Certificats</a></h2> + +<p>Bien qu'Alice soit parvenue à envoyer un message privé à sa banque, après +l'avoir signé et avoir ainsi assuré l'intégrité du message, elle doit encore vérifier +qu'elle communique réellement avec la banque. C'est à dire qu'elle doit +s'assurer que la clé publique qu'elle utilise appartient bien à la paire de +clés de la banque, et non à celle d'un intrus. +De même, la banque doit vérifier que la +signature du message a bien été construite avec la clé privée d'Alice.</p> + +<p>Si chaque partie possède un certificat qui valide l'identité de l'autre, +confirme la clé publique, et est signé par un organisme de confiance, alors +les deux protagonistes peuvent être sûrs que la personne avec laquelle ils +communiquent est bien celle avec laquelle ils désirent le faire. Un tel +organisme de confiance s'appelle une <em>Autorité de Certification</em>, et +on utilise les certificats à des fins d'authentification.</p> + +<h3><a name="certificatecontents" id="certificatecontents">Contenu d'un certificat</a></h3> + + <p>Un certificat associe une clé publique avec l'identité réelle d'un + individu, d'un serveur, ou d'une autre entité plus connue sous le nom de + sujet. Comme on le voit dans le <a href="#table1">Tableau 1</a>, les + information concernant le sujet comprennent des informations + d'identification (le nom distinctif ou distinguished name - dn), ainsi que + la clé publique. Il comporte aussi l'identification et la signature de + l'autorité de certification qui a délivré le certificat, ainsi que la + période de validité de ce dernier. Il peut aussi contenir des informations + supplémentaires (ou extensions) telles que des informations de gestion + destinées à l'autorité de certification, comme un numéro de série.</p> + + <h4><a name="table1" id="table1">Tableau 1: Information contenues dans un certificat</a></h4> + + <table> + + <tr><th>Sujet</th> + <td>Nom distinctif, Clé publique</td></tr> + <tr><th>Fournisseur</th> + <td>Nom distinctif, Signature</td></tr> + <tr><th>Période de validité</th> + <td>Pas avant, Pas après</td></tr> + <tr><th>Informations de gestion</th> + <td>Version, Numéro de série</td></tr> + <tr><th>Extensions</th> + <td>Contraintes de base, Drapeaux Netscape, etc.</td></tr> + </table> + + + <p>Un nom distinctif sert à fournir une identité dans un contexte + spécifique -- par exemple, un individu peut posséder un certificat + personnel, et aussi un certificat en tant qu'employé. Les noms distinctifs + doivent respecter le standard X509 [<a href="#X509">X509</a>], qui définit + les champs, les noms de champs, et les abréviations utilisées pour faire + référence aux champs (voir <a href="#table2">Tableau 2</a>).</p> + + <h4><a name="table2" id="table2">Tableau 2: Informations contenues dans le nom distinctif</a></h4> + + <table class="bordered"> + + <tr><th>Champ du DN</th> + <th>Abrév.</th> + <th>Description</th> + <th>Exemple</th></tr> + <tr><td>Nom complet (Common Name)</td> + <td>CN</td> + <td>Nom certifié</td> + <td>CN=Joe Average</td></tr> + <tr><td>Organisation or Entreprise</td> + <td>O</td> + <td>Nom est associé à cette<br />organisation</td> + <td>O=Snake Oil, Ltd.</td></tr> + <tr><td>Unité organisationnelle (Organizational Unit)</td> + <td>OU</td> + <td>Nom est associé avec cette <br />unité organisationnelle, + par exemple un département</td> + <td>OU=Research Institute</td></tr> + <tr><td>Ville/Localisation</td> + <td>L</td> + <td>Nom est localisé dans cette ville</td> + <td>L=Snake City</td></tr> + <tr><td>Etat/Province</td> + <td>ST</td> + <td>Nom est localisé dans cet état/province</td> + <td>ST=Desert</td></tr> + <tr><td>Pays</td> + <td>C</td> + <td>Nom est localisé dans ce pays (code ISO)</td> + <td>C=XZ</td></tr> + </table> + + + <p>Une autorité de certification peut définir une contrainte spécifiant + quels champs du nom distinctif sont optionnels et lesquels sont + obligatoires. Elle peut aussi imposer des contraintes sur le contenu des + champs, ce que peuvent aussi faire les utilisateurs de certificats. Par + exemple, un navigateur Netscape peut exiger, dans le cas d'un certificat + de serveur, que le nom complet (Common Name) corresponde à un nom générique + contenant le nom de domaine du serveur, comme + <code>*.snakeoil.com</code>.</p> + + <p>Le format binaire d'un certificat est défini en utilisant la + notation ASN.1 [<a href="#ASN1">ASN1</a>] [<a href="#PKCS">PKCS</a>]. + Cette notation definit la manière de spécifier les contenus, et les règles + d'encodage définissent la manière dont ces information sont converties au + format binaire. L'encodage binaire du certificat est défini par les Règles + d'Encodage Distinctives (Distinguished Encoding Rules - DER), qui se basent + d'une manière plus générale sur les Règles d'Encodage de Base (Basic + Encoding Rules - BER). Pour les transmissions qui ne supportent pas le + format binaire, ce dernier peut être converti au format ASCII en utilisant + le codage Base64 [<a href="#MIME">MIME</a>]. Lorsqu'il est placé entre des + délimiteurs de début et de fin (comme ci-dessous), on dit que le certificat + est encodé au format PEM ("Privacy Enhanced Mail").</p> + + <div class="example"><h3>Exemple de certificat encodé au format PEM (snakeoil.crt)</h3><pre>-----BEGIN CERTIFICATE----- +MIIC7jCCAlegAwIBAgIBATANBgkqhkiG9w0BAQQFADCBqTELMAkGA1UEBhMCWFkx +FTATBgNVBAgTDFNuYWtlIERlc2VydDETMBEGA1UEBxMKU25ha2UgVG93bjEXMBUG +A1UEChMOU25ha2UgT2lsLCBMdGQxHjAcBgNVBAsTFUNlcnRpZmljYXRlIEF1dGhv +cml0eTEVMBMGA1UEAxMMU25ha2UgT2lsIENBMR4wHAYJKoZIhvcNAQkBFg9jYUBz +bmFrZW9pbC5kb20wHhcNOTgxMDIxMDg1ODM2WhcNOTkxMDIxMDg1ODM2WjCBpzEL +MAkGA1UEBhMCWFkxFTATBgNVBAgTDFNuYWtlIERlc2VydDETMBEGA1UEBxMKU25h +a2UgVG93bjEXMBUGA1UEChMOU25ha2UgT2lsLCBMdGQxFzAVBgNVBAsTDldlYnNl +cnZlciBUZWFtMRkwFwYDVQQDExB3d3cuc25ha2VvaWwuZG9tMR8wHQYJKoZIhvcN +AQkBFhB3d3dAc25ha2VvaWwuZG9tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKB +gQDH9Ge/s2zcH+da+rPTx/DPRp3xGjHZ4GG6pCmvADIEtBtKBFAcZ64n+Dy7Np8b +vKR+yy5DGQiijsH1D/j8HlGE+q4TZ8OFk7BNBFazHxFbYI4OKMiCxdKzdif1yfaa +lWoANFlAzlSdbxeGVHoT0K+gT5w3UxwZKv2DLbCTzLZyPwIDAQABoyYwJDAPBgNV +HRMECDAGAQH/AgEAMBEGCWCGSAGG+EIBAQQEAwIAQDANBgkqhkiG9w0BAQQFAAOB +gQAZUIHAL4D09oE6Lv2k56Gp38OBDuILvwLg1v1KL8mQR+KFjghCrtpqaztZqcDt +2q2QoyulCgSzHbEGmi0EsdkPfg6mp0penssIFePYNI+/8u9HT4LuKMJX15hxBam7 +dUHzICxBVC1lnHyYGjDuAMhe396lYAn8bCld1/L4NMGBCQ== +-----END CERTIFICATE-----</pre></div> + + +<h3><a name="certificateauthorities" id="certificateauthorities">Autorités de certification</a></h3> + + <p>En vérifiant les informations contenues dans une demande de certificat + avant de l'accorder, l'autorité de certification s'assure de l'identité du + propriétaire de la clé privée issue de sa paire de clés. Par exemple, Si + Alice demande un certificat personnel, l'autorité de certification doit + d'abord s'assurer qu'elle correspond vraiment à la personne à laquelle + la demande de certificat fait référence.</p> + + <h4><a name="certificatechains" id="certificatechains">Chaînes de certification</a></h4> + + <p>Une autorité de certification peut aussi émettre un certificat à + destination d'une + autre autorité de certification. Pour vérifier un certificat, Alice + peut être amenée à vérifier le certificat de l'émetteur pour chaque + autorité de certification parente, jusqu'à ce qu'elle en atteigne une + en qui elle a confiance. Elle peut aussi ne faire confiance qu'aux + certificats faisant l'objet d'une chaîne limitée d'émetteurs, afin + de réduire le risque de rencontrer un "mauvais" certificat dans la + chaîne.</p> + + + <h4><a name="rootlevelca" id="rootlevelca">Création d'une autorité de certification racine</a></h4> + + <p>Comme indiqué plus haut, chaque certificat nécessite la validation + de l'identité du sujet par un émetteur de certificats + de niveau supérieur, et ceci en + remontant jusqu'à l'Autorité de Certification (CA) racine. Ceci pose un + problème : qui va se porter garant du certificat de l'autorité racine + qui ne possède pas d'émetteur de certificat ? C'est uniquement dans ce + cas que le certificat est auto-signé, l'émetteur du certificat et son + sujet étant confondus. Les navigateurs sont préconfigurés avec une + liste d'autorités de certification de confiance, mais il est important + d'être extrèmement prudent avant de faire confiance à un certificat + auto-signé. La large publication d'une clé publique par l'autorité + racine réduit cependant les risques encourus + en faisant confiance à cette clé -- + si quelqu'un publiait une clé en se faisant passer pour l'autorité, il + serait vite démasqué.</p> + + <p>Quelques compagnies, comme <a href="http://www.thawte.com/">Thawte</a> et <a href="http://www.verisign.com/">VeriSign</a>, + se sont proclamées elles-mêmes Autorités de Certification. Ces + compagnies proposent les services suivant :</p> + + <ul> + <li>Vérification des demandes de certificats</li> + <li>Traitement des demandes de certificats</li> + <li>Emission et gestion des certificats</li> + </ul> + + <p>Vous pouvez aussi créer votre propre autorité de certification. Bien + que risqué dans l'environnement de l'Internet, ceci peut s'avérer utile + dans un Intranet, où l'organisme peut vérifier facilement les identités + des individus et des serveurs.</p> + + + <h4><a name="certificatemanagement" id="certificatemanagement">Gestion des certificats</a></h4> + + <p>Constituer une autorité de certification représente une + responsabilité qui nécessite une solide infrastructure administrative, + technique et gestionnaire. Les autorités de certification ne se + contentent pas d'émettre des certificats, elles doivent aussi les gérer + -- à savoir elles déterminent leur durée de validité, elles les + renouvellent, et elles maintiennent des listes de certificats qui ont + été émis dans le passé mais ne sont plus valides (Listes de révocations + de certificats, ou CRLs).</p> + + <p>Par exemple, si Alice est titulaire d'un certificat en tant + qu'employée d'une compagnie, mais vient de quitter cette compagnie, + son certificat doit être révoqué. Comme les certificats ne sont émis + qu'après vérification de l'identité du sujet, et peuvent être envoyés + à tous ceux avec lesquels le sujet peut communiquer, il est impossible + de discerner à partir du seul certificat s'il a été révoqué. Pour + vérifier la validité d'un certificat, il est donc nécessaire de + contacter l'autorité de certification qui l'a émis afin de pouvoir + consulter ses listes de révocations de certificats -- ce qui n'est + en général pas une partie automatique du processus.</p> + + <div class="note"><h3>Note</h3> + <p>Si votre autorité de certification ne fait pas partie de la liste + des autorités de confiance de votre navigateur, il faut enregistrer le + certificat de l'autorité de certification dans ce dernier, ce qui lui + permettra de valider les certificats de serveurs signés par cette + autorité de certification. Ceci peut être dangereux, car une fois le + certificat enregistré, le navigateur acceptera tous les certificats + signés par cette autorité de certification.</p> + </div> + + + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="ssl" id="ssl">Couche Points d'Accès Sécurisés - Secure Sockets Layer (SSL)</a></h2> + +<p>Le protocole Couche Points d'Accès Sécurisés est une couche protocolaire +qui pourrait s'intercaler entre un protocole d'une couche réseau orientée +connexion (comme TCP/IP) et une couche protocolaire d'application (comme HTTP). +SSL fournit une communication sécurisée entre client et serveur en permettant +l'authentification mutuelle, l'utilisation des signatures numériques pour la +vérification de l'intégrité des données, et le chiffrement pour la +confidentialité.</p> + +<p>Ce protocole est conçu pour supporter un grand choix d'algorithmes +spécifiques utilisés pour la cryptographie, les empreintes et les signatures. +Ceci permet la sélection d'un algorithme pour des serveurs spécifiques en +respectant la légalité, les règles d'exportation ou autres contraintes, et +permet aussi au protocole de tirer parti des nouveaux algorithmes. Ces choix +font l'objet d'une négociation entre client et serveur lors de +l'établissement de la session protocolaire.</p> + +<h3><a name="table4" id="table4">Tableau 4: Versions du protocole SSL</a></h3> + + <table class="bordered"> + + <tr><th>Version</th> + <th>Source</th> + <th>Description</th> + </tr> + <tr><td>SSL v2.0</td> + <td>Standard du fournisseur (de Netscape Corp.)</td> + <td>Premier protocole SSL pour lequel il existe des implémentations</td> + </tr> + <tr><td>SSL v3.0</td> + <td>Projet Internet arrivé à expiration (de Netscape Corp.) [<a href="#SSL3">SSL3</a>]</td> + <td>Comporte des révisions permettant de prévenir certaines attaques de + sécurité spécifiques, ajout de chiffrements non RSA, et support des + chaînes de certification</td> + </tr> + <tr><td>TLS v1.0</td> + <td>Standard proposé pour l'Internet (de l'IETF) [<a href="#TLS1">TLS1</a>]</td> + <td>Révision de SSL 3.0 pour mettre à jour la couche MAC vers HMAC, + ajout du bourrage de bloc pour le chiffrement de bloc, standardisation + de l'ordonnancement des messages et plus de messages d'alerte.</td> + </tr> + <tr><td>TLS v1.1</td> + <td>Standard proposé pour l'Internet (de l'IETF) [<a href="#TLS11">TLS11</a>]</td> + <td>Mise à jour de TLS 1.0 pour la protection contre les + attaques de type Cipher block chaining (CBC).</td> + </tr> + <tr><td>TLS v1.2</td> + <td>Standard proposé pour l'Internet (de l'IETF) [<a href="#TLS12">TLS12</a>]</td> + <td>Mise à jour de TLS 1.1 rendant les condensés MD5 obsolètes, + et introduisant une incompatibilité avec SSL ce qui interdit toute + négociation en vue d'une utilisation de SSLv2.</td> + </tr> + </table> + + +<p>Il existe plusieurs versions du protocole SSL, comme le montre le +<a href="#table4">Tableau 4</a>. Comme indiqué dans ce dernier, un des apports +de SSL 3.0 est le support du chargement des chaînes de certification. Cette +fonctionnalité permet à un serveur de passer au navigateur un certificat de +serveur accompagné du certificat de l'émetteur. Le chargement de la +chaîne permet aussi au navigateur de valider le certificat du serveur, même si +les certificats de l'autorité de certification ne sont pas installés pour les +émetteurs intermédiaires, car ils sont inclus dans la chaîne de certification. +SSL 3.0 sert de base au standard du protocole Sécurité de la Couche Transport +ou Transport Layer Security +[<a href="#TLS1">TLS</a>], actuellement en développement au sein de +l'Internet Engineering Task Force (IETF).</p> + +<h3><a name="session" id="session">Etablissement d'une session</a></h3> + + <p>La session SSL est établie en suivant une séquence d'échanges + d'informations entre client et serveur, comme le montre la + <a href="#figure1">Figure 1</a>. Cette séquence peut varier, selon que + le serveur est configuré pour fournir un certificat de serveur ou + réclame un certificat client. Bien que dans certains cas, des étapes + d'échanges d'informations supplémentaires soient nécessaires pour la + gestion des informations de chiffrement, cet article résume un scénario + courant. Se reporter aux spécifications SSL pour avoir la liste de + toutes les possibilités.</p> + + <div class="note"><h3>Note</h3> + <p>Une fois la session SSL établie, elle peut être réutilisée. Ceci + permet d'éviter la perte de performances due à la répétition des nombreuses + étapes nécessaires à l'établissement d'une session. Pour parvenir à ceci, + le serveur assigne un identifiant de session unique à chaque session SSL ; + cet identifiant est mis en cache dans le serveur et le client peut + l'utiliser pour des connexions ultérieures afin de réduire la durée des + échanges d'informations (et ceci jusqu'à ce que l'identifiant de session + arrive à expiration dans le cache du serveur).</p> + </div> + + <p class="figure"> + <img src="../images/ssl_intro_fig1.gif" alt="" width="423" height="327" /><br /> + <a id="figure1" name="figure1"><dfn>Figure 1</dfn></a> : Séquence + simplifiée d'échanges d'informations SSL</p> + + <p>Les éléments de la séquence d'échanges d'informations, tels qu'ils + sont utilisés par le client et le serveur, sont énumérés ci-après :</p> + + <ol> + <li>Négociation de la suite de chiffrement à utiliser durant le transfert des données</li> + <li>Elaboration et échange d'une clé de session entre le client et le serveur</li> + <li>Authentification éventuelle du serveur par le client</li> + <li>Authentification éventuelle du client par le serveur</li> + </ol> + + <p>La première étape, la négociation de la suite de chiffrement, permet au + client et au serveur de choisir une suite de chiffrement qu'ils supportent + tous les deux. La spécification du protocole SSL 3.0 définit 31 suites de + chiffrement. Une suite de chiffrement se compose des éléments + suivants :</p> + + <ul> + <li>Méthode d'échange de la clé</li> + <li>Chiffrement du transfert des données</li> + <li>Empreinte du message servant à créer le code d'authentification du + message (MAC)</li> + </ul> + + <p>Ces trois éléments sont décrits dans les sections suivantes.</p> + + +<h3><a name="keyexchange" id="keyexchange">Méthode d'échange de la clé</a></h3> + + <p>La méthode d'échange de la clé définit la manière + dont la clé de chiffrement + symétrique secrète et partagée utilisée pour le transfert des données de + l'application sera acceptée par le client et le serveur. SSL 2.0 utilise + l'échange de clé RSA seulement, tandis que SSL 3.0 supporte tout un choix + d'algorithmes d'échange de clé incluant l'échange de clé RSA (quand les + certificats sont utilisés), et l'échange de clés Diffie-Hellman (pour + échanger des clés sans certificat, ou en l'absence de communication + préalable entre le client et le serveur).</p> + + <p>Les signatures numériques constituent une variante dans le choix des + méthodes d'échange de clé -- utiliser les signatures ou pas, et dans + l'affirmative, quel genre de signatures utiliser. La signature à l'aide + d'une clé privée fournit une protection contre une attaque + "man-in-the-middle" au cours de laquelle + l'échange d'informations destiné à générer la + clé partagée peut être intercepté [<a href="#AC96">AC96</a>, p516].</p> + + +<h3><a name="ciphertransfer" id="ciphertransfer">Chiffrement du transfert de données</a></h3> + + <p>Comme décrit plus haut, SSL utilise le chiffrement symétrique + conventionnel pour chiffrer les messages au cours d'une session. Il existe + neuf choix possibles pour le chiffrement, y compris l'option du transfert + non chiffré :</p> + + <ul> + <li>Pas de chiffrement</li> + <li>Chiffrement en continu (Stream Ciphers) + <ul> + <li>RC4 avec clés de 40 bits</li> + <li>RC4 avec clés de 128 bits</li> + </ul></li> + <li>Chiffrement par blocs CBC (CBC Block Ciphers) + <ul><li>RC2 avec clé de 40 bits</li> + <li>DES avec clé de 40 bits</li> + <li>DES avec clé de 56 bits</li> + <li>Triple-DES avec clé de 168 bits</li> + <li>Idea (clé de 128 bits)</li> + <li>Fortezza (clé de 96 bits)</li> + </ul></li> + </ul> + + <p>"CBC" signifie Cipher Block Chaining (Chaînage de blocs chiffrés), + c'est à dire qu'une portion du bloc de texte chiffré précédent est utilisée + pour le chiffrement du bloc courant. "DES" signifie Data Encryption + Standard (Standard de Chiffrement des Données) + [<a href="#AC96">AC96</a>, ch12], et possède de nombreuses variantes + (telles que DES40 et 3DES_EDE). Parmi les algorithmes disponibles, "Idea" + est actuellement un des meilleurs et des plus puissants sur le plan + cryptographique, et "RC2" est un algorithme propriétaire de RSA DSI + [<a href="#AC96">AC96</a>, ch13].</p> + + +<h3><a name="digestfunction" id="digestfunction">Fonction de création d'empreinte</a></h3> + + <p>Le choix d'une fonction de création d'empreinte détermine la manière + dont une empreinte est créée à partir d'une unité de données. SSL supporte + les fonctions suivantes :</p> + + <ul> + <li>Pas d'empreinte (choix Null)</li> + <li>MD5, une empreinte de 128 bits</li> + <li>Algorithme d'Empreinte Sécurisée (Secure Hash Algorithm - SHA-1), une + empreinte de 160 bits</li> + </ul> + + <p>On utilise l'empreinte de message pour créer un Code d'Authentification + de Message (Message Authentication Code - MAC) qui est chiffré avec le + message afin de vérifier son intégrité et de se protéger contre les + attaques de type "rejeu".</p> + + +<h3><a name="handshake" id="handshake">Protocole de la séquence d'échanges d'informations</a></h3> + + <p>La séquence d'échanges d'informations utilise trois protocoles :</p> + + <ul> + <li>Le <dfn>Protocole d'échanges d'informations SSL</dfn> pour établir + la session SSl entre le client et le serveur.</li> + <li>Le <dfn>Protocole de spécification du chiffrement SSL</dfn> pour + l'agrément effectif de la suite de chiffrement à utiliser + pour la session.</li> + <li>Le <dfn>Protocole d'alertes SSL</dfn> pour la transmission de + messages d'erreur SSL entre le client et le serveur.</li> + </ul> + + <p>Ces protocoles, ainsi que les données du protocole de l'application, + sont encapsulés dans le <dfn>Protocole d'enregistrement SSL + (SSL Record Protocol)</dfn>, comme + le montre la <a href="#figure2">Figure 2</a>. Un protocole encapsulé est + tranféré en tant que données par le protocole de la couche de niveau + inférieur, qui ne se préoccupe pas du contenu des données. Le protocole + encapsulé n'a aucune connaissance du protocole sous-jacent.</p> + + <p class="figure"> + <img src="../images/ssl_intro_fig2.gif" alt="" width="428" height="217" /><br /> + <a id="figure2" name="figure2"><dfn>Figure 2</dfn></a>: + Pile du protocole SSL</p> + + <p>L'encapsulation des protocoles de contrôle SSL dans le protocole + d'enregistrement signifie que si une session active est renégociée, les + protocoles de contrôle seront transmis de manière sécurisée. S'il n'y + avait pas de session préalable, la suite de chiffrement Null est utilisée, + ce qui signifie que les messages ne seront pas chiffrés et ne possèderont + pas d'empreinte d'intégrité, jusqu'à ce que la session ait été établie.</p> + + +<h3><a name="datatransfer" id="datatransfer">Transmission des données</a></h3> + + <p>Le protocole d'enregistrement SSL, comme le montre la + <a href="#figure3">Figure 3</a>, est utilisé pour transmettre les données + de l'application et les données de contrôle SSL entre le client et le + serveur, les données étant nécessairement fragmentées en éléments plus + petits, ou plusieurs messages de données avec protocole de niveau + supérieur pouvant être combinés en un seul élément. Ce protocole peut + joindre des signatures d'empreintes, compresser et chiffrer ces éléments + avant de les transmettre en utilisant le protocole fiable de transport + sous-jacent (Note : actuellement, aucune implémentation majeure de SSL + n'inclut le support de la compression).</p> + + <p class="figure"> + <img src="../images/ssl_intro_fig3.gif" alt="" width="423" height="323" /><br /> + <a id="figure3" name="figure3"><dfn>Figure 3</dfn></a>: + Protocole d'enregistrement SSL</p> + + +<h3><a name="securehttp" id="securehttp">Sécurisation des communications HTTP</a></h3> + + <p>Une des utilisations courantes de SSL est la sécurisation des + communication HTTP sur le Web entre un navigateur et un serveur web. Ceci + n'exclut pas l'utilisation de HTTP non sécurisé - la version sécurisée + (appelée HTTPS) est identique à du vrai HTTP sur SSL, + mais utilise le préfixe + d'URL <code>https</code> au lieu de <code>http</code>, et un port + de serveur différent (par défaut le port 443). + Ceci constitue pour une large part + ce qu'apporte <code class="module"><a href="../mod/mod_ssl.html">mod_ssl</a></code> au serveur web Apache.</p> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="references" id="references">Références</a></h2> + +<dl> +<dt><a id="AC96" name="AC96">[AC96]</a></dt> +<dd>Bruce Schneier, <q>Applied Cryptography</q>, 2nd Edition, Wiley, +1996. Voir <a href="http://www.counterpane.com/">http://www.counterpane.com/</a> pour diverses autres productions de Bruce +Schneier.</dd> + +<dt><a id="ASN1" name="ASN1">[ASN1]</a></dt> +<dd>ITU-T Recommendation X.208, <q>Specification of Abstract Syntax Notation +One (ASN.1)</q>, dernière mise à jour en 2008. Voir <a href="http://www.itu.int/ITU-T/asn1/">http://www.itu.int/ITU-T/asn1/</a>. +</dd> + +<dt><a id="X509" name="X509">[X509]</a></dt> +<dd>ITU-T Recommendation X.509, <q>The Directory - Authentication +Framework</q>. A titre de référence, voir <a href="http://en.wikipedia.org/wiki/X.509">http://en.wikipedia.org/wiki/X.509</a>. +</dd> + +<dt><a id="PKCS" name="PKCS">[PKCS]</a></dt> +<dd><q>Public Key Cryptography Standards (PKCS)</q>, +RSA Laboratories Technical Notes, Voir <a href="http://www.rsasecurity.com/rsalabs/pkcs/">http://www.rsasecurity.com/rsalabs/pkcs/</a>.</dd> + +<dt><a id="MIME" name="MIME">[MIME]</a></dt> +<dd>N. Freed, N. Borenstein, <q>Multipurpose Internet Mail Extensions +(MIME) Part One: Format of Internet Message Bodies</q>, RFC2045. +Voir par exemple <a href="http://tools.ietf.org/html/rfc2045">http://tools.ietf.org/html/rfc2045</a>.</dd> + +<dt><a id="SSL3" name="SSL3">[SSL3]</a></dt> +<dd>Alan O. Freier, Philip Karlton, Paul C. Kocher, <q>The SSL Protocol +Version 3.0</q>, 1996. Voir <a href="http://www.netscape.com/eng/ssl3/draft302.txt">http://www.netscape.com/eng/ssl3/draft302.txt</a>.</dd> + +<dt><a id="TLS1" name="TLS1">[TLS1]</a></dt> +<dd>Tim Dierks, Christopher Allen, <q>The TLS Protocol Version 1.0</q>, +1999. Voir <a href="http://ietf.org/rfc/rfc2246.txt">http://ietf.org/rfc/rfc2246.txt</a>.</dd> + +<dt><a id="TLS11" name="TLS11">[TLS11]</a></dt> +<dd><q>Le protocole TLS Version 1.1</q>, +2006. Voir <a href="http://tools.ietf.org/html/rfc4346">http://tools.ietf.org/html/rfc4346</a>.</dd> + +<dt><a id="TLS12" name="TLS12">[TLS12]</a></dt> +<dd><q>Le protocole TLS Version 1.2</q>, +2008. Voir <a href="http://tools.ietf.org/html/rfc5246">http://tools.ietf.org/html/rfc5246</a>.</dd> +</dl> +</div></div> +<div class="bottomlang"> +<p><span>Langues Disponibles: </span><a href="../en/ssl/ssl_intro.html" hreflang="en" rel="alternate" title="English"> en </a> | +<a href="../fr/ssl/ssl_intro.html" title="Français"> fr </a> | +<a href="../ja/ssl/ssl_intro.html" hreflang="ja" rel="alternate" title="Japanese"> ja </a></p> +</div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Commentaires</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Libera.chat, or sent to our <a href="https://httpd.apache.org/lists.html">mailing lists</a>.</div> +<script type="text/javascript"><!--//--><![CDATA[//><!-- +var comments_shortname = 'httpd'; +var comments_identifier = 'http://httpd.apache.org/docs/2.4/ssl/ssl_intro.html'; +(function(w, d) { + if (w.location.hostname.toLowerCase() == "httpd.apache.org") { + d.write('<div id="comments_thread"><\/div>'); + var s = d.createElement('script'); + s.type = 'text/javascript'; + s.async = true; + s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier; + (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s); + } + else { + d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>'); + } +})(window, document); +//--><!]]></script></div><div id="footer"> +<p class="apache">Copyright 2023 The Apache Software Foundation.<br />Autorisé sous <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p> +<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossaire</a> | <a href="../sitemap.html">Plan du site</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!-- +if (typeof(prettyPrint) !== 'undefined') { + prettyPrint(); +} +//--><!]]></script> +</body></html>
\ No newline at end of file diff --git a/docs/manual/ssl/ssl_intro.html.ja.utf8 b/docs/manual/ssl/ssl_intro.html.ja.utf8 new file mode 100644 index 0000000..b48ad3f --- /dev/null +++ b/docs/manual/ssl/ssl_intro.html.ja.utf8 @@ -0,0 +1,730 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" lang="ja" xml:lang="ja"><head> +<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" /> +<!-- + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + This file is generated from xml source: DO NOT EDIT + XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + --> +<title>SSL/TLS 暗号化: はじめに - Apache HTTP サーバ バージョン 2.4</title> +<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" /> +<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" /> +<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" /> +<script src="../style/scripts/prettify.min.js" type="text/javascript"> +</script> + +<link href="../images/favicon.ico" rel="shortcut icon" /></head> +<body id="manual-page"><div id="page-header"> +<p class="menu"><a href="../mod/">モジュール</a> | <a href="../mod/directives.html">ディレクティブ</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">用語</a> | <a href="../sitemap.html">サイトマップ</a></p> +<p class="apache">Apache HTTP サーバ バージョン 2.4</p> +<img alt="" src="../images/feather.png" /></div> +<div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div> +<div id="path"> +<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP サーバ</a> > <a href="http://httpd.apache.org/docs/">ドキュメンテーション</a> > <a href="../">バージョン 2.4</a> > <a href="./">SSL/TLS</a></div><div id="page-content"><div id="preamble"><h1>SSL/TLS 暗号化: はじめに</h1> +<div class="toplang"> +<p><span>翻訳済み言語: </span><a href="../en/ssl/ssl_intro.html" hreflang="en" rel="alternate" title="English"> en </a> | +<a href="../fr/ssl/ssl_intro.html" hreflang="fr" rel="alternate" title="Français"> fr </a> | +<a href="../ja/ssl/ssl_intro.html" title="Japanese"> ja </a></p> +</div> +<div class="outofdate">この日本語訳はすでに古くなっている + 可能性があります。 + 最近更新された内容を見るには英語版をご覧下さい。 + </div> + +<blockquote> +<p>標準規格の良い所は、たくさんの規格から選べるということだ。 +そして、もし本当にどの規格も気に入らなければ、 +一年待つだけで探していた規格が現れる。</p> + +<p class="cite">-- <cite>A. Tanenbaum</cite>, "Introduction to +Computer Networks"</p> +</blockquote> + +<p> +入門ということで、この章は Web、HTTP、Apache に通じている +読者向けですが、セキュリティ専門家向けではありません。 +SSL プロトコルの決定的な手引きであるつもりはありません。 +また、組織内の認証管理のための特定のテクニックや、 +特許や輸出規制などの重要な法的な問題についても扱いません。 +むしろ、更なる研究への出発点として色々な概念、定義、例を並べることで +<code class="module"><a href="../mod/mod_ssl.html">mod_ssl</a></code> のユーザに基礎知識を提供する事を目的としています。</p> + +<p>ここに示された内容は主に、原著者の許可の下 +The Open Group Research Institute の <a href="http://home.earthlink.net/~fjhirsch/">Frederick J. Hirsch</a> + 氏の記事 <a href="http://home.earthlink.net/~fjhirsch/Papers/wwwj/"> +Introducing SSL and Certificates using SSLeay</a> を基にしています。 +氏の記事は <a href="http://www.ora.com/catalog/wjsum97/">Web Security: A Matter of +Trust</a>, World Wide Web Journal, Volume 2, Issue 3, Summer 1997 +に掲載されました。 +肯定的な意見は <a href="mailto:hirsch@fjhirsch.com">Frederick Hirsch</a> 氏 + (元記事の著者) へ全ての苦情は <a href="mailto:rse@engelschall.com">Ralf S. Engelschall</a> ( +<code class="module"><a href="../mod/mod_ssl.html">mod_ssl</a></code> の作者) へお願いします。 +<span class="transnote">(<em>訳注:</em> 訳については <a href="mailto:apache-docs@ml.apache.or.jp"> +Apache ドキュメント翻訳プロジェクト</a> +へお願いします。)</span></p> +</div> +<div id="quickview"><a href="https://www.apache.org/foundation/contributing.html" class="badge"><img src="https://www.apache.org/images/SupportApache-small.png" alt="Support Apache!" /></a><ul id="toc"><li><img alt="" src="../images/down.gif" /> <a href="#cryptographictech">暗号化技術</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#certificates">証明書</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#ssl">Secure Sockets Layer (SSL)</a></li> +<li><img alt="" src="../images/down.gif" /> <a href="#references">参考文献</a></li> +</ul><h3>参照</h3><ul class="seealso"><li><a href="#comments_section">コメント</a></li></ul></div> +<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="cryptographictech" id="cryptographictech">暗号化技術</a></h2> + +<p>SSL を理解するには、暗号アルゴリズム、 +メッセージダイジェスト関数(別名: 一方向関数、ハッシュ関数)、 +電子署名などへの理解が必要です。 +これらの技術は本が丸ごと必要な題目で +(例えば [<a href="#AC96">AC96</a>] を参照)、 +プライバシー、信用、認証などの技術の基礎となっています。</p> + +<h3><a name="cryptographicalgo" id="cryptographicalgo">暗号アルゴリズム</a></h3> + + <p>例えば、アリスが送金のために銀行にメッセージを送りたいとします。 + 口座番号や送金の金額が含まれるため、 + アリスはそのメッセージを秘密にしたいと思います。 + 解決方法の一つは暗号アルゴリズムを使って、メッセージを + 復号されるまで読むことができない暗号化された + 形態に変えてしまうことです。 + その形態になると、 + メッセージは秘密の鍵によってのみ復号化することができます。 + 鍵なしでは、メッセージは役に立ちません。 + 良い暗号アルゴリズムは、侵入者が元のテキストを解読することを + 非常に難しくするため、努力が割に合わなくさせます。</p> + + <p>暗号アルゴリズムには + 従来型と公開鍵の二つの種類があります。</p> + + <dl> + <dt>従来型暗号</dt> + <dd>対称暗号としても知られ、 + 送信者と受信者が鍵を共有することが必要です。 + 鍵とは、メッセージを暗号化したり復号するのに使われる秘密 + の情報のことです。 + この鍵が秘密になっている限り、送信者と受信者以外は誰もメッセージを読 + むことができません。 + もしも、アリスと銀行が秘密の鍵を知っているなら、 + 彼らはお互いに秘密のメッセージを送ることができるでしょう。 + ただし交信の前に、事前に内密に鍵を共有するという作業自体は難題かもしれません。</dd> + + <dt>公開鍵暗号</dt> + <dd>非対称暗号としても知られ、 + メッセージを暗号化することのできる二つの鍵 + を使用するアルゴリズムを定義することで鍵のやり取りの問題を解決 + します。 + もし、ある鍵が暗号化に使われたなら、 + もう片方の鍵で復号しなければいけません。 + この方式によって、一つの鍵を公表して(公開鍵)、 + もう片方を秘密にしておく(秘密鍵)だけで、 + 安全なメッセージを受け取ることができます。</dd> + </dl> + + <p>公開鍵を使って誰もがメッセージを暗号化できますが、秘 + 密鍵の持ち主だけがそれを読むことができます。 + この方法で、銀行の公開鍵を使って暗号化することで、 + アリスは秘密のメッセージを送ることができます。 + 銀行のみが送られたメッセージを復号することができます。</p> + + +<h3><a name="messagedigests" id="messagedigests">メッセージダイジェスト</a></h3> + + <p>アリスはメッセージを秘密にすることができますが、 + 誰かが例えば自分に送金するようにメッセージを変更したり、 + 別のものに置き換えてしまうかもしれないという問題があります。 + アリスのメッセージだという信憑性を保証する方法の一つは、 + メッセージの簡潔なダイジェストを作って、それも銀行に送るというものです。 + メッセージを受け取ると銀行側でもダイジェストを作成し、 + アリスが送ったダイジェストと比べます。もし一致したなら、 + 受け取ったメッセージは無傷だということになります。</p> + + <p>このような要約は<dfn>メッセージダイジェスト</dfn>、 + <em>一方行関数</em>、または<em>ハッシュ関数</em>と呼ばれます。 + メッセージダイジェストは長い可変長のメッセージから + 短い固定長の表現を作るのに使われます。 + ダイジェストアルゴリズムはメッセージから + 一意なダイジェストを生成するように作られています。 + メッセージダイジェストはダイジェストから元のメッセージを + 判定するのがとても難しいようにできていて、 + 同じ要約を作成する二つのメッセージを探すのは(理論上)不可能です。 + これによって、要約を変更することなくメッセージを置き換えられる + 可能性を排除しています。</p> + + <p>アリスへのもう一つの問題は、このダイジェストを安全に送る方法を探すことです。 + ダイジェストが安全に送られればダイジェストの信憑性が保障されて、 + ダイジェストの信憑性をもってオリジナルメッセージの信憑性を得ることができます。 + ダイジェストを安全に送った場合にのみ、そのメッセージの + 信憑性が得られます。</p> + + <p>ダイジェスト安全に送る方法の一つは、電子署名に含める方法です。</p> + + +<h3><a name="digitalsignatures" id="digitalsignatures">電子署名</a></h3> +<p>アリスが銀行にメッセージを送ったとき、 +侵入者が彼女になりすまして彼女の口座への取引を申請できないように、 +銀行側ではメッセージが本当に彼女からのものか確実に分かるようにしなければなりません。 +アリスによって作成されて、メッセージに含まれた +<em>電子署名</em>がここで役に立ちます。</p> + +<p>電子署名はメッセージのダイジェストやその他の情報(処理番号など)を +送信者の秘密鍵で暗号化することで作られます。 +誰もが公開鍵を使って署名を<em>復号</em>することができますが、 +送信者のみが秘密鍵を知っています。 +これは送信者のみが署名しえたことを意味します。 +ダイジェストを電子署名に含むことは、 +その署名がそのメッセージのみに有効であることを意味します。 +これは、誰もダイジェストを変えて署名をすることができないため、 +メッセージの信用も保証します。</p> + +<p>侵入者が署名を傍受して後日に再利用するのを防ぐため +電子署名には一意な処理番号が含まれます。 +これは、アリスがそんなメッセージは送っていないと言う詐欺 +から銀行を守ります。 +彼女だけが署名しえたからです。(否認防止)</p> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="certificates" id="certificates">証明書</a></h2> + +<p>アリスは秘密のメッセージを銀行に送り、 +署名をして、メッセージの信用を保証することができるおうになりましたが、 +通信している相手が本当に銀行なのか確かめなくてはいけません。 +つまり彼女が使おうとしている公開鍵が、銀行の秘密鍵と対になっていて、 +侵入者の秘密鍵と対になっているわけではないことを +確かめなくてはいけないことを意味しています。 +同様に銀行は、メッセージの署名が本当にアリスの持っている +秘密鍵で署名された署名かを確認する必要があります。</p> + +<p>もし両者に身元を証明し、公開鍵を確認し、また信頼された機関が署名 +した証明書があれば、両者とも通信相手について正しい相手だと +確信することができます。 +そのような信頼された機関は<em>認証局</em> + (Certificate Authority または CA) と呼ばれ、 +証明書 (certificate) が認証 (authentication) に使われます。</p> + +<h3><a name="certificatecontents" id="certificatecontents">証明書の内容</a></h3> + + <p>証明書は公開鍵と個人、サーバ、その他の主体の実在の身元を + 関連付けます。 + <a href="#table1">表1</a>に示されるように証明対象の情報は + 身元証明の情報(識別名)と公開鍵が含まれます。 + 証明書はまた、認証局の身元証明と署名、そして証明書の有効期間を + 含みます。 + シリアルナンバーなどの認証局の管理上の情報や + その他の追加の情報が含まれているかもしれません。</p> + + <h4><a name="table1" id="table1">表1: 証明書情報</a></h4> + + <table> + + <tr><th>証明対象</th> + <td>識別名、公開鍵</td></tr> + <tr><th>発行者</th> + <td>識別名、公開鍵</td></tr> + <tr><th>有効期間</th> + <td>開始日、失効日</td></tr> + <tr><th>管理情報</th> + <td>バージョン、シリアルナンバー</td></tr> + <tr><th>拡張情報</th> + <td>基本的な制約、ネットスケープフラッグ、その他</td></tr> + </table> + + + <p>識別名(ディスティングイッシュ・ネーム)は特定の状況における + 身分証明を提供するのに使われています。例えば、ある人は + 私用と会社とで別々の身分証明を持つかもしれません。 + + 識別名は X.509 標準規格 [<a href="#X509">X509</a>] で定義されています。 + X.509 標準規格は、項目、項目名、そして項目の略称を定義しています。(<a href="#table2">表 + 2</a> 参照)</p> + + <h4><a name="table2" id="table2">表 2: 識別名情報</a></h4> + + <table class="bordered"> + + <tr><th>識別名項目</th> + <th>略称</th> + <th>説明</th> + <th>例</th></tr> + <tr><td>Common Name (コモンネーム)</td> + <td>CN</td> + <td>認証される名前<br /> + SSL接続するURL</td> + <td>CN=www.example.com</td></tr> + <tr><td>Organization or Company (組織名)</td> + <td>O</td> + <td>団体の正式英語組織名</td> + <td>O=Example Japan K.K.</td></tr> + <tr><td>Organizational Unit (部門名)</td> + <td>OU</td> + <td>部署名など</td> + <td>OU=Customer Service</td></tr> + <tr><td>City/Locality (市区町村)</td> + <td>L</td> + <td>所在してる市区町村</td> + <td>L=Sapporo</td></tr> + <tr><td>State/Province (都道府県)</td> + <td>ST</td> + <td>所在してる都道府県</td> + <td>ST=Hokkaido</td></tr> + <tr><td>Country(国)</td> + <td>C</td> + <td>所在している国名の ISO コード<br /> + 日本の場合 JP + </td> + <td>C=JP</td></tr> + </table> + + + <p>認証局はどの項目が省略可能でどれが必須かの方針を定義する + かもしれません。項目の内容についても認証局や証明書のユーザからの + 要件があるかもしれません。 + 例えばネットスケープのブラウザは、サーバの証明書の + Common Name (コモンネーム)がサーバのドメイン名の + <code>*.snakeoil.com</code> + というようなワイルドカードのパターンにマッチすること + を要求します。</p> + + <p>バイナリ形式の証明書は ASN.1 表記法 + [<a href="#X208">X208</a>] [<a href="#PKCS">PKCS</a>] で + 定義されています。 + この表記法は内容をどのように記述するかを定義し、 + 符号化の規定がこの情報がどのようにバイナリ形式に変換されるかを + 定義します。 + 証明書のバイナリ符号化は Distinguished Encoding + Rules (DER) で定義され、それはより一般的な Basic Encoding Rules + (BER) に基づいています。 + バイナリ形式を扱うことのできない送信では、 + バイナリ形式は Base64 符号化 [<a href="#MIME">MIME</a>] で + ASCII 形式に変換されることがあります。 + 開始デリミタ行と終了デリミタ行で囲まれた、この形式のことを + PEM ("Privacy Enhanced Mail") 符号化された証明書と言います。</p> + + <div class="example"><h3>PEM 符号化された証明書の例 (example.crt)</h3><pre>-----BEGIN CERTIFICATE----- +MIIC7jCCAlegAwIBAgIBATANBgkqhkiG9w0BAQQFADCBqTELMAkGA1UEBhMCWFkx +FTATBgNVBAgTDFNuYWtlIERlc2VydDETMBEGA1UEBxMKU25ha2UgVG93bjEXMBUG +A1UEChMOU25ha2UgT2lsLCBMdGQxHjAcBgNVBAsTFUNlcnRpZmljYXRlIEF1dGhv +cml0eTEVMBMGA1UEAxMMU25ha2UgT2lsIENBMR4wHAYJKoZIhvcNAQkBFg9jYUBz +bmFrZW9pbC5kb20wHhcNOTgxMDIxMDg1ODM2WhcNOTkxMDIxMDg1ODM2WjCBpzEL +MAkGA1UEBhMCWFkxFTATBgNVBAgTDFNuYWtlIERlc2VydDETMBEGA1UEBxMKU25h +a2UgVG93bjEXMBUGA1UEChMOU25ha2UgT2lsLCBMdGQxFzAVBgNVBAsTDldlYnNl +cnZlciBUZWFtMRkwFwYDVQQDExB3d3cuc25ha2VvaWwuZG9tMR8wHQYJKoZIhvcN +AQkBFhB3d3dAc25ha2VvaWwuZG9tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKB +gQDH9Ge/s2zcH+da+rPTx/DPRp3xGjHZ4GG6pCmvADIEtBtKBFAcZ64n+Dy7Np8b +vKR+yy5DGQiijsH1D/j8HlGE+q4TZ8OFk7BNBFazHxFbYI4OKMiCxdKzdif1yfaa +lWoANFlAzlSdbxeGVHoT0K+gT5w3UxwZKv2DLbCTzLZyPwIDAQABoyYwJDAPBgNV +HRMECDAGAQH/AgEAMBEGCWCGSAGG+EIBAQQEAwIAQDANBgkqhkiG9w0BAQQFAAOB +gQAZUIHAL4D09oE6Lv2k56Gp38OBDuILvwLg1v1KL8mQR+KFjghCrtpqaztZqcDt +2q2QoyulCgSzHbEGmi0EsdkPfg6mp0penssIFePYNI+/8u9HT4LuKMJX15hxBam7 +dUHzICxBVC1lnHyYGjDuAMhe396lYAn8bCld1/L4NMGBCQ== +-----END CERTIFICATE-----</pre></div> + + +<h3><a name="certificateauthorities" id="certificateauthorities">認証局</a></h3> + + <p>証明書を承認する前に、証明書要求に記載されている情報を確認し、 + 認証局は鍵の所有者の身元を確認します。 + 例えば、アリスが個人証明書を申請したとすると、 + 認証局はアリスが証明書の申請が主張する通りの + 当の本人だということを確認しなくてはいけません。</p> + + <h4><a name="certificatechains" id="certificatechains">証明書の連鎖</a></h4> + + <p>認証局は他の認証局への証明書を発行することができます。 + 未知の証明書を調べる時に、アリスはその証明書の発行者 + に自信が持てるまで、発行者の証明書を + その上位階層の認証局をたどって調べる必要があります。 + 「悪質な」証明書の危険性を減らすため、 + 彼女は限られた連鎖の発行者のみ信頼するように + 決めることもできます。</p> + + + <h4><a name="rootlevelca" id="rootlevelca">最上位認証局の作成</a></h4> + + <p>前に述べたように、全ての証明書について、 + 最上位の認証局(CA)までそれぞれの発行者が + 対象の身元証明の有効性を明らかにする必要があります。 + 問題は、誰がその最上位の認証機関の証明書を保証するのか、 + ということです。 + このような場合に限り、証明書は「自己署名」されます。 + ブラウザには、とてもよく知られている認証局が初期登録されていますが、 + 自己署名された証明書を信用する際には + 細心の注意が必要です。 + 最上位認証局が公開鍵を広く公表することで、 + その鍵を信頼するリスクを低くすることができます。 + もし、他人がその認証局になりすました時に、それが露見しや + すいからです。</p> + + <p><a href="http://www.thawte.com/">Thawte</a> + や <a href="http://www.verisign.com/">VeriSign</a> + のような多くの会社が認証局として開設しました。 + このような会社は以下のサービスを提供します:</p> + + <ul> + <li>証明書申請の確認</li> + <li>証明書申請の処理</li> + <li>証明書の発行と管理</li> + </ul> + + <p>自分で認証局を作ることも可能です。 + インターネット環境では危険ですが、 + 個人やサーバの身元証明が簡単に行える組織の + イントラネット内では役に立つかもしれません。</p> + + + <h4><a name="certificatemanagement" id="certificatemanagement">証明書管理</a></h4> + + <p>認証局の開設は徹底した管理、技術、運用の体制を必要とする + 責任のある仕事です。 + 認証局は証明書を発行するだけでなく、 + 管理もしなければなりません。 + 具体的には、証明書がいつまで有効であり続けるかを決定し、更新し、 + また過去発行されて失効した証明書のリスト + (Certificate Revocation Lists または CRL) + を管理しなければいけません。</p> + + <p>例えばアリスが過去、会社の社員であることを証明する証明書を持っていたが、 + 現在は退職していた際、その証明書は失効されなければなりません。 + 証明書は次々と人に渡されていくものなので、 + 証明書そのものから、それが取り消されたか判断することは + 不可能です。 + よって、証明書の有効性を調べるときには、 + 認証局に連絡して CRL を照合する必要があります。 + 普通この過程は自動化されているものではありません。</p> + + <div class="note"><h3>注意</h3> + <p>ブラウザに信用できる認証局としてデフォルトで登録されていない + 認証局を使おうとした場合、 + 認証局の証明書をブラウザに読み込んで、 + ブラウザがその認証局によって署名されたサーバの証明書を + 有効にする必要があります。 + 一度読み込まれると、その認証局によって署名された全ての + 証明書を受け入れるため、危険を伴います。</p> + </div> + + + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="ssl" id="ssl">Secure Sockets Layer (SSL)</a></h2> + +<p>Secure Sockets Layer プロトコルは信頼性のあるコネクション型の +ネットワーク層のプロトコル(例えば、TCP/IP)と +アプリケーション層のプロトコル(例えば、HTTP) +の間に置くことができます。 +SSL は、相互認証によってサーバとクライアント間の安全な通信を、 +電子署名によってデータの完全性を、 +そして暗号化によってプライバシを提供します。</p> + +<p>SSL プロトコルは暗号化、ダイジェスト、電子署名について、 +様々なアルゴリズムをサポートするようにできています。 +こうすることで、法や輸出の規制を考慮に入れて、サーバに合わせた +アルゴリズムを選ぶことができ、また、新しいアルゴリズムを +利用していくことも可能にしています。 +アルゴリズムの選択はプロトコルセッション開始時に +サーバとクライアント間で取り決められます。</p> + +<h3><a name="table4" id="table4">表4: SSL プロトコルのバージョン</a></h3> + + <table class="bordered"> + + <tr><th>バージョン</th> + <th>出典</th> + <th>説明</th> + <th>ブラウザのサポート</th></tr> + <tr><td>SSL v2.0</td> + <td>Vendor Standard (Netscape Corp. より) [<a href="#SSL2">SSL2</a>]</td> + <td>実装が現存する初めての SSL プロトコル</td> + <td>- NS Navigator 1.x/2.x<br /> + - MS IE 3.x<br /> + - Lynx/2.8+OpenSSL</td></tr> + <tr><td>SSL v3.0</td> + <td>Expired Internet Draft (Netscape Corp. より) [<a href="#SSL3">SSL3</a>]</td> + <td>特定のセキュリティ攻撃を防ぐための改訂、 + 非RSA 暗号の追加、証明書階層構造のサポート</td> + <td>- NS Navigator 2.x/3.x/4.x<br /> + - MS IE 3.x/4.x<br /> + - Lynx/2.8+OpenSSL</td></tr> + <tr><td>TLS v1.0</td> + <td>Proposed Internet Standard (IETF より) [<a href="#TLS1">TLS1</a>]</td> + <td>MAC レイヤを HMAC へ更新、ブロック暗号の block + padding、メッセージ順序の標準化、警告文の充実などのため + SSL 3.0 を改訂。</td> + <td>- Lynx/2.8+OpenSSL</td></tr> + </table> + + +<p><a href="#table4">表4</a>に示されるとおり、SSL プロトコルには +いくつものバージョンがあります。 +表にも書かれているように、SSL 3.0 の利点の一つは +証明書階層構造をサポートすることです。 +この機能によって、サーバは自分の証明書に加えて、 +発行者の証明書をブラウザに渡すことができます。 +証明書階層構造によって、 +ブラウザに発行者の証明書が直接登録されていなくても、 +階層の中に含まれていれば、 +ブラウザはサーバの証明書を有効化することができます。 +SSL 3.0 は現在 Internet Engineering Task Force (IETF) +によって開発されている Transport Layer Security +[<a href="#TLS1">TLS</a>] プロトコル標準規格の基礎となっています。</p> + +<h3><a name="session" id="session">セッションの確立</a></h3> + + <p><a href="#figure1">図1</a>で示されるように、 + セッションの確立はクライアントとサーバ間の + ハンドシェークシークエンスによって行なわれます。 + サーバが証明書を提供するか、クライアントの証明書をリクエストするか + というサーバの設定により、このシークエンスは異なるものとなります。 + 暗号情報の管理のために、追加のハンドシェーク過程が必要になる + 場合もありますが、この記事では + よくあるシナリオを手短に説明します。 + 全ての可能性についは、SSL 仕様書を参照してください。</p> + + <div class="note"><h3>注意</h3> + <p>一度 SSL セッションが確立すると、セッションを再利用することで、 + セッションを開始するための多くの過程を繰り返すという + パフォーマンスの損失を防ぎます。 + そのため、サーバは全てのセッションに一意なセッション識別名を + 割り当て、サーバにキャッシュし、クライアントは次回から + (識別名がサーバのキャッシュで期限切れになるまでは) + ハンドシェークなしで接続することができます。</p> + </div> + + <p class="figure"> + <img src="../images/ssl_intro_fig1.gif" alt="" width="423" height="327" /><br /> + <a id="figure1" name="figure1"><dfn>図1</dfn></a>: SSL + ハンドシェークシークエンス概略</p> + + <p>サーバとクライアントで使われる + ハンドシェークシークエンスの要素を以下に示します:</p> + + <ol> + <li>データ通信に使われる暗号スイートの取り決め</li> + <li>クライアントとサーバ間でのセッション鍵の確立と共有</li> + <li>オプションとして、クライアントに対するサーバの認証</li> + <li>オプションとして、サーバに対するクライアントの認証</li> + </ol> + + <p>第一ステップの暗号スイート取り決めによって、 + サーバとクライアントはそれぞれにあった + 暗号スイートを選ぶことができます。 + SSL3.0 プロトコルの仕様書は 31 の暗号スイートを定義しています。 + 暗号スイートは以下のコンポーネントにより定義されています:</p> + + <ul> + <li>鍵の交換手段</li> + <li>データ通信の暗号術</li> + <li>Message Authentication Code (MAC) 作成のための + メッセージダイジェスト</li> + </ul> + + <p>これらの三つの要素は以下のセクションで説明されています。</p> + + +<h3><a name="keyexchange" id="keyexchange">鍵の交換手段</a></h3> + + <p>鍵の交換手段はアプリケーションのデータ通信に使われ、 + 共有される対称暗号鍵をどのようにがクライアントとサーバで + 取り決めるかを定義します。 + SSL 2.0 は RSA 鍵交換しか使いませんが、 + SSL 3.0 は (証明書が使われるときの) RSA 鍵交換や、 + (証明書無しの場合やクライアントとサーバの事前の通信が無い場合の) + Diffie-Hellman 鍵交換 + など様々な鍵交換アルゴリズムをサポートします。</p> + + <p>鍵の交換方法における一つの選択肢は電子署名です。 + 電子署名を使うかどうか、また、 + どの種類の署名を使うかという選択があります。 + 秘密鍵で署名することで共有鍵を保護し、情報交換する時の + マン・イン・ザ・ミドル攻撃を防ぐことができます。 + [<a href="#AC96">AC96</a>, p516]</p> + + +<h3><a name="ciphertransfer" id="ciphertransfer">データ通信の暗号術</a></h3> + + <p>SSL はセッションのメッセージの暗号化に前述した + 対称暗号方式を用います。 + 暗号化しないという選択肢も含め九つの暗号方式の選択肢があります:</p> + + <ul> + <li>暗号化なし</li> + <li>ストリーム暗号 + <ul> + <li>40-bit 鍵での RC4</li> + <li>128-bit 鍵での RC4</li> + </ul></li> + <li>CBC ブロック暗号 + <ul><li>40 bit 鍵での RC2</li> + <li>40 bit 鍵での DES</li> + <li>56 bit 鍵での DES</li> + <li>168 bit 鍵での Triple-DES</li> + <li>Idea (128 bit 鍵)</li> + <li>Fortezza (96 bit 鍵)</li> + </ul></li> + </ul> + + <p>CBC とは暗号ブロック連鎖 (Cipher Block Chaining) + の略で、一つ前の暗号化された暗号文の一部が + ブロックの暗号化に使われることを意味します。 + DES はデータ暗号化標準規格 (Data Encryption Standard) + [<a href="#AC96">AC96</a>, ch12] の略で、 + DES40 や 3DES_EDE を含むいくつもの種類があります。 + Idea は現在最高なものの一つで、暗号術的には現在ある中で + 最も強力なものです。 + RC2 は RSA DSI による独占的なアルゴリズムです。 + [<a href="#AC96">AC96</a>, + ch13]</p> + + +<h3><a name="digestfuntion" id="digestfuntion">ダイジェスト関数</a></h3> + + <p> + ダイジェスト関数の選択はレコードユニットからどのようにダイジェストが生成されるかを決定します。 + SSL は以下をサポートします:</p> + + <ul> + <li>ダイジェストなし</li> + <li>MD5 (128-bit ハッシュ)</li> + <li>Secure Hash Algorithm (SHA-1) (160-bit ハッシュ)</li> + </ul> + + <p>メッセージダイジェストは Message Authentication Code (MAC) + の生成に使われ、メッセージと共に暗号化され、メッセージの信憑性を + 確認し、リプレイ攻撃を防ぎます。</p> + + +<h3><a name="handshake" id="handshake">ハンドシェークシークエンスプロトコル</a></h3> + + <p>ハンドシェークシークエンスは三つのプロトコルを使います:</p> + + <ul> + <li><dfn>SSL ハンドシェークプロトコル</dfn>は + クライアントとサーバ間での SSL セッションの確立に使われます。</li> + <li><dfn>SSL 暗号仕様変更プロトコル</dfn>は + セッションでの暗号スイートの取り決めに使われます。</li> + <li><dfn>SSL 警告プロトコル</dfn>は + クライアントサーバ間で SSL エラーを伝達するのに使われます。</li> + </ul> + + <p>三つのプロトコルは、アプリケーションプロトコルデータとともに、 + <a href="#figure2">図2</a>に示すとおり <dfn>SSL レコードプロトコル</dfn> + でカプセル化されます。 + カプセル化されたプロトコルはデータを検査しない + 下層のプロトコルによってデータとして伝達されます。 + カプセル化されたプロトコルは下層のプロトコルに関して一切関知しません。</p> + + <p class="figure"> + <img src="../images/ssl_intro_fig2.gif" alt="" width="428" height="217" /><br /> + <a id="figure2" name="figure2"><dfn>図2</dfn></a>: SSL プロトコルスタック + </p> + + <p> + レコードプロトコルで SSL コントロールプロトコルがカプセル化されているということは、 + アクティブなセッション上で再ネゴシエーションされたときにも、 + コントロールプロトコルは安全であることを意味します。 + 既存のセッションが無い場合は、Null 暗号スイートが使われ、 + 暗号化は行なわれず、セッションが確立するまでは + ダイジェストも無い状態となります。</p> + + +<h3><a name="datatransfer" id="datatransfer">データ通信</a></h3> + + <p><a href="#figure3">図3</a>に示される SSL レコードプロトコル + はクライアントとサーバ間のアプリケーションや + SSL コントロールデータの通信に使われます。 + 必要に応じてこのデータはより小さいユニットに分けられたり、 + いくつかの高級プロトコルをまとめて一ユニットとして通信が + 行なわれることもあります。 + データを圧縮し、ダイジェスト署名を添付して、 + これらのユニットを暗号化したのち、ベースとなっている + 信頼性のあるトランスポートプロトコルを用いるかもしれません。 + (注意: 現在メジャーな SLL 実装で圧縮をサポートしているものはありません)</p> + + <p class="figure"> + <img src="../images/ssl_intro_fig3.gif" alt="" width="423" height="323" /><br /> + <a id="figure3" name="figure3"><dfn>図 3</dfn></a>: SSL レコードプロトコル + </p> + + +<h3><a name="securehttp" id="securehttp">HTTP 通信の安全化</a></h3> + + <p>よくある SSL の使い方はブラウザとウェブサーバ間の HTTP 通信 + の安全化です。 + これは、従来の安全ではない HTTP の使用を除外するものではありません。 + 安全化されたもの (HTTPS と呼ばれます) は、SSL 上での普通の HTTP で、 + URL スキームに <code>http</code> の代わりに <code>https</code> + を用い、サーバで別のポートを使うことです (デフォルトでは443)。 + これが主に <code class="module"><a href="../mod/mod_ssl.html">mod_ssl</a></code> が Apache + ウェブサーバに提供する機能です。</p> + +</div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div> +<div class="section"> +<h2><a name="references" id="references">参考文献</a></h2> + +<dl> +<dt><a id="AC96" name="AC96">[AC96]</a></dt> +<dd>Bruce Schneier, <q>Applied Cryptography</q>, 2nd Edition, Wiley, +1996. See <a href="http://www.counterpane.com/">http://www.counterpane.com/</a> for various other materials by Bruce +Schneier.</dd> + +<dt><a id="X208" name="X208">[X208]</a></dt> +<dd>ITU-T Recommendation X.208, <q>Specification of Abstract Syntax Notation +One (ASN.1)</q>, 1988. See for instance <a href="http://www.itu.int/rec/recommendation.asp?type=items&lang=e&parent=T-REC-X.208-198811-I">http://www.itu.int/rec/recommendation.asp?type=items&lang=e&parent=T-REC-X.208-198811-I</a>. +</dd> + +<dt><a id="X509" name="X509">[X509]</a></dt> +<dd>ITU-T Recommendation X.509, <q>The Directory - Authentication +Framework</q>. See for instance <a href="http://www.itu.int/rec/recommendation.asp?type=folders&lang=e&parent=T-REC-X.509">http://www.itu.int/rec/recommendation.asp?type=folders&lang=e&parent=T-REC-X.509</a>. +</dd> + +<dt><a id="PKCS" name="PKCS">[PKCS]</a></dt> +<dd><q>Public Key Cryptography Standards (PKCS)</q>, +RSA Laboratories Technical Notes, See <a href="http://www.rsasecurity.com/rsalabs/pkcs/">http://www.rsasecurity.com/rsalabs/pkcs/</a>.</dd> + +<dt><a id="MIME" name="MIME">[MIME]</a></dt> +<dd>N. Freed, N. Borenstein, <q>Multipurpose Internet Mail Extensions +(MIME) Part One: Format of Internet Message Bodies</q>, RFC2045. +See for instance <a href="http://ietf.org/rfc/rfc2045.txt">http://ietf.org/rfc/rfc2045.txt</a>.</dd> + +<dt><a id="SSL2" name="SSL2">[SSL2]</a></dt> +<dd>Kipp E.B. Hickman, <q>The SSL Protocol</q>, 1995. See <a href="http://www.netscape.com/eng/security/SSL_2.html">http://www.netscape.com/eng/security/SSL_2.html</a>.</dd> + +<dt><a id="SSL3" name="SSL3">[SSL3]</a></dt> +<dd>Alan O. Freier, Philip Karlton, Paul C. Kocher, <q>The SSL Protocol +Version 3.0</q>, 1996. See <a href="http://www.netscape.com/eng/ssl3/draft302.txt">http://www.netscape.com/eng/ssl3/draft302.txt</a>.</dd> + +<dt><a id="TLS1" name="TLS1">[TLS1]</a></dt> +<dd>Tim Dierks, Christopher Allen, <q>The TLS Protocol Version 1.0</q>, +1999. See <a href="http://ietf.org/rfc/rfc2246.txt">http://ietf.org/rfc/rfc2246.txt</a>.</dd> +</dl> +</div></div> +<div class="bottomlang"> +<p><span>翻訳済み言語: </span><a href="../en/ssl/ssl_intro.html" hreflang="en" rel="alternate" title="English"> en </a> | +<a href="../fr/ssl/ssl_intro.html" hreflang="fr" rel="alternate" title="Français"> fr </a> | +<a href="../ja/ssl/ssl_intro.html" title="Japanese"> ja </a></p> +</div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">コメント</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Libera.chat, or sent to our <a href="https://httpd.apache.org/lists.html">mailing lists</a>.</div> +<script type="text/javascript"><!--//--><![CDATA[//><!-- +var comments_shortname = 'httpd'; +var comments_identifier = 'http://httpd.apache.org/docs/2.4/ssl/ssl_intro.html'; +(function(w, d) { + if (w.location.hostname.toLowerCase() == "httpd.apache.org") { + d.write('<div id="comments_thread"><\/div>'); + var s = d.createElement('script'); + s.type = 'text/javascript'; + s.async = true; + s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier; + (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s); + } + else { + d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>'); + } +})(window, document); +//--><!]]></script></div><div id="footer"> +<p class="apache">Copyright 2023 The Apache Software Foundation.<br />この文書は <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a> のライセンスで提供されています。.</p> +<p class="menu"><a href="../mod/">モジュール</a> | <a href="../mod/directives.html">ディレクティブ</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">用語</a> | <a href="../sitemap.html">サイトマップ</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!-- +if (typeof(prettyPrint) !== 'undefined') { + prettyPrint(); +} +//--><!]]></script> +</body></html>
\ No newline at end of file |