{"action":"created","issue":{"url":"https://api.github.com/repos/seven1m/do-install-button/issues/7","labels_url":"https://api.github.com/repos/seven1m/do-install-button/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/seven1m/do-install-button/issues/7/comments","events_url":"https://api.github.com/repos/seven1m/do-install-button/issues/7/events","html_url":"https://github.com/seven1m/do-install-button/issues/7","id":54077446,"number":7,"title":"DO install button leaves users vulnerable to CSRF","user":{"login":"vlad902","id":1088893,"avatar_url":"https://avatars.githubusercontent.com/u/1088893?v=3","gravatar_id":"","url":"https://api.github.com/users/vlad902","html_url":"https://github.com/vlad902","followers_url":"https://api.github.com/users/vlad902/followers","following_url":"https://api.github.com/users/vlad902/following{/other_user}","gists_url":"https://api.github.com/users/vlad902/gists{/gist_id}","starred_url":"https://api.github.com/users/vlad902/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vlad902/subscriptions","organizations_url":"https://api.github.com/users/vlad902/orgs","repos_url":"https://api.github.com/users/vlad902/repos","events_url":"https://api.github.com/users/vlad902/events{/privacy}","received_events_url":"https://api.github.com/users/vlad902/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-12T16:53:16Z","updated_at":"2015-03-11T02:49:37Z","closed_at":null,"body":"The installer does not have a CSRF token, meaning that if a user has authorized the DO install button, clicking anywhere on a third-party website could allow that third party website to launch a VM on behalf of the user.\r\n\r\nThe attack is:\r\n1) User visits a malicious website evil.com\r\n2) evil.com launches an invisible submit button over the entire page, with a form pointing to your installer's '/install' endpoint and valid values for size/region/agree/url with the url pointing to a repository of their choosing.\r\n3) If/when a user clicks anywhere on the page, it will launch a VM on behalf of evil.com. This might also be achievable by javascript\r\n\r\nThis attack is mitigated by the fact that DO will email the user their root password, but this is still confusing and dangerous. You should include a CSRF token in the form and check it."},"comment":{"url":"https://api.github.com/repos/seven1m/do-install-button/issues/comments/78190688","html_url":"https://github.com/seven1m/do-install-button/issues/7#issuecomment-78190688","issue_url":"https://api.github.com/repos/seven1m/do-install-button/issues/7","id":78190688,"user":{"login":"seven1m","id":669,"avatar_url":"https://avatars.githubusercontent.com/u/669?v=3","gravatar_id":"","url":"https://api.github.com/users/seven1m","html_url":"https://github.com/seven1m","followers_url":"https://api.github.com/users/seven1m/followers","following_url":"https://api.github.com/users/seven1m/following{/other_user}","gists_url":"https://api.github.com/users/seven1m/gists{/gist_id}","starred_url":"https://api.github.com/users/seven1m/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seven1m/subscriptions","organizations_url":"https://api.github.com/users/seven1m/orgs","repos_url":"https://api.github.com/users/seven1m/repos","events_url":"https://api.github.com/users/seven1m/events{/privacy}","received_events_url":"https://api.github.com/users/seven1m/received_events","type":"User","site_admin":false},"created_at":"2015-03-11T02:49:37Z","updated_at":"2015-03-11T02:49:37Z","body":"@vlad902 thanks for pointing this out! For some reason I just now found this issue on GitHub -- my notification settings failed me. I didn't mean to ignore you!\r\n\r\nI have submitted PR #8 that should fix this. Care to review?"}}