{"action":"closed","number":40,"pull_request":{"url":"https://api.github.com/repos/kkos/oniguruma/pulls/40","id":97569759,"html_url":"https://github.com/kkos/oniguruma/pull/40","diff_url":"https://github.com/kkos/oniguruma/pull/40.diff","patch_url":"https://github.com/kkos/oniguruma/pull/40.patch","issue_url":"https://api.github.com/repos/kkos/oniguruma/issues/40","number":40,"state":"closed","locked":false,"title":"Deeply nested capture groups cause stack overflow","user":{"login":"k-takata","id":840186,"avatar_url":"https://avatars.githubusercontent.com/u/840186?v=3","gravatar_id":"","url":"https://api.github.com/users/k-takata","html_url":"https://github.com/k-takata","followers_url":"https://api.github.com/users/k-takata/followers","following_url":"https://api.github.com/users/k-takata/following{/other_user}","gists_url":"https://api.github.com/users/k-takata/gists{/gist_id}","starred_url":"https://api.github.com/users/k-takata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k-takata/subscriptions","organizations_url":"https://api.github.com/users/k-takata/orgs","repos_url":"https://api.github.com/users/k-takata/repos","events_url":"https://api.github.com/users/k-takata/events{/privacy}","received_events_url":"https://api.github.com/users/k-takata/received_events","type":"User","site_admin":false},"body":"Oniguruma's parser uses recursion, so it causes stack overflow when parsing\r\ndeeply nested capture groups. E.g.:\r\n\r\n  x2(\"(\" * 32767 + \"a\" + \")\" * 32767, \"a\", 0, 1)\r\n\r\nThis patch sets a limit for this.\r\nThe default value is defined in regint.h:\r\n* DEFAULT_PARSE_DEPTH_LIMIT (Currently 4096)\r\n\r\nAlso add two APIs to support this:\r\n* onig_get_parse_depth_limit\r\n* onig_set_parse_depth_limit\r\n\r\nPorted from k-takata/Onigmo#68 .","created_at":"2016-12-12T15:09:38Z","updated_at":"2016-12-13T08:05:18Z","closed_at":"2016-12-13T08:05:18Z","merged_at":"2016-12-13T08:05:18Z","merge_commit_sha":"dacfaba1082a00abea5d564931458f8d659bf3f2","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/kkos/oniguruma/pulls/40/commits","review_comments_url":"https://api.github.com/repos/kkos/oniguruma/pulls/40/comments","review_comment_url":"https://api.github.com/repos/kkos/oniguruma/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kkos/oniguruma/issues/40/comments","statuses_url":"https://api.github.com/repos/kkos/oniguruma/statuses/6b68ebe8360adefe45be94ed0dbf13a9aa9023ef","head":{"label":"k-takata:fix-stackoverflow","ref":"fix-stackoverflow","sha":"6b68ebe8360adefe45be94ed0dbf13a9aa9023ef","user":{"login":"k-takata","id":840186,"avatar_url":"https://avatars.githubusercontent.com/u/840186?v=3","gravatar_id":"","url":"https://api.github.com/users/k-takata","html_url":"https://github.com/k-takata","followers_url":"https://api.github.com/users/k-takata/followers","following_url":"https://api.github.com/users/k-takata/following{/other_user}","gists_url":"https://api.github.com/users/k-takata/gists{/gist_id}","starred_url":"https://api.github.com/users/k-takata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k-takata/subscriptions","organizations_url":"https://api.github.com/users/k-takata/orgs","repos_url":"https://api.github.com/users/k-takata/repos","events_url":"https://api.github.com/users/k-takata/events{/privacy}","received_events_url":"https://api.github.com/users/k-takata/received_events","type":"User","site_admin":false},"repo":{"id":71366005,"name":"oniguruma","full_name":"k-takata/oniguruma","owner":{"login":"k-takata","id":840186,"avatar_url":"https://avatars.githubusercontent.com/u/840186?v=3","gravatar_id":"","url":"https://api.github.com/users/k-takata","html_url":"https://github.com/k-takata","followers_url":"https://api.github.com/users/k-takata/followers","following_url":"https://api.github.com/users/k-takata/following{/other_user}","gists_url":"https://api.github.com/users/k-takata/gists{/gist_id}","starred_url":"https://api.github.com/users/k-takata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/k-takata/subscriptions","organizations_url":"https://api.github.com/users/k-takata/orgs","repos_url":"https://api.github.com/users/k-takata/repos","events_url":"https://api.github.com/users/k-takata/events{/privacy}","received_events_url":"https://api.github.com/users/k-takata/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/k-takata/oniguruma","description":"regular expression library","fork":true,"url":"https://api.github.com/repos/k-takata/oniguruma","forks_url":"https://api.github.com/repos/k-takata/oniguruma/forks","keys_url":"https://api.github.com/repos/k-takata/oniguruma/keys{/key_id}","collaborators_url":"https://api.github.com/repos/k-takata/oniguruma/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/k-takata/oniguruma/teams","hooks_url":"https://api.github.com/repos/k-takata/oniguruma/hooks","issue_events_url":"https://api.github.com/repos/k-takata/oniguruma/issues/events{/number}","events_url":"https://api.github.com/repos/k-takata/oniguruma/events","assignees_url":"https://api.github.com/repos/k-takata/oniguruma/assignees{/user}","branches_url":"https://api.github.com/repos/k-takata/oniguruma/branches{/branch}","tags_url":"https://api.github.com/repos/k-takata/oniguruma/tags","blobs_url":"https://api.github.com/repos/k-takata/oniguruma/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/k-takata/oniguruma/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/k-takata/oniguruma/git/refs{/sha}","trees_url":"https://api.github.com/repos/k-takata/oniguruma/git/trees{/sha}","statuses_url":"https://api.github.com/repos/k-takata/oniguruma/statuses/{sha}","languages_url":"https://api.github.com/repos/k-takata/oniguruma/languages","stargazers_url":"https://api.github.com/repos/k-takata/oniguruma/stargazers","contributors_url":"https://api.github.com/repos/k-takata/oniguruma/contributors","subscribers_url":"https://api.github.com/repos/k-takata/oniguruma/subscribers","subscription_url":"https://api.github.com/repos/k-takata/oniguruma/subscription","commits_url":"https://api.github.com/repos/k-takata/oniguruma/commits{/sha}","git_commits_url":"https://api.github.com/repos/k-takata/oniguruma/git/commits{/sha}","comments_url":"https://api.github.com/repos/k-takata/oniguruma/comments{/number}","issue_comment_url":"https://api.github.com/repos/k-takata/oniguruma/issues/comments{/number}","contents_url":"https://api.github.com/repos/k-takata/oniguruma/contents/{+path}","compare_url":"https://api.github.com/repos/k-takata/oniguruma/compare/{base}...{head}","merges_url":"https://api.github.com/repos/k-takata/oniguruma/merges","archive_url":"https://api.github.com/repos/k-takata/oniguruma/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/k-takata/oniguruma/downloads","issues_url":"https://api.github.com/repos/k-takata/oniguruma/issues{/number}","pulls_url":"https://api.github.com/repos/k-takata/oniguruma/pulls{/number}","milestones_url":"https://api.github.com/repos/k-takata/oniguruma/milestones{/number}","notifications_url":"https://api.github.com/repos/k-takata/oniguruma/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/k-takata/oniguruma/labels{/name}","releases_url":"https://api.github.com/repos/k-takata/oniguruma/releases{/id}","deployments_url":"https://api.github.com/repos/k-takata/oniguruma/deployments","created_at":"2016-10-19T14:30:41Z","updated_at":"2016-10-19T14:30:42Z","pushed_at":"2016-12-12T16:08:27Z","git_url":"git://github.com/k-takata/oniguruma.git","ssh_url":"git@github.com:k-takata/oniguruma.git","clone_url":"https://github.com/k-takata/oniguruma.git","svn_url":"https://github.com/k-takata/oniguruma","homepage":null,"size":1619,"stargazers_count":0,"watchers_count":0,"language":"C","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":"kkos:master","ref":"master","sha":"4ab96b4e2d4614494ca556496dc7d6123a832bea","user":{"login":"kkos","id":884169,"avatar_url":"https://avatars.githubusercontent.com/u/884169?v=3","gravatar_id":"","url":"https://api.github.com/users/kkos","html_url":"https://github.com/kkos","followers_url":"https://api.github.com/users/kkos/followers","following_url":"https://api.github.com/users/kkos/following{/other_user}","gists_url":"https://api.github.com/users/kkos/gists{/gist_id}","starred_url":"https://api.github.com/users/kkos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kkos/subscriptions","organizations_url":"https://api.github.com/users/kkos/orgs","repos_url":"https://api.github.com/users/kkos/repos","events_url":"https://api.github.com/users/kkos/events{/privacy}","received_events_url":"https://api.github.com/users/kkos/received_events","type":"User","site_admin":false},"repo":{"id":38999874,"name":"oniguruma","full_name":"kkos/oniguruma","owner":{"login":"kkos","id":884169,"avatar_url":"https://avatars.githubusercontent.com/u/884169?v=3","gravatar_id":"","url":"https://api.github.com/users/kkos","html_url":"https://github.com/kkos","followers_url":"https://api.github.com/users/kkos/followers","following_url":"https://api.github.com/users/kkos/following{/other_user}","gists_url":"https://api.github.com/users/kkos/gists{/gist_id}","starred_url":"https://api.github.com/users/kkos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kkos/subscriptions","organizations_url":"https://api.github.com/users/kkos/orgs","repos_url":"https://api.github.com/users/kkos/repos","events_url":"https://api.github.com/users/kkos/events{/privacy}","received_events_url":"https://api.github.com/users/kkos/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kkos/oniguruma","description":"regular expression library","fork":false,"url":"https://api.github.com/repos/kkos/oniguruma","forks_url":"https://api.github.com/repos/kkos/oniguruma/forks","keys_url":"https://api.github.com/repos/kkos/oniguruma/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kkos/oniguruma/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kkos/oniguruma/teams","hooks_url":"https://api.github.com/repos/kkos/oniguruma/hooks","issue_events_url":"https://api.github.com/repos/kkos/oniguruma/issues/events{/number}","events_url":"https://api.github.com/repos/kkos/oniguruma/events","assignees_url":"https://api.github.com/repos/kkos/oniguruma/assignees{/user}","branches_url":"https://api.github.com/repos/kkos/oniguruma/branches{/branch}","tags_url":"https://api.github.com/repos/kkos/oniguruma/tags","blobs_url":"https://api.github.com/repos/kkos/oniguruma/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kkos/oniguruma/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kkos/oniguruma/git/refs{/sha}","trees_url":"https://api.github.com/repos/kkos/oniguruma/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kkos/oniguruma/statuses/{sha}","languages_url":"https://api.github.com/repos/kkos/oniguruma/languages","stargazers_url":"https://api.github.com/repos/kkos/oniguruma/stargazers","contributors_url":"https://api.github.com/repos/kkos/oniguruma/contributors","subscribers_url":"https://api.github.com/repos/kkos/oniguruma/subscribers","subscription_url":"https://api.github.com/repos/kkos/oniguruma/subscription","commits_url":"https://api.github.com/repos/kkos/oniguruma/commits{/sha}","git_commits_url":"https://api.github.com/repos/kkos/oniguruma/git/commits{/sha}","comments_url":"https://api.github.com/repos/kkos/oniguruma/comments{/number}","issue_comment_url":"https://api.github.com/repos/kkos/oniguruma/issues/comments{/number}","contents_url":"https://api.github.com/repos/kkos/oniguruma/contents/{+path}","compare_url":"https://api.github.com/repos/kkos/oniguruma/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kkos/oniguruma/merges","archive_url":"https://api.github.com/repos/kkos/oniguruma/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kkos/oniguruma/downloads","issues_url":"https://api.github.com/repos/kkos/oniguruma/issues{/number}","pulls_url":"https://api.github.com/repos/kkos/oniguruma/pulls{/number}","milestones_url":"https://api.github.com/repos/kkos/oniguruma/milestones{/number}","notifications_url":"https://api.github.com/repos/kkos/oniguruma/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kkos/oniguruma/labels{/name}","releases_url":"https://api.github.com/repos/kkos/oniguruma/releases{/id}","deployments_url":"https://api.github.com/repos/kkos/oniguruma/deployments","created_at":"2015-07-13T08:19:17Z","updated_at":"2016-12-10T02:11:14Z","pushed_at":"2016-12-13T08:05:18Z","git_url":"git://github.com/kkos/oniguruma.git","ssh_url":"git@github.com:kkos/oniguruma.git","clone_url":"https://github.com/kkos/oniguruma.git","svn_url":"https://github.com/kkos/oniguruma","homepage":null,"size":1834,"stargazers_count":201,"watchers_count":201,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":41,"mirror_url":null,"open_issues_count":6,"forks":41,"open_issues":6,"watchers":201,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kkos/oniguruma/pulls/40"},"html":{"href":"https://github.com/kkos/oniguruma/pull/40"},"issue":{"href":"https://api.github.com/repos/kkos/oniguruma/issues/40"},"comments":{"href":"https://api.github.com/repos/kkos/oniguruma/issues/40/comments"},"review_comments":{"href":"https://api.github.com/repos/kkos/oniguruma/pulls/40/comments"},"review_comment":{"href":"https://api.github.com/repos/kkos/oniguruma/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kkos/oniguruma/pulls/40/commits"},"statuses":{"href":"https://api.github.com/repos/kkos/oniguruma/statuses/6b68ebe8360adefe45be94ed0dbf13a9aa9023ef"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"kkos","id":884169,"avatar_url":"https://avatars.githubusercontent.com/u/884169?v=3","gravatar_id":"","url":"https://api.github.com/users/kkos","html_url":"https://github.com/kkos","followers_url":"https://api.github.com/users/kkos/followers","following_url":"https://api.github.com/users/kkos/following{/other_user}","gists_url":"https://api.github.com/users/kkos/gists{/gist_id}","starred_url":"https://api.github.com/users/kkos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kkos/subscriptions","organizations_url":"https://api.github.com/users/kkos/orgs","repos_url":"https://api.github.com/users/kkos/repos","events_url":"https://api.github.com/users/kkos/events{/privacy}","received_events_url":"https://api.github.com/users/kkos/received_events","type":"User","site_admin":false},"comments":0,"review_comments":0,"commits":1,"additions":66,"deletions":0,"changed_files":7}}
{"actor":{"display_login":"kkos"}}