Developer forum

Forum » CMS - Standard features » Blocking unwanted guests

Blocking unwanted guests

Jonas Krarup Dam
Reply

Is there a way to block either individual ip-addresses or blocks of addresses in Dynamicweb, or does this have to be done in IIS/Firewall?

We have a customer where a limited number of ip-addresses are creating and abandoning about 500.000 carts every month...


Replies

 
Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

You can add the IP and an expiry date to /Files/System/_BannedIps.txt in the format:

 

111.222.111.222;2019-05-06T20:50:32

Hope this helps,

Imar

 

 
Morten Bengtson Dynamicweb Employee
Morten Bengtson
Reply

What Imar said.

Alternatively, if it's a crawler which respects robots.txt then you can add an entry in robots.txt on the website settings. A friendly crawler provides a link to their documentation in the user agent string of the request and the documentation often contains information about what to enter in robots.txt.

Another thing you can try is to change your "add to cart" links into form posts instead. That should also reduce the number of carts created by crawlers.

/Morten

 
Jonas Krarup Dam
Reply

Great input, thank you both :-) 

It looks like google is creating 4-8 empty carts every minute. I probably don't want to block googles IP...

 Any idea how I can find out which request is causing these carts to be created?

I'm leaning towards something like the "add to cart" in links, but all the "add to cart" functionality is for logged in users only, so there must be something hidden somewhere...

/Jonas

 
Jonas Krarup Dam
Reply

In case anyone else has the same challenge:

 

I looked at the logs in C:\inetpub\logs\LogFiles

matched the timestamps with order creation time, and as able to recreate the problem :-)

 

/Jonas

 

You must be logged in to post in the forum