{"action":"created","comment":{"url":"https://api.github.com/repos/apereo/cas/pulls/comments/140831565","pull_request_review_id":64960398,"id":140831565,"diff_hunk":"@@ -229,6 +237,32 @@ public boolean preHandle(final HttpServletRequest request, final HttpServletResp\n \n             }\n         };\n+        final String throttler = casProperties.getAuthn().getOauth().getThrottler();\n+        if (throttler.equals(\"neverThrottle\")) {\n+            return oauthHandlerInterceptorAdapter;\n+        } else {\n+            final HandlerInterceptor throttledInterceptor = this.applicationContext.getBean(throttler, HandlerInterceptor.class);\n+            final String throttledUrl = BASE_OAUTH20_URL.concat(\"/\").concat(ACCESS_TOKEN_URL);\n+            HandlerInterceptorAdapter throttledInceptorAdapter = new HandlerInterceptorAdapter() {\n+                @Override\n+                public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception {","path":"support/cas-server-support-oauth/src/main/java/org/apereo/cas/config/CasOAuthConfiguration.java","position":58,"original_position":58,"commit_id":"3f055a1612fe11b35aeaf92cd7f827e0f5598b0d","original_commit_id":"3f055a1612fe11b35aeaf92cd7f827e0f5598b0d","user":{"login":"codacy-bot","id":19940114,"avatar_url":"https://avatars1.githubusercontent.com/u/19940114?v=4","gravatar_id":"","url":"https://api.github.com/users/codacy-bot","html_url":"https://github.com/codacy-bot","followers_url":"https://api.github.com/users/codacy-bot/followers","following_url":"https://api.github.com/users/codacy-bot/following{/other_user}","gists_url":"https://api.github.com/users/codacy-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/codacy-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codacy-bot/subscriptions","organizations_url":"https://api.github.com/users/codacy-bot/orgs","repos_url":"https://api.github.com/users/codacy-bot/repos","events_url":"https://api.github.com/users/codacy-bot/events{/privacy}","received_events_url":"https://api.github.com/users/codacy-bot/received_events","type":"User","site_admin":false},"body":"![Codacy](https://www.codacy.com/assets/images/favicon.png) Issue found: [Parameter request should be final.](https://www.codacy.com/app/ApereoCAS/cas/pullRequest?prid=939649)","created_at":"2017-09-25T16:44:00Z","updated_at":"2017-09-25T16:44:00Z","html_url":"https://github.com/apereo/cas/pull/2949#discussion_r140831565","pull_request_url":"https://api.github.com/repos/apereo/cas/pulls/2949","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/apereo/cas/pulls/comments/140831565"},"html":{"href":"https://github.com/apereo/cas/pull/2949#discussion_r140831565"},"pull_request":{"href":"https://api.github.com/repos/apereo/cas/pulls/2949"}}},"pull_request":{"url":"https://api.github.com/repos/apereo/cas/pulls/2949","id":142927999,"html_url":"https://github.com/apereo/cas/pull/2949","diff_url":"https://github.com/apereo/cas/pull/2949.diff","patch_url":"https://github.com/apereo/cas/pull/2949.patch","issue_url":"https://api.github.com/repos/apereo/cas/issues/2949","number":2949,"state":"open","locked":false,"title":"Add cas throttle to o auth","user":{"login":"philliprower","id":1828651,"avatar_url":"https://avatars1.githubusercontent.com/u/1828651?v=4","gravatar_id":"","url":"https://api.github.com/users/philliprower","html_url":"https://github.com/philliprower","followers_url":"https://api.github.com/users/philliprower/followers","following_url":"https://api.github.com/users/philliprower/following{/other_user}","gists_url":"https://api.github.com/users/philliprower/gists{/gist_id}","starred_url":"https://api.github.com/users/philliprower/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philliprower/subscriptions","organizations_url":"https://api.github.com/users/philliprower/orgs","repos_url":"https://api.github.com/users/philliprower/repos","events_url":"https://api.github.com/users/philliprower/events{/privacy}","received_events_url":"https://api.github.com/users/philliprower/received_events","type":"User","site_admin":false},"body":"Enables CAS Throttle to be configured for accessing an OAuth token.  Prevents brute force attacks on OAuth configured CAS on the /accessToken path.  Similar to the CAS Rest configuration for CAS Throttle.\r\n\r\nAlso reverts change to /accessToken from GET back to POST.  Please see https://tools.ietf.org/html/rfc6749#section-4.1.3.  Plus the CAS documentation also specifies it should be a POST and not a GET.\r\n","created_at":"2017-09-25T16:27:51Z","updated_at":"2017-09-25T16:44:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2c0f7f189ef2eb0301e3b91f978f99ad936741ea","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/apereo/cas/pulls/2949/commits","review_comments_url":"https://api.github.com/repos/apereo/cas/pulls/2949/comments","review_comment_url":"https://api.github.com/repos/apereo/cas/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apereo/cas/issues/2949/comments","statuses_url":"https://api.github.com/repos/apereo/cas/statuses/3f055a1612fe11b35aeaf92cd7f827e0f5598b0d","head":{"label":"philliprower:AddCASThrottleToOAuth","ref":"AddCASThrottleToOAuth","sha":"3f055a1612fe11b35aeaf92cd7f827e0f5598b0d","user":{"login":"philliprower","id":1828651,"avatar_url":"https://avatars1.githubusercontent.com/u/1828651?v=4","gravatar_id":"","url":"https://api.github.com/users/philliprower","html_url":"https://github.com/philliprower","followers_url":"https://api.github.com/users/philliprower/followers","following_url":"https://api.github.com/users/philliprower/following{/other_user}","gists_url":"https://api.github.com/users/philliprower/gists{/gist_id}","starred_url":"https://api.github.com/users/philliprower/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philliprower/subscriptions","organizations_url":"https://api.github.com/users/philliprower/orgs","repos_url":"https://api.github.com/users/philliprower/repos","events_url":"https://api.github.com/users/philliprower/events{/privacy}","received_events_url":"https://api.github.com/users/philliprower/received_events","type":"User","site_admin":false},"repo":{"id":70742109,"name":"cas","full_name":"philliprower/cas","owner":{"login":"philliprower","id":1828651,"avatar_url":"https://avatars1.githubusercontent.com/u/1828651?v=4","gravatar_id":"","url":"https://api.github.com/users/philliprower","html_url":"https://github.com/philliprower","followers_url":"https://api.github.com/users/philliprower/followers","following_url":"https://api.github.com/users/philliprower/following{/other_user}","gists_url":"https://api.github.com/users/philliprower/gists{/gist_id}","starred_url":"https://api.github.com/users/philliprower/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/philliprower/subscriptions","organizations_url":"https://api.github.com/users/philliprower/orgs","repos_url":"https://api.github.com/users/philliprower/repos","events_url":"https://api.github.com/users/philliprower/events{/privacy}","received_events_url":"https://api.github.com/users/philliprower/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/philliprower/cas","description":"Apereo CAS - Enterprise Single Sign On for all","fork":true,"url":"https://api.github.com/repos/philliprower/cas","forks_url":"https://api.github.com/repos/philliprower/cas/forks","keys_url":"https://api.github.com/repos/philliprower/cas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/philliprower/cas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/philliprower/cas/teams","hooks_url":"https://api.github.com/repos/philliprower/cas/hooks","issue_events_url":"https://api.github.com/repos/philliprower/cas/issues/events{/number}","events_url":"https://api.github.com/repos/philliprower/cas/events","assignees_url":"https://api.github.com/repos/philliprower/cas/assignees{/user}","branches_url":"https://api.github.com/repos/philliprower/cas/branches{/branch}","tags_url":"https://api.github.com/repos/philliprower/cas/tags","blobs_url":"https://api.github.com/repos/philliprower/cas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/philliprower/cas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/philliprower/cas/git/refs{/sha}","trees_url":"https://api.github.com/repos/philliprower/cas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/philliprower/cas/statuses/{sha}","languages_url":"https://api.github.com/repos/philliprower/cas/languages","stargazers_url":"https://api.github.com/repos/philliprower/cas/stargazers","contributors_url":"https://api.github.com/repos/philliprower/cas/contributors","subscribers_url":"https://api.github.com/repos/philliprower/cas/subscribers","subscription_url":"https://api.github.com/repos/philliprower/cas/subscription","commits_url":"https://api.github.com/repos/philliprower/cas/commits{/sha}","git_commits_url":"https://api.github.com/repos/philliprower/cas/git/commits{/sha}","comments_url":"https://api.github.com/repos/philliprower/cas/comments{/number}","issue_comment_url":"https://api.github.com/repos/philliprower/cas/issues/comments{/number}","contents_url":"https://api.github.com/repos/philliprower/cas/contents/{+path}","compare_url":"https://api.github.com/repos/philliprower/cas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/philliprower/cas/merges","archive_url":"https://api.github.com/repos/philliprower/cas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/philliprower/cas/downloads","issues_url":"https://api.github.com/repos/philliprower/cas/issues{/number}","pulls_url":"https://api.github.com/repos/philliprower/cas/pulls{/number}","milestones_url":"https://api.github.com/repos/philliprower/cas/milestones{/number}","notifications_url":"https://api.github.com/repos/philliprower/cas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/philliprower/cas/labels{/name}","releases_url":"https://api.github.com/repos/philliprower/cas/releases{/id}","deployments_url":"https://api.github.com/repos/philliprower/cas/deployments","created_at":"2016-10-12T21:13:17Z","updated_at":"2016-10-12T21:13:30Z","pushed_at":"2017-09-25T15:26:29Z","git_url":"git://github.com/philliprower/cas.git","ssh_url":"git@github.com:philliprower/cas.git","clone_url":"https://github.com/philliprower/cas.git","svn_url":"https://github.com/philliprower/cas","homepage":"https://apereo.github.io/cas/","size":1273288,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"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":"apereo:5.0.x","ref":"5.0.x","sha":"c4eaf8039b47e138e3342c1a4e22069aa7eaa50f","user":{"login":"apereo","id":4679233,"avatar_url":"https://avatars3.githubusercontent.com/u/4679233?v=4","gravatar_id":"","url":"https://api.github.com/users/apereo","html_url":"https://github.com/apereo","followers_url":"https://api.github.com/users/apereo/followers","following_url":"https://api.github.com/users/apereo/following{/other_user}","gists_url":"https://api.github.com/users/apereo/gists{/gist_id}","starred_url":"https://api.github.com/users/apereo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apereo/subscriptions","organizations_url":"https://api.github.com/users/apereo/orgs","repos_url":"https://api.github.com/users/apereo/repos","events_url":"https://api.github.com/users/apereo/events{/privacy}","received_events_url":"https://api.github.com/users/apereo/received_events","type":"Organization","site_admin":false},"repo":{"id":2352744,"name":"cas","full_name":"apereo/cas","owner":{"login":"apereo","id":4679233,"avatar_url":"https://avatars3.githubusercontent.com/u/4679233?v=4","gravatar_id":"","url":"https://api.github.com/users/apereo","html_url":"https://github.com/apereo","followers_url":"https://api.github.com/users/apereo/followers","following_url":"https://api.github.com/users/apereo/following{/other_user}","gists_url":"https://api.github.com/users/apereo/gists{/gist_id}","starred_url":"https://api.github.com/users/apereo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apereo/subscriptions","organizations_url":"https://api.github.com/users/apereo/orgs","repos_url":"https://api.github.com/users/apereo/repos","events_url":"https://api.github.com/users/apereo/events{/privacy}","received_events_url":"https://api.github.com/users/apereo/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apereo/cas","description":"Apereo CAS - Enterprise Single Sign On for all earthlings and beyond.","fork":false,"url":"https://api.github.com/repos/apereo/cas","forks_url":"https://api.github.com/repos/apereo/cas/forks","keys_url":"https://api.github.com/repos/apereo/cas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apereo/cas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apereo/cas/teams","hooks_url":"https://api.github.com/repos/apereo/cas/hooks","issue_events_url":"https://api.github.com/repos/apereo/cas/issues/events{/number}","events_url":"https://api.github.com/repos/apereo/cas/events","assignees_url":"https://api.github.com/repos/apereo/cas/assignees{/user}","branches_url":"https://api.github.com/repos/apereo/cas/branches{/branch}","tags_url":"https://api.github.com/repos/apereo/cas/tags","blobs_url":"https://api.github.com/repos/apereo/cas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apereo/cas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apereo/cas/git/refs{/sha}","trees_url":"https://api.github.com/repos/apereo/cas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apereo/cas/statuses/{sha}","languages_url":"https://api.github.com/repos/apereo/cas/languages","stargazers_url":"https://api.github.com/repos/apereo/cas/stargazers","contributors_url":"https://api.github.com/repos/apereo/cas/contributors","subscribers_url":"https://api.github.com/repos/apereo/cas/subscribers","subscription_url":"https://api.github.com/repos/apereo/cas/subscription","commits_url":"https://api.github.com/repos/apereo/cas/commits{/sha}","git_commits_url":"https://api.github.com/repos/apereo/cas/git/commits{/sha}","comments_url":"https://api.github.com/repos/apereo/cas/comments{/number}","issue_comment_url":"https://api.github.com/repos/apereo/cas/issues/comments{/number}","contents_url":"https://api.github.com/repos/apereo/cas/contents/{+path}","compare_url":"https://api.github.com/repos/apereo/cas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apereo/cas/merges","archive_url":"https://api.github.com/repos/apereo/cas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apereo/cas/downloads","issues_url":"https://api.github.com/repos/apereo/cas/issues{/number}","pulls_url":"https://api.github.com/repos/apereo/cas/pulls{/number}","milestones_url":"https://api.github.com/repos/apereo/cas/milestones{/number}","notifications_url":"https://api.github.com/repos/apereo/cas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apereo/cas/labels{/name}","releases_url":"https://api.github.com/repos/apereo/cas/releases{/id}","deployments_url":"https://api.github.com/repos/apereo/cas/deployments","created_at":"2011-09-09T01:36:42Z","updated_at":"2017-09-25T10:27:59Z","pushed_at":"2017-09-25T16:27:52Z","git_url":"git://github.com/apereo/cas.git","ssh_url":"git@github.com:apereo/cas.git","clone_url":"https://github.com/apereo/cas.git","svn_url":"https://github.com/apereo/cas","homepage":"https://apereo.github.io/cas/","size":1316630,"stargazers_count":3109,"watchers_count":3109,"language":"Java","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1740,"mirror_url":null,"open_issues_count":8,"forks":1740,"open_issues":8,"watchers":3109,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apereo/cas/pulls/2949"},"html":{"href":"https://github.com/apereo/cas/pull/2949"},"issue":{"href":"https://api.github.com/repos/apereo/cas/issues/2949"},"comments":{"href":"https://api.github.com/repos/apereo/cas/issues/2949/comments"},"review_comments":{"href":"https://api.github.com/repos/apereo/cas/pulls/2949/comments"},"review_comment":{"href":"https://api.github.com/repos/apereo/cas/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apereo/cas/pulls/2949/commits"},"statuses":{"href":"https://api.github.com/repos/apereo/cas/statuses/3f055a1612fe11b35aeaf92cd7f827e0f5598b0d"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"codacy-bot"}}