{"action":"created","issue":{"url":"https://api.github.com/repos/swagger-api/swagger-js/issues/509","labels_url":"https://api.github.com/repos/swagger-api/swagger-js/issues/509/labels{/name}","comments_url":"https://api.github.com/repos/swagger-api/swagger-js/issues/509/comments","events_url":"https://api.github.com/repos/swagger-api/swagger-js/issues/509/events","html_url":"https://github.com/swagger-api/swagger-js/pull/509","id":91094082,"number":509,"title":"Fix inability to apply multiple apiKey authentications","user":{"login":"PASSTor","id":8559936,"avatar_url":"https://avatars.githubusercontent.com/u/8559936?v=3","gravatar_id":"","url":"https://api.github.com/users/PASSTor","html_url":"https://github.com/PASSTor","followers_url":"https://api.github.com/users/PASSTor/followers","following_url":"https://api.github.com/users/PASSTor/following{/other_user}","gists_url":"https://api.github.com/users/PASSTor/gists{/gist_id}","starred_url":"https://api.github.com/users/PASSTor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PASSTor/subscriptions","organizations_url":"https://api.github.com/users/PASSTor/orgs","repos_url":"https://api.github.com/users/PASSTor/repos","events_url":"https://api.github.com/users/PASSTor/events{/privacy}","received_events_url":"https://api.github.com/users/PASSTor/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-06-25T22:33:57Z","updated_at":"2015-07-05T08:53:06Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/swagger-api/swagger-js/pulls/509","html_url":"https://github.com/swagger-api/swagger-js/pull/509","diff_url":"https://github.com/swagger-api/swagger-js/pull/509.diff","patch_url":"https://github.com/swagger-api/swagger-js/pull/509.patch"},"body":"If you have several apiKey authentications defined (like key+secret),\r\nthey were not applied both to the Request, because of\r\n`status = status || !!auth.apply(obj);`\r\n\r\nOnce status becomes `true` after applying the first security rule, the\r\nseconds (and all next ones) are ignored, as logic expression was\r\nerrorneous.\r\n\r\nFixing it, by changing OR into AND, as we want to return `false` if ANY\r\nof the auths were failing, second of all making `auth.apply(obj)` be\r\nexecuted always, by extracting the statement into separate line."},"comment":{"url":"https://api.github.com/repos/swagger-api/swagger-js/issues/comments/118596647","html_url":"https://github.com/swagger-api/swagger-js/pull/509#issuecomment-118596647","issue_url":"https://api.github.com/repos/swagger-api/swagger-js/issues/509","id":118596647,"user":{"login":"webron","id":241629,"avatar_url":"https://avatars.githubusercontent.com/u/241629?v=3","gravatar_id":"","url":"https://api.github.com/users/webron","html_url":"https://github.com/webron","followers_url":"https://api.github.com/users/webron/followers","following_url":"https://api.github.com/users/webron/following{/other_user}","gists_url":"https://api.github.com/users/webron/gists{/gist_id}","starred_url":"https://api.github.com/users/webron/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webron/subscriptions","organizations_url":"https://api.github.com/users/webron/orgs","repos_url":"https://api.github.com/users/webron/repos","events_url":"https://api.github.com/users/webron/events{/privacy}","received_events_url":"https://api.github.com/users/webron/received_events","type":"User","site_admin":false},"created_at":"2015-07-05T08:53:06Z","updated_at":"2015-07-05T08:53:06Z","body":"@PASSTor - thanks for the PR. Can you please resubmit against the develop_2.0 branch?"}}