{"id":268354,"date":"2015-11-17T12:20:03","date_gmt":"2015-11-17T09:20:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=268354"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=268354","title":{"rendered":"CSRF-\u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c VK Open Api, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0430\u044f \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0443 \u0431\u0435\u0437 \u0432\u0435\u0434\u043e\u043c\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c Access Token\u2019\u044b \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u0445 \u0441\u0430\u0439\u0442\u043e\u0432, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u0430 \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u044f \u0447\u0435\u0440\u0435\u0437 VK"},"content":{"rendered":"<p>       \u041f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044e \u0432\u0430\u0448\u0435\u043c\u0443 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044e \u043e\u0431\u0437\u043e\u0440 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438, \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u043e\u0439 \u0441 \u043d\u0435\u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u043c \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435\u043c JSONP \u0432 VK Open Api. \u041d\u0430 \u043c\u043e\u0439 \u0432\u0437\u0433\u043b\u044f\u0434, \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u0435\u0440\u044c\u0451\u0437\u043d\u0430\u044f, \u0442.\u043a. \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u043b\u0430 \u0441\u0430\u0439\u0442\u0443 \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430 \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c Access Token \u0434\u0440\u0443\u0433\u043e\u0433\u043e \u0441\u0430\u0439\u0442\u0430, \u0435\u0441\u043b\u0438 \u043d\u0430 \u043d\u0451\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u044f \u0447\u0435\u0440\u0435\u0437 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 VK Open API. \u041d\u0430 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0443\u044f\u0437\u0432\u0438\u043c\u044b\u0439 \u043a\u043e\u0434 \u043f\u043e\u043f\u0440\u0430\u0432\u0438\u043b\u0438, \u0440\u0435\u043f\u043e\u0440\u0442 \u043d\u0430 HackerOne \u0437\u0430\u043a\u0440\u044b\u043b\u0438, \u0432\u043e\u0437\u043d\u0430\u0433\u0440\u0430\u0436\u0434\u0435\u043d\u0438\u0435 \u0432\u044b\u043f\u043b\u0430\u0442\u0438\u043b\u0438 (1,500$).<\/p>\n<h3>\u041a\u0430\u043a \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u043e<\/h3>\n<p>  \u0412 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0435, \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e Access Token&#8217;\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435\u0439 \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b \u043f\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 \u0441\u0445\u0435\u043c\u0435 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0430\u0446\u0438\u0438 CSRF-\u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438:<\/p>\n<ol>\n<li>\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0437\u0430\u0445\u043e\u0434\u0438\u0442 \u043d\u0430 \u0441\u0430\u0439\u0442, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0438\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 VK Open API (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>).<\/li>\n<li>\u0410\u0432\u0442\u043e\u0440\u0438\u0437\u0443\u0435\u0442\u0441\u044f \u0442\u0430\u043c \u0447\u0435\u0440\u0435\u0437 VK.<\/li>\n<li>\u041f\u043e\u0442\u043e\u043c \u0437\u0430\u0445\u043e\u0434\u0438\u0442 \u043d\u0430 \u0441\u0430\u0439\u0442 \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <a href=\"http:\/\/www.vk-test-auth.com\">www.vk-test-auth.com<\/a>), \u043a\u043e\u0442\u043e\u0440\u044b\u0439, \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u044f \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c, \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 Access Token, \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0438\u0439 \u0441\u0430\u0439\u0442\u0443 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>.<\/li>\n<li>\u041f\u043e\u043b\u0443\u0447\u0438\u0432 Access Token \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a \u043c\u043e\u0436\u0435\u0442 \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a VK API \u0441 \u0442\u0435\u043c\u0438 \u043f\u0440\u0430\u0432\u0430\u043c\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0434\u0430\u043b \u0441\u0430\u0439\u0442\u0443 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a> \u043f\u0440\u0438 \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u0438 \u043d\u0430 \u043d\u0435\u043c \u0447\u0435\u0440\u0435\u0437 VK.<\/li>\n<\/ol>\n<p>  <\/p>\n<h3>\u0414\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u044f<\/h3>\n<p>  \u041d\u0430 \u0432\u0438\u0434\u0435\u043e \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e, \u043a\u0430\u043a \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u00ab\u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430\u00bb \u043d\u0430 \u0434\u043e\u043c\u0435\u043d\u0435 <a href=\"http:\/\/www.vk-test-auth.com\">www.vk-test-auth.com<\/a> \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 Access Token \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f VK, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u043b\u0441\u044f \u043d\u0430 \u0441\u0430\u0439\u0442\u0435 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>, \u043d\u0435\u0441\u043c\u043e\u0442\u0440\u044f \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f VK, \u0434\u043e\u0441\u0442\u0443\u043f \u0440\u0430\u0437\u0440\u0435\u0448\u0451\u043d \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u0434\u043e\u043c\u0435\u043d\u0430 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>.<\/p>\n<p>  <iframe loading=\"lazy\" width=\"560\" height=\"315\" src=\"https:\/\/www.youtube.com\/embed\/xtEGpwmE-FE?feature=oembed\" frameborder=\"0\" allowfullscreen><\/iframe><br \/>  <a name=\"habracut\"><\/a><br \/>  \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u0434\u043e\u043c\u0435\u043d\u044b \u044f \u043d\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043b, \u0442.\u043a. \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u044d\u0442\u043e \u043d\u0435 \u0438\u0433\u0440\u0430\u0435\u0442 \u043d\u0438\u043a\u0430\u043a\u043e\u0439 \u0440\u043e\u043b\u0438. \u041a\u043e\u0433\u0434\u0430 \u0437\u0430\u043f\u0438\u0441\u044b\u0432\u0430\u043b\u0441\u044f \u0441\u043a\u0440\u0438\u043d\u043a\u0430\u0441\u0442, \u043e\u043d\u0438 \u0431\u044b\u043b\u0438 \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u043d\u044b \u0432 hosts.<\/p>\n<h3>\u041d\u0435\u043c\u043d\u043e\u0433\u043e \u043e VK Open API<\/h3>\n<p>  \u0412\u044b\u0434\u0435\u0440\u0436\u043a\u0430 \u0438\u0437 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438:  <\/p>\n<blockquote><p><i>Open API \u2014 \u0441\u0438\u0441\u0442\u0435\u043c\u0430 \u0434\u043b\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u0445 \u0441\u0430\u0439\u0442\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043b\u0435\u0433\u043a\u043e \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u0412\u041a\u043e\u043d\u0442\u0430\u043a\u0442\u0435 \u043d\u0430 \u0412\u0430\u0448\u0435\u043c \u0441\u0430\u0439\u0442\u0435. \u041a\u0440\u043e\u043c\u0435 \u044d\u0442\u043e\u0433\u043e, \u0441 \u0441\u043e\u0433\u043b\u0430\u0441\u0438\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439, \u0432\u044b \u0441\u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e\u0431 \u0438\u0445 \u0434\u0440\u0443\u0437\u044c\u044f\u0445, \u0444\u043e\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u044f\u0445, \u0430\u0443\u0434\u0438\u043e\u0437\u0430\u043f\u0438\u0441\u044f\u0445, \u0432\u0438\u0434\u0435\u043e\u0440\u043e\u043b\u0438\u043a\u0430\u0445 \u0438 \u043f\u0440\u043e\u0447\u0438\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0412\u041a\u043e\u043d\u0442\u0430\u043a\u0442\u0435 \u0434\u043b\u044f \u0431\u043e\u043b\u0435\u0435 \u0433\u043b\u0443\u0431\u043e\u043a\u043e\u0439 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0438 \u0441 \u0412\u0430\u0448\u0438\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u043c.<\/i><\/p><\/blockquote>\n<p>  \u0422.\u0435. \u044d\u0442\u043e JS \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0430\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 VK API (\u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u044f, \u0432\u044b\u0437\u043e\u0432 \u043c\u0435\u0442\u043e\u0434\u043e\u0432 API, \u0432\u0440\u043e\u0434\u0435 &#8216;wall.post&#8217;, &#8216;audio.get&#8217;, &#8216;video.add&#8217;, etc&#8230;) \u043f\u0440\u044f\u043c\u043e \u0441\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432\u0430\u0448\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u0443 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u044c VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0441 \u0442\u0438\u043f\u043e\u043c \u00ab\u0412\u0435\u0431-\u0441\u0430\u0439\u0442\u00bb, \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0434\u043e\u043c\u0435\u043d \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445, \u0438 \u0440\u0430\u0437\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u043f\u0430\u0440\u0443 \u0442\u0435\u0433\u043e\u0432 script \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435.<\/p>\n<h3>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438<\/h3>\n<p>  \u041f\u0440\u0438\u043c\u0435\u0440 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0438 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438:<\/p>\n<pre><code class=\"html\">&lt;script src=&quot;\/\/vk.com\/js\/api\/openapi.js&quot; type=&quot;text\/javascript&quot;&gt;&lt;\/script&gt; &lt;script type=&quot;text\/javascript&quot;&gt;   VK.init({     apiId: \u0412\u0410\u0428_APP_ID   }); &lt;\/script&gt; <\/code><\/pre>\n<p>  \u0415\u0441\u0442\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u0432 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0435 <code>appId<\/code> \u043c\u043e\u0436\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e ID VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u00ab\u0411\u0430\u0437\u043e\u0432\u044b\u0439 \u0434\u043e\u043c\u0435\u043d\u00bb \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043c\u044b \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443.<\/p>\n<p>  \u041d\u0430\u0448\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u043c\u043e\u0436\u0435\u0442 \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a \u043c\u0435\u0442\u043e\u0434\u0430\u043c VK API \u043f\u043e\u0441\u043b\u0435 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0432\u043e \u0432\u0441\u043f\u043b\u044b\u0432\u0430\u044e\u0449\u0435\u043c \u043e\u043a\u043d\u0435 \u0440\u0430\u0437\u0440\u0435\u0448\u0438\u0442 VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044e \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u0440\u043e\u0444\u0438\u043b\u044e. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c \u044d\u0442\u043e \u0432\u0441\u043f\u043b\u044b\u0432\u0430\u044e\u0449\u0435\u0435 \u043e\u043a\u043d\u043e, \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u043e\u0434 <code>VK.Auth.login()<\/code>. \u0418 \u043f\u043e\u0441\u043b\u0435 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043e, \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a VK API. \u0412\u0430\u0436\u043d\u043e\u0435 \u0437\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u0435: \u0435\u0441\u043b\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043e\u0434\u043d\u0430\u0436\u0434\u044b \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u043b \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044e \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u0440\u043e\u0444\u0438\u043b\u044e, \u0442\u043e \u0434\u0430\u0436\u0435 \u043f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0435\u0433\u043e \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u043e\u0441\u0442\u0430\u0435\u0442\u0441\u044f \u0432 \u0441\u0438\u043b\u0435: \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0430\u0437 \u0432\u044b\u0437\u044b\u0432\u0430\u0442\u044c <code>VK.Auth.login()<\/code>. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c, \u043d\u0443\u0436\u043d\u043e \u043b\u0438 \u043f\u0440\u043e\u0441\u0438\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0441\u0430\u0439\u0442\u0443 (\u0442\u043e\u0447\u043d\u0435\u0435, VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044e \u0441\u0430\u0439\u0442\u0430) \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u0440\u043e\u0444\u0438\u043b\u044e, \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043a\u043e\u0434:<\/p>\n<pre><code class=\"javascript\">VK.Auth.getLoginStatus(function(resp) {  \tif (resp.session) {  \t\t\/\/ \u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0443\u0436\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u0440\u043e\u0444\u0438\u043b\u044e. \t\t\/\/ \u041c\u043e\u0436\u043d\u043e \u0441\u043f\u043e\u043a\u043e\u0439\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 VK API.   \t} else {  \t\t\/\/ \u041d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u0441\u0438\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f, \t\t\/\/ \u0438 \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0441\u043b\u0435 \u0435\u0433\u043e \u0441\u043e\u0433\u043b\u0430\u0441\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 VK API.  \t\tVK.Auth.login(...); \t}  });  <\/code><\/pre>\n<p>  \u0415\u0441\u043b\u0438 \u043f\u0440\u0438 \u0432\u044b\u0437\u043e\u0432\u0435 <code>VK.init()<\/code> \u0443\u043a\u0430\u0437\u0430\u0442\u044c ID \u0447\u0443\u0436\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0434\u043e\u043c\u0435\u043d \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043d\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u2013 \u043d\u0438\u0447\u0435\u0433\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u043e (\u0434\u0430\u0436\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u044f-callback, \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u043d\u0430\u044f \u0432 <code>getLoginStatus()<\/code> \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u043d\u0430).<\/p>\n<p>  \u041d\u0435\u0431\u043e\u043b\u044c\u0448\u0430\u044f \u043e\u0433\u043e\u0432\u043e\u0440\u043a\u0430: \u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f, \u044d\u0442\u043e\u0442 \u0437\u0430\u043f\u0440\u0435\u0442 \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u043e\u0439\u0442\u0438. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0431\u044b\u043b\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u0435\u0435, \u0432\u043a\u0440\u0430\u0442\u0446\u0435 \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0443, \u043a\u0430\u043a \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u00ab\u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u043d\u043d\u043e\u0441\u0442\u0438\u00bb \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0432 VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438.<\/p>\n<h3>\u041f\u0440\u0438\u043d\u0446\u0438\u043f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f<\/h3>\n<p>  \u0414\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441 VK API \u0438\u0437 JS-\u043a\u043e\u0434\u0430 \u0432\u0435\u0431-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043c\u0435\u0442\u043e\u0434 <code>VK.Api.call()<\/code>, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<pre><code class=\"javascript\">\/\/ \u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u0442\u0435\u043a\u0443\u0449\u0435\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435 VK.Api.call('users.get', {}, function(result) { \tvar user; \tif (result.response) { \t\tuser = result.response[0]; \t\talert('\u0417\u0434\u0440\u0430\u0432\u0441\u0442\u0432\u0443\u0439\u0442\u0435, ' + user.first_name + ' ' + user.last_name + '!'); \t} });  <\/code><\/pre>\n<p>  \u041f\u0440\u0438 \u043f\u0435\u0440\u0432\u043e\u043c \u0432\u044b\u0437\u043e\u0432\u0435 \u043c\u0435\u0442\u043e\u0434\u0430 <code>VK.Api.call()<\/code>, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u043e\u0431\u0440\u0430\u0449\u0430\u0435\u0442\u0441\u044f \u043d\u0430 \u0431\u0435\u043a\u0435\u043d\u0434 VK \u0437\u0430 Access Token&#8217;\u043e\u043c. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e, \u0432\u043d\u0443\u0442\u0440\u0438 <code>VK.Api.call()<\/code> \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043c\u0435\u0442\u043e\u0434 <code>VK.Auth.getLoginStatus()<\/code>, \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u044d\u0442\u043e\u0442 \u0442\u043e\u043a\u0435\u043d (\u043a\u043e\u043d\u0435\u0447\u043d\u043e, \u0435\u0441\u043b\u0438 \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0440\u0430\u043d\u0435\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0434\u043e\u0441\u0442\u0443\u043f \u0441\u0430\u0439\u0442\u0443 \u043a \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u0440\u043e\u0444\u0438\u043b\u044e). \u041f\u043e\u0441\u043b\u0435 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u0442\u043e\u043a\u0435\u043d \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c, \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0437\u0430\u043f\u0440\u043e\u0441 \u043a API \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043e\u0442\u0432\u0435\u0442\u0430 \u043e\u0442 \u0441\u0435\u0440\u0432\u0435\u0440\u0430. \u0423\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u043a\u0440\u043e\u0435\u0442\u0441\u044f \u0432 \u0441\u043f\u043e\u0441\u043e\u0431\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0435 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u043e\u0442\u0432\u0435\u0442\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 <code>VK.Auth.getLoginStatus()<\/code>. \u0412\u0441\u0435\u043c\u0443 \u0432\u0438\u043d\u043e\u0439 JSONP, \u0432\u0435\u0440\u043d\u0435\u0435, \u0435\u0433\u043e \u043d\u0435\u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e\u0435 \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435.<\/p>\n<h3>\u041f\u043e\u0440\u043e\u0447\u043d\u044b\u0439 JSONP<\/h3>\n<p>  \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0443 \u043c\u0435\u0442\u043e\u0434\u0430 <code>VK.Auth.getLoginStatus()<\/code>. \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c Access Token, \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f JSONP-\u0437\u0430\u043f\u0440\u043e\u0441 \u043d\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 URL:<\/p>\n<pre>https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456<\/pre>\n<p>  \u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b:<\/p>\n<ul>\n<li><code>aid<\/code> \u2013 ID \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f<\/li>\n<li><code>location<\/code> \u2013 \u0434\u043e\u043c\u0435\u043d, \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0437\u0430\u043f\u0440\u043e\u0441<\/li>\n<li><code>rnd<\/code> \u2013 ID callback-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 (\u0432\u0435\u0434\u044c \u044d\u0442\u043e JSONP)<\/li>\n<\/ul>\n<p>  \u0415\u0441\u043b\u0438 \u0432 \u0437\u0430\u043f\u0440\u043e\u0441\u0435 \u043f\u043e URL, \u043f\u0440\u0438\u0432\u0435\u0434\u0451\u043d\u043d\u043e\u043c \u0432\u044b\u0448\u0435, \u0434\u043e\u043c\u0435\u043d \u0432 HTTP Referrer \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u044b\u043b \u0443\u043a\u0430\u0437\u0430\u043d \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0438\u043b\u0438 \u0435\u0441\u043b\u0438 HTTP Referrer \u043d\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0441\u043e\u0432\u0441\u0435\u043c (!) \u2013 \u0442\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0442\u0430\u043a\u043e\u0439 \u043e\u0442\u0432\u0435\u0442:<\/p>\n<pre><code class=\"javascript\">\/* &lt;html&gt;&lt;script&gt;window.location='http:\/\/vk.com';&lt;\/script&gt;&lt;\/html&gt; *\/ if (location.hostname != 'www.example.com') { \twindow.location.href = 'http:\/\/vk.com\/oauth'; \tfor (;;); } else { \tVK.Auth.lsCb[456]({ \t\t&quot;auth&quot;: true, \t\t&quot;access_token&quot;: &quot;5ea11111d799a53236f5d3eff5d34bcd2dda0f9e6a7aaf743f7d26d3487456f6ce8d5e1ff82eaa6f7b04a&quot;, \t\t&quot;expire&quot;: 1436755095, \t\t&quot;time&quot;: 7200, \t\t&quot;sig&quot;: &quot;12d254526496a6db2af6bed2eb1dd3e7&quot;, \t\t&quot;secret&quot;: &quot;oauth&quot;, \t\t&quot;user&quot;: { \t\t\t&quot;id&quot;: &quot;%ID_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;, \t\t\t&quot;domain&quot;: &quot;%\u0438\u043c\u044f_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;, \t\t\t&quot;href&quot;: &quot;https:\\\/\\\/vk.com\\\/%\u0438\u043c\u044f_\u0438\u043b\u0438_id_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;, \t\t\t&quot;first_name&quot;: &quot;%\u0438\u043c\u044f%&quot;, \t\t\t&quot;last_name&quot;: &quot;%\u0444\u0430\u043c\u0438\u043b\u0438\u044f%&quot;, \t\t\t&quot;nickname&quot;: &quot;&quot; \t\t} \t}); } <\/code><\/pre>\n<p>  \u0412\u0430\u0436\u043d\u043e: \u041f\u0440\u0438 JSONP-\u0437\u0430\u043f\u0440\u043e\u0441\u0435 \u043d\u0430 \u0432\u044b\u0448\u0435\u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0439 URL, \u0431\u0440\u0430\u0443\u0437\u0435\u0440 \u0442\u0430\u043a\u0436\u0435 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u043a\u0443\u043a\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f. \u041f\u043e\u044d\u0442\u043e\u043c\u0443, \u0441\u0435\u0440\u0432\u0435\u0440 \u0437\u043d\u0430\u0435\u0442, \u043e\u0442 \u0438\u043c\u0435\u043d\u0438 \u043a\u0430\u043a\u043e\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f VK \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0437\u0430\u043f\u0440\u043e\u0441, \u0438 \u0441\u0442\u0440\u043e\u0438\u0442 \u043e\u0442\u0432\u0435\u0442 \u0438\u0441\u0445\u043e\u0434\u044f \u0438\u0437 \u044d\u0442\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438. <\/p>\n<p>  \u041a\u0430\u043a \u044f \u0443\u0436\u0435 \u0433\u043e\u0432\u043e\u0440\u0438\u043b \u0440\u0430\u043d\u043d\u0435\u0435, \u043e\u0442\u0432\u0435\u0442\u043e\u043c \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f JS-\u043a\u043e\u0434, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f \u043b\u043e\u0433\u0438\u043a\u0430: \u0435\u0441\u043b\u0438 \u0434\u043e\u043c\u0435\u043d \u0442\u0435\u043a\u0443\u0449\u0435\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b (<code>location.hostname<\/code>) \u0440\u0430\u0432\u0435\u043d \u0434\u043e\u043c\u0435\u043d\u0443, \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u043c\u0443 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u2013 \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u044e <code>VK.Auth.lsCb[%\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435_\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430_rnd%]()<\/code>, \u0438 \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430 \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u043c \u043e\u0431\u044a\u0435\u043a\u0442 \u0441 Access Token&#8217;\u043e\u043c, \u0438\u043d\u0430\u0447\u0435 \u2013 \u043f\u0435\u0440\u0435\u043d\u0430\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u043d\u0430 <code>http:\/\/vk.com\/oauth<\/code>. \u0417\u0430\u0447\u0435\u043c? \u042d\u0442\u043e \u0442\u0430\u043a\u0430\u044f \u0437\u0430\u0449\u0438\u0442\u0430. \u0422.\u043a. \u0435\u0441\u043b\u0438 \u0431\u044b \u0434\u043e\u043c\u0435\u043d, \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0439 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043d\u0435 \u0441\u0432\u0435\u0440\u044f\u043b\u0441\u044f \u0441 <code>location.hostname<\/code>, \u0442\u043e \u043b\u044e\u0431\u043e\u0439 \u043c\u043e\u0433 \u0431\u044b \u0440\u0430\u0437\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u0443 \u0441\u0435\u0431\u044f \u043d\u0430 \u0441\u0430\u0439\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043a\u043e\u0434:<\/p>\n<pre><code class=\"html\">&lt;script&gt; var VK = { \tAuth: { \t\tlsCb: { \t\t\t456: function (data) { \t\t\t\t\/\/ \u0412 \u043e\u0431\u044a\u0435\u043a\u0442\u0435 data \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f Access Token (data.access_token) \t\t\t\t\/\/ \u0438 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u043e \u0442\u0435\u043a\u0443\u0449\u0435\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435 (data.user) \t\t\t}\t \t\t} \t} } &lt;\/script&gt; &lt;script src=&quot;https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456&quot;&gt; <\/code><\/pre>\n<p>  \u0418 \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c Access Token (\u0430 \u0432\u043c\u0435\u0441\u0442\u0435 \u0441 \u044d\u0442\u0438\u043c \u0438 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043f\u0440\u043e\u0444\u0438\u043b\u044e) \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u043f\u043e\u0441\u0435\u0442\u0438\u0432\u0448\u0435\u0433\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430, \u0435\u0441\u043b\u0438 \u044d\u0442\u043e\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0441\u0430\u0439\u0442\u0443, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0435\u043c\u0443 VK Open API, \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u0440\u043e\u0444\u0438\u043b\u044e (\u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0432\u044b\u0448\u0435, \u044d\u0442\u043e <a href=\"http:\/\/www.example.com\">www.example.com<\/a>). \u0417\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0443 \u043e\u0441\u0442\u0430\u0451\u0442\u0441\u044f \u043b\u0438\u0448\u044c \u0441\u043a\u0440\u044b\u0442\u044c HTTP Referrer \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0437\u0430\u043f\u0440\u043e\u0441 \u2013 \u044d\u0442\u043e \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e.<\/p>\n<p>  \u0418\u0442\u0430\u043a, \u0437\u0430\u0449\u0438\u0442\u0430 \u0432\u0440\u043e\u0434\u0435 \u0431\u044b \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u0441\u0432\u0435\u0440\u043a\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e <code>location.hostname<\/code> \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0435\u0442 \u0434\u043e\u0441\u0442\u0443\u043f \u043f\u043e\u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u043c \u043a Access Token, \u043d\u043e\u2026 \u0432 JavaScript \u0435\u0441\u0442\u044c \u0433\u0435\u0442\u0442\u0435\u0440\u044b\/\u0441\u0435\u0442\u0442\u0435\u0440\u044b, \u0430 \u0443 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u0432 \u0441\u0432\u043e\u0438 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438\/\u0441\u0442\u0440\u0430\u043d\u043d\u043e\u0441\u0442\u0438 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0433\u043e \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f JS (BOM).<\/p>\n<h3>\u042d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0430\u0446\u0438\u044f \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438<\/h3>\n<p>  \u0422\u043e\u0433\u0434\u0430 \u044f \u0440\u0435\u0448\u0438\u043b \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c, \u0430 \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u0434\u043b\u044f <code>location.hostname<\/code> \u0433\u0435\u0442\u0442\u0435\u0440, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0432\u0441\u0435\u0433\u0434\u0430 \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u0441\u0442\u0440\u043e\u043a\u0443 <code>&quot;www.example.com&quot;<\/code>? \u0411\u044b\u0441\u0442\u0440\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0432 \u0441\u0432\u043e\u044e \u0434\u043e\u0433\u0430\u0434\u043a\u0443 \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438, \u0438 \u0443\u0431\u0435\u0434\u0438\u0432\u0448\u0438\u0441\u044c, \u0447\u0442\u043e \u044d\u0442\u043e\u0442 \u0445\u0430\u043a \u043d\u0430 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u043b:<\/p>\n<pre><code class=\"javascript\">\/\/ \u0420\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0432 Chrome-\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0445 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430\u0445 \u043c\u043b\u0430\u0434\u0448\u0435 42-\u0439 \u0432\u0435\u0440\u0441\u0438\u0438, \u0438 \u0432\u0441\u0451\u043c, \u0447\u0442\u043e \u043d\u0430 \u043d\u0451\u043c \u043e\u0441\u043d\u043e\u0432\u0430\u043d\u043e: \/\/ Yandex.Browser, Opera (WebKit), Android Chrome, etc\u2026 \/\/ \u041d\u0430 \u043c\u043e\u043c\u0435\u043d\u0442 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u044d\u0442\u043e\u0433\u043e \u043a\u043e\u0434\u0430, \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0439 \u0431\u044b\u043b\u0430 ~41 \u0432\u0435\u0440\u0441\u0438\u044f \u0425\u0440\u043e\u043c\u0430. \/\/ \u0420\u0430\u0431\u043e\u0442\u0430\u043b\u043e \u043f\u043e\u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u043f\u043e\u043b\u0435 hostname \u043e\u0431\u044a\u0435\u043a\u0442\u0430 location \u044f\u0432\u043b\u044f\u043b\u043e\u0441\u044c configurable-\u043f\u043e\u043b\u0435\u043c. location.__defineGetter__('hostname', function () { \treturn '\u043a\u0430\u043a\u0430\u044f-\u0442\u043e \u0441\u0442\u0440\u043e\u043a\u0430'; });  console.log(location.hostname); \/\/ '\u043a\u0430\u043a\u0430\u044f-\u0442\u043e \u0441\u0442\u0440\u043e\u043a\u0430' <\/code><\/pre>\n<p>  \u0420\u0435\u0448\u0438\u043b \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u043c\u0430\u043d\u0443\u0442\u044c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u0434\u043e\u043c\u0435\u043d\u0430 \u0442\u0430\u043a:<\/p>\n<pre><code class=\"html\">&lt;script&gt; var VK = { \tAuth: { \t\tlsCb: { \t\t\t\/\/ \u042d\u0442\u043e\u0442 \u043c\u0435\u0442\u043e\u0434 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u043d \u043f\u043e\u0441\u043b\u0435 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f JSONP-\u043e\u0442\u0432\u0435\u0442\u0430 \u043e\u0442 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 VK \t\t\t456: function (data) { \t\t\t\talert(data.access_token); \t\t\t} \t\t\t\t \t\t} \t} };  location.__defineGetter__('hostname', function () {return 'www.example.com'}); &lt;\/script&gt; &lt;script src=&quot;https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456&quot;&gt; <\/code><\/pre>\n<p>  \u041d\u043e \u043f\u043e\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0434\u0440\u0443\u0433\u0430\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u2013 HTTP Refferer. \u0412\u0435\u0434\u044c \u0441 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u043c \u043f\u043e URL <code>https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456<\/code> \u0431\u0443\u0434\u0435\u0442 \u0442\u0430\u043a\u0436\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c\u0441\u044f HTTP Refferer \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u0438 \u0435\u0441\u043b\u0438 \u0434\u043e\u043c\u0435\u043d \u044d\u0442\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043d\u0435 \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c, \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u043c \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0440\u0435\u0434\u0438\u0440\u0435\u043a\u0442 \u043d\u0430 <code>https:\/\/vk.com\/js\/api\/openapi_error.js<\/code>, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043a\u043e\u0434:<\/p>\n<pre><code class=\"javascript\">try{console.log('open api access error');}catch(e){} <\/code><\/pre>\n<p>  \u041d\u043e! \u041a\u0430\u043a \u044f \u0443\u0436\u0435 \u043f\u0438\u0441\u0430\u043b \u0432\u044b\u0448\u0435, \u0435\u0441\u043b\u0438 HTTP Refferer \u043d\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u0441\u043e\u0432\u0441\u0435\u043c, \u0442\u043e \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u043e\u0442\u0432\u0435\u0442. \u042f \u0434\u0443\u043c\u0430\u044e, \u0442\u0430\u043a \u0431\u044b\u043b\u043e \u0441\u0434\u0435\u043b\u0430\u043d\u043e \u043f\u043e \u0434\u0432\u0443\u043c \u043f\u0440\u0438\u0447\u0438\u043d\u0430\u043c:<\/p>\n<ol>\n<li>HTTP Refferer \u043c\u043e\u0436\u0435\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430.<\/li>\n<li>\u0412\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u043d\u043e \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 VK Open API \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430\u0445, \u0443 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u043d\u0435\u0442 \u0441\u0432\u043e\u0435\u0433\u043e \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u043e\u0433\u043e URL (\u0442.\u0435. \u0430\u0434\u0440\u0435\u0441 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a\u0430\u043a-\u0431\u044b \u0435\u0441\u0442\u044c, \u043d\u043e \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u0432\u0430\u0448\u0435\u0433\u043e \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 Data URL, ObjectURL \u0438\u043b\u0438 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a \u043a\u0430\u043a\u043e\u0433\u043e-\u043d\u0438\u0431\u0443\u0434\u044c \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043d\u043e\u0433\u043e \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u044f).<\/li>\n<\/ol>\n<p>  \u041e\u0434\u0438\u043d \u0438\u0437 \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u0432 \u0441\u043a\u0440\u044b\u0442\u044c HTTP Refferer \u2013 \u0440\u0430\u0437\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 iframe, \u0432 src \u0443 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0431\u0443\u0434\u0435\u0442 Data URL, \u0430 \u0432 \u043d\u0451\u043c \u043a\u043e\u0434 \u0434\u0440\u0443\u0433\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439:<\/p>\n<ol>\n<li>\u041f\u043e\u0434\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f <code>location.hostname<\/code>.<\/li>\n<li>\u041e\u0431\u044a\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f-\u043f\u043e\u043b\u0443\u0447\u0430\u0442\u0435\u043b\u044c Access Token&#8217;\u0430 ( <code>VK.Auth.lsCb[456]()<\/code>).<\/li>\n<li>\u0420\u0430\u0437\u043c\u0435\u0449\u0430\u0435\u0442\u0441\u044f <code>&lt;script src=&quot;https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456&quot;&gt;<\/code>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439, \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u0438 \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u0442 \u043e\u0442\u0432\u0435\u0442 \u043e\u0442 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 c \u0432\u044b\u0437\u043e\u0432\u043e\u043c JSONP-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 <code>VK.Auth.lsCb[456]()<\/code>.<\/li>\n<\/ol>\n<p>  \u042d\u0442\u0443 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0440\u0430\u0437\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u043d\u0430 \u043b\u044e\u0431\u043e\u043c \u0434\u043e\u043c\u0435\u043d\u0435, \u0438\u043b\u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u043e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435 \u0434\u0430\u0436\u0435 \u0431\u0435\u0437 \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0438 \u043e\u043d\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u043b\u0430 Access Token \u0438 \u0434\u0430\u043d\u043d\u044b\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u0435\u0441\u043b\u0438 \u043e\u043d \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u043b\u0441\u044f \u0447\u0435\u0440\u0435\u0437 VK \u043d\u0430 \u0441\u0430\u0439\u0442\u0435, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0435\u043c VK Open API. \u0414\u043b\u044f \u0443\u0441\u043f\u0435\u0448\u043d\u043e\u0439 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0430\u0446\u0438\u0438 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438, \u043d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043b\u0438\u0448\u044c \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0432 \u0437\u0430\u043f\u0440\u043e\u0441\u0435 ID \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f (\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 <code>aid<\/code>) \u0438 \u0434\u043e\u043c\u0435\u043d \u0441\u0430\u0439\u0442\u0430, \u043a \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u043f\u0440\u0438\u0432\u044f\u0437\u0430\u043d\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 (\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 <code>location<\/code>).<\/p>\n<p>  \u041a\u0430\u043a \u044d\u0442\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0447\u043a\u0430 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u0430:<\/p>\n<pre><code class=\"html\">&lt;!doctype html&gt; &lt;html&gt; &lt;head&gt; \t&lt;title&gt;\u0423\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c VK JS Api&lt;\/title&gt; \t&lt;meta charset=&quot;utf-8&quot;&gt; \t&lt;style&gt; \t\tbody,html { \t\t\tmargin:0; \t\t\tpadding:0; \t\t\twidth:100%; \t\t\theight:100%; \t\t} \t&lt;\/style&gt; &lt;\/head&gt; &lt;body&gt; \t&lt;iframe  \t\tsrc=&quot;data:text\/html;charset=utf-8,%\u043a\u043e\u043d\u0442\u0435\u043d\u0442_\u0437\u0430\u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0439_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot; \t\tstyle=&quot;width:100%;height:100%;border:0&quot; \/&gt; &lt;\/body&gt; &lt;\/html&gt; <\/code><\/pre>\n<p>  \u041f\u0440\u0438\u0431\u043b\u0438\u0437\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0442\u0430\u043a \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b <code>%\u043a\u043e\u043d\u0442\u0435\u043d\u0442_\u0437\u0430\u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0439_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%<\/code> \u0432 iframe:<\/p>\n<pre><code class=\"html\">&lt;!doctype html&gt; &lt;html&gt; &lt;body&gt; &lt;script&gt; \t\/\/ \u0423\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043f\u043e\u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u0434\u043c\u0435\u043d\u0438\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 location.hostname \twindow.location.__defineGetter__('hostname', function () {return 'www.example.com'});  \tvar VK = { \t\tAuth: { \t\t\tlsCb:{ \t\t\t\t456: function (data) { \t\t\t\t\t \t\t\t\t\t\/\/ \u0415\u0441\u043b\u0438 \u0432 \u043e\u0442\u0432\u0435\u0442\u0435 \u0435\u0441\u0442\u044c access_token, \u0437\u043d\u0430\u0447\u0438\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u043d \t\t\t\t\tif (data.access_token) { \t\t\t\t\t\t\/\/ \u0417\u0430\u043d\u0435\u0441\u0435\u043d\u0438\u0435 \u0438\u043c\u0435\u043d\u0438, \u0444\u0430\u043c\u0438\u043b\u0438\u0438, ID \u0438 Access Token'a \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \t\t\t\t\t\t\/\/ \u0432 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435. \t\t\t\t\t} else { \t\t\t\t\t\t\/\/ \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0441\u044c\u0431\u044b \u043f\u0435\u0440\u0435\u0439\u0442\u0438 \u043d\u0430 \u0441\u0430\u0439\u0442 www.example.com, \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0442\u0430\u043c \t\t\t\t\t\t\/\/ \u0438 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c \u044d\u0442\u0443 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443. \t\t\t\t\t} \t\t\t\t\t \t\t\t\t} \t\t\t} \t\t} \t}; &lt;\/script&gt;  &lt;!-- \t\u0412 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0435 aid \u043c\u043e\u0433 \u0431\u044b\u0442\u044c ID \u043b\u044e\u0431\u043e\u0433\u043e VK-\u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0442\u0438\u043f\u0430 &quot;\u0412\u0435\u0431-\u0441\u0430\u0439\u0442&quot;, \u0438 \u0435\u0441\u043b\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c  \t\u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0441\u0430\u0439\u0442\u0443-\u0436\u0435\u0440\u0442\u0432\u0435 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0432\u043e\u0435\u043c\u0443 \u043f\u0440\u043e\u0444\u0438\u043b\u044e VK, \u0442\u043e \u043a\u043e\u0434, \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0439 \u0432\u044b\u0448\u0435, \u0443\u0441\u043f\u0435\u0448\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u043b  \tAccess Token \u0438 \u043c\u043e\u0433 \u0441\u0432\u043e\u0431\u043e\u0434\u043d\u043e \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a VK API.  --&gt; &lt;script src=&quot;https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456&quot;&gt;&lt;\/script&gt;  &lt;\/body&gt; &lt;\/html&gt; <\/code><\/pre>\n<p>  \u0417\u0430\u043f\u0430\u043a\u043e\u0432\u0430\u0432 \u044d\u0442\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440 \u0432 \u0430\u0440\u0445\u0438\u0432, \u044f \u043d\u0430\u043f\u0438\u0441\u0430\u043b \u0432 VK, \u0438 \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u043b \u0438\u043c \u044d\u0442\u043e\u0442 \u0430\u0440\u0445\u0438\u0432. \u0427\u0435\u0440\u0435\u0437 \u043f\u0430\u0440\u0443 \u0434\u043d\u0435\u0439 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u043b\u0438. \u0422\u043e\u0447\u043d\u0435\u0435, \u043f\u043e\u0441\u043b\u0435 \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u0441\u0442\u0430\u043b\u0430 \u0435\u0449\u0451 \u0441\u0435\u0440\u044c\u0451\u0437\u043d\u0435\u0435. \u0415\u0441\u043b\u0438 \u043e\u043d\u0430 \u0440\u0430\u043d\u044c\u0448\u0435 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u043b\u0430\u0441\u044c \u0438\u0437-\u0437\u0430 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u0432 \u043d\u0430 WebKit, \u0438 \u0442\u043e \u0434\u043e ~42 \u0432\u0435\u0440\u0441\u0438\u0438 Google Chrome, \u0442\u043e \u0442\u0435\u043f\u0435\u0440\u044c, \u043e\u043d\u0430 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u043b\u0430\u0441\u044c \u043d\u0430 \u0432\u0441\u0435\u0445 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430\u0445, \u0431\u043e\u043b\u0435\u0435-\u043c\u0435\u043d\u0435\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0449\u0438\u0445 JavaScript. \u0417\u043d\u0430\u0442\u043e\u043a\u0438 JS, \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0439\u0442\u0435 \u0434\u043e\u0433\u0430\u0434\u0430\u0442\u044c\u0441\u044f \u043f\u043e \u043a\u043e\u0434\u0443, \u0440\u0430\u0437\u043c\u0435\u0449\u0451\u043d\u043d\u043e\u043c\u0443 \u043d\u0438\u0436\u0435, \u043f\u043e\u0447\u0435\u043c\u0443 \u0432\u0441\u0451 \u0441\u0442\u0430\u043b\u043e \u0435\u0449\u0451 \u0445\u0443\u0436\u0435? \u0423\u0447\u0442\u0438\u0442\u0435, \u0447\u0442\u043e \u0442\u0430\u043c \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u0434\u043e\u043c\u0435\u043d\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043d\u0435 \u043f\u043e\u043b\u0435 <code>hostname<\/code> (\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u0443\u0435\u043c\u044b\u043c), \u0430 <code>href<\/code>, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u041d\u0415 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u0443\u0435\u043c\u044b\u043c, \u0438 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u0434\u043b\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043d\u0435\u043b\u044c\u0437\u044f \u0437\u0430\u0434\u0430\u0442\u044c \u0433\u0435\u0442\u0442\u0435\u0440, \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u044e\u0449\u0438\u0439 \u043d\u0443\u0436\u043d\u043e\u0435 \u043d\u0430\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435. <\/p>\n<p>  \u041e\u0442\u0432\u0435\u0442 \u043e\u0442 \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u043f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438:<\/p>\n<pre><code class=\"javascript\">\/* &lt;html&gt;&lt;script&gt;window.location='http:\/\/vk.com';&lt;\/script&gt;&lt;\/html&gt; *\/ if (!location.href.match(\/https?:\\\/\\\/www\\.mysite\\.com\\\/\/)) {     window.location.href = 'http:\/\/vk.com\/oauth';     for (;;); } else {     VK.Auth.lsCb[456]({         &quot;auth&quot;: true,         &quot;access_token&quot;: &quot;5ea11111d799a53236f5d3eff5d34bcd2dda0f9e6a7aaf743f7d26d3487456f6ce8d5e1ff82eaa6f7b04a&quot;,         &quot;expire&quot;: 1436755095,         &quot;time&quot;: 7200,         &quot;sig&quot;: &quot;12d254526496a6db2af6bed2eb1dd3e7&quot;,         &quot;secret&quot;: &quot;oauth&quot;,         &quot;user&quot;: {             &quot;id&quot;: &quot;%ID_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;,             &quot;domain&quot;: &quot;%\u0438\u043c\u044f_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;,             &quot;href&quot;: &quot;https:\\\/\\\/vk.com\\\/%\u0438\u043c\u044f_\u0438\u043b\u0438_id_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;,             &quot;first_name&quot;: &quot;%\u0438\u043c\u044f%&quot;,             &quot;last_name&quot;: &quot;%\u0444\u0430\u043c\u0438\u043b\u0438\u044f%&quot;,             &quot;nickname&quot;: &quot;&quot;         }     }); } <\/code><\/pre>\n<p>  \u0421\u0430\u043c\u043e\u0435 \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u043e\u0435 \u2013 \u043d\u0435\u0437\u0430\u044f\u043a\u043e\u0440\u0435\u043d\u043d\u043e\u0435 \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435, \u0438\u2026 \u044f \u044d\u0442\u043e \u0437\u0430\u043c\u0435\u0442\u0438\u043b \u0442\u043e\u043b\u044c\u043a\u043e \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043a\u0438 \u0441\u0442\u0430\u0442\u044c\u0438. \u041c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u043e\u0441\u0442\u0440\u043e\u0438\u0442\u044c URL \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u044e\u0449\u0435\u0439 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u0442\u0430\u043a, \u0447\u0442\u043e\u0431\u044b \u0432 \u043d\u0435\u0439 \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u043e\u0432\u0430\u043b\u0430 \u043f\u043e\u0434\u0441\u0442\u0440\u043e\u043a\u0430 \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u044e\u0449\u0430\u044f \u0441 \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u044b\u043c \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435\u043c, \u0438 \u0432\u0441\u0451 \u0431\u044b \u0437\u0430\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u043e, \u043f\u0440\u0430\u0432\u0434\u0430, \u0434\u043e \u0442\u0435\u0445 \u043f\u043e\u0440, \u043f\u043e\u043a\u0430 \u0432 \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043a\u0443 \u043d\u0435 \u0434\u043e\u0431\u0430\u0432\u044f\u0442 \u044f\u043a\u043e\u0440\u044c <code>&quot;^&quot;<\/code>. \u041d\u043e \u0432\u0435\u0434\u044c \u043f\u043e\u0434\u043c\u0435\u043d\u0430 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043d\u043e\u0433\u043e \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f JS \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u0435\u0435!<\/p>\n<p>  \u0422\u0430\u043a \u0432\u043e\u0442, \u043f\u043e\u0434\u043c\u0435\u043d\u0438\u0442\u044c \u0442\u0443\u0442 \u043c\u043e\u0436\u043d\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u043c\u0435\u0442\u043e\u0434 <code>match()<\/code> \u0438\u0437 \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f\u0430 <code>String<\/code>. \u0415\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0434\u043c\u0435\u043d\u0438\u0442\u044c \u0442\u0430\u043a, \u0447\u0442\u043e\u0431\u044b \u043e\u043d \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u043b <code>true<\/code>, \u0435\u0441\u043b\u0438 \u043f\u0435\u0440\u0432\u044b\u0439 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442 \u0440\u0430\u0432\u0435\u043d \u0440\u0435\u0433\u0443\u043b\u044f\u0440\u043d\u043e\u043c\u0443 \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u044e <code>&quot;\/https?:\\\/\\\/www\\.mysite\\.com\\\/\/&quot;<\/code>, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043d\u0435\u0432\u0430\u0436\u043d\u043e, \u0447\u0442\u043e \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0441\u0442\u0440\u043e\u043a\u0435-\u043f\u043e\u043b\u0443\u0447\u0430\u0442\u0435\u043b\u0435 \u0432\u044b\u0437\u043e\u0432\u0430 \u043c\u0435\u0442\u043e\u0434\u0430 <code>match()<\/code>. \u0414\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u0432 \u0434\u0435\u043c\u043e, \u044f \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u043b \u043e\u0431\u043d\u043e\u0432\u043b\u0451\u043d\u043d\u0443\u044e \u0432\u0435\u0440\u0441\u0438\u044e \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438 \u0432 VK.<\/p>\n<p>  \u041a\u0430\u043a \u0438 \u0432 \u043f\u0440\u043e\u0448\u043b\u044b\u0439 \u0440\u0430\u0437, \u044d\u0442\u043e \u0431\u044b\u043b\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0441 iframe, \u0432 src \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0431\u044b\u043b Data URL:<\/p>\n<pre><code class=\"html\">&lt;!doctype html&gt; &lt;html&gt; &lt;body&gt; &lt;script&gt; \tvar VK = { \t\tAuth: { \t\t\tlsCb:{ \t\t\t\t456: function (data) { \t\t\t\t\tif (data.access_token) { \t\t\t\t\t\tApp.ready = true; \t\t\t\t\t\tApp.access_token = data.access_token; \t\t\t\t\t\tApp.first_name = data.user.first_name; \t\t\t\t\t\tApp.last_name = data.user.last_name; \t\t\t\t\t\tApp.user_id = data.user.id; \t\t\t\t\t} \t\t\t\t\tApp.init(); \t\t\t\t} \t\t\t} \t\t} \t}, \tApp = { \t\t_original_match_method: String.prototype.match,  \t\t_restoreOriginalMatch: function () { \t\t\tString.prototype.match = this._original_match_method; \t\t},  \t\tinit: function () { \t\t\t\/\/ \u0412\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u043e\u0433\u043e String.prototype.match() \t\t\tthis._restoreOriginalMatch();  \t\t\tif (this.ready) { \t\t\t\t\/\/ \u0417\u0430\u043d\u0435\u0441\u0435\u043d\u0438\u0435 \u0438\u043c\u0435\u043d\u0438, \u0444\u0430\u043c\u0438\u043b\u0438\u0438, ID \u0438 Access Token'a \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \t\t\t\t\/\/ \u0432 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435. \t\t\t} else { \t\t\t\t\/\/ \u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0441\u044c\u0431\u044b \u043f\u0435\u0440\u0435\u0439\u0442\u0438 \u043d\u0430 \u0441\u0430\u0439\u0442 www.example.com, \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0442\u0430\u043c \t\t\t\t\/\/ \u0447\u0435\u0440\u0435\u0437 VK \u0438 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c \u044d\u0442\u0443 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443. \t\t\t} \t\t} \t};  \t\/\/ \u0414\u043e\u0431\u0438\u0432\u0430\u0435\u043c\u0441\u044f \u0442\u0430\u043a\u043e\u0433\u043e \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u044f: \t\/\/ 'any string'.match(\/https?:\\\/\\\/www\\.mysite\\.com\\\/\/) \/\/ true \t\/\/ 'any string'.match(\/.*\/) \/\/ ['any string'] \t(function () { \t\tvar original_match = String.prototype.match; \t\tString.prototype.match = function () { \t\t\t\/\/ \u0417\u043d\u0430\u044e, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u043f\u043e-\u0434\u0440\u0443\u0433\u043e\u043c\u0443, \u043d\u043e \u0442\u043e\u0433\u0434\u0430 \u043f\u043e\u0447\u0435\u043c\u0443-\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u043b \u0442\u0430\u043a. \t\t\treturn arguments[0] == '\/https?:\\\\\/\\\\\/www\\\\.mysite\\\\.com\\\\\/\/' ? true : original_match.apply(this, arguments); \t\t} \t})(); &lt;\/script&gt; &lt;script src=&quot;https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456&quot;&gt;&lt;\/script&gt;  &lt;\/body&gt; &lt;\/html&gt; <\/code><\/pre>\n<p>  \u041e\u0442\u043f\u0440\u0430\u0432\u0438\u0432 \u0432\u0441\u0451 \u044d\u0442\u043e \u044f \u0441\u0442\u0430\u043b \u0436\u0434\u0430\u0442\u044c. <\/p>\n<h3>\u041f\u0435\u0440\u0435\u0445\u043e\u0434 \u043d\u0430 \u043d\u043e\u0432\u044b\u0439 \u0443\u0440\u043e\u0432\u0435\u043d\u044c: WebWorkers<\/h3>\n<p>  \u0427\u0435\u0440\u0435\u0437 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u043f\u043e\u0441\u043b\u0435 \u0442\u043e\u0433\u043e, \u043a\u0430\u043a \u044f \u043e\u0442\u043f\u0440\u0430\u0432\u0438\u043b \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0435 \u0434\u0435\u043c\u043e, \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u043b\u0438. \u0418 \u0441\u043d\u043e\u0432\u0430, \u044f \u0440\u0435\u0448\u0438\u043b \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f, \u043a\u0430\u043a \u0438\u043c\u0435\u043d\u043d\u043e \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u043b\u0438 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c. <\/p>\n<p>  \u041a\u0430\u043a \u0438 \u0440\u0430\u043d\u044c\u0448\u0435, \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f Access Token&#8217;\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0434\u0435\u043b\u0430\u043b\u0441\u044f JSONP-\u0437\u0430\u043f\u0440\u043e\u0441 \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440 VK, \u0438 \u0432 \u043e\u0442\u0432\u0435\u0442\u0435 \u0431\u044b\u043b\u0430 \u0432\u0441\u0451 \u0442\u0430 \u0436\u0435 \u0441\u0432\u0435\u0440\u043a\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u0434\u043e\u043c\u0435\u043d\u0430 \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f VK:<\/p>\n<pre><code class=\"javascript\">\/* &lt;html&gt;&lt;script&gt;window.location='http:\/\/vk.com';&lt;\/script&gt;&lt;\/html&gt; *\/ if ( \tlocation.href !==  \t\t(location.protocol == 'https:' ? 'https' : 'http')  \t\t+ ':\/\/www.example.com'  \t\t+ (location.port ? ':' + location.port : '')  \t\t+ '\/' + location.pathname.slice(1)  \t\t+ location.search + location.hash ) { \twindow.location.href = 'http:\/\/vk.com\/oauth'; \tfor (;;); } else { \tVK.Auth.lsCb[456]({ \t\t&quot;auth&quot;: true, \t\t&quot;access_token&quot;: &quot;512aae7f9e9070f3bbb1600b934238546e4567892q2fj29739242e2b66521da110fdf5nmj9fee6ce8&quot;, \t\t&quot;expire&quot;: 1438739486, \t\t&quot;time&quot;: 7200, \t\t&quot;sig&quot;: &quot;53aa7a11c2431d96v8765e1b3c7q2c22&quot;, \t\t&quot;secret&quot;: &quot;oauth&quot;, \t\t&quot;user&quot;: { \t\t\t&quot;id&quot;: &quot;%ID_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;, \t\t\t&quot;domain&quot;: &quot;%\u0438\u043c\u044f_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;, \t\t\t&quot;href&quot;: &quot;https:\\\/\\\/vk.com\\\/%\u0438\u043c\u044f_\u0438\u043b\u0438_id_\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b%&quot;, \t\t\t&quot;first_name&quot;: &quot;%\u0438\u043c\u044f%&quot;, \t\t\t&quot;last_name&quot;: &quot;%\u0444\u0430\u043c\u0438\u043b\u0438\u044f%&quot;, \t\t\t&quot;nickname&quot;: &quot;&quot; \t\t}     }); } <\/code><\/pre>\n<p>  \u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u043a\u0430\u0436\u0435\u0442\u0441\u044f \u0431\u0435\u0437\u0443\u043f\u0440\u0435\u0447\u043d\u043e\u0439, \u0442.\u043a. \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u0434\u043e\u043c\u0435\u043d\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u041d\u0415 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u0443\u0435\u043c\u043e\u0435 \u043f\u043e\u043b\u0435 <code>location.href<\/code> (\u0442.\u0435. \u043d\u0430 \u043d\u0435\u0433\u043e \u043d\u0435\u043b\u044c\u0437\u044f \u043d\u0430\u0432\u0435\u0441\u0438\u0442\u044c getter\/setter). \u0421\u043a\u043e\u043b\u044c\u043a\u043e \u043d\u0435 \u043f\u0440\u043e\u0431\u0443\u0439, \u043a\u0430\u0436\u0435\u0442\u0441\u044f, \u0432 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 UI-\u043f\u043e\u0442\u043e\u043a\u0430 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430 (\u0442\u0430\u043c, \u0433\u0434\u0435 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u043c \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f <code>window<\/code>) <code>location<\/code> \u043d\u0435 \u043f\u043e\u0434\u043c\u0435\u043d\u0438\u0442\u044c\u2026 \u041d\u043e \u0443 \u043d\u0430\u0441 \u0432\u0435\u0434\u044c \u0435\u0449\u0451 \u0435\u0441\u0442\u044c \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 WebWorker&#8217;a! \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0432 \u0441\u0432\u043e\u044e \u0434\u043e\u0433\u0430\u0434\u043a\u0443, \u0441\u0442\u0430\u043b\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u043e, \u0447\u0442\u043e \u0432 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 Worker&#8217;a (<code>DedicatedWorkerGlobalScope<\/code>) \u043f\u043e\u043b\u0435 <code>location<\/code> \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <code>self<\/code> \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u0430\u043a\u0440\u044b\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c \u0441 \u043f\u043e\u043b\u044f\u043c\u0438 <code>href<\/code>, <code>hostname<\/code> \u0438 \u0434\u0440. \u041f\u043e\u0447\u0435\u043c\u0443? \u0412\u0441\u0451 \u043f\u0440\u043e\u0441\u0442\u043e: \u043e\u0431\u044a\u0435\u043a\u0442 <code>location<\/code> \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0435 \u0432 \u0441\u0430\u043c\u043e\u043c \u043e\u0431\u044a\u0435\u043a\u0442\u0435 <code>self<\/code>, \u0430 \u0432 \u0435\u0433\u043e \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f\u0435, \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044f <code>var location = {};<\/code> \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u043d\u0430\u044f \u0432 \u0433\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u043e\u0439 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 \u0432\u0438\u0434\u0438\u043c\u043e\u0441\u0442\u0438 Worker&#8217;a, \u0438\u043b\u0438 <code>Object.defineProperty(self, 'location', {value: ... })<\/code> \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0435\u0440\u0435\u043a\u0440\u044b\u0432\u0430\u044e\u0442 <code>location<\/code> \u0438\u0437 \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <code>self<\/code> (\u0442.\u0435. \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043e\u0431\u044a\u0435\u043a\u0442\u0443 <code>self<\/code> <i>\u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u043f\u043e\u043b\u0435<\/i> <code>location<\/code>). \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u043a\u043e\u0434, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0434\u0433\u0440\u0443\u0436\u0435\u043d \u0447\u0435\u0440\u0435\u0437 <code>self.importScripts()<\/code> \u043f\u0440\u0438 \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u0438 \u043a <code>location<\/code>, \u043f\u043e\u043b\u0443\u0447\u0438\u0442 \u043d\u0430\u0448 \u043e\u0431\u044a\u0435\u043a\u0442, \u0430 \u043d\u0435 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0439. \u041a\u0441\u0442\u0430\u0442\u0438, \u0432 UI-\u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430 \u0442\u0430\u043a\u043e\u0439 \u0442\u0440\u044e\u043a \u043d\u0435 \u043f\u0440\u043e\u0439\u0434\u0451\u0442: \u0442\u0430\u043c \u043e\u0431\u044a\u0435\u043a\u0442 <code>location<\/code> \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d \u043a\u0430\u043a <i>\u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u043f\u043e\u043b\u0435<\/i> \u043e\u0431\u044a\u0435\u043a\u0442\u0430 <code>window<\/code>, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043d\u0438\u0447\u0435\u043c \u043d\u0435 \u043f\u0435\u0440\u0435\u043a\u0440\u043e\u0435\u0448\u044c.<\/p>\n<p>  \u041d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u043f\u0440\u0438\u043c\u0435\u0440, \u043a\u0430\u043a \u044d\u0442\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442:<\/p>\n<pre><code class=\"html\">&lt;!doctype html&gt; &lt;html&gt; &lt;head&gt; \t&lt;title&gt;Workers&lt;\/title&gt; \t&lt;meta charset=&quot;utf-8&quot; \/&gt; \t &lt;\/head&gt; &lt;body&gt;  &lt;script&gt; (function () { \tvar worker, \t\/\/ \u042d\u0442\u043e\u0442 \u043a\u043e\u0434 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u0432 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u043c \u043f\u043e\u0442\u043e\u043a\u0435, \u0432 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 Worker'\u0430. \t\/\/ \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043a\u043e\u0434 \u0432 \u0432 \u0432\u0438\u0434\u0435 \u0442\u0435\u043a\u0441\u0442\u0430,  \t\/\/ \u043e\u0431\u044a\u044f\u0432\u043b\u044f\u0435\u043c \u0430\u043d\u043e\u043d\u0438\u043c\u043d\u0443\u044e \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0435\u0451 \u0441\u0442\u0440\u043e\u043a\u043e\u0432\u043e\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0435. \tworker_code = (function () {  \t\t\/\/ \u0417\u0430\u0442\u0438\u0440\u0430\u0435\u043c \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0439 location \t\tvar location = { \t\t\t\/\/ URL \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u044b \u044d\u043c\u0443\u043b\u0438\u0440\u0443\u0435\u043c \t\t\thref: 'http:\/\/www.example.com\/', \t\t\tsearch: '', \t\t\thash: '', \t\t\tpathname: '' \t\t}, \t\tVK = { \t\t\tAuth: { \t\t\t\tlsCb: { \t\t\t\t\t\/\/ \u041e\u0431\u044a\u044f\u0432\u043b\u044f\u0435\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u044e-\u043f\u0440\u0438\u0435\u043c\u043d\u0438\u043a \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u0441 access_token'\u043e\u043c \t\t\t\t\t456: function (data) { \t\t\t\t\t\t\/\/ \u041e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c UI-\u043f\u043e\u0442\u043e\u043a\u0443 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u044b\u0439 \u043e\u0431\u044a\u0435\u043a\u0442 \t\t\t\t\t\tself.postMessage(data); \t\t\t\t\t} \t\t\t\t} \t\t\t} \t\t};  \t\t\/\/ \u0417\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u043c \u0441\u043a\u0440\u0438\u043f\u0442 \u0441 Access Token'\u043e\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f (\u043a\u0443\u043a\u0438 \u0442\u0443\u0442 \u0442\u043e\u0436\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u044e\u0442\u0441\u044f). \t\t\/\/ \u041f\u043e \u0441\u0447\u0430\u0441\u0442\u043b\u0438\u0432\u043e\u0439 \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0441\u0442\u0438, \u0433\u0434\u0435-\u0442\u043e \u0441 42-\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 Chrome, \u0441 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u043c \u0432 importScripts() \t\t\/\/ \u043d\u0435 \u043f\u043e\u0441\u044b\u043b\u0430\u0435\u0442\u0441\u044f Refferer, \u0435\u0441\u043b\u0438 \u0432 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440 Worker'\u0443 \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c ObjectURL, \t\t\/\/ \u0432\u043c\u0435\u0441\u0442\u043e \u043f\u0443\u0442\u0438 \u043a \u0444\u0430\u0439\u043b\u0443. \u0422\u0430\u043a \u0447\u0442\u043e referrer \u0441 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u043c \u043d\u0438\u0436\u0435 \u043d\u0435 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f, \u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u0447\u0435\u043c\u0443 \t\t\/\/ \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0432\u0430\u043b\u0438\u0434\u043d\u044b\u0439 \u043e\u0442\u0432\u0435\u0442 \u043e\u0442 VK. \t\timportScripts('https:\/\/login.vk.com\/?act=openapi&oauth=1&aid=1234567&location=www.example.com&rnd=456'); \t\t\t \t}).toString(); \t \t\/\/ \u0423\u0434\u0430\u043b\u044f\u0435\u043c \u0438\u0437 \u043a\u043e\u0434\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043f\u043e\u0434\u0441\u0442\u0440\u043e\u043a\u0443 &quot;function () {&quot; \u0432 \u043d\u0430\u0447\u0430\u043b\u0435, \u0438 &quot;}&quot; \u0432 \u043a\u043e\u043d\u0446\u0435  \tworker_code = worker_code.substring(worker_code.indexOf('{') + 1, worker_code.length - 1);  \tworker = new Worker( \t\t\/\/ \u0411\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f ObjectURL, \u043c\u043e\u0436\u0435\u043c \u043e\u0431\u043e\u0439\u0442\u0438\u0441\u044c \u0431\u0435\u0437 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0433\u043e \u0444\u0430\u0439\u043b\u0430 \u0441 \u043a\u043e\u0434\u043e\u043c \u0434\u043b\u044f Worker'a \t\tURL.createObjectURL( \t\t\tnew Blob([worker_code], {type: 'application\/javascript'}) \t\t) \t);  \tworker.addEventListener('message', function (e) { \t\tif (e.data.auth) { \t\t\talert(e.data.access_token); \t\t} else { \t\t\talert('\u0410\u0432\u0442\u043e\u0440\u0438\u0437\u0443\u0439\u0442\u0435\u0441\u044c \u0447\u0435\u0440\u0435\u0437 VK \u043d\u0430 \u0441\u0430\u0439\u0442\u0435 www.example.com \u0438 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u0435 \u044d\u0442\u0443 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443'); \t\t} \t}, false); }());  &lt;\/script&gt; &lt;\/body&gt; &lt;\/html&gt; <\/code><\/pre>\n<p>  \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c, \u0443 \u043d\u0430\u0441 \u0435\u0441\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u043e\u0434\u043c\u0435\u043d\u044f\u0442\u044c JS API \u043f\u043e\u043a\u0440\u0443\u0447\u0435, \u0447\u0435\u043c \u0432 UI-\u043f\u043e\u0442\u043e\u043a\u0435. \u041e\u0444\u043e\u0440\u043c\u0438\u0432 \u0432\u0441\u0451 \u044d\u0442\u043e \u00ab\u043f\u043e-\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e\u043c\u0443\u00bb, \u044f \u0441\u0442\u0430\u043b \u0436\u0434\u0430\u0442\u044c \u043e\u0442\u0432\u0435\u0442\u0430. \u0427\u0435\u0440\u0435\u0437 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u0443\u044f\u0437\u0432\u0438\u043c\u044b\u0439 \u043a\u043e\u0434 \u0432 openapi.js \u043f\u043e\u043f\u0440\u0430\u0432\u0438\u043b\u0438. \u0422\u0435\u043f\u0435\u0440\u044c \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f Access Token&#8217;\u0430, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u0434\u0435\u043b\u0430\u0435\u0442 \u043a\u0440\u043e\u0441\u0441\u0434\u043e\u043c\u0435\u043d\u043d\u044b\u0439 \u0437\u0430\u043f\u0440\u043e\u0441 \u043d\u0430 backend VK \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 <a href=\"https:\/\/ru.wikipedia.org\/wiki\/Cross-origin_resource_sharing\">Cross-origin resource sharing<\/a>.<\/p>\n<h3>\u041f\u043e-\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e\u043c\u0443<\/h3>\n<p>  \u041f\u043e\u0441\u043b\u0435 \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 \u043f\u0435\u0440\u0432\u044b\u0445 \u0434\u0432\u0443\u0445 \u0434\u0435\u043c\u043e, \u043c\u043d\u0435 \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043a\u0430\u043a-\u0442\u043e \u043d\u0435\u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u0434\u0435\u043c\u043e \u0432 \u0432\u0438\u0434\u0435 \u043f\u0440\u043e\u0441\u0442\u043e\u0433\u043e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e Access Token&#8217;a\u2026 \u0418 \u043f\u043e\u0441\u043b\u0435 \u043d\u0435\u0434\u043e\u043b\u0433\u0438\u0445 \u0440\u0430\u0437\u0434\u0443\u043c\u0438\u0439, \u044f \u0440\u0435\u0448\u0438\u043b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0430\u0442\u0447 \u0434\u043b\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 VK Open API (http:\/\/vk.com\/js\/api\/openapi.js) \u0442\u0430\u043a, \u0447\u0442\u043e\u0431\u044b \u043e\u043d\u0430 \u0441\u0430\u043c\u0430 \u0443\u043c\u0435\u043b\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c\u044e.<\/p>\n<p>  \u0427\u0442\u043e \u0432 \u0438\u0442\u043e\u0433\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c:<\/p>\n<pre><code class=\"html\">&lt;!doctype html&gt; &lt;html&gt; &lt;head&gt;\t \t&lt;!-- \u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c VK Open Api --&gt; \t&lt;script src=&quot;http:\/\/vk.com\/js\/api\/openapi.js&quot;&gt;&lt;\/script&gt;  \t&lt;!--  \t\t\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c \u043f\u0430\u0442\u0447, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043a \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u043c\u0443 openapi.js \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a VK API \t\t\u043e\u0442 \u0438\u043c\u0435\u043d\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043f\u0440\u0438\u0432\u044f\u0437\u0430\u043d\u043e \u043a \u0434\u0440\u0443\u0433\u043e\u043c\u0443 \u0434\u043e\u043c\u0435\u043d\u0443. \t\t\u0422.\u0435. \u0435\u0441\u043b\u0438 \u044d\u0442\u043e\u0442 \u0444\u0430\u0439\u043b \u043d\u0435 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c, \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0435 \u0431\u0443\u0434\u0435\u0442. \u041a\u042d\u041f. \t --&gt; \t&lt;script src=&quot;vk_opanapi_insecure_patch.js&quot;&gt;&lt;\/script&gt;\t &lt;\/head&gt; &lt;body&gt; &lt;script&gt; VK.init({ \t\/\/ \u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 - ID VK \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \tapiId: 1234567, \t \t\/\/ \u0412 \u0444\u0430\u0439\u043b\u0435 vk_opanapi_insecure_patch.js, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 openapi.js \u043c\u043e\u0434\u0438\u0444\u0438\u0446\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0442\u0430\u043a, \t\/\/ \u0447\u0442\u043e JSONP-\u0437\u0430\u043f\u0440\u043e\u0441 \u043d\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 Access Token'\u0430 \u0434\u0435\u043b\u0430\u0435\u0442\u0441\u044f \u0432 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0438 Worker'a, \t\/\/ \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0438\u043c\u0438\u0442\u0438\u0440\u0443\u0435\u0442 UI-\u043f\u043e\u0442\u043e\u043a \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c \u0438\u0437 \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430. \tappDomain: 'www.example.com' });  \/\/ \u041f\u043e\u0441\u043b\u0435 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0441 \u043d\u0435\u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u043c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u043c &quot;appDomain&quot;,  \/\/ \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a \u043c\u0435\u0442\u043e\u0434\u0430\u043c API \u043a\u0430\u043a \u0431\u0443\u0434\u0442\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0441 ID &quot;1234567&quot; \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0430\u0448\u0438\u043c,  \/\/ \u0438 \u043c\u044b \u043d\u0430\u0445\u043e\u0434\u0438\u043c\u0441\u044f \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u0441 \u0434\u043e\u043c\u0435\u043d\u043e\u043c &quot;www.example.com&quot;. VK.Api.call('users.get', {}, function(r) {    if(r.response) {      alert('\u0422\u0435\u043a\u0443\u0449\u0438\u0439 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c: ' + r.response[0].first_name + ' ' + r.response[0].last_name);    }  });  &lt;\/script&gt; &lt;\/body&gt; &lt;\/html&gt; <\/code><\/pre>\n<p>  <a href=\"https:\/\/drive.google.com\/file\/d\/0B8mwJU8Ya6USQXoydlFxOS0teEE\/view?usp=sharing\">\u0421\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u0430\u0440\u0445\u0438\u0432<\/a>.<\/p>\n<h3>\u0412\u044b\u0432\u043e\u0434\u044b<\/h3>\n<p>  \u041f\u043e\u0440\u043e\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0448\u044c\u0441\u044f \u043d\u0430 \u043f\u0440\u043e\u0442\u044f\u0436\u0435\u043d\u0438\u0438 \u0434\u043e\u043b\u0433\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438, \u043f\u0440\u0435\u043f\u043e\u0434\u043d\u043e\u0441\u0438\u0442 \u0441\u044e\u0440\u043f\u0440\u0438\u0437\u044b. \u0418\u043d\u043e\u0433\u0434\u0430 \u0432 \u0432\u0438\u0434\u0435 \u0441\u0435\u0440\u044c\u0451\u0437\u043d\u044b\u0445 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0435\u0439. \u041e\u0434\u043d\u0430\u043a\u043e \u0435\u0441\u0442\u044c \u043e\u0431\u0449\u0435\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u043e: \u043d\u0438\u043a\u043e\u0433\u0434\u0430 \u043d\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0439\u0442\u0435 \u0447\u0435\u0440\u0435\u0437 JSONP \u043a\u043e\u043d\u0444\u0438\u0434\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435. \u0414\u0430\u0436\u0435 \u043a\u043e\u0433\u0434\u0430 \u043a\u043e\u0434 \u0432\u0430\u043b\u0438\u0434\u0430\u0446\u0438\u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u0435\u043b\u044f JSONP-\u043e\u0442\u0432\u0435\u0442\u0430 \u043a\u0430\u0436\u0435\u0442\u0441\u044f \u0431\u0435\u0437\u0443\u043f\u0440\u0435\u0447\u043d\u044b\u043c, \u0432\u044b\u044f\u0441\u043d\u044f\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0434\u043c\u0435\u043d\u0438\u0442\u044c \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043d\u043e\u0435 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u0435 JS (BOM) \u0442\u0430\u043a, \u0447\u0442\u043e \u0432\u0441\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u043f\u0435\u0440\u0435\u0434 \u043f\u0435\u0440\u0435\u0434\u0430\u0447\u0435\u0439 \u0442\u043e\u043a\u0435\u043d\u0430 \u043a\u043e\u0434\u0443 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0441\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430 \u043d\u0435\u0442. \u0412\u043e\u043e\u0431\u0449\u0435, \u043f\u043e\u0440\u0430 \u043e\u0442\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0442 JSONP \u0432 \u043f\u043e\u043b\u044c\u0437\u0443 CORS. <\/p>\n<p>  \u0412 \u044d\u0442\u043e\u0439 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438, \u044f \u043d\u0438 \u0432 \u043a\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0435 \u0445\u043e\u0442\u0435\u043b \u0432\u044b\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 VK Open API \u0432 \u043d\u0435\u0445\u043e\u0440\u043e\u0448\u0435\u043c \u0441\u0432\u0435\u0442\u0435. \u041d\u0430\u043e\u0431\u043e\u0440\u043e\u0442: \u0440\u0435\u0431\u044f\u0442\u0430 \u043c\u043e\u043b\u043e\u0434\u0446\u044b, \u0440\u0430\u0437\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u044e\u0442 \u043a\u0440\u0443\u0442\u043e\u0439 \u0441\u0435\u0440\u0432\u0438\u0441, \u043d\u0430 \u043a\u0440\u0443\u0442\u044b\u0445 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u044f\u0445 \u0441 \u043e\u0442\u043b\u0438\u0447\u043d\u043e\u0439 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0435\u0439 \u0438 \u0441\u043b\u0443\u0436\u0431\u043e\u0439 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0438. \u0410 \u043e\u0448\u0438\u0431\u0438\u0442\u044c\u0441\u044f \u043c\u043e\u0436\u0435\u0442 \u043a\u0430\u0436\u0434\u044b\u0439. \u041e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u043f\u0440\u0438\u0447\u0438\u043d\u0430, \u043f\u043e \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u044f \u0442\u0430\u043a\u0438 \u0440\u0435\u0448\u0438\u043b\u0441\u044f \u043d\u0430 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0441\u0442\u0430\u0442\u044c\u0438 \u2014 \u044d\u0442\u043e \u0436\u0435\u043b\u0430\u043d\u0438\u0435 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0435\u0440\u0435\u0447\u044c \u0432\u0435\u0431-\u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 \u043e\u0442 \u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0445 \u043e\u0448\u0438\u0431\u043e\u043a.<\/p>\n<p>  \u0412 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0435, \u044d\u0442\u043e \u0432\u0441\u0451. \u042f \u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043b \u043e\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0443\u0442\u044c \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438 \u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0430\u0431\u0437\u0430\u0446\u0430\u0445, \u043e\u0434\u043d\u0430\u043a\u043e \u043f\u043e\u0441\u043b\u0435 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u0438\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0430\u0431\u0437\u0430\u0446\u0430 \u043c\u0435\u043d\u044f \u043d\u0435 \u043f\u043e\u043a\u0438\u0434\u0430\u043b\u043e \u0447\u0443\u0432\u0441\u0442\u0432\u043e \u043d\u0435\u0434\u043e\u0441\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0441\u0442\u0438. \u0422\u0430\u043a \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u044d\u0442\u0430 \u043f\u0435\u043b\u0435\u043d\u0430 \u0442\u0435\u043a\u0441\u0442\u0430.<\/p>\n<p>  \u0411\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044e \u0437\u0430 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435!       <\/p>\n<div class=\"clear\"><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/271031\/\"> http:\/\/habrahabr.ru\/post\/271031\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>       \u041f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044e \u0432\u0430\u0448\u0435\u043c\u0443 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044e \u043e\u0431\u0437\u043e\u0440 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438, \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u043e\u0439 \u0441 \u043d\u0435\u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u043c \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435\u043c JSONP \u0432 VK Open Api. \u041d\u0430 \u043c\u043e\u0439 \u0432\u0437\u0433\u043b\u044f\u0434, \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u0435\u0440\u044c\u0451\u0437\u043d\u0430\u044f, \u0442.\u043a. \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u043b\u0430 \u0441\u0430\u0439\u0442\u0443 \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430 \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c Access Token \u0434\u0440\u0443\u0433\u043e\u0433\u043e \u0441\u0430\u0439\u0442\u0430, \u0435\u0441\u043b\u0438 \u043d\u0430 \u043d\u0451\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u044f \u0447\u0435\u0440\u0435\u0437 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 VK Open API. \u041d\u0430 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0443\u044f\u0437\u0432\u0438\u043c\u044b\u0439 \u043a\u043e\u0434 \u043f\u043e\u043f\u0440\u0430\u0432\u0438\u043b\u0438, \u0440\u0435\u043f\u043e\u0440\u0442 \u043d\u0430 HackerOne \u0437\u0430\u043a\u0440\u044b\u043b\u0438, \u0432\u043e\u0437\u043d\u0430\u0433\u0440\u0430\u0436\u0434\u0435\u043d\u0438\u0435 \u0432\u044b\u043f\u043b\u0430\u0442\u0438\u043b\u0438 (1,500$).<\/p>\n<h3>\u041a\u0430\u043a \u044d\u0442\u043e \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u043e<\/h3>\n<p>  \u0412 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0435, \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e Access Token&#8217;\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435\u0439 \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u043b \u043f\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 \u0441\u0445\u0435\u043c\u0435 \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0430\u0446\u0438\u0438 CSRF-\u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438:<\/p>\n<ol>\n<li>\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0437\u0430\u0445\u043e\u0434\u0438\u0442 \u043d\u0430 \u0441\u0430\u0439\u0442, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0438\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 VK Open API (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>).<\/li>\n<li>\u0410\u0432\u0442\u043e\u0440\u0438\u0437\u0443\u0435\u0442\u0441\u044f \u0442\u0430\u043c \u0447\u0435\u0440\u0435\u0437 VK.<\/li>\n<li>\u041f\u043e\u0442\u043e\u043c \u0437\u0430\u0445\u043e\u0434\u0438\u0442 \u043d\u0430 \u0441\u0430\u0439\u0442 \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <a href=\"http:\/\/www.vk-test-auth.com\">www.vk-test-auth.com<\/a>), \u043a\u043e\u0442\u043e\u0440\u044b\u0439, \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0438\u0440\u0443\u044f \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c, \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 Access Token, \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0430\u0449\u0438\u0439 \u0441\u0430\u0439\u0442\u0443 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>.<\/li>\n<li>\u041f\u043e\u043b\u0443\u0447\u0438\u0432 Access Token \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a \u043c\u043e\u0436\u0435\u0442 \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c\u0441\u044f \u043a VK API \u0441 \u0442\u0435\u043c\u0438 \u043f\u0440\u0430\u0432\u0430\u043c\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0434\u0430\u043b \u0441\u0430\u0439\u0442\u0443 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a> \u043f\u0440\u0438 \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u0430\u0446\u0438\u0438 \u043d\u0430 \u043d\u0435\u043c \u0447\u0435\u0440\u0435\u0437 VK.<\/li>\n<\/ol>\n<p>  <\/p>\n<h3>\u0414\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u044f<\/h3>\n<p>  \u041d\u0430 \u0432\u0438\u0434\u0435\u043e \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e, \u043a\u0430\u043a \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u00ab\u0437\u043b\u043e\u0443\u043c\u044b\u0448\u043b\u0435\u043d\u043d\u0438\u043a\u0430\u00bb \u043d\u0430 \u0434\u043e\u043c\u0435\u043d\u0435 <a href=\"http:\/\/www.vk-test-auth.com\">www.vk-test-auth.com<\/a> \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 Access Token \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f VK, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0430\u0432\u0442\u043e\u0440\u0438\u0437\u043e\u0432\u0430\u043b\u0441\u044f \u043d\u0430 \u0441\u0430\u0439\u0442\u0435 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>, \u043d\u0435\u0441\u043c\u043e\u0442\u0440\u044f \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f VK, \u0434\u043e\u0441\u0442\u0443\u043f \u0440\u0430\u0437\u0440\u0435\u0448\u0451\u043d \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u0434\u043e\u043c\u0435\u043d\u0430 <a href=\"http:\/\/www.another-test-domain.com\">www.another-test-domain.com<\/a>.<\/p>\n<p>  <iframe loading=\"lazy\" width=\"560\" height=\"315\" src=\"https:\/\/www.youtube.com\/embed\/xtEGpwmE-FE?feature=oembed\" frameborder=\"0\" allowfullscreen><\/iframe>  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-268354","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/268354","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=268354"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/268354\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=268354"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=268354"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=268354"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}