Tech-invite3GPPspaceIETFspace
959493929190898887868584838281807978777675747372717069686766656463626160595857565554535251504948474645444342414039383736353433323130292827262524232221201918171615141312111009080706050403020100
in Index   Prev   Next

RFC 6125

Representation and Verification of Domain-Based Application Service Identity within Internet Public Key Infrastructure Using X.509 (PKIX) Certificates in the Context of Transport Layer Security (TLS)

Pages: 57
Obsoleted by:  9525
Part 2 of 3 – Pages 18 to 39
First   Prev   Next

Top   ToC   RFC6125 - Page 18   prevText

3. Designing Application Protocols

This section provides guidelines for designers of application protocols, in the form of a checklist to follow when reusing the recommendations provided in this document. o Does your technology use DNS SRV records to resolve the DNS domain names of application services? If so, consider recommending or requiring support for the SRV-ID identifier type in PKIX certificates issued and used in your technology community. (Note that many existing application technologies use DNS SRV records to resolve the DNS domain names of application services, but do not rely on representations of those records in PKIX certificates by means of SRV-IDs as defined in [SRVNAME].) o Does your technology use URIs to identify application services? If so, consider recommending or requiring support for the URI-ID identifier type. (Note that many existing application technologies use URIs to identify application services, but do not rely on representation of those URIs in PKIX certificates by means of URI-IDs.) o Does your technology need to use DNS domain names in the Common Name of certificates for the sake of backward compatibility? If so, consider recommending support for the CN-ID identifier type as a fallback. o Does your technology need to allow the wildcard character in DNS domain names? If so, consider recommending support for wildcard certificates, and specify exactly where the wildcard character is allowed to occur (e.g., only the complete left-most label of a DNS domain name). Sample text is provided under Appendix A.

4. Representing Server Identity

This section provides rules and guidelines for issuers of certificates.

4.1. Rules

When a certification authority issues a certificate based on the fully qualified DNS domain name at which the application service provider will provide the relevant application, the following rules apply to the representation of application service identities. The
Top   ToC   RFC6125 - Page 19
   reader needs to be aware that some of these rules are cumulative and
   can interact in important ways that are illustrated later in this
   document.

   1.  The certificate SHOULD include a "DNS-ID" if possible as a
       baseline for interoperability.

   2.  If the service using the certificate deploys a technology for
       which the relevant specification stipulates that certificates
       ought to include identifiers of type SRV-ID (e.g., this is true
       of [XMPP]), then the certificate SHOULD include an SRV-ID.

   3.  If the service using the certificate deploys a technology for
       which the relevant specification stipulates that certificates
       ought to include identifiers of type URI-ID (e.g., this is true
       of [SIP] as specified by [SIP-CERTS], but not true of [HTTP]
       since [HTTP-TLS] does not describe usage of a URI-ID for HTTP
       services), then the certificate SHOULD include a URI-ID.  The
       scheme SHALL be that of the protocol associated with the
       application service type and the "host" component (or its
       equivalent) SHALL be the fully qualified DNS domain name of the
       service.  A specification that reuses this one MUST specify which
       URI schemes are to be considered acceptable in URI-IDs contained
       in PKIX certificates used for the application protocol (e.g.,
       "sip" but not "sips" or "tel" for SIP as described in [SIP-SIPS],
       or perhaps http and https for HTTP as might be described in a
       future specification).

   4.  The certificate MAY include other application-specific
       identifiers for types that were defined before publication of
       [SRVNAME] (e.g., XmppAddr for [XMPP]) or for which service names
       or URI schemes do not exist; however, such application-specific
       identifiers are not applicable to all application technologies
       and therefore are out of scope for this specification.

   5.  Even though many deployed clients still check for the CN-ID
       within the certificate subject field, certification authorities
       are encouraged to migrate away from issuing certificates that
       represent the server's fully qualified DNS domain name in a
       CN-ID.  Therefore, the certificate SHOULD NOT include a CN-ID
       unless the certification authority issues the certificate in
       accordance with a specification that reuses this one and that
       explicitly encourages continued support for the CN-ID identifier
       type in the context of a given application technology.

   6.  The certificate MAY contain more than one DNS-ID, SRV-ID, or
       URI-ID but SHOULD NOT contain more than one CN-ID, as further
       explained under Section 7.4.
Top   ToC   RFC6125 - Page 20
   7.  Unless a specification that reuses this one allows continued
       support for the wildcard character '*', the DNS domain name
       portion of a presented identifier SHOULD NOT contain the wildcard
       character, whether as the complete left-most label within the
       identifier (following the description of labels and domain names
       in [DNS-CONCEPTS], e.g., "*.example.com") or as a fragment
       thereof (e.g., *oo.example.com, f*o.example.com, or
       fo*.example.com).  A more detailed discussion of so-called
       "wildcard certificates" is provided under Section 7.2.

4.2. Examples

Consider a simple website at "www.example.com", which is not discoverable via DNS SRV lookups. Because HTTP does not specify the use of URIs in server certificates, a certificate for this service might include only a DNS-ID of "www.example.com". It might also include a CN-ID of "www.example.com" for backward compatibility with deployed infrastructure. Consider an IMAP-accessible email server at the host "mail.example.net" servicing email addresses of the form "user@example.net" and discoverable via DNS SRV lookups on the application service name of "example.net". A certificate for this service might include SRV-IDs of "_imap.example.net" and "_imaps.example.net" (see [EMAIL-SRV]) along with DNS-IDs of "example.net" and "mail.example.net". It might also include CN-IDs of "example.net" and "mail.example.net" for backward compatibility with deployed infrastructure. Consider a SIP-accessible voice-over-IP (VoIP) server at the host "voice.example.edu" servicing SIP addresses of the form "user@voice.example.edu" and identified by a URI of <sip: voice.example.edu>. A certificate for this service would include a URI-ID of "sip:voice.example.edu" (see [SIP-CERTS]) along with a DNS-ID of "voice.example.edu". It might also include a CN-ID of "voice.example.edu" for backward compatibility with deployed infrastructure. Consider an XMPP-compatible instant messaging (IM) server at the host "im.example.org" servicing IM addresses of the form "user@im.example.org" and discoverable via DNS SRV lookups on the "im.example.org" domain. A certificate for this service might include SRV-IDs of "_xmpp-client.im.example.org" and "_xmpp-server.im.example.org" (see [XMPP]), a DNS-ID of "im.example.org", and an XMPP-specific "XmppAddr" of "im.example.org" (see [XMPP]). It might also include a CN-ID of "im.example.org" for backward compatibility with deployed infrastructure.
Top   ToC   RFC6125 - Page 21

5. Requesting Server Certificates

This section provides rules and guidelines for service providers regarding the information to include in certificate signing requests (CSRs). In general, service providers are encouraged to request certificates that include all of the identifier types that are required or recommended for the application service type that will be secured using the certificate to be issued. If the certificate might be used for any type of application service, then the service provider is encouraged to request a certificate that includes only a DNS-ID. If the certificate will be used for only a single type of application service, then the service provider is encouraged to request a certificate that includes a DNS-ID and, if appropriate for the application service type, an SRV-ID or URI-ID that limits the deployment scope of the certificate to only the defined application service type. If a service provider offering multiple application service types (e.g., a World Wide Web service, an email service, and an instant messaging service) wishes to limit the applicability of certificates using SRV-IDs or URI-IDs, then the service provider is encouraged to request multiple certificates, i.e., one certificate per application service type. Conversely, the service provider is discouraged from requesting a single certificate containing multiple SRV-IDs or URI- IDs identifying each different application service type. This guideline does not apply to application service type "bundles" that are used to identify manifold distinct access methods to the same underlying application (e.g., an email application with access methods denoted by the application service types of "imap", "imaps", "pop3", "pop3s", and "submission" as described in [EMAIL-SRV]).

6. Verifying Service Identity

This section provides rules and guidelines for implementers of application client software regarding algorithms for verification of application service identity.

6.1. Overview

At a high level, the client verifies the application service's identity by performing the actions listed below (which are defined in the following subsections of this document):
Top   ToC   RFC6125 - Page 22
   1.  The client constructs a list of acceptable reference identifiers
       based on the source domain and, optionally, the type of service
       to which the client is connecting.

   2.  The server provides its identifiers in the form of a PKIX
       certificate.

   3.  The client checks each of its reference identifiers against the
       presented identifiers for the purpose of finding a match.

   4.  When checking a reference identifier against a presented
       identifier, the client matches the source domain of the
       identifiers and, optionally, their application service type.

   Naturally, in addition to checking identifiers, a client might
   complete further checks to ensure that the server is authorized to
   provide the requested service.  However, such checking is not a
   matter of verifying the application service identity presented in a
   certificate, and therefore methods for doing so (e.g., consulting
   local policy information) are out of scope for this document.

6.2. Constructing a List of Reference Identifiers

6.2.1. Rules

The client MUST construct a list of acceptable reference identifiers, and MUST do so independently of the identifiers presented by the service. The inputs used by the client to construct its list of reference identifiers might be a URI that a user has typed into an interface (e.g., an HTTPS URL for a website), configured account information (e.g., the domain name of a particular host or URI used for retrieving information or connecting to a network, which might be different from the DNS domain name portion of a username), a hyperlink in a web page that triggers a browser to retrieve a media object or script, or some other combination of information that can yield a source domain and an application service type. The client might need to extract the source domain and application service type from the input(s) it has received. The extracted data MUST include only information that can be securely parsed out of the inputs (e.g., parsing the fully qualified DNS domain name out of the "host" component (or its equivalent) of a URI or deriving the application service type from the scheme of a URI) or information that is derived in a manner not subject to subversion by network attackers (e.g., pulling the data from a delegated domain that is explicitly established via client or system configuration, resolving
Top   ToC   RFC6125 - Page 23
   the data via [DNSSEC], or obtaining the data from a third-party
   domain mapping service in which a human user has explicitly placed
   trust and with which the client communicates over a connection or
   association that provides both mutual authentication and integrity
   checking).  These considerations apply only to extraction of the
   source domain from the inputs; naturally, if the inputs themselves
   are invalid or corrupt (e.g., a user has clicked a link provided by a
   malicious entity in a phishing attack), then the client might end up
   communicating with an unexpected application service.

      Example: Given an input URI of <sips:alice@example.net>, a client
      would derive the application service type "sip" from the "scheme"
      and parse the domain name "example.net" from the "host" component
      (or its equivalent).

   Each reference identifier in the list SHOULD be based on the source
   domain and SHOULD NOT be based on a derived domain (e.g., a host name
   or domain name discovered through DNS resolution of the source
   domain).  This rule is important because only a match between the
   user inputs and a presented identifier enables the client to be sure
   that the certificate can legitimately be used to secure the client's
   communication with the server.  There is only one scenario in which
   it is acceptable for an interactive client to override the
   recommendation in this rule and therefore communicate with a domain
   name other than the source domain: because a human user has "pinned"
   the application service's certificate to the alternative domain name
   as further discussed under Section 6.6.4 and Section 7.1.  In this
   case, the inputs used by the client to construct its list of
   reference identifiers might include more than one fully qualified DNS
   domain name, i.e., both (a) the source domain and (b) the alternative
   domain contained in the pinned certificate.

   Using the combination of fully qualified DNS domain name(s) and
   application service type, the client constructs a list of reference
   identifiers in accordance with the following rules:

   o  The list SHOULD include a DNS-ID.  A reference identifier of type
      DNS-ID can be directly constructed from a fully qualified DNS
      domain name that is (a) contained in or securely derived from the
      inputs (i.e., the source domain), or (b) explicitly associated
      with the source domain by means of user configuration (i.e., a
      derived domain).

   o  If a server for the application service type is typically
      discovered by means of DNS SRV records, then the list SHOULD
      include an SRV-ID.
Top   ToC   RFC6125 - Page 24
   o  If a server for the application service type is typically
      associated with a URI for security purposes (i.e., a formal
      protocol document specifies the use of URIs in server
      certificates), then the list SHOULD include a URI-ID.

   o  The list MAY include a CN-ID, mainly for the sake of backward
      compatibility with deployed infrastructure.

   Which identifier types a client includes in its list of reference
   identifiers is a matter of local policy.  For example, in certain
   deployment environments, a client that is built to connect only to a
   particular kind of service (e.g., only IM services) might be
   configured to accept as valid only certificates that include an
   SRV-ID for that application service type; in this case, the client
   would include only SRV-IDs matching the application service type in
   its list of reference identifiers (not, for example, DNS-IDs).  By
   contrast, a more lenient client (even one built to connect only to a
   particular kind of service) might include both SRV-IDs and DNS-IDs in
   its list of reference identifiers.

      Implementation Note: It is highly likely that implementers of
      client software will need to support CN-IDs for the foreseeable
      future, because certificates containing CN-IDs are so widely
      deployed.  Implementers are advised to monitor the state of the
      art with regard to certificate issuance policies and migrate away
      from support CN-IDs in the future if possible.

      Implementation Note: The client does not need to construct the
      foregoing identifiers in the actual formats found in a certificate
      (e.g., as ASN.1 types); it only needs to construct the functional
      equivalent of such identifiers for matching purposes.

      Security Warning: A client MUST NOT construct a reference
      identifier corresponding to Relative Distinguished Names (RDNs)
      other than those of type Common Name and MUST NOT check for RDNs
      other than those of type Common Name in the presented identifiers.

6.2.2. Examples

A web browser that is connecting via HTTPS to the website at "www.example.com" might have two reference identifiers: a DNS-ID of "www.example.com" and, as a fallback, a CN-ID of "www.example.com". A mail user agent that is connecting via IMAPS to the email service at "example.net" (resolved as "mail.example.net") might have five reference identifiers: an SRV-ID of "_imaps.example.net" (see [EMAIL-SRV]), DNS-IDs of "example.net" and "mail.example.net", and, as a fallback, CN-IDs of "example.net" and "mail.example.net". (A
Top   ToC   RFC6125 - Page 25
   legacy email user agent would not support [EMAIL-SRV] and therefore
   would probably be explicitly configured to connect to
   "mail.example.net", whereas an SRV-aware user agent would derive
   "example.net" from an email address of the form "user@example.net"
   but might also accept "mail.example.net" as the DNS domain name
   portion of reference identifiers for the service.)

   A voice-over-IP (VoIP) user agent that is connecting via SIP to the
   voice service at "voice.example.edu" might have only one reference
   identifier: a URI-ID of "sip:voice.example.edu" (see [SIP-CERTS]).

   An instant messaging (IM) client that is connecting via XMPP to the
   IM service at "im.example.org" might have three reference
   identifiers: an SRV-ID of "_xmpp-client.im.example.org" (see [XMPP]),
   a DNS-ID of "im.example.org", and an XMPP-specific "XmppAddr" of
   "im.example.org" (see [XMPP]).

6.3. Preparing to Seek a Match

Once the client has constructed its list of reference identifiers and has received the server's presented identifiers in the form of a PKIX certificate, the client checks its reference identifiers against the presented identifiers for the purpose of finding a match. The search fails if the client exhausts its list of reference identifiers without finding a match. The search succeeds if any presented identifier matches one of the reference identifiers, at which point the client SHOULD stop the search. Implementation Note: A client might be configured to perform multiple searches, i.e., to match more than one reference identifier. Although such behavior is not forbidden by this specification, rules for matching multiple reference identifiers are a matter for implementation or future specification. Security Warning: A client MUST NOT seek a match for a reference identifier of CN-ID if the presented identifiers include a DNS-ID, SRV-ID, URI-ID, or any application-specific identifier types supported by the client. Before applying the comparison rules provided in the following sections, the client might need to split the reference identifier into its DNS domain name portion and its application service type portion, as follows: o A reference identifier of type DNS-ID does not include an application service type portion and thus can be used directly as the DNS domain name for comparison purposes. As an example, a
Top   ToC   RFC6125 - Page 26
      DNS-ID of "www.example.com" would result in a DNS domain name
      portion of "www.example.com".

   o  A reference identifier of type CN-ID also does not include an
      application service type portion and thus can be used directly as
      the DNS domain name for comparison purposes.  As previously
      mentioned, this document specifies that a CN-ID always contains a
      string whose form matches that of a DNS domain name (thus
      differentiating a CN-ID from a Common Name containing a human-
      friendly name).

   o  For a reference identifier of type SRV-ID, the DNS domain name
      portion is the Name and the application service type portion is
      the Service.  As an example, an SRV-ID of "_imaps.example.net"
      would be split into a DNS domain name portion of "example.net" and
      an application service type portion of "imaps" (mapping to an
      application protocol of IMAP as explained in [EMAIL-SRV]).

   o  For a reference identifier of type URI-ID, the DNS domain name
      portion is the "reg-name" part of the "host" component (or its
      equivalent) and the application service type portion is the
      application service type associated with the scheme name matching
      the [ABNF] "scheme" rule from [URI] (not including the ':'
      separator).  As previously mentioned, this document specifies that
      a URI-ID always contains a "host" component (or its equivalent)
      containing a "reg-name".  (Matching only the "reg-name" rule from
      [URI] limits verification to DNS domain names, thereby
      differentiating a URI-ID from a uniformResourceIdentifier entry
      that contains an IP address or a mere host name, or that does not
      contain a "host" component at all.)  Furthermore, note that
      extraction of the "reg-name" might necessitate normalization of
      the URI (as explained in [URI]).  As an example, a URI-ID of "sip:
      voice.example.edu" would be split into a DNS domain name portion
      of "voice.example.edu" and an application service type of "sip"
      (associated with an application protocol of SIP as explained in
      [SIP-CERTS]).

   Detailed comparison rules for matching the DNS domain name portion
   and application service type portion of the reference identifier are
   provided in the following sections.

6.4. Matching the DNS Domain Name Portion

The client MUST match the DNS domain name portion of a reference identifier according to the following rules (and SHOULD also check the application service type as described under Section 6.5). The rules differ depending on whether the domain to be checked is a "traditional domain name" or an "internationalized domain name" (as
Top   ToC   RFC6125 - Page 27
   defined under Section 2.2).  Furthermore, to meet the needs of
   clients that support presented identifiers containing the wildcard
   character '*', we define a supplemental rule for so-called "wildcard
   certificates".  Finally, we also specify the circumstances under
   which it is acceptable to check the "CN-ID" identifier type.

6.4.1. Checking of Traditional Domain Names

If the DNS domain name portion of a reference identifier is a "traditional domain name", then matching of the reference identifier against the presented identifier is performed by comparing the set of domain name labels using a case-insensitive ASCII comparison, as clarified by [DNS-CASE] (e.g., "WWW.Example.Com" would be lower-cased to "www.example.com" for comparison purposes). Each label MUST match in order for the names to be considered to match, except as supplemented by the rule about checking of wildcard labels (Section 6.4.3).

6.4.2. Checking of Internationalized Domain Names

If the DNS domain name portion of a reference identifier is an internationalized domain name, then an implementation MUST convert any U-labels [IDNA-DEFS] in the domain name to A-labels before checking the domain name. In accordance with [IDNA-PROTO], A-labels MUST be compared as case-insensitive ASCII. Each label MUST match in order for the domain names to be considered to match, except as supplemented by the rule about checking of wildcard labels (Section 6.4.3; but see also Section 7.2 regarding wildcards in internationalized domain names).

6.4.3. Checking of Wildcard Certificates

A client employing this specification's rules MAY match the reference identifier against a presented identifier whose DNS domain name portion contains the wildcard character '*' as part or all of a label (following the description of labels and domain names in [DNS-CONCEPTS]). For information regarding the security characteristics of wildcard certificates, see Section 7.2. If a client matches the reference identifier against a presented identifier whose DNS domain name portion contains the wildcard character '*', the following rules apply: 1. The client SHOULD NOT attempt to match a presented identifier in which the wildcard character comprises a label other than the left-most label (e.g., do not match bar.*.example.net).
Top   ToC   RFC6125 - Page 28
   2.  If the wildcard character is the only character of the left-most
       label in the presented identifier, the client SHOULD NOT compare
       against anything but the left-most label of the reference
       identifier (e.g., *.example.com would match foo.example.com but
       not bar.foo.example.com or example.com).

   3.  The client MAY match a presented identifier in which the wildcard
       character is not the only character of the label (e.g.,
       baz*.example.net and *baz.example.net and b*z.example.net would
       be taken to match baz1.example.net and foobaz.example.net and
       buzz.example.net, respectively).  However, the client SHOULD NOT
       attempt to match a presented identifier where the wildcard
       character is embedded within an A-label or U-label [IDNA-DEFS] of
       an internationalized domain name [IDNA-PROTO].

6.4.4. Checking of Common Names

As noted, a client MUST NOT seek a match for a reference identifier of CN-ID if the presented identifiers include a DNS-ID, SRV-ID, URI-ID, or any application-specific identifier types supported by the client. Therefore, if and only if the presented identifiers do not include a DNS-ID, SRV-ID, URI-ID, or any application-specific identifier types supported by the client, then the client MAY as a last resort check for a string whose form matches that of a fully qualified DNS domain name in a Common Name field of the subject field (i.e., a CN-ID). If the client chooses to compare a reference identifier of type CN-ID against that string, it MUST follow the comparison rules for the DNS domain name portion of an identifier of type DNS-ID, SRV-ID, or URI-ID, as described under Section 6.4.1, Section 6.4.2, and Section 6.4.3.

6.5. Matching the Application Service Type Portion

When a client checks identifiers of type SRV-ID and URI-ID, it MUST check not only the DNS domain name portion of the identifier but also the application service type portion. The client does this by splitting the identifier into the DNS domain name portion and the application service type portion (as described under Section 6.3), then checking both the DNS domain name portion (as described under Section 6.4) and the application service type portion as described in the following subsections. Implementation Note: An identifier of type SRV-ID or URI-ID provides an application service type portion to be checked, but that portion is combined only with the DNS domain name portion of the SRV-ID or URI-ID itself. For example, if a client's list of
Top   ToC   RFC6125 - Page 29
      reference identifiers includes an SRV-ID of "_xmpp-
      client.im.example.org" and a DNS-ID of "apps.example.net", the
      client would check (a) the combination of an application service
      type of "xmpp-client" and a DNS domain name of "im.example.org"
      and (b) a DNS domain name of "apps.example.net".  However, the
      client would not check (c) the combination of an application
      service type of "xmpp-client" and a DNS domain name of
      "apps.example.net" because it does not have an SRV-ID of "_xmpp-
      client.apps.example.net" in its list of reference identifiers.

6.5.1. SRV-ID

The application service name portion of an SRV-ID (e.g., "imaps") MUST be matched in a case-insensitive manner, in accordance with [DNS-SRV]. Note that the "_" character is prepended to the service identifier in DNS SRV records and in SRV-IDs (per [SRVNAME]), and thus does not need to be included in any comparison.

6.5.2. URI-ID

The scheme name portion of a URI-ID (e.g., "sip") MUST be matched in a case-insensitive manner, in accordance with [URI]. Note that the ":" character is a separator between the scheme name and the rest of the URI, and thus does not need to be included in any comparison.

6.6. Outcome

The outcome of the matching procedure is one of the following cases.

6.6.1. Case #1: Match Found

If the client has found a presented identifier that matches a reference identifier, then the service identity check has succeeded. In this case, the client MUST use the matched reference identifier as the validated identity of the application service.

6.6.2. Case #2: No Match Found, Pinned Certificate

If the client does not find a presented identifier matching any of the reference identifiers but the client has previously pinned the application service's certificate to one of the reference identifiers in the list it constructed for this communication attempt (as "pinning" is explained under Section 1.8), and the presented certificate matches the pinned certificate (including the context as described under Section 7.1), then the service identity check has succeeded.
Top   ToC   RFC6125 - Page 30

6.6.3. Case #3: No Match Found, No Pinned Certificate

If the client does not find a presented identifier matching any of the reference identifiers and the client has not previously pinned the certificate to one of the reference identifiers in the list it constructed for this communication attempt, then the client MUST proceed as described under Section 6.6.4.

6.6.4. Fallback

If the client is an interactive client that is directly controlled by a human user, then it SHOULD inform the user of the identity mismatch and automatically terminate the communication attempt with a bad certificate error; this behavior is preferable because it prevents users from inadvertently bypassing security protections in hostile situations. Security Warning: Some interactive clients give advanced users the option of proceeding with acceptance despite the identity mismatch, thereby "pinning" the certificate to one of the reference identifiers in the list constructed by the client for this communication attempt. Although this behavior can be appropriate in certain specialized circumstances, in general it ought to be exposed only to advanced users. Even then it needs to be handled with extreme caution, for example by first encouraging even an advanced user to terminate the communication attempt and, if the advanced user chooses to proceed anyway, by forcing the user to view the entire certification path and only then allowing the user to pin the certificate (on a temporary or permanent basis, at the user's option). Otherwise, if the client is an automated application not directly controlled by a human user, then it SHOULD terminate the communication attempt with a bad certificate error and log the error appropriately. An automated application MAY provide a configuration setting that disables this behavior, but MUST enable the behavior by default.

7. Security Considerations

7.1. Pinned Certificates

As defined under Section 1.8, a certificate is said to be "pinned" to a DNS domain name when a user has explicitly chosen to associate a service's certificate with that DNS domain name despite the fact that the certificate contains some other DNS domain name (e.g., the user has explicitly approved "apps.example.net" as a domain associated with a source domain of "example.com"). The cached name association
Top   ToC   RFC6125 - Page 31
   MUST take account of both the certificate presented and the context
   in which it was accepted or configured (where the "context" includes
   the chain of certificates from the presented certificate to the trust
   anchor, the source domain, the application service type, the
   service's derived domain and port number, and any other relevant
   information provided by the user or associated by the client).

7.2. Wildcard Certificates

This document states that the wildcard character '*' SHOULD NOT be included in presented identifiers but MAY be checked by application clients (mainly for the sake of backward compatibility with deployed infrastructure). As a result, the rules provided in this document are more restrictive than the rules for many existing application technologies (such as those excerpted under Appendix B). Several security considerations justify tightening the rules: o Wildcard certificates automatically vouch for any and all host names within their domain. This can be convenient for administrators but also poses the risk of vouching for rogue or buggy hosts. See for example [Defeating-SSL] (beginning at slide 91) and [HTTPSbytes] (slides 38-40). o Specifications for existing application technologies are not clear or consistent about the allowable location of the wildcard character, such as whether it can be: * only the complete left-most label (e.g., *.example.com) * some fragment of the left-most label (e.g., fo*.example.com, f*o.example.com, or *oo.example.com) * all or part of a label other than the left-most label (e.g., www.*.example.com or www.foo*.example.com) * all or part of a label that identifies a so-called "public suffix" (e.g., *.co.uk or *.com) * included more than once in a given label (e.g., f*b*r.example.com * included as all or part of more than one label (e.g., *.*.example.com) These ambiguities might introduce exploitable differences in identity checking behavior among client implementations and necessitate overly complex and inefficient identity checking algorithms.
Top   ToC   RFC6125 - Page 32
   o  There is no specification that defines how the wildcard character
      may be embedded within the A-labels or U-labels [IDNA-DEFS] of an
      internationalized domain name [IDNA-PROTO]; as a result,
      implementations are strongly discouraged from including or
      attempting to check for the wildcard character embedded within the
      A-labels or U-labels of an internationalized domain name (e.g.,
      "xn--kcry6tjko*.example.org").  Note, however, that a presented
      domain name identifier MAY contain the wildcard character as long
      as that character occupies the entire left-most label position,
      where all of the remaining labels are valid NR-LDH labels,
      A-labels, or U-labels (e.g., "*.xn--kcry6tjko.example.org").

   Notwithstanding the foregoing security considerations, specifications
   that reuse this one can legitimately encourage continued support for
   the wildcard character if they have good reasons to do so, such as
   backward compatibility with deployed infrastructure (see, for
   example, [EV-CERTS]).

7.3. Internationalized Domain Names

Allowing internationalized domain names can lead to the inclusion of visually similar (so-called "confusable") characters in certificates; for discussion, see for example [IDNA-DEFS].

7.4. Multiple Identifiers

A given application service might be addressed by multiple DNS domain names for a variety of reasons, and a given deployment might service multiple domains (e.g., in so-called "virtual hosting" environments). In the default TLS handshake exchange, the client is not able to indicate the DNS domain name with which it wants to communicate, and the TLS server returns only one certificate for itself. Absent an extension to TLS, a typical workaround used to facilitate mapping an application service to multiple DNS domain names is to embed all of the domain names into a single certificate. A more recent approach, formally specified in [TLS-EXT], is for the client to use the TLS "Server Name Indication" (SNI) extension when sending the client_hello message, stipulating the DNS domain name it desires or expects of the service. The service can then return the appropriate certificate in its Certificate message, and that certificate can represent a single DNS domain name. To accommodate the workaround that was needed before the development of the SNI extension, this specification allows multiple DNS-IDs, SRV-IDs, or URI-IDs in a certificate; however, it explicitly discourages multiple CN-IDs. Although it would be preferable to forbid multiple CN-IDs entirely, there are several reasons at this
Top   ToC   RFC6125 - Page 33
   time why this specification states that they SHOULD NOT (instead of
   MUST NOT) be included:

   o  At least one significant technology community of interest
      explicitly allows multiple CN-IDs [EV-CERTS].

   o  At least one significant certification authority is known to issue
      certificates containing multiple CN-IDs.

   o  Many service providers often deem inclusion of multiple CN-IDs
      necessary in virtual hosting environments because at least one
      widely deployed operating system does not yet support the SNI
      extension.

   It is hoped that the recommendation regarding multiple CN-IDs can be
   further tightened in the future.

8. Contributors

The following individuals made important contributions to the text of this document: Shumon Huque, RL 'Bob' Morgan, and Kurt Zeilenga.

9. Acknowledgements

The editors and contributors wish to thank the following individuals for their feedback and suggestions: Bernard Aboba, Richard Barnes, Uri Blumenthal, Nelson Bolyard, Kaspar Brand, Anthony Bryan, Scott Cantor, Wan-Teh Chang, Bil Corry, Dave Cridland, Dave Crocker, Cyrus Daboo, Charles Gardiner, Philip Guenther, Phillip Hallam-Baker, Bruno Harbulot, Wes Hardaker, David Harrington, Paul Hoffman, Love Hornquist Astrand, Henry Hotz, Russ Housley, Jeffrey Hutzelman, Cullen Jennings, Simon Josefsson, Geoff Keating, John Klensin, Scott Lawrence, Matt McCutchen, Alexey Melnikov, Subramanian Moonesamy, Eddy Nigg, Ludwig Nussel, Joe Orton, Tom Petch, Yngve N. Pettersen, Tim Polk, Robert Relyea, Eric Rescorla, Pete Resnick, Martin Rex, Joe Salowey, Stefan Santesson, Jim Schaad, Rob Stradling, Michael Stroeder, Andrew Sullivan, Peter Sylvester, Martin Thomson, Paul Tiemann, Sean Turner, Nicolas Williams, Dan Wing, Dan Winship, and Stefan Winter. Thanks also to Barry Leiba and Ben Campbell for their reviews on behalf of the Security Directorate and the General Area Review Team, respectively. The responsible Area Director was Alexey Melnikov.
Top   ToC   RFC6125 - Page 34

10. References

10.1. Normative References

[DNS-CONCEPTS] Mockapetris, P., "Domain names - concepts and facilities", STD 13, RFC 1034, November 1987. [DNS-SRV] Gulbrandsen, A., Vixie, P., and L. Esibov, "A DNS RR for specifying the location of services (DNS SRV)", RFC 2782, February 2000. [IDNA-DEFS] Klensin, J., "Internationalized Domain Names for Applications (IDNA): Definitions and Document Framework", RFC 5890, August 2010. [IDNA-PROTO] Klensin, J., "Internationalized Domain Names in Applications (IDNA): Protocol", RFC 5891, August 2010. [KEYWORDS] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997. [LDAP-DN] Zeilenga, K., Ed., "Lightweight Directory Access Protocol (LDAP): String Representation of Distinguished Names", RFC 4514, June 2006. [PKIX] Cooper, D., Santesson, S., Farrell, S., Boeyen, S., Housley, R., and W. Polk, "Internet X.509 Public Key Infrastructure Certificate and Certificate Revocation List (CRL) Profile", RFC 5280, May 2008. [SRVNAME] Santesson, S., "Internet X.509 Public Key Infrastructure Subject Alternative Name for Expression of Service Name", RFC 4985, August 2007. [URI] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform Resource Identifier (URI): Generic Syntax", STD 66, RFC 3986, January 2005.

10.2. Informative References

[ABNF] Crocker, D., Ed. and P. Overell, "Augmented BNF for Syntax Specifications: ABNF", STD 68, RFC 5234, January 2008. [DNS-CASE] Eastlake 3rd, D., "Domain Name System (DNS) Case Insensitivity Clarification", RFC 4343, January 2006.
Top   ToC   RFC6125 - Page 35
   [DNSSEC]         Arends, R., Austein, R., Larson, M., Massey, D., and
                    S. Rose, "DNS Security Introduction and
                    Requirements", RFC 4033, March 2005.

   [DTLS]           Rescorla, E. and N. Modadugu, "Datagram Transport
                    Layer Security", RFC 4347, April 2006.

   [Defeating-SSL]  Marlinspike, M., "New Tricks for Defeating SSL in
                    Practice", BlackHat DC, February 2009,
                    <http://www.blackhat.com/presentations/
                    bh-dc-09/Marlinspike/ BlackHat-DC-09-Marlinspike-
                    Defeating-SSL.pdf>.

   [EMAIL-SRV]      Daboo, C., "Use of SRV Records for Locating Email
                    Submission/Access Services", RFC 6186, March 2011.

   [EV-CERTS]       CA/Browser Forum, "Guidelines For The Issuance And
                    Management Of Extended Validation Certificates",
                    October 2009,
                    <http://www.cabforum.org/Guidelines_v1_2.pdf>.

   [GIST]           Schulzrinne, H. and R. Hancock, "GIST: General
                    Internet Signalling Transport", RFC 5971,
                    October 2010.

   [HTTP]           Fielding, R., Gettys, J., Mogul, J., Frystyk, H.,
                    Masinter, L., Leach, P., and T. Berners-Lee,
                    "Hypertext Transfer Protocol -- HTTP/1.1", RFC 2616,
                    June 1999.

   [HTTP-TLS]       Rescorla, E., "HTTP Over TLS", RFC 2818, May 2000.

   [HTTPSbytes]     Sokol, J. and R. Hansen, "HTTPS Can Byte Me",
                    BlackHat Abu Dhabi, November 2010,
                    <https://media.blackhat.com/bh-ad-10/Hansen/
                    Blackhat-AD-2010-Hansen-Sokol-HTTPS-Can-Byte-Me-
                    slides.pdf>.

   [IDNA2003]       Faltstrom, P., Hoffman, P., and A. Costello,
                    "Internationalizing Domain Names in Applications
                    (IDNA)", RFC 3490, March 2003.

   [IMAP]           Crispin, M., "INTERNET MESSAGE ACCESS PROTOCOL -
                    VERSION 4rev1", RFC 3501, March 2003.

   [IP]             Postel, J., "Internet Protocol", STD 5, RFC 791,
                    September 1981.
Top   ToC   RFC6125 - Page 36
   [IPSEC]          Kent, S. and K. Seo, "Security Architecture for the
                    Internet Protocol", RFC 4301, December 2005.

   [IPv6]           Deering, S. and R. Hinden, "Internet Protocol,
                    Version 6 (IPv6) Specification", RFC 2460,
                    December 1998.

   [LDAP]           Sermersheim, J., "Lightweight Directory Access
                    Protocol (LDAP): The Protocol", RFC 4511, June 2006.

   [LDAP-AUTH]      Harrison, R., "Lightweight Directory Access Protocol
                    (LDAP): Authentication Methods and Security
                    Mechanisms", RFC 4513, June 2006.

   [LDAP-SCHEMA]    Sciberras, A., Ed., "Lightweight Directory Access
                    Protocol (LDAP): Schema for User Applications",
                    RFC 4519, June 2006.

   [LDAP-TLS]       Hodges, J., Morgan, R., and M. Wahl, "Lightweight
                    Directory Access Protocol (v3): Extension for
                    Transport Layer Security", RFC 2830, May 2000.

   [NAPTR]          Mealling, M., "Dynamic Delegation Discovery System
                    (DDDS) Part Three: The Domain Name System (DNS)
                    Database", RFC 3403, October 2002.

   [NETCONF]        Enns, R., Ed., "NETCONF Configuration Protocol",
                    RFC 4741, December 2006.

   [NETCONF-SSH]    Wasserman, M. and T. Goddard, "Using the NETCONF
                    Configuration Protocol over Secure SHell (SSH)",
                    RFC 4742, December 2006.

   [NETCONF-TLS]    Badra, M., "NETCONF over Transport Layer Security
                    (TLS)", RFC 5539, May 2009.

   [NNTP]           Feather, C., "Network News Transfer Protocol
                    (NNTP)", RFC 3977, October 2006.

   [NNTP-TLS]       Murchison, K., Vinocur, J., and C. Newman, "Using
                    Transport Layer Security (TLS) with Network News
                    Transfer Protocol (NNTP)", RFC 4642, October 2006.

   [OCSP]           Myers, M., Ankney, R., Malpani, A., Galperin, S.,
                    and C. Adams, "X.509 Internet Public Key
                    Infrastructure Online Certificate Status Protocol -
                    OCSP", RFC 2560, June 1999.
Top   ToC   RFC6125 - Page 37
   [OPENPGP]        Callas, J., Donnerhacke, L., Finney, H., Shaw, D.,
                    and R. Thayer, "OpenPGP Message Format", RFC 4880,
                    November 2007.

   [PKIX-OLD]       Housley, R., Ford, W., Polk, T., and D. Solo,
                    "Internet X.509 Public Key Infrastructure
                    Certificate and CRL Profile", RFC 2459,
                    January 1999.

   [POP3]           Myers, J. and M. Rose, "Post Office Protocol -
                    Version 3", STD 53, RFC 1939, May 1996.

   [PRIVATE]        Rekhter, Y., Moskowitz, R., Karrenberg, D., Groot,
                    G., and E. Lear, "Address Allocation for Private
                    Internets", BCP 5, RFC 1918, February 1996.

   [S-NAPTR]        Daigle, L. and A. Newton, "Domain-Based Application
                    Service Location Using SRV RRs and the Dynamic
                    Delegation Discovery Service (DDDS)", RFC 3958,
                    January 2005.

   [SECTERMS]       Shirey, R., "Internet Security Glossary, Version 2",
                    RFC 4949, August 2007.

   [SIP]            Rosenberg, J., Schulzrinne, H., Camarillo, G.,
                    Johnston, A., Peterson, J., Sparks, R., Handley, M.,
                    and E. Schooler, "SIP: Session Initiation Protocol",
                    RFC 3261, June 2002.

   [SIP-CERTS]      Gurbani, V., Lawrence, S., and A. Jeffrey, "Domain
                    Certificates in the Session Initiation Protocol
                    (SIP)", RFC 5922, June 2010.

   [SIP-SIPS]       Audet, F., "The Use of the SIPS URI Scheme in the
                    Session Initiation Protocol (SIP)", RFC 5630,
                    October 2009.

   [SMTP]           Klensin, J., "Simple Mail Transfer Protocol",
                    RFC 5321, October 2008.

   [SMTP-AUTH]      Siemborski, R., Ed. and A. Melnikov, Ed., "SMTP
                    Service Extension for Authentication", RFC 4954,
                    July 2007.

   [SMTP-TLS]       Hoffman, P., "SMTP Service Extension for Secure SMTP
                    over Transport Layer Security", RFC 3207,
                    February 2002.
Top   ToC   RFC6125 - Page 38
   [SNMP]           Harrington, D., Presuhn, R., and B. Wijnen, "An
                    Architecture for Describing Simple Network
                    Management Protocol (SNMP) Management Frameworks",
                    STD 62, RFC 3411, December 2002.

   [SNMP-TLS]       Hardaker, W., "Transport Layer Security (TLS)
                    Transport Model for the Simple Network Management
                    Protocol (SNMP)", RFC 5953, August 2010.

   [SYSLOG]         Gerhards, R., "The Syslog Protocol", RFC 5424,
                    March 2009.

   [SYSLOG-DTLS]    Salowey, J., Petch, T., Gerhards, R., and H. Feng,
                    "Datagram Transport Layer Security (DTLS) Transport
                    Mapping for Syslog", RFC 6012, October 2010.

   [SYSLOG-TLS]     Miao, F., Ed., Ma, Y., Ed., and J. Salowey, Ed.,
                    "Transport Layer Security (TLS) Transport Mapping
                    for Syslog", RFC 5425, March 2009.

   [TLS]            Dierks, T. and E. Rescorla, "The Transport Layer
                    Security (TLS) Protocol Version 1.2", RFC 5246,
                    August 2008.

   [TLS-EXT]        Eastlake 3rd, D., "Transport Layer Security (TLS)
                    Extensions: Extension Definitions", RFC 6066,
                    January 2011.

   [US-ASCII]       American National Standards Institute, "Coded
                    Character Set - 7-bit American Standard Code for
                    Information Interchange", ANSI X3.4, 1986.

   [USINGTLS]       Newman, C., "Using TLS with IMAP, POP3 and ACAP",
                    RFC 2595, June 1999.

   [WSC-UI]         Saldhana, A. and T. Roessler, "Web Security Context:
                    User Interface Guidelines", World Wide Web
                    Consortium LastCall WD-wsc-ui-20100309, March 2010,
                    <http://www.w3.org/TR/2010/WD-wsc-ui-20100309>.

   [X.500]          International Telecommunications Union, "Information
                    Technology - Open Systems Interconnection - The
                    Directory: Overview of concepts, models and
                    services", ITU-T Recommendation X.500, ISO Standard
                    9594-1, August 2005.
Top   ToC   RFC6125 - Page 39
   [X.501]          International Telecommunications Union, "Information
                    Technology - Open Systems Interconnection - The
                    Directory: Models", ITU-T Recommendation X.501,
                    ISO Standard 9594-2, August 2005.

   [X.509]          International Telecommunications Union, "Information
                    Technology - Open Systems Interconnection - The
                    Directory: Public-key and attribute certificate
                    frameworks", ITU-T Recommendation X.509,
                    ISO Standard 9594-8, August 2005.

   [X.520]          International Telecommunications Union, "Information
                    Technology - Open Systems Interconnection - The
                    Directory: Selected attribute types", ITU-
                    T Recommendation X.509, ISO Standard 9594-6,
                    August 2005.

   [X.690]          International Telecommunications Union, "Information
                    Technology - ASN.1 encoding rules: Specification of
                    Basic Encoding Rules (BER), Canonical Encoding Rules
                    (CER) and Distinguished Encoding Rules (DER)", ITU-
                    T Recommendation X.690, ISO Standard 8825-1,
                    August 2008.

   [XMPP]           Saint-Andre, P., "Extensible Messaging and Presence
                    Protocol (XMPP): Core", RFC 6120, March 2011.

   [XMPP-OLD]       Saint-Andre, P., Ed., "Extensible Messaging and
                    Presence Protocol (XMPP): Core", RFC 3920,
                    October 2004.


(next page on part 3)

Next Section