WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
235602
CSP: Clean up effective-violation handling in reports
https://bugs.webkit.org/show_bug.cgi?id=235602
Summary
CSP: Clean up effective-violation handling in reports
Patrick Griffis
Reported
2022-01-25 12:31:38 PST
CSP: Clean up effective-violation handling in reports
Attachments
Patch
(93.20 KB, patch)
2022-01-25 12:32 PST
,
Patrick Griffis
no flags
Details
Formatted Diff
Diff
Patch
(91.59 KB, patch)
2022-01-25 12:57 PST
,
Patrick Griffis
no flags
Details
Formatted Diff
Diff
Patch
(98.51 KB, patch)
2022-01-26 08:41 PST
,
Patrick Griffis
no flags
Details
Formatted Diff
Diff
Patch
(88.21 KB, patch)
2022-01-27 07:07 PST
,
Patrick Griffis
no flags
Details
Formatted Diff
Diff
Patch
(92.94 KB, patch)
2022-01-27 07:36 PST
,
Patrick Griffis
no flags
Details
Formatted Diff
Diff
Patch
(91.01 KB, patch)
2022-01-27 07:38 PST
,
Patrick Griffis
no flags
Details
Formatted Diff
Diff
Patch
(94.53 KB, patch)
2022-01-27 09:07 PST
,
Patrick Griffis
no flags
Details
Formatted Diff
Diff
Patch for landing
(94.41 KB, patch)
2022-01-27 09:11 PST
,
Patrick Griffis
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Show Obsolete
(7)
View All
Add attachment
proposed patch, testcase, etc.
Patrick Griffis
Comment 1
2022-01-25 12:32:30 PST
Comment hidden (obsolete)
Created
attachment 449953
[details]
Patch
Patrick Griffis
Comment 2
2022-01-25 12:57:36 PST
Comment hidden (obsolete)
Created
attachment 449959
[details]
Patch
Patrick Griffis
Comment 3
2022-01-26 08:41:59 PST
Comment hidden (obsolete)
Created
attachment 450024
[details]
Patch
Patrick Griffis
Comment 4
2022-01-27 07:07:47 PST
Comment hidden (obsolete)
Created
attachment 450133
[details]
Patch
Patrick Griffis
Comment 5
2022-01-27 07:36:11 PST
Comment hidden (obsolete)
Created
attachment 450135
[details]
Patch
Patrick Griffis
Comment 6
2022-01-27 07:38:05 PST
Created
attachment 450136
[details]
Patch
Kate Cheney
Comment 7
2022-01-27 08:50:11 PST
Comment on
attachment 450136
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=450136&action=review
r=me once EWS is happy.
> Source/WebCore/page/csp/ContentSecurityPolicy.cpp:74 > + // Normalize script-src and style-src for logs as its generally what developers use
nit: missing a period at the end of this comment.
> Source/WebCore/page/csp/ContentSecurityPolicy.cpp:75 > + if (violatedDirective.nameForReporting().startsWith(ContentSecurityPolicyDirectiveNames::scriptSrc))
you could remove the else statements and have fewer lines of code if you do something like: String name = violatedDirective.nameForReporting(); if (violatedDirective.nameForReporting().startsWith(ContentSecurityPolicyDirectiveNames::scriptSrc)) name = ContentSecurityPolicyDirectiveNames::scriptSrc; if (violatedDirective.nameForReporting().startsWith(ContentSecurityPolicyDirectiveNames::styleSrc)) name = ContentSecurityPolicyDirectiveNames::styleSrc;
> Source/WebCore/page/csp/ContentSecurityPolicy.cpp:809 > + violationEventInit.violatedDirective = effectiveViolatedDirective; // Historical alias to effectiveDirective:
https://www.w3.org/TR/CSP3/#violation-events
nit: comment is missing a period.
Patrick Griffis
Comment 8
2022-01-27 09:07:33 PST
Comment hidden (obsolete)
Created
attachment 450145
[details]
Patch
Patrick Griffis
Comment 9
2022-01-27 09:11:31 PST
Created
attachment 450146
[details]
Patch for landing
EWS
Comment 10
2022-01-27 10:15:12 PST
Committed
r288678
(
246484@main
): <
https://commits.webkit.org/246484@main
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 450146
[details]
.
Radar WebKit Bug Importer
Comment 11
2022-01-27 10:16:39 PST
<
rdar://problem/88140258
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug