idnits 2.17.1 draft-ietf-nfsv4-rpcsec-gssv3-06.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 329 has weird spacing: '...ned int ver...' == Line 343 has weird spacing: '...ss3_lfs lfs...' == Line 360 has weird spacing: '...3_label label...' == Line 362 has weird spacing: '...3_privs privs...' -- The document date (October 17, 2013) is 3842 days in the past. Is this intentional? -- Found something which looks like a code comment -- if you have code sections in the document, please surround them with '' and '' lines. Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) -- Possible downref: Non-RFC (?) normative reference: ref. '1' ** Obsolete normative reference: RFC 1831 (ref. '4') (Obsoleted by RFC 5531) == Outdated reference: A later version (-41) exists of draft-ietf-nfsv4-minorversion2-19 ** Obsolete normative reference: RFC 5226 (ref. '8') (Obsoleted by RFC 8126) == Outdated reference: A later version (-05) exists of draft-ietf-nfsv4-labreqs-03 Summary: 2 errors (**), 0 flaws (~~), 7 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 NFSv4 W. Adamson 3 Internet-Draft NetApp 4 Intended status: Standards Track N. Williams 5 Expires: April 20, 2014 Cryptonector 6 October 17, 2013 8 Remote Procedure Call (RPC) Security Version 3 9 draft-ietf-nfsv4-rpcsec-gssv3-06.txt 11 Abstract 13 This document specifies version 3 of the Remote Procedure Call (RPC) 14 security protocol (RPCSEC_GSS). This protocol provides for compound 15 authentication of client hosts and users to server (constructed by 16 generic composition), security label assertions for multi-level and 17 type enforcement, structured privilege assertions, and channel 18 bindings. 20 Requirements Language 22 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 23 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 24 document are to be interpreted as described in RFC 2119 [1]. 26 Status of this Memo 28 This Internet-Draft is submitted in full conformance with the 29 provisions of BCP 78 and BCP 79. 31 Internet-Drafts are working documents of the Internet Engineering 32 Task Force (IETF). Note that other groups may also distribute 33 working documents as Internet-Drafts. The list of current Internet- 34 Drafts is at http://datatracker.ietf.org/drafts/current/. 36 Internet-Drafts are draft documents valid for a maximum of six months 37 and may be updated, replaced, or obsoleted by other documents at any 38 time. It is inappropriate to use Internet-Drafts as reference 39 material or to cite them other than as "work in progress." 41 This Internet-Draft will expire on April 20, 2014. 43 Copyright Notice 45 Copyright (c) 2013 IETF Trust and the persons identified as the 46 document authors. All rights reserved. 48 This document is subject to BCP 78 and the IETF Trust's Legal 49 Provisions Relating to IETF Documents 50 (http://trustee.ietf.org/license-info) in effect on the date of 51 publication of this document. Please review these documents 52 carefully, as they describe your rights and restrictions with respect 53 to this document. Code Components extracted from this document must 54 include Simplified BSD License text as described in Section 4.e of 55 the Trust Legal Provisions and are provided without warranty as 56 described in the Simplified BSD License. 58 Table of Contents 60 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 61 1.1. Applications of RPCSEC_GSSv3 . . . . . . . . . . . . . . . 4 62 2. The RPCSEC_GSSv3 Protocol . . . . . . . . . . . . . . . . . . 5 63 2.1. New auth_stat Values . . . . . . . . . . . . . . . . . . . 9 64 2.2. RPC Message Credential and Verifier . . . . . . . . . . . 10 65 2.3. Control Messages . . . . . . . . . . . . . . . . . . . . . 10 66 2.3.1. Create Request . . . . . . . . . . . . . . . . . . . . 11 67 2.3.2. Destruction Request . . . . . . . . . . . . . . . . . 15 68 2.3.3. List Request . . . . . . . . . . . . . . . . . . . . . 15 69 2.3.4. Extensibility . . . . . . . . . . . . . . . . . . . . 16 70 2.4. Data Messages . . . . . . . . . . . . . . . . . . . . . . 16 71 3. Security Considerations . . . . . . . . . . . . . . . . . . . 17 72 4. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 18 73 5. References . . . . . . . . . . . . . . . . . . . . . . . . . . 18 74 5.1. Normative References . . . . . . . . . . . . . . . . . . . 18 75 5.2. Informative References . . . . . . . . . . . . . . . . . . 19 76 Appendix A. Acknowledgments . . . . . . . . . . . . . . . . . . . 19 77 Appendix B. RFC Editor Notes . . . . . . . . . . . . . . . . . . 19 78 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 19 80 1. Introduction 82 The original RPCSEC_GSS protocol [2] provided for authentication of 83 RPC clients and servers to each other using the Generic Security 84 Services Application Programming Interface (GSS-API) [3]. The second 85 version of RPCSEC_GSS [4] added support for channel bindings [5]. 87 We find that GSS-API mechanisms are insufficient for communicating 88 certain aspects of a client's authority to a server. The GSS-API and 89 its mechanisms certainly could be extended to address this 90 shortcoming, but it seems be far simpler to address it at the 91 application layer, namely, in this case, RPCSEC_GSS. 93 The motivation for RPCSEC_GSSv3 is to add support for labeled 94 security and server-side copy for NFSv4 (see [6] and [9]). Both of 95 these features require assertions of authority from the client. 97 Assertions need to be verified. One party that can verify an 98 assertion is the client host, which can authenticate to the server 99 using its own credentials. We can also require users to verify an 100 assertion as well. This calls for compound authentication. 102 Because the design of RPCSEC_GSSv3 relies on either RPCSEC_GSS 103 version 1 (though version 2 can be used) to do the actual GSS-API 104 security context establishment, we add support for channel binding so 105 that implementors who have implemented RPCSEC_GSS version 1 but not 106 version 2 can provide a (simplified) channel binding implementation 107 using RPCSEC_GSSv3. 109 We therefore describe a new version of RPCSEC_GSS that allows for the 110 following client-side assertions of authority: 112 o Security labels for multi-level, type enforcement, and other 113 labeled security models. See [10], [11], [12], [6] and [9]. 115 o Application-specific structured privileges. For an example see 116 server-side copy [6]. 118 o Compound authentication of the client host and user to the server 119 done by binding two RPCSEC_GSS handles. 121 o Simplified channel binding. 123 Assertions of labels and privileges are evaluated by the server, 124 which may then map the asserted values to other values, all according 125 to server-side policy. 127 We add an option for enumerating server supported label format 128 specifiers (LFS). The LFS and Label Format Registry are described in 129 detail in [13]. 131 RPCSEC_GSSv3 is patterned as follows: 133 o A client uses an existing RPCSEC_GSSv1 (or RPCSEC_GSSv2) context 134 handle to protect RPCSEC_GSSv3 exchanges (this will be termed the 135 "parent" handle) 137 o The server issues a "child" RPCSEC_GSSv3 handle which uses the 138 underlying GSS-API security context of the parent handle in all 139 subsequent exchanges that uses the child handle. 141 o The child handle, however, has its own sequence number space 142 distinct from that of the parent. 144 [[Comment.1: I removed the "child has a window distinct from that of 145 the parent" because RFC2203 states: " In a successful response, the 146 seq_window field is set to the sequence window length supported by 147 the server for this context. This window specifies the maximum 148 number of client requests that may be outstanding for this context." 149 If we want a distinct window, we will need to add that to the 150 rpc_gss3_create_res so that the server can set it. I see no point - 151 just use the parent window. --AA]] 153 [[Comment.2: RFC2203 states that when data integrity is used, the 154 seq_num in the rpc_gss_data_t must be the same as in the credential. 155 This means that using data integrity with GSS3 context's can not 156 simply construct it using the parent context as the seq_num must be 157 from the GSS3 context. --AA]] 159 This means that RPCSEC_GSSv3 depends on an existing parent 160 RPCSEC_GSSv1 or RPCSEC_GSSv2 context for actual GSS-API security 161 context establishment. This keeps the specification of RPCSEC_GSSv3 162 simple by avoiding the need to duplicate the core functionality of 163 RPCSEC_GSS version 1. This also means that an RPCSEC_GSSv3 context 164 MUST be destroyed prior to it's parent context being destroyed. 166 [[Comment.3: Destruction of the parent context => first destroy child 167 handle. IOW fail the RPCSEC_GSS_DESTROY of parent with new 168 RPCSEC_GSS3_CONTEXT_EXISTS error code OR upon the destruction of the 169 parent context destroy any associated RPCSEC_GSSv3 contexts OR..... 170 --AA]] 172 1.1. Applications of RPCSEC_GSSv3 174 The common uses of RPCSEC_GSSv3, particularly for NFSv4 [6], are 175 expected to be: 177 a. labeled security: client-side process label assertion [+ 178 privilege assertion] + compound client host & user 179 authentication; 181 b. inter-server server-side copy: compound client host & user 182 authentication [+ critical structured privilege assertions] 184 Labeled NFS (see Section 8 of [6]) uses the subject label provided by 185 the client via the RPCSEC_GSSv3 layer to enforce MAC access to 186 objects owned by the server to enable server guest mode or full mode 187 labeled NFS. 189 [[Comment.4: check that this language states what NFSv4.2 labeled NFS 190 problem we are really solving. (setting labels on the server) --AA]] 192 A traditional inter-server file copy entails the user gaining access 193 to a file on the source, reading it, and writing it to a file on the 194 destination. In secure NFSv4 inter-server server-side copy (see 195 Section 3.4.1 of [6]), the user first secures access to both source 196 and destination files, and then uses RPCSEC_GSSv3 compound 197 authentication and structured privileges to authorize the destination 198 to copy the file from the source on behalf of the user. 200 2. The RPCSEC_GSSv3 Protocol 202 This document contains the External Data Representation (XDR) ([7]) 203 definitions for the RPCSEC_GSSv3 protocol. 205 The XDR description is provided in this document in a way that makes 206 it simple for the reader to extract into ready to compile form. The 207 reader can feed this document in the following shell script to 208 produce the machine readable XDR description of RPCSEC_GSSv3: 210 #!/bin/sh 211 grep "^ *///" | sed 's?^ */// ??' | sed 's?^ *///$??' 213 I.e. if the above script is stored in a file called "extract.sh", and 214 this document is in a file called "spec.txt", then the reader can do: 216 sh extract.sh < spec.txt > rpcsec_gss_v3.x 218 The effect of the script is to remove leading white space from each 219 line, plus a sentinel sequence of "///". 221 The XDR description, with the sentinel sequence follows: 223 /// /* 224 /// * Copyright (c) 2013 IETF Trust and the persons 225 /// * identified as the document authors. All rights 226 /// * reserved. 227 /// * 228 /// * The document authors are identified in [RFC2203], 229 /// * [RFC5403], and [RFCxxxx]. 230 /// * 231 /// * Redistribution and use in source and binary forms, 232 /// * with or without modification, are permitted 233 /// * provided that the following conditions are met: 234 /// * 235 /// * o Redistributions of source code must retain the above 236 /// * copyright notice, this list of conditions and the 237 /// * following disclaimer. 238 /// * 239 /// * o Redistributions in binary form must reproduce the 240 /// * above copyright notice, this list of 241 /// * conditions and the following disclaimer in 242 /// * the documentation and/or other materials 243 /// * provided with the distribution. 244 /// * 245 /// * o Neither the name of Internet Society, IETF or IETF 246 /// * Trust, nor the names of specific contributors, may be 247 /// * used to endorse or promote products derived from this 248 /// * software without specific prior written permission. 249 /// * 250 /// * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 251 /// * AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED 252 /// * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 253 /// * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 254 /// * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 255 /// * EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 256 /// * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 257 /// * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 258 /// * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 259 /// * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 260 /// * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 261 /// * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 262 /// * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING 263 /// * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 264 /// * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 265 /// */ 266 /// 267 /// /* 268 /// * This code was derived from [RFC2203]. Please 269 /// * reproduce this note if possible. 270 /// */ 271 /// 272 /// /* 273 /// * rpcsec_gss_v3.x 274 /// */ 275 /// 276 /// enum rpc_gss_service_t { 277 /// /* Note: the enumerated value for 0 is reserved. */ 278 /// rpc_gss_svc_none = 1, 279 /// rpc_gss_svc_integrity = 2, 280 /// rpc_gss_svc_privacy = 3, 281 /// rpc_gss_svc_channel_prot = 4 282 /// }; 283 /// 284 /// enum rpc_gss_proc_t { 285 /// RPCSEC_GSS_DATA = 0, 286 /// RPCSEC_GSS_INIT = 1, 287 /// RPCSEC_GSS_CONTINUE_INIT = 2, 288 /// RPCSEC_GSS_DESTROY = 3, 289 /// RPCSEC_GSS_BIND_CHANNEL = 4 290 /// }; 291 /// 292 /// struct rpc_gss_cred_vers_1_t { 293 /// rpc_gss_proc_t gss_proc; /* control procedure */ 294 /// unsigned int seq_num; /* sequence number */ 295 /// rpc_gss_service_t service; /* service used */ 296 /// opaque handle<>; /* context handle */ 297 /// }; 298 /// 299 /// enum rpc_gss3_proc_t { 300 /// RPCSEC_GSS3_DATA = 0, 301 /// RPCSEC_GSS3_LIST = 5, 302 /// RPCSEC_GSS3_CREATE = 6, 303 /// RPCSEC_GSS3_DESTROY = 7 304 /// }; 305 /// 306 /// struct rpc_gss_cred_vers_3_t { 307 /// rpc_gss3_proc_t gss_proc; 308 /// unsigned int seq_num; 309 /// rpc_gss_service_t service; 310 /// opaque handle<>; 311 /// }; 312 /// 313 /// const RPCSEC_GSS_VERS_1 = 1; 314 /// const RPCSEC_GSS_VERS_2 = 2; 315 /// const RPCSEC_GSS_VERS_3 = 3; /* new */ 316 /// 317 /// union rpc_gss_cred_t switch (unsigned int rgc_version) { 318 /// case RPCSEC_GSS_VERS_1: 319 /// case RPCSEC_GSS_VERS_2: 321 /// rpc_gss_cred_vers_1_t rgc_cred_v1; 322 /// case RPCSEC_GSS_VERS_3: /* new */ 323 /// rpc_gss_cred_vers_3_t rgc_cred_v3; 324 /// }; 325 /// 326 /// const MAXSEQ = 0x80000000; 327 /// 328 /// struct rpc_gss3_gss_binding { 329 /// unsigned int vers; 330 /// opaque handle<>; 331 /// opaque nonce<>; 332 /// opaque mic<>; 333 /// }; 334 /// 335 /// typedef opaque rpc_gss3_chan_binding<>; 336 /// 337 /// struct rpc_gss3_lfs { 338 /// unsigned int lfs_id; 339 /// unsigned int pi_id; 340 /// }; 341 /// 342 /// struct rpc_gss3_label { 343 /// rpc_gss3_lfs lfs; 344 /// opaque label<>; 345 /// }; 346 /// 347 /// struct rpc_gss3_privs { 348 /// string name; /* human readable */ 349 /// opaque privilege<>; 350 /// }; 351 /// 352 /// enum rpc_gss3_assertion_type { 353 /// LABEL = 0, 354 /// PRIVS = 1 355 /// }; 356 /// 357 /// union rpc_gss3_assertion_u 358 /// switch (rpc_gss3_assertion_type atype) { 359 /// case LABEL: 360 /// rpc_gss3_label label; 361 /// case PRIVS: 362 /// rpc_gss3_privs privs; 363 /// default: 364 /// opaque ext<>; 365 /// }; 366 /// 367 /// struct rpc_gss3_assertion { 368 /// bool critical; 369 /// rpc_gss3_assertion_u assertion; 370 /// }; 371 /// 372 /// struct rpc_gss3_create_args { 373 /// rpc_gss3_gss_binding *compound_binding; 374 /// rpc_gss3_chan_binding *chan_binding_mic; 375 /// rpc_gss3_assertion assertions<>; 376 /// }; 377 /// 378 /// struct rpc_gss3_create_res { 379 /// opaque handle<>; 380 /// rpc_gss3_chan_binding *chan_binding_mic; 381 /// rpc_gss3_assertion granted_assertions<>; 382 /// }; 383 /// 384 /// enum rpc_gss3_list_item { 385 /// LABEL = 0, 386 /// }; 387 /// 388 /// struct rpc_gss3_list_args { 389 /// rpc_gss3_list_item list_what<>; 390 /// }; 391 /// 392 /// union rpc_gss3_list_item_u 393 /// switch (rpc_gss3_list_item itype) { 394 /// case LABEL: 395 /// rpc_gss3_lable labels<>; 396 /// default: 397 /// opaque ext<>; 398 /// }; 399 /// 400 /// typedef rpc_gss3_list_item_u rpc_gss3_list_res<>; 402 2.1. New auth_stat Values 404 RPCSEC_GSSv3 requires the addition of several values to the auth_stat 405 enumerated type definition: 407 enum auth_stat { 408 ... 409 /* 410 * RPCSEC_GSSv3 errors 411 */ 412 RPCSEC_GSS3_COMPOUND_PROBEM = <>, 413 RPCSEC_GSS3_LABEL_PROBLEM = <>, 414 RPCSEC_GSS3_UNKNOWN_PRIVILEGE = <> 415 RPCSEC_GSS3_UNKNOWN_MESSAGE = <> 416 }; 418 [[Comment.5: fix above into YYY. All the entries are TBD... --NW]] 419 [[Comment.6: The compound authentication problems are: can't find the 420 handle plus handle version on the target, or the MIC of the nounce 421 does not match. Both of these errors already have auth_stat entries: 422 RPCSEC_GSS_CREDPROBLEM for the first and "reply status of 423 MSG_ACCEPTED, and an acceptance status of GARBAGE_ARGS." --AA]] 425 2.2. RPC Message Credential and Verifier 427 The rpc_gss_cred_vers_3_t type is used in much the same way that 428 rpc_gss_cred_vers_1_t is used in RPCSEC_GSSv1, that is: as the arm of 429 the rpc_gss_cred_t discriminated union in the RPC message header 430 opaque_auth structure corresponding to version 3 (RPCSEC_GSS_VERS_3). 431 It differs from rpc_gss_cred_vers_1_t in that: 433 a. the values for gss_proc corresponding to control messages are 434 different. 436 b. the handle field is the RPCSEC_GSSv3 (child) handle, except for 437 the RPCSEC_GSS3_CREATE and RPCSEC_GSS3_LIST control messages 438 where it is set to the parent context handle. 440 For all RPCSEC_GSSv3 data and control messages, the verifier field in 441 the RPC message header is constructed in the RPCSEC_GSSv1 manner 442 using the parent GSS-API security context. 444 2.3. Control Messages 446 There are three RPCSEC_GSSv3 control messages: RPCSEC_GSS3_CREATE, 447 RPCSEC_GSS3_DESTROY, and RPCSEC_GSS3_LIST. 449 RPCSEC_GSSv3 control messages are similar to the RPCSEC_GSSv1 450 RPCSEC_GSS_DESTROY control message (see section 5.4 [2]) in that the 451 sequence number in the request must be valid, and the header checksum 452 in the verifier must be valid. In other words, they look a lot like 453 an RPCSEC_GSSv3 data message with the header procedure set to 454 NULLPROC. 456 As in RPCSEC_GSSv1, the RPCSEC_GSSv3 control messages may contain 457 information following the verifier in the body of the NULLPROC 458 procedure. 460 The client MUST use one of the following security services to protect 461 any RPCSEC_GSSv3 control message: 463 o rpc_gss_svc_channel_prot (see RPCSEC_GSSv2) 464 o rpc_gss_svc_integrity 466 o rpc_gss_svc_privacy 468 Specifically the client MUST NOT use rpc_gss_svc_none. 470 For RPCSEC_GSSv3 control messages the rpc_gss_cred_vers_3_t in the 471 RPC message opaque_auth structure is encoded as follows: 473 o the union rpc_gss_cred_t version is set to 3 with the value being 474 of type rpc_gss_cred_vers_3_t instead of rpc_gss_cred_vers_1_t. 476 o the gss_proc is set to one of RPCSEC_GSS3_CREATE, 477 RPCSEC_GSS3_DESTROY, or RPCSEC_GSS3_LIST. 479 o the seq_num is a valid sequence number for the context in the 480 handle field. 482 o the rpc_gss_service_t is one of rpc_gss_svc_integrity, 483 rpc_gss_svc_privacy, or rpc_gss_svc_channel_prot. 485 o the rpc_gss_cred_vers_3_t handle field is either set to the parent 486 context handle for RPCSEC_GSS3_CREATE and RPCSEC_GSS3_LIST, or to 487 the GSS3 child handle for RPCSEC_GSS3_DESTROY. 489 2.3.1. Create Request 491 As noted in the introduction, RPCSEC_GSSv3 relies on the RPCSEC_GSS 492 version 1 parent context (though version 2 can be used) secure 493 connection to do the actual GSS-API GSS3 security context 494 establishment. As such, for the RPCSEC_GSS3_CREATE request, the 495 rpc_gss_cred_vers_3_t fields in the RPC Call opaque_auth use the 496 parent context handle and seq_num stream. 498 The RPCSEC_GSS3_CREATE call message binds one or more items of 499 several kinds into a new RPCSEC_GSSv3 context handle: 501 o another RPCSEC_GSS (version 1, 2, or 3) context handle (compound 502 authentication) 504 o a channel binding 506 o authorization assertions (labels, privileges) 508 The reply to this message consists of either an error or an 509 rpc_gss3_create_res structure which includes a new RPCSEC_GSSv3 510 handle, termed the "child" which is used for subsequent control and 511 data messages. 513 Upon successful RPCSEC_GSS3_CREATE, both the client and the server 514 should associate the resultant GSSv3 child context handle with the 515 parent context handle in their GSS context caches so as to be able to 516 reference the parent context given the child context handle. 518 Server implementation and policy MAY result in labels, privileges, 519 and identities being mapped to concepts and values that are local to 520 the server. Server policies should take into account the identity of 521 the client and/or user as authenticated via the GSS-API. 523 2.3.1.1. Compound Authentication 525 RPCSEC_GSSv3 allows for compound authentication of client hosts and 526 users to servers. As in non-compound authentication, there is a 527 parent handle used to protect the RPCSEC_GSS3_CREATE call message and 528 a resultant RPCSEC_GSSv3 child handle. In addition to the parent 529 handle, the compound authentication create control message has a 530 handle referenced via the compound_binding field of the 531 RPCSEC_GSS3_CREATE arguments structure (rpc_gss3_create_args) termed 532 the "inner" handle, as well as a nonce and a MIC of that nounce 533 created using the GSS-API security context associated with the 534 "inner" handle. 536 This feature is needed, for example, when a client wishes to use 537 authority assertions that the server may only grant if a user and a 538 client are authenticated together to the server. Thus a server may 539 refuse to grant requested authority to a user acting alone (e.g., via 540 an unprivileged user-space program), or to a client acting alone 541 (e.g. when a client is acting on behalf of a user) but may grant 542 requested authority to a client acting on behalf of a user if the 543 server identifies the user and trusts the client. 545 It is assumed that an unprivileged user-space program would not have 546 access to client host credentials needed to establish a GSS-API 547 security context authenticating the client to the server, therefore 548 an unprivileged user-space program could not create an RPCSEC_GSSv3 549 RPCSEC_GSS3_CREATE message that successfully binds a client and a 550 user security context. 552 Clients using RPCSEC_GSS context binding MUST use, as the parent 553 context handle, an RPCSEC_GSS context handle that corresponds to a 554 GSS-API security context that authenticates the client host, and for 555 the inner context handle it SHOULD use a context handle to 556 authenticate a user. The reverse (parent handle authenticates user, 557 inner authenticates client) MUST NOT be used. Other compounds might 558 eventually make sense. 560 An RPCSEC_GSSv3 context handle that is bound to another RPCSEC_GSS 561 context MUST be treated by servers as authenticating the GSS-API 562 initiator principal authenticated by the inner context handle's GSS- 563 API security context. This principal may be mapped to a server-side 564 notion of user or principal. 566 2.3.1.2. Channel Binding 568 RPCSEC_GSSv3 provides a different way to do channel binding than 569 RPCSEC_GSSv2. Specifically: 571 a. RPCSEC_GSSv3 builds on RPCSEC_GSSv1 by reusing existing, 572 established context handles rather than providing a different RPC 573 security flavor for establishing context handles, 575 b. channel bindings data are not hashed because the community now 576 agrees that it is the secure channel's responsibility to produce 577 channel bindings data of manageable size. 579 (a) is useful in keeping RPCSEC_GSSv3 simple in general, not just for 580 channel binding. (b) is useful in keeping RPCSEC_GSSv3 simple 581 specifically for channel binding. 583 Channel binding is accomplished as follows. The client prefixes the 584 channel bindings data octet string with the channel type as described 585 in [5], then the client calls GSS_GetMIC() to get a MIC of resulting 586 octet string, using the parent RPCSEC_GSS context handle's GSS-API 587 security context. The MIC is then placed in the chan_binding_mic 588 field of RPCSEC_GSS3_CREATE arguments (rpc_gss3_create_args). 590 If the chan_binding_mic field of the arguments of a 591 RPCSEC_GSS3_CREATE control message is set, then the server MUST 592 verify the client's channel binding MIC if the server supports this 593 feature. If channel binding verification succeeds then the server 594 MUST generate a new MIC of the same channel bindings and place it in 595 the chan_binding_mic field of the RPCSEC_GSS3_CREATE results. If 596 channel binding verification fails or the server doesn't support 597 channel binding then the server MUST indicate this in its reply by 598 not including a chan_binding_mic value (chan_binding_mic is an 599 optional field). 601 The client MUST verify the result's chan_binding_mic value, if the 602 server included it, by calling GSS_VerifyMIC() with the given MIC and 603 the channel bindings data (including the channel type prefix). If 604 client-side channel binding verification fails then the client MUST 605 call RPCSEC_GSS3_DESTROY. If the client requested channel binding 606 but the server did not include a chan_binding_mic field in the 607 results, then the client MAY continue to use the resulting context 608 handle as though channel binding had never been requested, otherwise 609 (if the client really wanted channel binding) it MUST call 610 RPCSEC_GSS3_DESTROY. 612 As per-RPCSEC_GSSv2 [4]: 614 "Once a successful [channel binding] procedure has been performed 615 on an [RPCSEC_GSSv3] context handle, the initiator's 616 implementation may map application requests for rpc_gss_svc_none 617 and rpc_gss_svc_integrity to rpc_gss_svc_channel_prot credentials. 618 And if the secure channel has privacy enabled, requests for 619 rpc_gss_svc_privacy can also be mapped to 620 rpc_gss_svc_channel_prot." 622 Any RPCSEC_GSSv3 context handle that has been bound to a secure 623 channel in this way SHOULD be used only with the 624 rpc_gss_svc_channel_prot, and SHOULD NOT be used with 625 rpc_gss_svc_none nor rpc_gss_svc_integrity -- if the secure channel 626 does not provide privacy protection then the client MAY use 627 rpc_gss_svc_privacy where privacy protection is needed or desired. 629 2.3.1.3. Label Assertions 631 RPCSEC_GSSv3 clients MAY assert a security label in some LSF by 632 binding this assertion into an RPCSEC_GSSv3 context handle. This is 633 done by including an assertion of type rpc_gss3_label in the 634 'assertions' field (discriminant: 'LABEL') of the RPCSEC_GSS3_CREATE 635 arguments to the desired LSF and label. 637 Label encoding is specified to mirror the NFSv4 sec_label attribute 638 described in Section 12.2.2 of [6]. The label format specifier (LFS) 639 is an identifier used by the client to establish the syntactic format 640 of the security label and the semantic meaning of its components. 641 The policy identifier (PI) is an optional part of the definition of 642 an LFS which allows for clients and server to identify specific 643 security policies. The opaque label field of rpc_gss3_label is 644 dependent on the MAC model to interpret and enforce. 646 [[Comment.7: Check that this Label definition provides all the 647 required pieces to enable full mode when combined with NFSv4.2 LNFS. 648 Specifically, how does the client find out and respond if a server 649 has changed a label. --AA]] 651 If a label itself requires privacy protection (i.e., that the user 652 can assert that label is a secret) then the client MUST use the 653 rpc_gss_svc_privacy protection service for the RPCSEC_GSS3_CREATE 654 request or, if the parent handle is bound to a secure channel that 655 provides privacy protection, rpc_gss_svc_channel_prot. 657 If a client wants to ensure that the server understands the asserted 658 label then it MUST set the 'critical' field of the label assertion to 659 TRUE, otherwise it MUST set it to FALSE. 661 Servers that do not support labeling MUST ignore non-critical label 662 assertions. Servers that do not support the requested LFS MUST 663 either ignore non-critical label assertions or map them to a suitable 664 label in a supported LFS. Servers that do not support labeling or do 665 not support the requested LFS MUST return an error if the label 666 request is critical. Servers that support labeling in the requested 667 LFS MAY map the requested label to different label as a result of 668 server-side policy evaluation. 670 2.3.1.4. Structured Privilege Assertions 672 A structured privilege is an RPC application defined structure that 673 is opaque, and is encoded in the rpc_gss3_privs privilege field. 674 Encoding, server verification and any server policies for structured 675 privileges are described by the RPC application definition. 677 A successful structured privilege assertion RPCSEC_GSS3_CREATE call 678 must return all granted privileges in the rpc_gss3_privs 679 granted_assertions field. 681 Section 3.4.1.2. "Inter-Server Copy with RPCSEC_GSSv3" of [6] shows 682 an example of structured privilege definition and use. 684 2.3.2. Destruction Request 686 The RPCSEC_GSS3_DESTROY control message is the same as the 687 RPCSEC_GSSv1 RPCSEC_GSS_DESTROY control message, but with the version 688 3 header. Specifically, the rpc_gss_cred_vers_3_t fields in the RPC 689 Call opaque_auth use the GSS3 context handle and seq_num stream. As 690 with all RPCSEC_GSSv3 messages, the header checksum uses the parent 691 context, and needs to be valid. 693 The server sends a response as it would to a data request. The 694 client and server must then destroy the context for the session. 696 2.3.3. List Request 698 The RPCSEC_GSS3_LIST control message is similar to RPCSEC_GSS3_CREATE 699 message. Specifically, the rpc_gss_cred_vers_3_t fields in the RPC 700 Call opaque_auth use the parent context handle and seq_num stream. 701 As with all RPCSEC_GSSv3 messages, the header checksum uses the 702 parent context, and needs to be valid. 704 The RPCSEC_GSS3_LIST control message consists of a single integer 705 indicating what should be listed, and the reply consists of an error 706 or the requested list. The client may query the server to list 707 available LFSs. 709 The result is an opaque octet string containing a list of LFSs 710 [encoding TBD]. 712 2.3.4. Extensibility 714 Assertion types may be added in the future by adding arms to the 715 'rpc_gss3_assertion_u' union. Every assertion has a 'critical' flag 716 that can be used to indicate criticality. Other assertion types are 717 described elsewhere and include: 719 o Client-side assertions of identity: 721 * Primary client/user identity 723 * Supplementary group memberships of the client/user, including 724 support for specifying deltas to the membership list as seen on 725 the server. 727 New control message types may be added. 729 Servers receiving unknown critical client assertions MUST return an 730 error. 732 2.4. Data Messages 734 RPCSEC_GSS3_DATA messages differ from from RPCSEC_GSSv1 data messages 735 in that the version number used MUST be '3' instead of '1'. As noted 736 in Section 2.2 the RPCSEC_GSSv3 context handle is used along with 737 it's sequence number stream. 739 For RPCSEC_GSSv3 data messages the rpc_gss_cred_vers_3_t in the RPC 740 message opaque_auth structure is encoded as follows: 742 1. the union rpc_gss_cred_t version is set to 3 with the value being 743 of type rpc_gss_cred_vers_3_t instead of rpc_gss_cred_vers_1_t. 745 2. the gss_proc is set to RPCSEC_GSS3_DATA 747 3. the seq_num is a valid GSS3 context (child context) sequence 748 number. 750 4. just as in RPCSEC_GSSv1, the rpc_gss_service_t is one of 751 rpc_gss_svc_none, rpc_gss_svc_integrity, rpc_gss_svc_privacy, or 752 rpc_gss_svc_channel_prot. 754 5. the handle field is set to the (child) RPCSEC_GSSv3 context 755 handle 757 3. Security Considerations 759 This entire document deals with security issues. 761 The RPCSEC_GSSv3 protocol allows for client-side assertions of data 762 that is relevant to server-side authorization decisions. These 763 assertions must be evaludated by the server in the context of whether 764 the client and/or user are authenticated, whether compound 765 authentication was used, whether the client is trusted, what ranges 766 of assertions are allowed for the client and the user (separately or 767 together), and any relevant server-side policy. 769 The security semantics of assertions carried by RPCSEC_GSSv3 are 770 application protocol-specific. 772 RPCSEC_GSSv3 supports a notion of critical assertions but there's no 773 need for peers to tell each other what assertions were granted, or 774 what they were mapped to. 776 Note that RPSEC_GSSv3 is not a complete solution for labeling: it 777 conveys the labels of actors, but not the labels of objects. RPC 778 application protocols may require extending in order to carry object 779 label information. 781 There may be interactions with NFSv4's callback security scheme and 782 NFSv4.1's GSS-API "SSV" mechanisms. Specifically, the NFSv4 callback 783 scheme requires that the server initiate GSS-API security contexts, 784 which does not work well in practice, and in the context of client- 785 side processes running as the same user but with different privileges 786 and security labels the NFSv4 callback security scheme seems 787 particularly unlikely to work well. NFSv4.1 has the server use an 788 existing, client-initiated RPCSEC_GSS context handle to protect 789 server-initiated callback RPCs. The NFSv4.1 callback security scheme 790 lacks all the problems of the NFSv4 scheme, however, it is important 791 that the server pick an appropriate RPCSEC_GSS context handle to 792 protect any callbacks. Specifically, it is important that the server 793 use RPCSEC_GSS context handles which authenticate the client to 794 protect any callbacks relating to server state initiated by RPCs 795 protected by RPCSEC_GSSv3 contexts. 797 [[Comment.8: [Add text about interaction with GSS-SSV...] --NW]] 799 [[Comment.9: I see no reason to use RPCSEC_GSSv3 contexts for NFSv4.x 800 back channel. --AA]] 802 [[Comment.10: Since GSS3 requires an RPCSEC_GSSv1 or v2 context 803 handle to establish a GSS3 context, SSV can not be used as this draft 804 is written.]] 806 [[Comment.11: AFAICS the reason to use SSV is to avoid using a client 807 machine credential which means compound authentication can not be 808 used. Since GSS3 requires an RPCSEC_GSSv1 or v2 context handle to 809 establish a GSS3 context, SSV can not be used as the parent context 810 for GSSv3. --AA]] 812 4. IANA Considerations 814 This section uses terms that are defined in [8]. 816 There are no IANA considerations in this document. TBDs in this 817 document will be assigned by the ONC RPC registrar (which is not 818 IANA, XXX: verify). 820 5. References 822 5.1. Normative References 824 [1] Bradner, S., "Key words for use in RFCs to Indicate Requirement 825 Levels", March 1997. 827 [2] Eisler, M., Chiu, A., and L. Ling, "RPCSEC_GSS Protocol 828 Specification", RFC 2203, September 1997. 830 [3] Linn, J., "Generic Security Service Application Program 831 Interface Version 2, Update 1", RFC 2743, January 2000. 833 [4] Srinivasan, R., "RPC: Remote Procedure Call Protocol 834 Specification Version 2", RFC 1831, August 1995. 836 [5] Williams, N., "On the Use of Channel Bindings to Secure 837 Channels", RFC 5056, November 2007. 839 [6] Haynes, T., "NFS Version 4 Minor Version 2", 840 draft-ietf-nfsv4-minorversion2-19 (Work In Progress), 841 March 2013. 843 [7] Eisler, M., "XDR: External Data Representation Standard", 844 RFC 4506, May 2006. 846 [8] Narten, T. and H. Alvestrand, "Guidelines for Writing an IANA 847 Considerations Section in RFCs", BCP 26, RFC 5226, May 2008. 849 5.2. Informative References 851 [9] Haynes, T., "Requirements for Labeled NFS", 852 draft-ietf-nfsv4-labreqs-03 (work in progress). 854 [10] "Section 46.6. Multi-Level Security (MLS) of Deployment Guide: 855 Deployment, configuration and administration of Red Hat 856 Enterprise Linux 5, Edition 6", 2011. 858 [11] Smalley, S., "The Distributed Trusted Operating System (DTOS) 859 Home Page", 860 . 862 [12] Carter, J., "Implementing SELinux Support for NFS", 863 . 865 [13] Quigley, D. and J. Lu, "Registry Specification for MAC Security 866 Label Formats", draft-quigley-label-format-registry (work in 867 progress), 2011. 869 Appendix A. Acknowledgments 871 Appendix B. RFC Editor Notes 873 [RFC Editor: please remove this section prior to publishing this 874 document as an RFC] 876 [RFC Editor: prior to publishing this document as an RFC, please 877 replace all occurrences of RFCTBD10 with RFCxxxx where xxxx is the 878 RFC number of this document] 880 Authors' Addresses 882 William A. (Andy) Adamson 883 NetApp 884 3629 Wagner Ridge Ctt 885 Ann Arbor, MI 48103 886 USA 888 Phone: +1 734 665 1204 889 Email: andros@netapp.com 890 Nico Williams 891 cryptonector.com 892 13115 Tamayo Dr 893 Austin, TX 78729 894 USA 896 Email: nico@cryptonector.com