INTERNET-DRAFT                                            M. Yevstifeyev
Intended Status: Informational                            April 23, 2011
Expires: October 25, 2011

                      The 'view-source' URI Scheme
                  draft-yevstifeyev-view-source-uri-01

Abstract

   This document specifies the 'view-source' Uniform Resource Identifier
   (URI) scheme, which refers to the source code of resource identified
   by it.


Status of this Memo

   This Internet-Draft is submitted to IETF in full conformance with the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as
   Internet-Drafts.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/1id-abstracts.html

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html


Copyright and License Notice

   Copyright (c) 2011 IETF Trust and the persons identified as the
   document authors. All rights reserved.

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents
   (http://trustee.ietf.org/license-info) in effect on the date of
   publication of this document. Please review these documents
   carefully, as they describe your rights and restrictions with respect
   to this document. Code Components extracted from this document must
   include Simplified BSD License text as described in Section 4.e of



Yevstifeyev             Expires October 25, 2011                [Page 1]


INTERNET DRAFT          'view-source' URI Scheme          April 23, 2011


   the Trust Legal Provisions and are provided without warranty as
   described in the Simplified BSD License.


Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . . . 2
      1.1.  Terminology  . . . . . . . . . . . . . . . . . . . . . . . 2
   2.  URI Scheme Registration Template  . . . . . . . . . . . . . . . 2
   3.  Security Considerations . . . . . . . . . . . . . . . . . . . . 4
   4.  IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 4
   5.  References  . . . . . . . . . . . . . . . . . . . . . . . . . . 4
      5.1.  Normative References . . . . . . . . . . . . . . . . . . . 4
      5.2.  Informative References . . . . . . . . . . . . . . . . . . 5
   Author's Addresses  . . . . . . . . . . . . . . . . . . . . . . . . 5


1.  Introduction

   This document specifies the 'view-source' Uniform Resource Identifier
   (URI) scheme.  The 'view-source' URIs have long been used by web-
   browsers to refer to the source code of resource identified by it
   having mostly semi-formal specifications (such as the article at
   Microsoft Developer Network libarary [MSDN-VIEW-SOURCE]) and no
   official record at the IETF.  This document is to remove this
   uncertainty; it gives the formal definition of 'view-source' URI
   scheme and registers it in the corresponding IANA registry.

   Generic URI syntax is defined in RFC 3986 [RFC3986]; registration
   procedures for new URI schemes are described in RFC 4395 [RFC4395].

1.1.  Terminology

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
   document are to be interpreted as described in RFC 2119 [RFC2119].


2.  URI Scheme Registration Template

   This section contains the registration template for 'view-source' URI
   scheme, as required by RFC 4395 [RFC4395].

   o URI Scheme Name:  view-source

   o Status:  Provisional

   o URI Scheme Syntax:  The 'view-source' URI takes the form of the



Yevstifeyev             Expires October 25, 2011                [Page 2]


INTERNET DRAFT          'view-source' URI Scheme          April 23, 2011


     <view-source-uri> rule below, defined in ABNF [RFC5234]:

     view-source-uri = "view-source:" absolute-URI

     where the <absolute-URI> rule is defined in Appendix A of RFC 3986
     [RFC3986]

   o URI Scheme Semantics:  The application resolving the 'view-source'
     URI SHALL return the source code of the resource, identified by
     <absolute-URI>.  Each application implementing the 'view-source'
     URI scheme is permitted to choose how the source code is displayed.
      However this specification recommends that it SHOULD be
     represented in the media type "text/plain" [RFC2046] or "text/html"
     [RFC2854] and the character encoding "UTF-8" [RFC3629].

     Per RFC 4395, not all URI schemes are used to refer to a particular
     piece of information (a resource), but rather identify the endpoint
     for establishing connection (for instance, the 'telnet' URI scheme
     [RFC4248]) or performing other actions (such as sending an e-mail
     message [RFC5322] using the 'mailto' URI scheme [RFC6068]).
     Therefore if the 'view-source' URI refers to such URI (e. g.
     <view-source:tel:+1-201-555-0123> with a 'tel' URI [RFC3966] in the
     <absolute-URI> part), such URI SHALL be resolved to the resource of
     zero length, containing no data, with the media type "text/plain"
     [RFC2046] and the character encoding "UTF-8" [RFC3629].

     This specification does not set any restrictions on how the
     applications shall resolve such URIs as
     <view-source:view-source:example://example.com>, i. e. with the
     "view-source:" prefixed more than once.  However it recommends that
     such URIs SHOULD be resolved to the resource of zero length,
     containing no data, with the media type "text/plain" [RFC2046] and
     the character encoding "UTF-8" [RFC3629]

   o Encoding Considerations:  There are no other encoding
     considerations for 'view-source' URIs not discussed in RFC 3986
     [RFC3986]

   o Applications and Protocols that Use this URI Scheme Name:  The
     'view-source' URIs is generally used by web-browsers.  However this
     document does not place the limit on where else they can be used.

     See Wikipedia's entry on "View-source URI scheme"
     [WIKI-VIEW-SOURCE] for the up-to-date list of browser support
     information

   o Interoperability Considerations:  The 'view-source' URI may
     sometimes refer to the source code that is under certain legal



Yevstifeyev             Expires October 25, 2011                [Page 3]


INTERNET DRAFT          'view-source' URI Scheme          April 23, 2011


     provisions, according to which an individual or a company may not
     have granted the free access or other actions with regard to it.
     The users of such information should be careful regarding these
     matters

   o Security Considerations:  Security considerations for 'view-source'
     URIs are discussed in Section 3 of this document

   o Contact:  Mykyta Yevstifeyev <evnikita2@gmail.com>

   o Author/Change Controller:  IESG <iesg@ietf.org>

   o References:  See Section 5 of this document


3.  Security Considerations

   Generic security considerations for URIs are discussed in Section 7
   of RFC 3986 [RFC3986].

   The 'view-source' URIs may sometimes reveal the information (source
   code) that is a governmental, trade or other type of secret and,
   therefore, disclose confidential information.  It can also sometimes
   refer to the source code that is under certain legal provisions,
   according to which an individual or a company may not have granted
   the free access or other actions with regard to it.  The users of
   such information should be careful with regard to these matters.


4.  IANA Considerations

   IANA is asked to register the 'view-source' URI scheme using the
   template of Section 2.


5.  References

5.1.  Normative References

   [RFC2046]  Freed, N. and N. Borenstein, "Multipurpose Internet Mail
              Extensions (MIME) Part Two: Media Types", RFC 2046,
              November 1996.

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC2854]  Connolly, D. and L. Masinter, "The 'text/html' Media
              Type", RFC 2854, June 2000.



Yevstifeyev             Expires October 25, 2011                [Page 4]


INTERNET DRAFT          'view-source' URI Scheme          April 23, 2011


   [RFC3629]  Yergeau, F., "UTF-8, a transformation format of ISO
              10646", STD 63, RFC 3629, November 2003.

   [RFC3986]  Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform
              Resource Identifier (URI): Generic Syntax", STD 66,
              RFC 3986, January 2005.

   [RFC5234]  Crocker, D., Ed., and P. Overell, "Augmented BNF for
              Syntax Specifications: ABNF", STD 68, RFC 5234, January
              2008.


5.2.  Informative References

   [MSDN-VIEW-SOURCE]
              Microsoft Corporation, "view-source Protocol," Microsoft
              Developer Network (MSDN).
              <http://msdn.microsoft.com/en-us/library/aa767742.aspx>

   [RFC3966]  Schulzrinne, H., "The tel URI for Telephone Numbers",
              RFC 3966, December 2004.

   [RFC4248]  Hoffman, P., "The telnet URI Scheme", RFC 4248, October
              2005.

   [RFC4395]  Hansen, T., Hardie, T., and L. Masinter, "Guidelines and
              Registration Procedures for New URI Schemes", BCP 35,
              RFC 4395, February 2006.

   [RFC5322]  Resnick, P., Ed., "Internet Message Format", RFC 5322,
              October 2008.

   [RFC6068]  Duerst, M., Masinter, L., and J. Zawinski, "The 'mailto'
              URI Scheme", RFC 6068, October 2010.

   [WIKI-VIEW-SOURCE]
              Wikipedia Contributors, "View-source URI scheme,"
              Wikipedia, The Free Encyclopedia, March 2011.
              <http://en.wikipedia.org/wiki/View-source_URI_scheme>


Author's Addresses

   Mykyta Yevstifeyev
   8 Kuzovkov St., flat 25
   Kotovsk
   Ukraine




Yevstifeyev             Expires October 25, 2011                [Page 5]


INTERNET DRAFT          'view-source' URI Scheme          April 23, 2011


   EMail: evnikita2@gmail.com


















































Yevstifeyev             Expires October 25, 2011                [Page 6]