/
213.txt
267 lines (197 loc) · 13.3 KB
/
213.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
* 仕様書
[REFS[
- [31] [CITE@en[RFC 2046 - Multipurpose Internet Mail Extensions (MIME) Part Two: Media Types]] ([TIME[2015-03-22 13:14:46 +09:00]] 版) <http://tools.ietf.org/html/rfc2046#section-5.1.4>
- [36] [CITE@en[RFC 2046 - Multipurpose Internet Mail Extensions (MIME) Part Two: Media Types]] ([TIME[2015-03-22 13:14:46 +09:00]] 版) <http://tools.ietf.org/html/rfc2046#section-5.2.3>
- [38] [CITE@en[RFC 2392 - Content-ID and Message-ID Uniform Resource Locators]] ([TIME[2015-06-21 16:39:07 +09:00]] 版) <https://tools.ietf.org/html/rfc2392>
- [39] [CITE[RFC Errata Report]] ([TIME[2015-06-24 13:52:46 +09:00]] 版) <http://www.rfc-editor.org/errata_search.php?rfc=2392>
]REFS]
* [CODE(MIME)@en[multipart/alternative]] における意味
[32] [CODE(MIME)@en[[[multipart/alternative]]]] の各[[本体部分]]は、
情報内容が同じでないなら、異なる [CODE(MIME)@en[[[Content-ID]]]]
とするべきです [SRC[>>31]]。
[33] 情報内容が同じ[[本体部分]]は、同じ [CODE(MIME)@en[[[Content-ID]]]]
でも構いません [SRC[>>31]]。
[EG[
[34] 例えば異なる方法でアクセスする [CODE(MIME)@en[[[message/external-body]]]]
同士は、同じ [CODE(MIME)@en[[[Content-ID]]]] にできます [SRC[>>31]]。
]EG]
[35] [CODE(MIME)@en[[[multipart/alternative]]]] 全体と各[[本体部分]]では、
異なる [CODE(MIME)@en[[[Content-ID]]]] とするべきです [SRC[>>31]]。
* [CODE(MIME)@en[message/external-body]]
[37] [CODE(MIME)@en[[[message/external-body]]]] の内側の[[ヘッダー]]では、
[CODE(MIME)@en[[[Content-ID]]]] は必須です [SRC[>>36]]。
* [CODE(URI)@en[cid:]] URL
[43] [CODE(URI)@en[[[cid:]]]] [[URL]] を使うと [CODE(MIME)@en[[[Content-ID]]]]
によって[[本体部分]]を識別できます。
[44] この [[URL]] は、同じ[[メッセージ]]中の[[本体部分]]を参照するために使えます
[SRC[>>38]]。
;; [45] 同じ[[メッセージ]]との制約しかありませんから、 [CODE(MIME)@en[[[multipart/*]]]]
の階層を超えて参照することはできると思われます。 [CODE(MIME)@en[[[message/rfc822]]]]
など [CODE(MIME)@en[[[message/*]]]] の壁を越えることはできないと思われます。
* [CODE(URI)@en[mid:]] URL
[46] [CODE(URI)@en[[[mid:]]]] [[URL]] には[[メッセージID]]に加えて
[CODE(MIME)@en[[[Content-ID]]]] を指定できます。異なる[[メッセージ]]であっても[[本体部分]]を識別できます。
;; [CODE(URI)@en[[[mid:]]]] を参照。
* 歴史
[FIG(quote)[
[FIGCAPTION[
[40] RFC 1340 6.1 Optional Content-ID Header Field
]FIGCAPTION]
> In constructing a high-level user agent, it may be desirable
to allow one body to make reference to another.
Accordingly, bodies may be labeled using the "Content-ID"
header field, which is syntactically identical to the
"Message-ID" header field:
[1] 高水準[[利用者エージェント]]の構築のために、ある[[本体]]が他の本体を参照可能にするのが望ましいかもしれません。
従って、本体は "Message-ID" 頭欄と構文的に同等の "Content-ID"
頭欄を使って札付けできます。
- [2] Content-ID := msg-id
> Like the Message-ID values, Content-ID values must be
generated to be as unique as possible.
[3] Message-ID 値同様、 Content-ID 値は可能な限り固有であるように生成しなければなりません。
]FIG]
[FIG(quote)[
[FIGCAPTION[
[41] RFC 1521 6.1. Optional Content-ID Header Field
]FIGCAPTION]
> In constructing a high-level user agent, it may be desirable to allow
one body to make reference to another. Accordingly, bodies may be
labeled using the "Content-ID" header field, which is syntactically
identical to the "Message-ID" header field:
[8] 高水準[[利用者エージェント]]の構築のために、ある[[本体]]が他の本体を参照可能にするのが望ましいかもしれません。
従って、本体は "Message-ID" 頭欄と構文的に同等の "Content-ID"
頭欄を使って札付けできます。
- [4] id := "Content-ID" ":" msg-id
> Like the Message-ID values, Content-ID values must be generated to be
world-unique.
[5] Message-ID 値同様、 Content-ID 値は世界的に固有であるように生成しなければなりません。
> The Content-ID value may be used for uniquely identifying MIME
entities in several contexts, particularly for cacheing data
referenced by the message/external-body mechanism. Although the
Content-ID header is generally optional, its use is mandatory in
implementations which generate data of the optional MIME Content-type
"message/external-body". That is, each message/external-body entity
must have a Content-ID field to permit cacheing of such data.
[6] Content-ID 値は幾つかの文脈で [[MIME]]
[[実体]]を唯一的に特定するために使われ得ます。
とりわけ message/external-body
の仕組みでは参照データのキャッシュのために使われます。
Content-ID 頭は一般に省略可能ですが、任意の MIME
内容型 "message/external-body"
のデータを生成する実装には使用することを強制します。
つまり、各 message/external-body 実体は必ず Content-ID
欄を持ってそうしたデータのキャッシュを可能にしなければなりません。
> It is also worth noting that the Content-ID value has special
semantics in the case of the multipart/alternative content-type.
This is explained in the section of this document dealing with
multipart/alternative.
[7] Content-ID 値は multipart/alternative
内容型の場合に特別な意味を持つことにも注意しておく必要があります。
これはこの文書の multipart/alternative の処理の節で説明しています。
[INS[
訳注: [[message/external-body媒体型]]及び
[[mulipart/alternative媒体型]]を参照。
]INS]
]FIG]
[FIG(quote)[
[FIGCAPTION[
[42] RFC 2045 7. Content-ID Header Field
]FIGCAPTION]
> In constructing a high-level user agent, it may be desirable to allow
one body to make reference to another. Accordingly, bodies may be
labelled using the "Content-ID" header field, which is syntactically
identical to the "Message-ID" header field:
[9] 高水準[[利用者エージェント]]の構築のために、ある[[本体]]が他の本体を参照可能にするのが望ましいかもしれません。
従って、本体は "Message-ID" 頭欄と構文的に同等の "Content-ID"
頭欄を使って札付けできます。
- [10] id := "Content-ID" ":" msg-id
> Like the Message-ID values, Content-ID values must be generated to be
world-unique.
[11] Message-ID 値同様、 Content-ID 値は世界的に固有であるように生成しなければなりません。
> The Content-ID value may be used for uniquely identifying MIME
entities in several contexts, particularly for caching data
referenced by the message/external-body mechanism. Although the
Content-ID header is generally optional, its use is MANDATORY in
implementations which generate data of the optional MIME media type
"message/external-body". That is, each message/external-body entity
must have a Content-ID field to permit caching of such data.
[12] Content-ID 値は幾つかの文脈で [[MIME]]
[[実体]]を唯一的に特定するために使われ得ます。
とりわけ message/external-body
の仕組みでは参照データのキャッシュのために使われます。
Content-ID 頭は一般に省略可能ですが、任意の MIME
内容型 "message/external-body"
のデータを生成する実装には使用することを強制します。
つまり、各 message/external-body 実体は必ず Content-ID
欄を持ってそうしたデータのキャッシュを可能にしなければなりません。
> It is also worth noting that the Content-ID value has special
semantics in the case of the multipart/alternative media type. This
is explained in the section of RFC 2046 dealing with
multipart/alternative.
[13] Content-ID 値は multipart/alternative
内容型の場合に特別な意味を持つことにも注意しておく必要があります。
これはこの文書の multipart/alternative の処理の節で説明しています。
;; [50] [[訳注]]: [[message/external-body媒体型]]及び
[[multipart/alternative媒体型]]を参照。
]FIG]
* メモ
- [14] [WEAK[2002-12-10 (火) 20:19]] ''[[名無しさん]]'': CID を未だに正しく使わない [[UA]] があります。特に [[M$]] 製品, 例えば [[Windoze]] XP 付属の [[M$NExplorer]] の「ようこそ」メッセージは、画像[[部分]]の Content-ID: 欄の値を foo.gif のような名前にし、 [[HTML]] 部分の [[img要素]]の [[src属性]]を cid:foo.gif とするような'''激しい規格違反'''を平気でしています。どうせ M$ のことですから、[[プロトコルの脱共有化]]かなんかの一環として積極的にやってるんでしょう。
- [15] [[HTML+]] では、複数部分で form 入力を送る時に [CODE[Content-ID:]] 欄を [[URI]] として使う云々と言っています (''Sending form data to an HTTP server'' <http://www.w3.org/MarkUp/HTMLPlus/htmlplus_42.html>)。 [[cid:]] URI が規定される前ですし、 [[HTTP]] の [[Message-ID:]] 欄は [[URI]] を指定するとされていたことから考えても、この当時から [CODE[Content-ID:]] 欄に URI を入れようと考えていたことが推察されます。 (ただ例示がないので確かではありません。)
- [16] >>15 これは実装されてたんでしょうかね? [[Arena]] とかで。
[17] [CITE@en[RFC 5621 - Message Body Handling in the Session Initiation Protocol (SIP)]]
([TIME[2009-09-12 07:37:40 +09:00]] 版)
<http://tools.ietf.org/html/rfc5621#section-9.2>
[18] [CITE@ja[デコメ。auのContent-IDの制約。@はひとつだけ。 - CPA-LABテクニカル]]
([TIME[2009-10-16 09:00:00 +09:00]] 版)
<http://www.cpa-lab.com/tech/0135>
[19] [CITE@en[RFC 4463 - A Media Resource Control Protocol (MRCP) Developed by Cisco, Nuance, and Speechworks]]
( ([TIME[2011-12-04 10:31:11 +09:00]] 版))
<http://tools.ietf.org/html/rfc4463#section-5.4.5>
[20] [CITE@en[RFC 4975 - The Message Session Relay Protocol (MSRP)]]
( ([TIME[2012-02-26 13:20:50 +09:00]] 版))
<http://tools.ietf.org/html/rfc4975#page-38>
[21] [CITE@en[RFC 6787 - Media Resource Control Protocol Version 2 (MRCPv2)]]
( ([TIME[2012-11-13 15:18:40 +09:00]] 版))
<http://tools.ietf.org/html/rfc6787#section-6.2.7>
[REFS[
- [22] [CITE[OData Version 4.0 Part 1: Protocol Plus Errata 01]] ([TIME[2014-09-04 16:00:00 +09:00]] 版) <http://docs.oasis-open.org/odata/odata/v4.0/odata-v4.0-part1-protocol.html#_Toc370374937>
]REFS]
[23] >>22 も正しくない [CODE(MIME)@en[[[Content-ID:]]]] の例を示しています。
[24] [CITE@en[RFC 5547 - A Session Description Protocol (SDP) Offer/Answer Mechanism to Enable File Transfer]]
( ([TIME[2014-09-13 18:22:39 +09:00]] 版))
<https://tools.ietf.org/html/rfc5547#section-6>
[28] [[DRP]] は [[HTTPヘッダー]]として、値が [[URL]] である [CODE(HTTP)@en[[[Content-ID:]]]]
[[ヘッダー]]を提案していました [SRC[>>25]]。
[REFS[
- [25] [CITE[The HTTP Distribution and Replication Protocol]]
( ([TIME[1999-02-05 02:56:54 +09:00]] 版))
<http://www.w3.org/TR/NOTE-drp>
- [26] [CITE@en[RFC 4229 - HTTP Header Field Registrations]] ([TIME[2014-11-02 18:53:20 +09:00]] 版) <http://tools.ietf.org/html/rfc4229#section-2.1.24>
]REFS]
[27] [[RFC 4229]] は [[DRP]] [SRC[>>25]] を出典に [[HTTPヘッダー]]の
[[IANA登録簿]]に状態「[[情報提供]]」で登録しています [SRC[>>26]]。
[29] [CITE@en[RFC 2392 - Content-ID and Message-ID Uniform Resource Locators]]
( ([TIME[2014-12-22 15:20:11 +09:00]] 版))
<https://tools.ietf.org/html/rfc2392>
[30] [CITE@en-US[Batch Requests | ArangoDB Documentation]]
( ([TIME[2015-01-13 16:43:59 +09:00]] 版))
<https://docs.arangodb.com/HttpBatchRequest/README.html>
[47] [CITE@en[RFC 5621 - Message Body Handling in the Session Initiation Protocol (SIP)]]
([TIME[2015-06-21 16:17:31 +09:00]] 版)
<https://tools.ietf.org/html/rfc5621>
[FIG(quote)[
[FIGCAPTION[
[48] [CITE@en[Batching Requests | Gmail API | Google Developers]]
([TIME[2015-10-08 03:21:07 +09:00]] 版)
<https://developers.google.com/gmail/api/guides/batch>
]FIGCAPTION]
> If a given part of the request had a Content-ID header, then the corresponding part of the response has a matching Content-ID header, with the original value preceded by the string response-, as shown in the following example.
]FIG]
[FIG(quote)[
[FIGCAPTION[
[49] [CITE@ja[Google アナリティクス API リクエストのバッチ処理 | アナリティクス Real Time Reporting API | Google Developers]]
( ([TIME[2016-09-30 03:30:47 +09:00]]))
<https://developers.google.com/analytics/devguides/reporting/realtime/v3/batching>
]FIGCAPTION]
> リクエストのパーツに Content-ID ヘッダーがある場合、対応する応答のパーツには、それに一致する Content-ID ヘッダーが指定されます。応答のパーツのヘッダーは、以下の例に示すように、元の値の先頭に文字列 response- が付いた値となります。
]FIG]