{"action":"created","comment":{"url":"https://api.github.com/repos/ethcore/parity/pulls/comments/88343680","pull_request_review_id":8920684,"id":88343680,"diff_hunk":"@@ -0,0 +1,166 @@\n+// Copyright 2015, 2016 Ethcore (UK) Ltd.\n+// This file is part of Parity.\n+\n+// Parity is free software: you can redistribute it and/or modify\n+// it under the terms of the GNU General Public License as published by\n+// the Free Software Foundation, either version 3 of the License, or\n+// (at your option) any later version.\n+\n+// Parity is distributed in the hope that it will be useful,\n+// but WITHOUT ANY WARRANTY; without even the implied warranty of\n+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n+// GNU General Public License for more details.\n+\n+// You should have received a copy of the GNU General Public License\n+// along with Parity.  If not, see <http://www.gnu.org/licenses/>.\n+\n+import React, { Component, PropTypes } from 'react';\n+import { observer } from 'mobx-react';\n+import ActionDoneAll from 'material-ui/svg-icons/action/done-all';\n+import ContentClear from 'material-ui/svg-icons/content/clear';\n+\n+import { Button, IdentityIcon, Modal } from '../../ui';\n+\n+import {\n+  GATHERING_DATA, GATHERED_DATA,\n+  POSTING_REQUEST, POSTED_REQUEST,\n+  REQUESTING_SMS, REQUESTED_SMS,\n+  POSTING_CONFIRMATION, POSTED_CONFIRMATION,\n+  DONE\n+} from './store';\n+\n+import GatherData from './GatherData';\n+import SendRequest from './SendRequest';\n+import QueryCode from './QueryCode';\n+import SendConfirmation from './SendConfirmation';\n+import Done from './Done';\n+\n+@observer\n+export default class SMSVerification extends Component {\n+  static propTypes = {\n+    store: PropTypes.any.isRequired,\n+    account: PropTypes.string.isRequired,\n+    onClose: PropTypes.func.isRequired\n+  }\n+\n+  static phases = { // mapping (store steps -> steps)\n+    [GATHERING_DATA]: 0, [GATHERED_DATA]: 0,\n+    [POSTING_REQUEST]: 1, [POSTED_REQUEST]: 1, [REQUESTING_SMS]: 1,\n+    [REQUESTED_SMS]: 2,\n+    [POSTING_CONFIRMATION]: 3, [POSTED_CONFIRMATION]: 3,\n+    [DONE]: 4\n+  }\n+\n+  componentDidMount () {\n+    this.props.store.gatherData();\n+  }\n+\n+  render () {\n+    const phase = SMSVerification.phases[this.props.store.step];\n+    const { error, isStepValid } = this.props.store;\n+\n+    return (\n+      <Modal\n+        actions={ this.renderDialogActions(phase, error, isStepValid) }\n+        title='verify your account via SMS'\n+        visible scroll\n+        current={ phase }\n+        steps={ ['Enter Data', 'Request', 'Enter Code', 'Confirm', 'Done!'] }\n+        waiting={ error ? [] : [ 1, 3 ] }\n+      >\n+        { this.renderStep(phase, error) }\n+      </Modal>\n+    );\n+  }\n+\n+  renderDialogActions (phase, error, isStepValid) {\n+    const { store, account, onClose } = this.props;\n+\n+    const cancel = (\n+      <Button\n+        key='cancel' label='Cancel'\n+        icon={ <ContentClear /> }\n+        onClick={ onClose }\n+      />\n+    );\n+    if (error) return (<div>{ cancel }</div>);","path":"js/src/modals/SMSVerification/SMSVerification.js","position":86,"original_position":86,"commit_id":"ed2b8e14fcac6969bd3c576d90ae29d31fcbeda7","original_commit_id":"ed2b8e14fcac6969bd3c576d90ae29d31fcbeda7","user":{"login":"jacogr","id":1424473,"avatar_url":"https://avatars.githubusercontent.com/u/1424473?v=3","gravatar_id":"","url":"https://api.github.com/users/jacogr","html_url":"https://github.com/jacogr","followers_url":"https://api.github.com/users/jacogr/followers","following_url":"https://api.github.com/users/jacogr/following{/other_user}","gists_url":"https://api.github.com/users/jacogr/gists{/gist_id}","starred_url":"https://api.github.com/users/jacogr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jacogr/subscriptions","organizations_url":"https://api.github.com/users/jacogr/orgs","repos_url":"https://api.github.com/users/jacogr/repos","events_url":"https://api.github.com/users/jacogr/events{/privacy}","received_events_url":"https://api.github.com/users/jacogr/received_events","type":"User","site_admin":false},"body":"Nitpick: Not sure what we gan by placing this on a single line, apart from slightly less readability.","created_at":"2016-11-16T22:13:27Z","updated_at":"2016-11-16T22:13:27Z","html_url":"https://github.com/ethcore/parity/pull/3336#discussion_r88343680","pull_request_url":"https://api.github.com/repos/ethcore/parity/pulls/3336","_links":{"self":{"href":"https://api.github.com/repos/ethcore/parity/pulls/comments/88343680"},"html":{"href":"https://github.com/ethcore/parity/pull/3336#discussion_r88343680"},"pull_request":{"href":"https://api.github.com/repos/ethcore/parity/pulls/3336"}}},"pull_request":{"url":"https://api.github.com/repos/ethcore/parity/pulls/3336","id":93128731,"html_url":"https://github.com/ethcore/parity/pull/3336","diff_url":"https://github.com/ethcore/parity/pull/3336.diff","patch_url":"https://github.com/ethcore/parity/pull/3336.patch","issue_url":"https://api.github.com/repos/ethcore/parity/issues/3336","number":3336,"state":"open","locked":false,"title":"sms verification modal","user":{"login":"derhuerst","id":5072613,"avatar_url":"https://avatars.githubusercontent.com/u/5072613?v=3","gravatar_id":"","url":"https://api.github.com/users/derhuerst","html_url":"https://github.com/derhuerst","followers_url":"https://api.github.com/users/derhuerst/followers","following_url":"https://api.github.com/users/derhuerst/following{/other_user}","gists_url":"https://api.github.com/users/derhuerst/gists{/gist_id}","starred_url":"https://api.github.com/users/derhuerst/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/derhuerst/subscriptions","organizations_url":"https://api.github.com/users/derhuerst/orgs","repos_url":"https://api.github.com/users/derhuerst/repos","events_url":"https://api.github.com/users/derhuerst/events{/privacy}","received_events_url":"https://api.github.com/users/derhuerst/received_events","type":"User","site_admin":false},"body":"This PR adds the ability for users to prove for a single account that they control an associated phone number. An account can only be verified once, just like a phone number can be used once.\r\n\r\nCheck out the diagram on how it works, [over at the `sms-verification` repo](https://github.com/ethcore/sms-verification#parity-sms-verification). The server code is deployed at `sms-verification.parity.io`.\r\n\r\n~~Note that this PR should not get merged before TJ provides a legal text, as we process potentially sensitive user data. Also, I need to do a few minor cleanups.~~ The legal text is in place.\r\n\r\nEdit: In 4931381, this PR also adds a `maxConfirmations` property to `TxHash`.","created_at":"2016-11-10T10:59:15Z","updated_at":"2016-11-16T22:13:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fea5a2b9df18d932724739adb26c719f912a455b","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/ethcore/parity/pulls/3336/commits","review_comments_url":"https://api.github.com/repos/ethcore/parity/pulls/3336/comments","review_comment_url":"https://api.github.com/repos/ethcore/parity/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ethcore/parity/issues/3336/comments","statuses_url":"https://api.github.com/repos/ethcore/parity/statuses/ed2b8e14fcac6969bd3c576d90ae29d31fcbeda7","head":{"label":"ethcore:sms-verification-modal","ref":"sms-verification-modal","sha":"ed2b8e14fcac6969bd3c576d90ae29d31fcbeda7","user":{"login":"ethcore","id":14176906,"avatar_url":"https://avatars.githubusercontent.com/u/14176906?v=3","gravatar_id":"","url":"https://api.github.com/users/ethcore","html_url":"https://github.com/ethcore","followers_url":"https://api.github.com/users/ethcore/followers","following_url":"https://api.github.com/users/ethcore/following{/other_user}","gists_url":"https://api.github.com/users/ethcore/gists{/gist_id}","starred_url":"https://api.github.com/users/ethcore/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethcore/subscriptions","organizations_url":"https://api.github.com/users/ethcore/orgs","repos_url":"https://api.github.com/users/ethcore/repos","events_url":"https://api.github.com/users/ethcore/events{/privacy}","received_events_url":"https://api.github.com/users/ethcore/received_events","type":"Organization","site_admin":false},"repo":{"id":46714939,"name":"parity","full_name":"ethcore/parity","owner":{"login":"ethcore","id":14176906,"avatar_url":"https://avatars.githubusercontent.com/u/14176906?v=3","gravatar_id":"","url":"https://api.github.com/users/ethcore","html_url":"https://github.com/ethcore","followers_url":"https://api.github.com/users/ethcore/followers","following_url":"https://api.github.com/users/ethcore/following{/other_user}","gists_url":"https://api.github.com/users/ethcore/gists{/gist_id}","starred_url":"https://api.github.com/users/ethcore/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethcore/subscriptions","organizations_url":"https://api.github.com/users/ethcore/orgs","repos_url":"https://api.github.com/users/ethcore/repos","events_url":"https://api.github.com/users/ethcore/events{/privacy}","received_events_url":"https://api.github.com/users/ethcore/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ethcore/parity","description":"Fast, light, robust Ethereum implementation","fork":false,"url":"https://api.github.com/repos/ethcore/parity","forks_url":"https://api.github.com/repos/ethcore/parity/forks","keys_url":"https://api.github.com/repos/ethcore/parity/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ethcore/parity/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ethcore/parity/teams","hooks_url":"https://api.github.com/repos/ethcore/parity/hooks","issue_events_url":"https://api.github.com/repos/ethcore/parity/issues/events{/number}","events_url":"https://api.github.com/repos/ethcore/parity/events","assignees_url":"https://api.github.com/repos/ethcore/parity/assignees{/user}","branches_url":"https://api.github.com/repos/ethcore/parity/branches{/branch}","tags_url":"https://api.github.com/repos/ethcore/parity/tags","blobs_url":"https://api.github.com/repos/ethcore/parity/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ethcore/parity/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ethcore/parity/git/refs{/sha}","trees_url":"https://api.github.com/repos/ethcore/parity/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ethcore/parity/statuses/{sha}","languages_url":"https://api.github.com/repos/ethcore/parity/languages","stargazers_url":"https://api.github.com/repos/ethcore/parity/stargazers","contributors_url":"https://api.github.com/repos/ethcore/parity/contributors","subscribers_url":"https://api.github.com/repos/ethcore/parity/subscribers","subscription_url":"https://api.github.com/repos/ethcore/parity/subscription","commits_url":"https://api.github.com/repos/ethcore/parity/commits{/sha}","git_commits_url":"https://api.github.com/repos/ethcore/parity/git/commits{/sha}","comments_url":"https://api.github.com/repos/ethcore/parity/comments{/number}","issue_comment_url":"https://api.github.com/repos/ethcore/parity/issues/comments{/number}","contents_url":"https://api.github.com/repos/ethcore/parity/contents/{+path}","compare_url":"https://api.github.com/repos/ethcore/parity/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ethcore/parity/merges","archive_url":"https://api.github.com/repos/ethcore/parity/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ethcore/parity/downloads","issues_url":"https://api.github.com/repos/ethcore/parity/issues{/number}","pulls_url":"https://api.github.com/repos/ethcore/parity/pulls{/number}","milestones_url":"https://api.github.com/repos/ethcore/parity/milestones{/number}","notifications_url":"https://api.github.com/repos/ethcore/parity/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ethcore/parity/labels{/name}","releases_url":"https://api.github.com/repos/ethcore/parity/releases{/id}","deployments_url":"https://api.github.com/repos/ethcore/parity/deployments","created_at":"2015-11-23T11:07:32Z","updated_at":"2016-11-16T13:39:07Z","pushed_at":"2016-11-16T21:19:43Z","git_url":"git://github.com/ethcore/parity.git","ssh_url":"git@github.com:ethcore/parity.git","clone_url":"https://github.com/ethcore/parity.git","svn_url":"https://github.com/ethcore/parity","homepage":"","size":104359,"stargazers_count":658,"watchers_count":658,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":128,"mirror_url":null,"open_issues_count":257,"forks":128,"open_issues":257,"watchers":658,"default_branch":"master"}},"base":{"label":"ethcore:master","ref":"master","sha":"df1fbf50d84d8eaecc3e8059acc4a1bf273ca9de","user":{"login":"ethcore","id":14176906,"avatar_url":"https://avatars.githubusercontent.com/u/14176906?v=3","gravatar_id":"","url":"https://api.github.com/users/ethcore","html_url":"https://github.com/ethcore","followers_url":"https://api.github.com/users/ethcore/followers","following_url":"https://api.github.com/users/ethcore/following{/other_user}","gists_url":"https://api.github.com/users/ethcore/gists{/gist_id}","starred_url":"https://api.github.com/users/ethcore/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethcore/subscriptions","organizations_url":"https://api.github.com/users/ethcore/orgs","repos_url":"https://api.github.com/users/ethcore/repos","events_url":"https://api.github.com/users/ethcore/events{/privacy}","received_events_url":"https://api.github.com/users/ethcore/received_events","type":"Organization","site_admin":false},"repo":{"id":46714939,"name":"parity","full_name":"ethcore/parity","owner":{"login":"ethcore","id":14176906,"avatar_url":"https://avatars.githubusercontent.com/u/14176906?v=3","gravatar_id":"","url":"https://api.github.com/users/ethcore","html_url":"https://github.com/ethcore","followers_url":"https://api.github.com/users/ethcore/followers","following_url":"https://api.github.com/users/ethcore/following{/other_user}","gists_url":"https://api.github.com/users/ethcore/gists{/gist_id}","starred_url":"https://api.github.com/users/ethcore/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethcore/subscriptions","organizations_url":"https://api.github.com/users/ethcore/orgs","repos_url":"https://api.github.com/users/ethcore/repos","events_url":"https://api.github.com/users/ethcore/events{/privacy}","received_events_url":"https://api.github.com/users/ethcore/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ethcore/parity","description":"Fast, light, robust Ethereum implementation","fork":false,"url":"https://api.github.com/repos/ethcore/parity","forks_url":"https://api.github.com/repos/ethcore/parity/forks","keys_url":"https://api.github.com/repos/ethcore/parity/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ethcore/parity/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ethcore/parity/teams","hooks_url":"https://api.github.com/repos/ethcore/parity/hooks","issue_events_url":"https://api.github.com/repos/ethcore/parity/issues/events{/number}","events_url":"https://api.github.com/repos/ethcore/parity/events","assignees_url":"https://api.github.com/repos/ethcore/parity/assignees{/user}","branches_url":"https://api.github.com/repos/ethcore/parity/branches{/branch}","tags_url":"https://api.github.com/repos/ethcore/parity/tags","blobs_url":"https://api.github.com/repos/ethcore/parity/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ethcore/parity/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ethcore/parity/git/refs{/sha}","trees_url":"https://api.github.com/repos/ethcore/parity/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ethcore/parity/statuses/{sha}","languages_url":"https://api.github.com/repos/ethcore/parity/languages","stargazers_url":"https://api.github.com/repos/ethcore/parity/stargazers","contributors_url":"https://api.github.com/repos/ethcore/parity/contributors","subscribers_url":"https://api.github.com/repos/ethcore/parity/subscribers","subscription_url":"https://api.github.com/repos/ethcore/parity/subscription","commits_url":"https://api.github.com/repos/ethcore/parity/commits{/sha}","git_commits_url":"https://api.github.com/repos/ethcore/parity/git/commits{/sha}","comments_url":"https://api.github.com/repos/ethcore/parity/comments{/number}","issue_comment_url":"https://api.github.com/repos/ethcore/parity/issues/comments{/number}","contents_url":"https://api.github.com/repos/ethcore/parity/contents/{+path}","compare_url":"https://api.github.com/repos/ethcore/parity/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ethcore/parity/merges","archive_url":"https://api.github.com/repos/ethcore/parity/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ethcore/parity/downloads","issues_url":"https://api.github.com/repos/ethcore/parity/issues{/number}","pulls_url":"https://api.github.com/repos/ethcore/parity/pulls{/number}","milestones_url":"https://api.github.com/repos/ethcore/parity/milestones{/number}","notifications_url":"https://api.github.com/repos/ethcore/parity/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ethcore/parity/labels{/name}","releases_url":"https://api.github.com/repos/ethcore/parity/releases{/id}","deployments_url":"https://api.github.com/repos/ethcore/parity/deployments","created_at":"2015-11-23T11:07:32Z","updated_at":"2016-11-16T13:39:07Z","pushed_at":"2016-11-16T21:19:43Z","git_url":"git://github.com/ethcore/parity.git","ssh_url":"git@github.com:ethcore/parity.git","clone_url":"https://github.com/ethcore/parity.git","svn_url":"https://github.com/ethcore/parity","homepage":"","size":104359,"stargazers_count":658,"watchers_count":658,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":128,"mirror_url":null,"open_issues_count":257,"forks":128,"open_issues":257,"watchers":658,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ethcore/parity/pulls/3336"},"html":{"href":"https://github.com/ethcore/parity/pull/3336"},"issue":{"href":"https://api.github.com/repos/ethcore/parity/issues/3336"},"comments":{"href":"https://api.github.com/repos/ethcore/parity/issues/3336/comments"},"review_comments":{"href":"https://api.github.com/repos/ethcore/parity/pulls/3336/comments"},"review_comment":{"href":"https://api.github.com/repos/ethcore/parity/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ethcore/parity/pulls/3336/commits"},"statuses":{"href":"https://api.github.com/repos/ethcore/parity/statuses/ed2b8e14fcac6969bd3c576d90ae29d31fcbeda7"}}}}
{"actor":{"display_login":"jacogr"}}