跳到主要内容

5. Client Certificate URLs (客户端证书 URL)

client_certificate_url extension 允许 client 在 certificate-based client authentication 中发送指向 certificate 的 URL, 而不是直接发送完整 certificate chain. 这可减少受限 client 的内存和带宽消耗.

5.1 Client Hello Processing (Client Hello 处理)

Client MAY 在 extended client hello 中包含 client_certificate_url extension. extension_data MUST 包含 CertChainType:

enum {
individual_certs(0), pkipath(1), (255)
} CertChainType;

struct {
CertChainType type;
} CertificateURL;

发送该 extension 的 client MUST 准备处理 individual_certspkipath 类型的 CertificateURL message.

5.2 Server Hello Processing (Server Hello 处理)

Server MAY 通过在 extended server hello 中包含空 client_certificate_url extension, 表示允许 client 发送 certificate URL. Client 收到该响应后 MAY 发送 CertificateURL message 代替普通 Certificate message.

5.3 Client Certificate Message (客户端 Certificate 消息)

如果 server 请求 client certificate, 且已接受 client_certificate_url, client MAY 发送扩展的 CertificateURL message. URL list 按偏好顺序排列, 每个 URL 指向单个 certificate 或 certificate sequence. Server MUST 支持 HTTP URL, MAY 支持 FTP 或 HTTPS. URL MUST NOT 指定非默认 port.

Server 可根据 individual_certspkipath 类型获取 certificate. 若 URLAndOptionalHash 中包含 hash, server MUST 验证获取到的 certificate 或 PkiPath 与给定 hash 匹配. 不匹配时 MUST 使用 bad_certificate_hash_value(114) alert 中止连接.

5.4 Certificate Hash Information (证书哈希信息)

Certificate URL 可包含对应 DER-encoded data 的 SHA-1 hash, 以便 server 复用缓存 certificate. 对 individual_certs, hash 覆盖单个 DER certificate. 对 pkipath, hash 覆盖完整 DER-encoded PkiPath sequence.

5.5 Server Processing (服务器处理)

Server 收到 CertificateURL 后 MUST 验证 message 格式正确, URL scheme 受支持, URL 不使用非默认 port, CertificateType 可理解, 且至少支持 X509. 如果 message malformed, server MUST 使用 decode_error 中止连接. 获取 certificate 后, server MUST 按 RFC 5246 执行标准 certificate validation.