2.19. 替换 Section 5.3.22 - Polling Request and Response
2.19. 替换 Section 5.3.22 - Polling Request and Response
[RFC4210] Section 5.3.22 描述 polling message 何时以及如何用于 ir, cr 和 kur message. 本文档将 outstanding response 的 polling mechanism 扩展到任何类型的 request message. 本次更新还修复术语 'pReq' 与 'pollReq', 以及 'pRep' 与 'pollRep' 使用不一致的问题.
将 [RFC4210] Section 5.3.22 替换为以下文本:
这一对 message 用于处理 client 需要轮询 server 以确定 outstanding response 状态的场景 (即已收到 "waiting" PKIStatus 时).
PollReqContent ::= SEQUENCE OF SEQUENCE {
certReqId INTEGER }
PollRepContent ::= SEQUENCE OF SEQUENCE {
certReqId INTEGER,
checkAfter INTEGER, -- time in seconds
reason PKIFreeText OPTIONAL }
响应 ir, cr, p10cr 或 kur request message 时, polling 由包含 status "waiting" 的 ip, cp 或 kup response message 启动. 对于任何类型的 request message, polling 都可以由 status 为 "waiting" 的 error response message 启动. 以下条款描述 polling message 的用法. 这里假定在 transaction 期间可以发送多个 certConf message. 对每个包含已签发 certificate 的 CertStatus 的 ip, cp 或 kup, 都会发送一个 certConf 作为响应.
-
响应 ip, cp 或 kup message 时, EE 将为所有已签发 certificate 发送 certConf, 并期望每个 certConf 都收到 PKIconf. 对 ip, cp 或 kup message 中每个 status 为 "waiting" 的 CertResponse 元素, 以及对 status 为 "waiting" 的 error message, EE 都会发送 pollReq message 作为响应. 其 certReqId MUST 是 status 为 "waiting" 的 CertResponse data structure 的索引, 或为 -1 以引用完整 response.
-
响应 pollReq 时, 如果仍处于 pending 的 requested certificate 中有一个或多个已经就绪, 或者某种其他 request type 的 final response 已可用, CA/RA 将返回 ip, cp 或 kup; 否则, 它将返回 pollRep.
-
如果 EE 收到 pollRep, 它将在发送另一个 pollReq 之前至少等待 checkAfter 字段给出的秒数.
-
如果 EE 收到 ip, cp 或 kup, 则按与 initial response 相同的方式处理; 如果收到任何其他 response, 则将其视为 original request 的 final response.
以下 client-side state machine 描述针对单个 CertResponse 元素的 polling.
START
|
v
Send ir
| ip
v
Check status
of returned <------------------------+
certs |
| |
+------------------------>|<------------------+ |
| | | |
| (issued) v (waiting) | |
Add to <----------- Check CertResponse ------> Add to |
conf list for each certificate pending list |
/ |
/ |
(conf list) / (empty conf list) |
/ ip |
/ +-----------------+
(empty pending list) / | pollRep
END <---- Send certConf Send pollReq---------->Wait
| ^ ^ |
| | | |
+-----------------+ +---------------+
(pending list)
在以下交换中, end entity 在一个 request 中注册两个 certificate.
Step End Entity PKI
--------------------------------------------------------------------
1 Format ir
2 -> ir ->
3 处理 ir
4 两个 cert 都需要
人工介入
5 <- ip <-
6 处理 ip
7 格式化 pollReq
8 -> pollReq ->
9 检查 cert request 状态
10 Certificate 尚未就绪
11 格式化 pollRep
12 <- pollRep <-
13 等待
14 格式化 pollReq
15 -> pollReq ->
16 检查 cert request 状态
17 一个 certificate 已就绪
18 格式化 ip
19 <- ip <-
20 处理 ip
21 格式化 certConf
22 -> certConf ->
23 处理 certConf
24 格式化 ack
25 <- pkiConf <-
26 格式化 pollReq
27 -> pollReq ->
28 检查 certificate 状态
29 Certificate 已就绪
30 格式化 ip
31 <- ip <-
31 处理 ip
32 格式化 certConf
33 -> certConf ->
34 处理 certConf
35 格式化 ack
36 <- pkiConf <-
以下 client-side state machine 描述针对完整 response message 的 polling.
Start
|
| Send request
|
+----------- Receive response ------------+
| |
| ip/cp/kup/error with | other
| status "waiting" | response
| |
v |
+------> Polling |
| | |
| | Send pollReq |
| | Receive response |
| | |
| pollRep | other response |
+-----------+------------------->+<-------------------+
|
v
End