0

using rules in .htaccess I am attempting to block access to sites hosted on my server from traffic using a specific browser version (firefox 27.0).

Is there any way to test if I have .htaccess setup correctly to block visitors using this browser other than perhaps trying to locate and install this version of Firefox?

Can it be done through a php program? through Linux command line?

3
  • Each of the major browsers allow you to customize the User-Agent string: howtogeek.com/113439/…
    – heavyd
    Apr 21, 2015 at 20:34
  • 1
    Why would you want to do that? Note it's easy to get around such blocks by changing the User-Agent string as per @heavyd's comment.
    – DavidPostill
    Apr 21, 2015 at 20:57
  • thanks, i am aware that is is easy to get around, but there is a bot clicking on my adsense ads which only uses that specific version of firefox, for whatever reason.
    – psvj
    Apr 21, 2015 at 23:05

1 Answer 1

1

There is a Chrome extension that will allow you to imitate different user agents (including Firefox 27).

https://chrome.google.com/webstore/detail/user-agent-switcher/lkmofgnohbedopheiphabfhfjgkhfcgf?hl=en-US

Follow these steps:

enter image description here

enter image description here

enter image description here

Copy the user-agent string in this textbox... enter image description here

...reopen the extension and paste that user-agent string into this textbox; then click change. enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .