From 3fccfa7aeb420779df762121438b5bbc4f809deb Mon Sep 17 00:00:00 2001 From: Dan Robertson Date: Thu, 5 May 2022 02:12:14 +0000 Subject: [PATCH] Only allow blob: URLs that have a backing blob Document the need to return a network error on fetch if the blob URL has no backing blob. --- fetch.bs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/fetch.bs b/fetch.bs index 6471179cb..20f888059 100644 --- a/fetch.bs +++ b/fetch.bs @@ -4503,12 +4503,14 @@ steps: canceled:
    -
  1. Let blob be request's current URL's - blob URL entry's object. +

  2. Let blobURLEntry be request's current URL's + blob URL entry.

  3. -

    If request's method is not `GET` or - blob is not a {{Blob}} object, then return a network error. [[!FILEAPI]] +

    If request's method is not `GET`, + blobURLEntry is null, or blobURLEntry's + object is not a {{Blob}} object, then return a + network error. [[!FILEAPI]]

    The `GET` method restriction serves no useful purpose other than being interoperable.