{"action":"created","comment":{"url":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/comments/83274657","pull_request_review_id":4129620,"id":83274657,"diff_hunk":"@@ -0,0 +1,181 @@\n+===========\n+Definitions\n+===========\n+\n+Permission\n+==========\n+\n+A permission is a case-sensitive??? hierarchical string key that is used to determine whether a Subject can do a specific action or not.\n+The string is split into separate parts using the dot character.\n+Permissions should be structured like this.\n+\n+.. code-block:: text\n+    \n+    <PluginID>.<MainGroup>.<Subgroup1>...\n+\n+Allowed characters are:\n+\n+* \"A\" - \"Z\"\n+* \"a\" - \"z\"\n+* \"0\" - \"9\"\n+* \"_\"\n+* \"-\"\n+* \".\"\n+\n+Examples\n+~~~~~~~~\n+\n+* ``myPlugin``\n+    * Grants **full** access to all plugin's permissions.\n+\n+* ``myPlugin.commands``\n+    * Grants **full** access to all plugin's commands.\n+\n+* ``myPlugin.commands.teleport.execute``\n+    * Only grants the user the permission to execute the command. Without this permission he is not able to execute the\n+      command even if he has other `teleport` permissions.\n+      (With this permission alone the user would only be able to teleport himself to others in his current world.)\n+\n+* ``myPlugin.commands.teleport.others``\n+    * Only grants the user the permission to teleport others.\n+\n+* ``myPlugin.commands.teleport.all``\n+    * Only grants the user the permission to teleport all players at once.\n+\n+* ``myPlugin.commands.teleport.worlds``\n+    * Only grants the user the permission to teleport to all worlds.\n+\n+* ``myPlugin.commands.teleport.worlds.mynetherworld``\n+    * Only grants the user the permission to teleport to *mynetherworld*.\n+\n+\n+.. note::\n+\n+    There is no such thing as a ``myPlugin.commands.teleport.worlds.*`` wildcard permission.\n+    Use ``myPlugin.commands.teleport.worlds`` for that.\n+\n+\n+PermissionDescription\n+=====================\n+\n+The permission description is an utility that is meant to provide the server owner with details on a certain permission.\n+\n+The description consists of:\n+\n+* the target permission id\n+* a Text description\n+* and an assigned role\n+* the owning plugin\n+\n+If you have a dynamic element such as a world or item type then you can use ``<TemplateParts>``.\n+\n+Simple-Example\n+~~~~~~~~~~~~~~\n+\n+.. code-block:: text\n+    \n+    myPlugin.commands.teleport.execute\n+    \n+    Description: Allows the user to execute the teleport command.\n+    Role: user\n+    Owner: MyPlugin v1.2.3\n+\n+Template-Example\n+~~~~~~~~~~~~~~~~\n+\n+.. code-block:: text\n+    \n+    myPlugin.commands.teleport.worlds.<World>\n+    \n+    Description: Allows the user to teleport to the world <World>.\n+    Role: staff\n+    Owner: MyPlugin v1.2.3\n+\n+.. tip::\n+\n+    You might skip writing descriptions for some parent permission groups such as ``myPlugin.commands.teleport.worlds``\n+    or ``myPlugin.commands`` as their meaning can be derived from the permission structure and the defined children\n+    alone.\n+\n+Subject\n+=======\n+\n+A Subject is a holder of assigned permissions it can be obtained from all CommandSources.\n+Permissions can be granted or denied. Plugin authors will usually only deal with Subjects.\n+\n+Example\n+~~~~~~~\n+\n+The permission plugin's config might look like this.\n+\n+.. code-block:: text\n+    \n+    users:\n+      Spongie:\n+        permissions:\n+          - myPlugin.commands.teleport.execute\n+          - myPlugin.commands.teleport.others\n+          - myPlugin.commands.teleport.worlds\n+          - !myPlugin.commands.teleport.worlds.protectedworld\n+\n+In this case the user `Spongie` was granted the permission to execute the teleport command and teleport her or other players to all worlds, , other than `protectedworld`.\n+\n+Inheritance\n+~~~~~~~~~~~\n+\n+Subjects also inherit permissions from their parents, unless the given permission is defined in the subject itself.\n+Following that rule if any of his parents is granted the ``myPlugin.commands.teleport`` permission the user would\n+automatically inherit the ``myPlugin.commands.teleport.all`` permission allowing him to teleport all players at once.\n+He still is not able to teleport himself or others to the `protectedworld` though.\n+\n+If neither the subject itself nor any parent subjects grant or deny a permission then it will be inherited from the\n+default subject. The permission plugin/the server owner alone is allowed to define persistent defaults. \n+All other plugins are required to define `transient`/`virtual` defaults for their own permissions.\n+\n+.. note::\n+\n+    Persistent permission assignments always take precedence over transient ones.\n+\n+TODO: Specify persistent vs transient behaviour regarding inheritance.\n+\n+If neither the subject, nor any of its parent, nor the default grant or deny a permission, then it is automatically\n+denied.\n+\n+.. note::\n+\n+    Order of precedence in descending order:\n+    \n+    * Subject himself\n+    * Parent subjects\n+    * Defaults\n+      * Persistent (Server owner via Permission plugin)\n+      * Transient (Plugins themselves)\n+    * Deny permission\n+\n+SubjectCollections\n+==================\n+\n+A container for subjects that can be used obtained a Subject by name.\n+These are the default Subject Collections:\n+\n+* User/Player\n+* Group \n+* System\n+* Command Block\n+* Role Template","path":"source/plugin/permissions/definitions.rst","position":165,"original_position":165,"commit_id":"0e5d2b976a69b37d60885da22e7f13ca43bb9c3d","original_commit_id":"0e5d2b976a69b37d60885da22e7f13ca43bb9c3d","user":{"login":"ST-DDT","id":1579362,"avatar_url":"https://avatars.githubusercontent.com/u/1579362?v=3","gravatar_id":"","url":"https://api.github.com/users/ST-DDT","html_url":"https://github.com/ST-DDT","followers_url":"https://api.github.com/users/ST-DDT/followers","following_url":"https://api.github.com/users/ST-DDT/following{/other_user}","gists_url":"https://api.github.com/users/ST-DDT/gists{/gist_id}","starred_url":"https://api.github.com/users/ST-DDT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ST-DDT/subscriptions","organizations_url":"https://api.github.com/users/ST-DDT/orgs","repos_url":"https://api.github.com/users/ST-DDT/repos","events_url":"https://api.github.com/users/ST-DDT/events{/privacy}","received_events_url":"https://api.github.com/users/ST-DDT/received_events","type":"User","site_admin":false},"body":"Done","created_at":"2016-10-13T17:56:40Z","updated_at":"2016-10-13T17:56:40Z","html_url":"https://github.com/SpongePowered/SpongeDocs/pull/536#discussion_r83274657","pull_request_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536","_links":{"self":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/comments/83274657"},"html":{"href":"https://github.com/SpongePowered/SpongeDocs/pull/536#discussion_r83274657"},"pull_request":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536"}}},"pull_request":{"url":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536","id":88722830,"html_url":"https://github.com/SpongePowered/SpongeDocs/pull/536","diff_url":"https://github.com/SpongePowered/SpongeDocs/pull/536.diff","patch_url":"https://github.com/SpongePowered/SpongeDocs/pull/536.patch","issue_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/issues/536","number":536,"state":"open","locked":false,"title":"[WIP] Permission documentation","user":{"login":"ST-DDT","id":1579362,"avatar_url":"https://avatars.githubusercontent.com/u/1579362?v=3","gravatar_id":"","url":"https://api.github.com/users/ST-DDT","html_url":"https://github.com/ST-DDT","followers_url":"https://api.github.com/users/ST-DDT/followers","following_url":"https://api.github.com/users/ST-DDT/following{/other_user}","gists_url":"https://api.github.com/users/ST-DDT/gists{/gist_id}","starred_url":"https://api.github.com/users/ST-DDT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ST-DDT/subscriptions","organizations_url":"https://api.github.com/users/ST-DDT/orgs","repos_url":"https://api.github.com/users/ST-DDT/repos","events_url":"https://api.github.com/users/ST-DDT/events{/privacy}","received_events_url":"https://api.github.com/users/ST-DDT/received_events","type":"User","site_admin":false},"body":"# Permission System\r\n\r\nCreates some documentation on the permission system. Fixes: https://github.com/SpongePowered/SpongeDocs/issues/32\r\n\r\nIf you would like to help me just go ahead.\r\n\r\n## TODO\r\n\r\n* [ ] Index page (30%)\r\n* [ ] Definitions (80%)\r\n* [ ] Check for permissions\r\n* [ ] Provide descriptions\r\n* [ ] Provide contexts\r\n* [ ] Configure permission plugin (is there anything that I could say here?)\r\n* [ ] Implement permission plugin (may be omited)\r\n\r\n## PS\r\n\r\nPlease note that this is my first participation on this docs, so I would appreciate early feedback and suggestions for improvements.\r\nIs there a public build/showcase server for this or do I have to setup my own?\r\n","created_at":"2016-10-10T20:08:14Z","updated_at":"2016-10-13T17:56:40Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ac02eb9b4440ca68b67804e6f98db9572620f2ed","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536/commits","review_comments_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536/comments","review_comment_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/issues/536/comments","statuses_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/statuses/0e5d2b976a69b37d60885da22e7f13ca43bb9c3d","head":{"label":"ST-DDT:Permissions","ref":"Permissions","sha":"0e5d2b976a69b37d60885da22e7f13ca43bb9c3d","user":{"login":"ST-DDT","id":1579362,"avatar_url":"https://avatars.githubusercontent.com/u/1579362?v=3","gravatar_id":"","url":"https://api.github.com/users/ST-DDT","html_url":"https://github.com/ST-DDT","followers_url":"https://api.github.com/users/ST-DDT/followers","following_url":"https://api.github.com/users/ST-DDT/following{/other_user}","gists_url":"https://api.github.com/users/ST-DDT/gists{/gist_id}","starred_url":"https://api.github.com/users/ST-DDT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ST-DDT/subscriptions","organizations_url":"https://api.github.com/users/ST-DDT/orgs","repos_url":"https://api.github.com/users/ST-DDT/repos","events_url":"https://api.github.com/users/ST-DDT/events{/privacy}","received_events_url":"https://api.github.com/users/ST-DDT/received_events","type":"User","site_admin":false},"repo":{"id":70511713,"name":"SpongeDocs","full_name":"ST-DDT/SpongeDocs","owner":{"login":"ST-DDT","id":1579362,"avatar_url":"https://avatars.githubusercontent.com/u/1579362?v=3","gravatar_id":"","url":"https://api.github.com/users/ST-DDT","html_url":"https://github.com/ST-DDT","followers_url":"https://api.github.com/users/ST-DDT/followers","following_url":"https://api.github.com/users/ST-DDT/following{/other_user}","gists_url":"https://api.github.com/users/ST-DDT/gists{/gist_id}","starred_url":"https://api.github.com/users/ST-DDT/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ST-DDT/subscriptions","organizations_url":"https://api.github.com/users/ST-DDT/orgs","repos_url":"https://api.github.com/users/ST-DDT/repos","events_url":"https://api.github.com/users/ST-DDT/events{/privacy}","received_events_url":"https://api.github.com/users/ST-DDT/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ST-DDT/SpongeDocs","description":"Documentation for Sponge and its Implementations","fork":true,"url":"https://api.github.com/repos/ST-DDT/SpongeDocs","forks_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/forks","keys_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/teams","hooks_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/hooks","issue_events_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/issues/events{/number}","events_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/events","assignees_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/assignees{/user}","branches_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/branches{/branch}","tags_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/tags","blobs_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/git/refs{/sha}","trees_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/statuses/{sha}","languages_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/languages","stargazers_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/stargazers","contributors_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/contributors","subscribers_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/subscribers","subscription_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/subscription","commits_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/commits{/sha}","git_commits_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/git/commits{/sha}","comments_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/comments{/number}","issue_comment_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/issues/comments{/number}","contents_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/contents/{+path}","compare_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/merges","archive_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/downloads","issues_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/issues{/number}","pulls_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/pulls{/number}","milestones_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/milestones{/number}","notifications_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/labels{/name}","releases_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/releases{/id}","deployments_url":"https://api.github.com/repos/ST-DDT/SpongeDocs/deployments","created_at":"2016-10-10T17:25:45Z","updated_at":"2016-10-10T17:25:47Z","pushed_at":"2016-10-11T16:58:54Z","git_url":"git://github.com/ST-DDT/SpongeDocs.git","ssh_url":"git@github.com:ST-DDT/SpongeDocs.git","clone_url":"https://github.com/ST-DDT/SpongeDocs.git","svn_url":"https://github.com/ST-DDT/SpongeDocs","homepage":"","size":5206,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"SpongePowered:master","ref":"master","sha":"fb1f65425bc433df2a5dce630d5f61f305fb6658","user":{"login":"SpongePowered","id":8683473,"avatar_url":"https://avatars.githubusercontent.com/u/8683473?v=3","gravatar_id":"","url":"https://api.github.com/users/SpongePowered","html_url":"https://github.com/SpongePowered","followers_url":"https://api.github.com/users/SpongePowered/followers","following_url":"https://api.github.com/users/SpongePowered/following{/other_user}","gists_url":"https://api.github.com/users/SpongePowered/gists{/gist_id}","starred_url":"https://api.github.com/users/SpongePowered/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SpongePowered/subscriptions","organizations_url":"https://api.github.com/users/SpongePowered/orgs","repos_url":"https://api.github.com/users/SpongePowered/repos","events_url":"https://api.github.com/users/SpongePowered/events{/privacy}","received_events_url":"https://api.github.com/users/SpongePowered/received_events","type":"Organization","site_admin":false},"repo":{"id":27024702,"name":"SpongeDocs","full_name":"SpongePowered/SpongeDocs","owner":{"login":"SpongePowered","id":8683473,"avatar_url":"https://avatars.githubusercontent.com/u/8683473?v=3","gravatar_id":"","url":"https://api.github.com/users/SpongePowered","html_url":"https://github.com/SpongePowered","followers_url":"https://api.github.com/users/SpongePowered/followers","following_url":"https://api.github.com/users/SpongePowered/following{/other_user}","gists_url":"https://api.github.com/users/SpongePowered/gists{/gist_id}","starred_url":"https://api.github.com/users/SpongePowered/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SpongePowered/subscriptions","organizations_url":"https://api.github.com/users/SpongePowered/orgs","repos_url":"https://api.github.com/users/SpongePowered/repos","events_url":"https://api.github.com/users/SpongePowered/events{/privacy}","received_events_url":"https://api.github.com/users/SpongePowered/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SpongePowered/SpongeDocs","description":"Documentation for Sponge and its Implementations","fork":false,"url":"https://api.github.com/repos/SpongePowered/SpongeDocs","forks_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/forks","keys_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/teams","hooks_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/hooks","issue_events_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/issues/events{/number}","events_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/events","assignees_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/assignees{/user}","branches_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/branches{/branch}","tags_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/tags","blobs_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/git/refs{/sha}","trees_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/statuses/{sha}","languages_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/languages","stargazers_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/stargazers","contributors_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/contributors","subscribers_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/subscribers","subscription_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/subscription","commits_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/commits{/sha}","git_commits_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/git/commits{/sha}","comments_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/comments{/number}","issue_comment_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/issues/comments{/number}","contents_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/contents/{+path}","compare_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/merges","archive_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/downloads","issues_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/issues{/number}","pulls_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls{/number}","milestones_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/milestones{/number}","notifications_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/labels{/name}","releases_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/releases{/id}","deployments_url":"https://api.github.com/repos/SpongePowered/SpongeDocs/deployments","created_at":"2014-11-23T06:56:04Z","updated_at":"2016-09-25T18:29:09Z","pushed_at":"2016-10-11T16:58:55Z","git_url":"git://github.com/SpongePowered/SpongeDocs.git","ssh_url":"git@github.com:SpongePowered/SpongeDocs.git","clone_url":"https://github.com/SpongePowered/SpongeDocs.git","svn_url":"https://github.com/SpongePowered/SpongeDocs","homepage":"","size":6403,"stargazers_count":63,"watchers_count":63,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":69,"mirror_url":null,"open_issues_count":63,"forks":69,"open_issues":63,"watchers":63,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536"},"html":{"href":"https://github.com/SpongePowered/SpongeDocs/pull/536"},"issue":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/issues/536"},"comments":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/issues/536/comments"},"review_comments":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536/comments"},"review_comment":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/pulls/536/commits"},"statuses":{"href":"https://api.github.com/repos/SpongePowered/SpongeDocs/statuses/0e5d2b976a69b37d60885da22e7f13ca43bb9c3d"}}}}
{"actor":{"display_login":"ST-DDT"}}