Skip to main content

WebP Image Format Media Type Registration
draft-zern-webp-02

The information below is for an old version of the document.
Document Type
This is an older version of an Internet-Draft whose latest revision state is "Active".
Author James Zern
Last updated 2021-09-21 (Latest revision 2021-08-31)
RFC stream Internet Engineering Task Force (IETF)
Formats
Reviews
Additional resources
Stream WG state (None)
Document shepherd Huapeng Zhou
IESG IESG state AD Evaluation::AD Followup
Consensus boilerplate Yes
Telechat date (None)
Responsible AD Murray Kucherawy
Send notices to shodoco@gmail.com
draft-zern-webp-02
Internet Engineering Task Force                                  J. Zern
Internet-Draft                                                Google LLC
Intended status: Standards Track                          31 August 2021
Expires: 4 March 2022

               WebP Image Format Media Type Registration
                           draft-zern-webp-02

Abstract

   WebP is a RIFF-based image file format which supports lossless and
   lossy compression as well as alpha (transparency) and animation.  It
   covers use cases similar to JPEG, PNG and GIF.

Status of This Memo

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

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF).  Note that other groups may also distribute
   working documents as Internet-Drafts.  The list of current Internet-
   Drafts is at https://datatracker.ietf.org/drafts/current/.

   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."

   This Internet-Draft will expire on 4 March 2022.

Copyright Notice

   Copyright (c) 2021 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 (https://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 the Trust Legal Provisions and are
   provided without warranty as described in the Simplified BSD License.

Zern                      Expires 4 March 2022                  [Page 1]
Internet-Draft  WebP Image Format Media Type Registratio     August 2021

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2
   2.  The 'image/webp' Media Type . . . . . . . . . . . . . . . . .   2
     2.1.  Registration Details  . . . . . . . . . . . . . . . . . .   2
   3.  Security Considerations . . . . . . . . . . . . . . . . . . .   3
   4.  Interoperability Considerations . . . . . . . . . . . . . . .   3
   5.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .   4
   6.  References  . . . . . . . . . . . . . . . . . . . . . . . . .   4
     6.1.  Normative References  . . . . . . . . . . . . . . . . . .   4
     6.2.  Informative References  . . . . . . . . . . . . . . . . .   4
   Author's Address  . . . . . . . . . . . . . . . . . . . . . . . .   5

1.  Introduction

   This document provides references for the WebP image format and
   considerations for its use across platforms.

   WebP is a Resource Interchange File Format (RIFF) [riff-spec] based
   image file format [webp-riff] which supports lossless and lossy
   compression as well as alpha (transparency) and animation.  It covers
   use cases similar to JPEG [jpeg-spec], PNG [RFC2083] and the Graphics
   Interchange Format (GIF) [gif-spec].

   WebP consists of two compression algorithms used to reduce the size
   of image pixel data, including alpha (transparency) information.
   Lossy compression is achieved using VP8 intra-frame encoding
   [RFC6386].  The lossless algorithm [webp-lossless] stores and
   restores the pixel values exactly, including the color values for
   zero alpha pixels.  The format uses subresolution images, recursively
   embedded into the format itself, for storing statistical data about
   the images, such as the used entropy codes, spatial predictors, color
   space conversion, and color table.  LZ77 [lz77], Huffman coding
   [huffman], and a color cache are used for compression of the bulk
   data.

2.  The 'image/webp' Media Type

   This section contains the media type registration details as per
   [RFC6838].

2.1.  Registration Details

   Media type name: image

   Media subtype name: webp

   Required parameters: N/A

Zern                      Expires 4 March 2022                  [Page 2]
Internet-Draft  WebP Image Format Media Type Registratio     August 2021

   Optional parameters: N/A

   Encoding considerations: Binary.  The Base64 encoding [RFC4648]
   should be used on transports that cannot accommodate binary data
   directly.

   Security considerations: See Section 3 below.

   Interoperability considerations: See Section 4 below.

   Applications which use this media type: Anywhere image size is an
   issue.

   Fragment identifier considerations: N/A

   Restrictions on usage: N/A

   Additional information:

      Deprecated alias names for this type: N/A

      Magic number(s): The first 4 bytes are 0x52, 0x49, 0x46, 0x46
      ('RIFF'), followed by 4 bytes for the RIFF chunk size.  The next 7
      bytes are 0x57, 0x45, 0x42, 0x50, 0x56, 0x50, 0x38 ('WEBPVP8').

      File extension(s): webp

      Apple Uniform Type Identifier: org.webmproject.webp conforms to
      public.image

      Object Identifiers: N/A

3.  Security Considerations

   Security risks are similar to other media content and may include
   buffer overruns and uninitialized data usage as part of the demuxing
   and decoding process [cve.mitre.org-libwebp] [crbug-security].

4.  Interoperability Considerations

   The format is defined using little-endian byte ordering (see
   Section 3.1 of [RFC2781]), but demuxing and decoding are possible on
   platforms using a different ordering with the appropriate conversion.
   The container is RIFF-based and allows extension via user defined
   chunks, but nothing beyond the chunks defined by the container format
   [webp-riff] are required for decoding of the image.

Zern                      Expires 4 March 2022                  [Page 3]
Internet-Draft  WebP Image Format Media Type Registratio     August 2021

5.  IANA Considerations

   IANA has updated the "Image Media Types" registry to include 'image/
   webp' as described in Section 2.

6.  References

6.1.  Normative References

   [RFC2781]  Hoffman, P. and F. Yergeau, "UTF-16, an encoding of ISO
              10646", RFC 2781, DOI 10.17487/RFC2781, February 2000,
              <https://www.rfc-editor.org/info/rfc2781>.

   [RFC4648]  Josefsson, S., "The Base16, Base32, and Base64 Data
              Encodings", RFC 4648, DOI 10.17487/RFC4648, October 2006,
              <https://www.rfc-editor.org/info/rfc4648>.

   [RFC6386]  Bankoski, J., Koleszar, J., Quillio, L., Salonen, J.,
              Wilkins, P., and Y. Xu, "VP8 Data Format and Decoding
              Guide", RFC 6386, DOI 10.17487/RFC6386, November 2011,
              <https://www.rfc-editor.org/info/rfc6386>.

   [RFC6838]  Freed, N., Klensin, J., and T. Hansen, "Media Type
              Specifications and Registration Procedures", BCP 13,
              RFC 6838, DOI 10.17487/RFC6838, January 2013,
              <https://www.rfc-editor.org/info/rfc6838>.

   [webp-lossless]
              Alakuijala, J., "WebP Lossless Bitstream Specification",
              September 2014,
              <https://developers.google.com/speed/webp/docs/
              webp_lossless_bitstream_specification>.

   [webp-riff]
              Google LLC, "WebP RIFF Container", April 2018,
              <https://developers.google.com/speed/webp/docs/
              riff_container>.

6.2.  Informative References

   [crbug-security]
              "libwebp Security Issues",
              <https://bugs.chromium.org/p/webp/issues/
              list?q=label%3ASecurity>.

   [cve.mitre.org-libwebp]
              "libwebp CVE List", <https://cve.mitre.org/cgi-bin/
              cvekey.cgi?keyword=libwebp>.

Zern                      Expires 4 March 2022                  [Page 4]
Internet-Draft  WebP Image Format Media Type Registratio     August 2021

   [gif-spec] "GIF89a Specification",
              <https://www.w3.org/Graphics/GIF/spec-gif89a.txt>.

   [huffman]  Huffman, D. A., "A Method for the Construction of Minimum
              Redundancy Codes", Proceedings of the Institute of Radio
              Engineers Number 9, pp. 1098-1101., September 1952.

   [jpeg-spec]
              "JPEG Standard (JPEG ISO/IEC 10918-1 ITU-T Recommendation
              T.81)", <https://www.w3.org/Graphics/JPEG/itu-t81.pdf>.

   [lz77]     Ziv, J. and A. Lempel, "A Universal Algorithm for
              Sequential Data Compression", IEEE Transactions on
              Information Theory Vol. 23, No. 3, pp. 337-343., May 1977.

   [RFC2083]  Boutell, T., "PNG (Portable Network Graphics)
              Specification Version 1.0", RFC 2083,
              DOI 10.17487/RFC2083, March 1997,
              <https://www.rfc-editor.org/info/rfc2083>.

   [riff-spec]
              "Multimedia Programming Interface and Data Specifications
              1.0", <http://www-
              mmsp.ece.mcgill.ca/Documents/AudioFormats/WAVE/Docs/
              riffmci.pdf>.

Author's Address

   James Zern
   Google LLC
   1600 Amphitheatre Parkway
   Mountain View, CA 94043
   United States of America

   Phone: +1 650 253-0000
   Email: jzern@google.com

Zern                      Expires 4 March 2022                  [Page 5]