{"action":"created","issue":{"url":"https://api.github.com/repos/mdanter/phpecc/issues/80","labels_url":"https://api.github.com/repos/mdanter/phpecc/issues/80/labels{/name}","comments_url":"https://api.github.com/repos/mdanter/phpecc/issues/80/comments","events_url":"https://api.github.com/repos/mdanter/phpecc/issues/80/events","html_url":"https://github.com/mdanter/phpecc/pull/80","id":63420028,"number":80,"title":"Refactoring","user":{"login":"afk11","id":5617245,"avatar_url":"https://avatars.githubusercontent.com/u/5617245?v=3","gravatar_id":"","url":"https://api.github.com/users/afk11","html_url":"https://github.com/afk11","followers_url":"https://api.github.com/users/afk11/followers","following_url":"https://api.github.com/users/afk11/following{/other_user}","gists_url":"https://api.github.com/users/afk11/gists{/gist_id}","starred_url":"https://api.github.com/users/afk11/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/afk11/subscriptions","organizations_url":"https://api.github.com/users/afk11/orgs","repos_url":"https://api.github.com/users/afk11/repos","events_url":"https://api.github.com/users/afk11/events{/privacy}","received_events_url":"https://api.github.com/users/afk11/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/mdanter/phpecc/labels/BC%20break","name":"BC break","color":"eb6420"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/mdanter/phpecc/milestones/1","html_url":"https://github.com/mdanter/phpecc/milestones/0.3.0","labels_url":"https://api.github.com/repos/mdanter/phpecc/milestones/1/labels","id":971420,"number":1,"title":"0.3.0","description":"","creator":{"login":"btcdrak","id":7275704,"avatar_url":"https://avatars.githubusercontent.com/u/7275704?v=3","gravatar_id":"","url":"https://api.github.com/users/btcdrak","html_url":"https://github.com/btcdrak","followers_url":"https://api.github.com/users/btcdrak/followers","following_url":"https://api.github.com/users/btcdrak/following{/other_user}","gists_url":"https://api.github.com/users/btcdrak/gists{/gist_id}","starred_url":"https://api.github.com/users/btcdrak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btcdrak/subscriptions","organizations_url":"https://api.github.com/users/btcdrak/orgs","repos_url":"https://api.github.com/users/btcdrak/repos","events_url":"https://api.github.com/users/btcdrak/events{/privacy}","received_events_url":"https://api.github.com/users/btcdrak/received_events","type":"User","site_admin":false},"open_issues":8,"closed_issues":39,"state":"open","created_at":"2015-02-09T09:27:49Z","updated_at":"2015-03-21T15:51:56Z","due_on":"2015-02-28T00:00:00Z","closed_at":null},"comments":4,"created_at":"2015-03-21T15:48:23Z","updated_at":"2015-03-25T15:11:19Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/mdanter/phpecc/pulls/80","html_url":"https://github.com/mdanter/phpecc/pull/80","diff_url":"https://github.com/mdanter/phpecc/pull/80.diff","patch_url":"https://github.com/mdanter/phpecc/pull/80.patch"},"body":"Work in progress for now, feedback on where I'm moving things welcome!"},"comment":{"url":"https://api.github.com/repos/mdanter/phpecc/issues/comments/86076088","html_url":"https://github.com/mdanter/phpecc/pull/80#issuecomment-86076088","issue_url":"https://api.github.com/repos/mdanter/phpecc/issues/80","id":86076088,"user":{"login":"aztech-dev","id":5682430,"avatar_url":"https://avatars.githubusercontent.com/u/5682430?v=3","gravatar_id":"","url":"https://api.github.com/users/aztech-dev","html_url":"https://github.com/aztech-dev","followers_url":"https://api.github.com/users/aztech-dev/followers","following_url":"https://api.github.com/users/aztech-dev/following{/other_user}","gists_url":"https://api.github.com/users/aztech-dev/gists{/gist_id}","starred_url":"https://api.github.com/users/aztech-dev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aztech-dev/subscriptions","organizations_url":"https://api.github.com/users/aztech-dev/orgs","repos_url":"https://api.github.com/users/aztech-dev/repos","events_url":"https://api.github.com/users/aztech-dev/events{/privacy}","received_events_url":"https://api.github.com/users/aztech-dev/received_events","type":"User","site_admin":false},"created_at":"2015-03-25T15:11:19Z","updated_at":"2015-03-25T15:11:19Z","body":"Awesome for merging my changes -- haven't had too much time to dwelve back into the branch, though I definitely wanted to get it done.\r\n\r\nI'm not too fond of placing the burden of conversion on the library user, I'd rather see a GmpInt class. It's definitely a better approach (the Math classes were always in my eyes a means to transition from the original codebase to a better approach -- I originally stuffed in there everything that called either bc or gmp to isolate the calls and removing all the code duplication that I could find). It would also be smart to see how PHP7 handles the code with/without gmp_strval's. If I recall correctly, PHP 7 is supposed to handle bigint's transparently now (any int greater than 32bits is internally (? not sure here) cast to a gmp resource).\r\n\r\nI'm not however convinced the performance boost will be tremendous -- the most expensive operation is obviously point multiplication, and the current algo relies on base conversions -- which boil down to gmp_init/gmp_strval -- on every iteration. But any venue for a significant perf improvement is worth exploring, and I'd love to be proved wrong (or see a better performing implementation of the montgomery ladder).\r\n\r\nAlso regarding the constant time algos, sounds like a good idea to provide a constant and a non-constant time implementation. Just need to make sure that it's done so that library consumers can't make a mistake easily."}}