D
D
Dmitry Gusev2015-09-16 11:07:34
PHP
Dmitry Gusev, 2015-09-16 11:07:34

How to protect yourself from DDoS from YandexBot/3.0?

Hello!
From time to time I observe bursts of traffic from YandexBot/3.0 on my various sites.
Here is the request header


/?gclid=CLP4ovuGrcYCFejJtAodauILSQ///////////////////////
ru,uk,be,en,*
{"connection":"upgrade","host" :"whitehouse-koblevo.com","x-real-ip":"5.255.253.151","x-forwarded-for":"5.255.253.151","user-agent":"Mozilla/5.0 (compatible; YandexBot/3.0; + yandex.com/bots) ","from":"[email protected]","accept-encoding":"gzip,deflate","accept-language":"ru, uk; q=0.8, be;q=0.8, en;q=0.7, *;q=0.01","accept":"*/*"}

I observe influxes several times a day, for 30-40 minutes.
The volume of traffic is critical (4-6 requests per second), but this situation is very annoying.
Tell me how to solve the problem, is the Yandex bot furious or is someone disguised as it?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
A
Alexander Pushkarev, 2019-04-19
@AXP-dev

<?php

$content='"{\"orderId\":\"ORDER-294\",\"paymentState\":\"CANCELED\",\"signature\":\"naK+I79FduGkXFHpVT\/aJT31EfQ=\",\"message\":\"\u041a\u043b\u0438\u0435\u043d\u0442 \u043d\u0435 \u0437\u0430\u0432\u0435\u0440\u0448\u0438\u043b \u043e\u043f\u043b\u0430\u0442\u0443\",\"storeId\":\"158CC6EE85DA472AB3FB\"}"';
$res=json_decode(json_decode($content), true);

print_r($res);

/*Array
(
    [orderId] => ORDER-294
    [paymentState] => CANCELED
    [signature] => naK+I79FduGkXFHpVT/aJT31EfQ=
    [message] => Клиент не завершил оплату
    [storeId] => 158CC6EE85DA472AB3FB
)
*/

R
Rodion Gashé, 2019-04-19
@zorba_buddha

strip first and last character, apply stripslashes, then json_decode

P
Puma Thailand, 2015-09-16
@illi

it’s just a Yandex spider,
set it up in a robot so that it only comes to you at night, for example, or optimize the site so that it doesn’t notice it, since 4-5 requests per second are not many, for many pages there are 60 requests per second sent by a spider and then already harder to live.

D
Dmitry Gusev, 2015-11-06
@illi

Yandex technical support replied:

Yes, this robot belongs to us. If you want to reduce the load on your server, I recommend that you place the Crawl-delay directive with the appropriate value in the robots.txt file: yandex.ru/support/webmaster/controlling-robot/robots-txt.xml#crawl-delay.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question