Bug 199307 - Web Inspector: support `console.screenshot` with dataURL strings
Summary: Web Inspector: support `console.screenshot` with dataURL strings
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: Devin Rousso
URL:
Keywords: InRadar
Depends on: 199308
Blocks: 200747
  Show dependency treegraph
 
Reported: 2019-06-27 19:45 PDT by Devin Rousso
Modified: 2019-08-14 18:16 PDT (History)
5 users (show)

See Also:


Attachments
Patch (4.80 KB, patch)
2019-06-27 22:51 PDT, Devin Rousso
no flags Details | Formatted Diff | Diff
Patch (13.61 KB, patch)
2019-08-14 12:50 PDT, Devin Rousso
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Devin Rousso 2019-06-27 19:45:19 PDT
.
Comment 1 Devin Rousso 2019-06-27 22:51:18 PDT
Created attachment 373087 [details]
Patch
Comment 2 Joseph Pecoraro 2019-07-22 13:18:46 PDT
Comment on attachment 373087 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=373087&action=review

r=me

> Source/WebCore/page/PageConsoleClient.cpp:315
> +    if (dataURL.isEmpty() || dataURL == "data:,") {

Seems like a weird case check for just "data:,". Someone could do: `data:image/png," and bypass this.
Comment 3 Devin Rousso 2019-07-24 16:49:24 PDT
I'm going to hold off on this a bit, as I think we should be a bit smarter about what is and isn't a dataURL.
Comment 4 Devin Rousso 2019-08-14 12:50:46 PDT
Created attachment 376297 [details]
Patch
Comment 5 WebKit Commit Bot 2019-08-14 14:59:30 PDT
Comment on attachment 376297 [details]
Patch

Clearing flags on attachment: 376297

Committed r248688: <https://trac.webkit.org/changeset/248688>
Comment 6 WebKit Commit Bot 2019-08-14 14:59:31 PDT
All reviewed patches have been landed.  Closing bug.
Comment 7 Radar WebKit Bug Importer 2019-08-14 15:00:20 PDT
<rdar://problem/54320656>