Bug 154040

Summary: CSP: Extract helper classes into their own files
Product: WebKit Reporter: Daniel Bates <dbates>
Component: WebCore Misc.Assignee: Daniel Bates <dbates>
Status: RESOLVED FIXED    
Severity: Normal CC: aestes, bfulgham, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Local Build   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch bfulgham: review+, bfulgham: commit-queue-

Description Daniel Bates 2016-02-09 11:11:31 PST
Currently ContentSecurityPolicy.cpp contains class definitions for various helper classes. We should extract these helper classes into their own files to better organize and compartmentalize the Content Security Policy code.
Comment 1 Radar WebKit Bug Importer 2016-02-09 11:11:50 PST
<rdar://problem/24571189>
Comment 2 Daniel Bates 2016-02-09 11:52:03 PST
Created attachment 270941 [details]
Patch
Comment 3 Brent Fulgham 2016-02-09 16:22:13 PST
Comment on attachment 270941 [details]
Patch

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

r=me. Please clean up the ChangeLog a bit so it's not so large -- most of that auto-generated information is not useful.

> Source/WebCore/ChangeLog:16
> +        (WebCore::ContentSecurityPolicy::didReceiveHeader): Ditto.

You should shrink this ChangeLog by just indicating:

WebCore::ContentSecurityPolicy implementation moved to page/csp/ContentSecurityPolicy.{h, cpp}:
WebCore::CSPSource implementation moved to page/csp/ContentSecurityPolicySource.{h, cpp}
... etc ...

> Source/WebCore/ChangeLog:35
> +        (WebCore::isSourceListNone): Deleted.

.... and mention which files these bare functions moved to.
Comment 4 Daniel Bates 2016-02-09 17:20:33 PST
(In reply to comment #3)
> [...]
> > Source/WebCore/ChangeLog:16
> > +        (WebCore::ContentSecurityPolicy::didReceiveHeader): Ditto.
> 
> You should shrink this ChangeLog by just indicating:
> 
> WebCore::ContentSecurityPolicy implementation moved to
> page/csp/ContentSecurityPolicy.{h, cpp}:
> WebCore::CSPSource implementation moved to
> page/csp/ContentSecurityPolicySource.{h, cpp}
> ... etc ...
> 

Will fix before landing.

> > Source/WebCore/ChangeLog:35
> > +        (WebCore::isSourceListNone): Deleted.
> 
> .... and mention which files these bare functions moved to.

Will fix before landing.
Comment 5 Daniel Bates 2016-02-09 17:21:21 PST
Committed r196350: <http://trac.webkit.org/changeset/196350>