mirror of
https://git.wownero.com/wownero/onion-wownero-blockchain-explorer.git
synced 2024-08-15 00:33:12 +00:00
does_header_has added to block tor scanner
This commit is contained in:
parent
4a856bc6f2
commit
fc167d86b0
1 changed files with 4 additions and 1 deletions
5
main.cpp
5
main.cpp
|
@ -121,6 +121,7 @@ int main(int ac, const char* av[]) {
|
|||
// on the explorer. I block it with this
|
||||
if (!xmreg::does_header_has(req, "Accept", "q=.2, */*; q=.2").empty())
|
||||
{
|
||||
cout << "Scanner with q=.2, */*; q=.2 blocked!" << endl;
|
||||
return crow::response(400);
|
||||
}
|
||||
|
||||
|
@ -134,7 +135,8 @@ int main(int ac, const char* av[]) {
|
|||
// on the explorer. I block it with this
|
||||
if (!xmreg::does_header_has(req, "Accept", "q=.2, */*; q=.2").empty())
|
||||
{
|
||||
return crow::response(400);;
|
||||
cout << "Scanner with q=.2, */*; q=.2 blocked!" << endl;
|
||||
return crow::response(400);
|
||||
}
|
||||
|
||||
return crow::response(xmrblocks.show_block(block_hash));
|
||||
|
@ -147,6 +149,7 @@ int main(int ac, const char* av[]) {
|
|||
// on the explorer. I block it with this
|
||||
if (!xmreg::does_header_has(req, "Accept", "q=.2, */*; q=.2").empty())
|
||||
{
|
||||
cout << "Scanner with q=.2, */*; q=.2 blocked!" << endl;
|
||||
return crow::response(400);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue