{"action":"created","comment":{"url":"https://api.github.com/repos/w3c/webappsec-csp/pulls/comments/90643740","pull_request_review_id":11161756,"id":90643740,"diff_hunk":"@@ -636,6 +636,60 @@ <h4 id=\"subsume-source-list\" algorithm>\n     In this case, |A| <a>subsumes</a> |B|.\n   </div>\n \n+  <h4 id=\"subsume-directive\" algorithm>\n+    Does <a>serialized-policy</a> |A| subsume <a>serialized-policy</a>\n+    |B| given their respective <a for=\"request\">origins</a>?\n+  </h4>\n+\n+  Given <a>serialized-policy</a> |A| with <a for=\"request\">origin</a>\n+  (|origin A|) and  <a>serialized-policy</a> |B| with \n+  <a for=\"request\">origin</a>  (|origin B|), this algorithm returns \"`Subsumes`\"\n+  if |A| <a>subsumes</a> |B|, and returns \"`Does Not Subsume`\" otherwise.\n+\n+  1.  If |A|'s <a>directive set</a> size is 0, return \"`Subsumes`\".\n+\n+  2.  For |directive A| in |set A|:\n+\n+      1.  Let |directive name| be |directive A|'s <a for=\"directive\">name</a>.\n+\n+      2.  If |directive name| is \"`default-src`\", \"`report-uri`\", \"`report-to`\",\n+          continue to the next |directive A|.\n+\n+      3.  Let |effective directive A| be the result of executing\n+          [[#operative-directive]] given |directive name| and |A|.\n+\n+      4.  Let |effective directive B| be the result of executing\n+          [[#operative-directive]] given |directive name| and |B|.\n+\n+      5.  If |effective directive A| is `null`, continue to the next \n+          |directive A|.\n+\n+      6.  If |effective directive B| is `null`, return \"`Does Not Subsume`\".\n+\n+      7.  If |directive A|'s <a>directive-value</a> is a \n+          <a>serialized-source-list</a>:\n+\n+          1.  If the result of executing [[#subsume-source-list]] is \n+              \"`Does Not Subsume`\" given |effective directive A|, |origin A|, \n+              |directive name|, |effective directive B|, |origin B|, and \n+              |directive name|, return \"`Does Not Subsume`\".\n+\n+      8.  If |directive A|'s <a>directive-value</a> is a \n+          <a>ancestor-source-list</a>:\n+\n+          1.  ISSUE: TODO.\n+\n+      9.  If |directive A|'s <a>directive-value</a> is a \n+          <a>media-type-list</a>:","path":"embedded/index.src.html","position":48,"original_position":48,"commit_id":"1fd56bf78401d7b02ebd90201bb111f119cdabea","original_commit_id":"1fd56bf78401d7b02ebd90201bb111f119cdabea","user":{"login":"mikewest","id":1497,"avatar_url":"https://avatars.githubusercontent.com/u/1497?v=3","gravatar_id":"","url":"https://api.github.com/users/mikewest","html_url":"https://github.com/mikewest","followers_url":"https://api.github.com/users/mikewest/followers","following_url":"https://api.github.com/users/mikewest/following{/other_user}","gists_url":"https://api.github.com/users/mikewest/gists{/gist_id}","starred_url":"https://api.github.com/users/mikewest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikewest/subscriptions","organizations_url":"https://api.github.com/users/mikewest/orgs","repos_url":"https://api.github.com/users/mikewest/repos","events_url":"https://api.github.com/users/mikewest/events{/privacy}","received_events_url":"https://api.github.com/users/mikewest/received_events","type":"User","site_admin":false},"body":"Ditto for `plugin-types`.","created_at":"2016-12-02T13:46:44Z","updated_at":"2016-12-02T13:48:51Z","html_url":"https://github.com/w3c/webappsec-csp/pull/154#discussion_r90643740","pull_request_url":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154","_links":{"self":{"href":"https://api.github.com/repos/w3c/webappsec-csp/pulls/comments/90643740"},"html":{"href":"https://github.com/w3c/webappsec-csp/pull/154#discussion_r90643740"},"pull_request":{"href":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154"}}},"pull_request":{"url":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154","id":95719395,"html_url":"https://github.com/w3c/webappsec-csp/pull/154","diff_url":"https://github.com/w3c/webappsec-csp/pull/154.diff","patch_url":"https://github.com/w3c/webappsec-csp/pull/154.patch","issue_url":"https://api.github.com/repos/w3c/webappsec-csp/issues/154","number":154,"state":"open","locked":false,"title":"Embbeding-CSP: Subsumption on policy to policy level","user":{"login":"Sun77789","id":5797085,"avatar_url":"https://avatars.githubusercontent.com/u/5797085?v=3","gravatar_id":"","url":"https://api.github.com/users/Sun77789","html_url":"https://github.com/Sun77789","followers_url":"https://api.github.com/users/Sun77789/followers","following_url":"https://api.github.com/users/Sun77789/following{/other_user}","gists_url":"https://api.github.com/users/Sun77789/gists{/gist_id}","starred_url":"https://api.github.com/users/Sun77789/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sun77789/subscriptions","organizations_url":"https://api.github.com/users/Sun77789/orgs","repos_url":"https://api.github.com/users/Sun77789/repos","events_url":"https://api.github.com/users/Sun77789/events{/privacy}","received_events_url":"https://api.github.com/users/Sun77789/received_events","type":"User","site_admin":false},"body":"To be submitted after: https://github.com/w3c/webappsec-csp/pull/153","created_at":"2016-11-29T15:54:24Z","updated_at":"2016-12-02T13:48:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"53f92e1f08ccaa81f41b8833b5c392101c209d77","assignee":{"login":"mikewest","id":1497,"avatar_url":"https://avatars.githubusercontent.com/u/1497?v=3","gravatar_id":"","url":"https://api.github.com/users/mikewest","html_url":"https://github.com/mikewest","followers_url":"https://api.github.com/users/mikewest/followers","following_url":"https://api.github.com/users/mikewest/following{/other_user}","gists_url":"https://api.github.com/users/mikewest/gists{/gist_id}","starred_url":"https://api.github.com/users/mikewest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikewest/subscriptions","organizations_url":"https://api.github.com/users/mikewest/orgs","repos_url":"https://api.github.com/users/mikewest/repos","events_url":"https://api.github.com/users/mikewest/events{/privacy}","received_events_url":"https://api.github.com/users/mikewest/received_events","type":"User","site_admin":false},"assignees":[{"login":"mikewest","id":1497,"avatar_url":"https://avatars.githubusercontent.com/u/1497?v=3","gravatar_id":"","url":"https://api.github.com/users/mikewest","html_url":"https://github.com/mikewest","followers_url":"https://api.github.com/users/mikewest/followers","following_url":"https://api.github.com/users/mikewest/following{/other_user}","gists_url":"https://api.github.com/users/mikewest/gists{/gist_id}","starred_url":"https://api.github.com/users/mikewest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikewest/subscriptions","organizations_url":"https://api.github.com/users/mikewest/orgs","repos_url":"https://api.github.com/users/mikewest/repos","events_url":"https://api.github.com/users/mikewest/events{/privacy}","received_events_url":"https://api.github.com/users/mikewest/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154/commits","review_comments_url":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154/comments","review_comment_url":"https://api.github.com/repos/w3c/webappsec-csp/pulls/comments{/number}","comments_url":"https://api.github.com/repos/w3c/webappsec-csp/issues/154/comments","statuses_url":"https://api.github.com/repos/w3c/webappsec-csp/statuses/1fd56bf78401d7b02ebd90201bb111f119cdabea","head":{"label":"Sun77789:directiveLevel","ref":"directiveLevel","sha":"1fd56bf78401d7b02ebd90201bb111f119cdabea","user":{"login":"Sun77789","id":5797085,"avatar_url":"https://avatars.githubusercontent.com/u/5797085?v=3","gravatar_id":"","url":"https://api.github.com/users/Sun77789","html_url":"https://github.com/Sun77789","followers_url":"https://api.github.com/users/Sun77789/followers","following_url":"https://api.github.com/users/Sun77789/following{/other_user}","gists_url":"https://api.github.com/users/Sun77789/gists{/gist_id}","starred_url":"https://api.github.com/users/Sun77789/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sun77789/subscriptions","organizations_url":"https://api.github.com/users/Sun77789/orgs","repos_url":"https://api.github.com/users/Sun77789/repos","events_url":"https://api.github.com/users/Sun77789/events{/privacy}","received_events_url":"https://api.github.com/users/Sun77789/received_events","type":"User","site_admin":false},"repo":{"id":72195104,"name":"webappsec-csp","full_name":"Sun77789/webappsec-csp","owner":{"login":"Sun77789","id":5797085,"avatar_url":"https://avatars.githubusercontent.com/u/5797085?v=3","gravatar_id":"","url":"https://api.github.com/users/Sun77789","html_url":"https://github.com/Sun77789","followers_url":"https://api.github.com/users/Sun77789/followers","following_url":"https://api.github.com/users/Sun77789/following{/other_user}","gists_url":"https://api.github.com/users/Sun77789/gists{/gist_id}","starred_url":"https://api.github.com/users/Sun77789/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sun77789/subscriptions","organizations_url":"https://api.github.com/users/Sun77789/orgs","repos_url":"https://api.github.com/users/Sun77789/repos","events_url":"https://api.github.com/users/Sun77789/events{/privacy}","received_events_url":"https://api.github.com/users/Sun77789/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Sun77789/webappsec-csp","description":"WebAppSec Content Security Policy","fork":true,"url":"https://api.github.com/repos/Sun77789/webappsec-csp","forks_url":"https://api.github.com/repos/Sun77789/webappsec-csp/forks","keys_url":"https://api.github.com/repos/Sun77789/webappsec-csp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Sun77789/webappsec-csp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Sun77789/webappsec-csp/teams","hooks_url":"https://api.github.com/repos/Sun77789/webappsec-csp/hooks","issue_events_url":"https://api.github.com/repos/Sun77789/webappsec-csp/issues/events{/number}","events_url":"https://api.github.com/repos/Sun77789/webappsec-csp/events","assignees_url":"https://api.github.com/repos/Sun77789/webappsec-csp/assignees{/user}","branches_url":"https://api.github.com/repos/Sun77789/webappsec-csp/branches{/branch}","tags_url":"https://api.github.com/repos/Sun77789/webappsec-csp/tags","blobs_url":"https://api.github.com/repos/Sun77789/webappsec-csp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Sun77789/webappsec-csp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Sun77789/webappsec-csp/git/refs{/sha}","trees_url":"https://api.github.com/repos/Sun77789/webappsec-csp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Sun77789/webappsec-csp/statuses/{sha}","languages_url":"https://api.github.com/repos/Sun77789/webappsec-csp/languages","stargazers_url":"https://api.github.com/repos/Sun77789/webappsec-csp/stargazers","contributors_url":"https://api.github.com/repos/Sun77789/webappsec-csp/contributors","subscribers_url":"https://api.github.com/repos/Sun77789/webappsec-csp/subscribers","subscription_url":"https://api.github.com/repos/Sun77789/webappsec-csp/subscription","commits_url":"https://api.github.com/repos/Sun77789/webappsec-csp/commits{/sha}","git_commits_url":"https://api.github.com/repos/Sun77789/webappsec-csp/git/commits{/sha}","comments_url":"https://api.github.com/repos/Sun77789/webappsec-csp/comments{/number}","issue_comment_url":"https://api.github.com/repos/Sun77789/webappsec-csp/issues/comments{/number}","contents_url":"https://api.github.com/repos/Sun77789/webappsec-csp/contents/{+path}","compare_url":"https://api.github.com/repos/Sun77789/webappsec-csp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Sun77789/webappsec-csp/merges","archive_url":"https://api.github.com/repos/Sun77789/webappsec-csp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Sun77789/webappsec-csp/downloads","issues_url":"https://api.github.com/repos/Sun77789/webappsec-csp/issues{/number}","pulls_url":"https://api.github.com/repos/Sun77789/webappsec-csp/pulls{/number}","milestones_url":"https://api.github.com/repos/Sun77789/webappsec-csp/milestones{/number}","notifications_url":"https://api.github.com/repos/Sun77789/webappsec-csp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Sun77789/webappsec-csp/labels{/name}","releases_url":"https://api.github.com/repos/Sun77789/webappsec-csp/releases{/id}","deployments_url":"https://api.github.com/repos/Sun77789/webappsec-csp/deployments","created_at":"2016-10-28T09:43:48Z","updated_at":"2016-10-28T09:43:49Z","pushed_at":"2016-12-02T13:44:49Z","git_url":"git://github.com/Sun77789/webappsec-csp.git","ssh_url":"git@github.com:Sun77789/webappsec-csp.git","clone_url":"https://github.com/Sun77789/webappsec-csp.git","svn_url":"https://github.com/Sun77789/webappsec-csp","homepage":"https://w3c.github.io/webappsec-csp/","size":2866,"stargazers_count":0,"watchers_count":0,"language":"HTML","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"w3c:master","ref":"master","sha":"900c47848e87e32e5439ee1d0be8329121cb6b73","user":{"login":"w3c","id":379216,"avatar_url":"https://avatars.githubusercontent.com/u/379216?v=3","gravatar_id":"","url":"https://api.github.com/users/w3c","html_url":"https://github.com/w3c","followers_url":"https://api.github.com/users/w3c/followers","following_url":"https://api.github.com/users/w3c/following{/other_user}","gists_url":"https://api.github.com/users/w3c/gists{/gist_id}","starred_url":"https://api.github.com/users/w3c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/w3c/subscriptions","organizations_url":"https://api.github.com/users/w3c/orgs","repos_url":"https://api.github.com/users/w3c/repos","events_url":"https://api.github.com/users/w3c/events{/privacy}","received_events_url":"https://api.github.com/users/w3c/received_events","type":"Organization","site_admin":false},"repo":{"id":43490815,"name":"webappsec-csp","full_name":"w3c/webappsec-csp","owner":{"login":"w3c","id":379216,"avatar_url":"https://avatars.githubusercontent.com/u/379216?v=3","gravatar_id":"","url":"https://api.github.com/users/w3c","html_url":"https://github.com/w3c","followers_url":"https://api.github.com/users/w3c/followers","following_url":"https://api.github.com/users/w3c/following{/other_user}","gists_url":"https://api.github.com/users/w3c/gists{/gist_id}","starred_url":"https://api.github.com/users/w3c/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/w3c/subscriptions","organizations_url":"https://api.github.com/users/w3c/orgs","repos_url":"https://api.github.com/users/w3c/repos","events_url":"https://api.github.com/users/w3c/events{/privacy}","received_events_url":"https://api.github.com/users/w3c/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/w3c/webappsec-csp","description":"WebAppSec Content Security Policy","fork":false,"url":"https://api.github.com/repos/w3c/webappsec-csp","forks_url":"https://api.github.com/repos/w3c/webappsec-csp/forks","keys_url":"https://api.github.com/repos/w3c/webappsec-csp/keys{/key_id}","collaborators_url":"https://api.github.com/repos/w3c/webappsec-csp/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/w3c/webappsec-csp/teams","hooks_url":"https://api.github.com/repos/w3c/webappsec-csp/hooks","issue_events_url":"https://api.github.com/repos/w3c/webappsec-csp/issues/events{/number}","events_url":"https://api.github.com/repos/w3c/webappsec-csp/events","assignees_url":"https://api.github.com/repos/w3c/webappsec-csp/assignees{/user}","branches_url":"https://api.github.com/repos/w3c/webappsec-csp/branches{/branch}","tags_url":"https://api.github.com/repos/w3c/webappsec-csp/tags","blobs_url":"https://api.github.com/repos/w3c/webappsec-csp/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/w3c/webappsec-csp/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/w3c/webappsec-csp/git/refs{/sha}","trees_url":"https://api.github.com/repos/w3c/webappsec-csp/git/trees{/sha}","statuses_url":"https://api.github.com/repos/w3c/webappsec-csp/statuses/{sha}","languages_url":"https://api.github.com/repos/w3c/webappsec-csp/languages","stargazers_url":"https://api.github.com/repos/w3c/webappsec-csp/stargazers","contributors_url":"https://api.github.com/repos/w3c/webappsec-csp/contributors","subscribers_url":"https://api.github.com/repos/w3c/webappsec-csp/subscribers","subscription_url":"https://api.github.com/repos/w3c/webappsec-csp/subscription","commits_url":"https://api.github.com/repos/w3c/webappsec-csp/commits{/sha}","git_commits_url":"https://api.github.com/repos/w3c/webappsec-csp/git/commits{/sha}","comments_url":"https://api.github.com/repos/w3c/webappsec-csp/comments{/number}","issue_comment_url":"https://api.github.com/repos/w3c/webappsec-csp/issues/comments{/number}","contents_url":"https://api.github.com/repos/w3c/webappsec-csp/contents/{+path}","compare_url":"https://api.github.com/repos/w3c/webappsec-csp/compare/{base}...{head}","merges_url":"https://api.github.com/repos/w3c/webappsec-csp/merges","archive_url":"https://api.github.com/repos/w3c/webappsec-csp/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/w3c/webappsec-csp/downloads","issues_url":"https://api.github.com/repos/w3c/webappsec-csp/issues{/number}","pulls_url":"https://api.github.com/repos/w3c/webappsec-csp/pulls{/number}","milestones_url":"https://api.github.com/repos/w3c/webappsec-csp/milestones{/number}","notifications_url":"https://api.github.com/repos/w3c/webappsec-csp/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/w3c/webappsec-csp/labels{/name}","releases_url":"https://api.github.com/repos/w3c/webappsec-csp/releases{/id}","deployments_url":"https://api.github.com/repos/w3c/webappsec-csp/deployments","created_at":"2015-10-01T10:33:26Z","updated_at":"2016-11-29T18:35:42Z","pushed_at":"2016-12-02T13:44:49Z","git_url":"git://github.com/w3c/webappsec-csp.git","ssh_url":"git@github.com:w3c/webappsec-csp.git","clone_url":"https://github.com/w3c/webappsec-csp.git","svn_url":"https://github.com/w3c/webappsec-csp","homepage":"https://w3c.github.io/webappsec-csp/","size":2952,"stargazers_count":26,"watchers_count":26,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":22,"mirror_url":null,"open_issues_count":71,"forks":22,"open_issues":71,"watchers":26,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154"},"html":{"href":"https://github.com/w3c/webappsec-csp/pull/154"},"issue":{"href":"https://api.github.com/repos/w3c/webappsec-csp/issues/154"},"comments":{"href":"https://api.github.com/repos/w3c/webappsec-csp/issues/154/comments"},"review_comments":{"href":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154/comments"},"review_comment":{"href":"https://api.github.com/repos/w3c/webappsec-csp/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/w3c/webappsec-csp/pulls/154/commits"},"statuses":{"href":"https://api.github.com/repos/w3c/webappsec-csp/statuses/1fd56bf78401d7b02ebd90201bb111f119cdabea"}}}}
{"actor":{"display_login":"mikewest"}}