You are not logged in.

#1 2017-06-07 5:16 pm

Bitdesire
Member
Registered: 2017-06-07
Posts: 4

CIDRAM for PHP5.4.45

Hello, I'm looking for the light version of CIDRAM (CIDRAM-L) which should be compatible with a linux server running php 5.4.45
I tried installing the regular version but it just won't work and the GitHub repository of CIDRAM-L appears to be deleted.

Anyone can help or give me a valid alternative script to block bad datacenters/bots from my website?

Thanks

Offline

#2 2017-06-07 6:59 pm

Maikuolan
Member
From: Perth, Western Australia
Registered: 2011-08-09
Posts: 799
Website

Re: CIDRAM for PHP5.4.45

Hi Bitdesire,

Not quite the right location to ask for help about this particular issue, but I'll try to answer anyhow, and hopefully pedigree and the SFS team won't mind too much. ;-)

Both the normal version of CIDRAM and its light version counterpart (CIDRAM-L) should be compatible with PHP versions => 5.4.0, and both should be compatible with linux webservers (as long as PHP is installed and functioning correctly, the two packages should work, irrespective of operating system).

A link to the normal version can be found in my signature here. As you've noticed, the repository for the light version was deleted. TBH, there were two core reasons for this: Maintainability, and what I believed to be a very small potential userbase for it. In short, to my knowledge, it (the light version) only ever had two people actually install it and use it (until now), and in consideration of that I was regularly updating the normal version and releasing new versions on a cycle between one and two months, I anticipated possible future maintainability issues, and that maintaining two different versions would likely cause delays in support and signature updates for either version, and so, I felt it made sense to delete it at the time and to just provide support privately for the few people that actually wanted the light version to help them maintain their copies without necessarily needing to worry about the maintenance burden of maintaining two separate official versions of what was essentially the same thing, minus a few features in the light version (hence the calling it a "light" version).

If your only concern about the normal version of CIDRAM is the version of PHP required, I wouldn't worry about that too much, seeing as currently, both versions of it have the same PHP version requirements. The main reason for the existence of the light version was that some users didn't want the extra features provided by the normal version, so the light version is basically a hacked down, stripped out, minified version of the package.

Otherwise, if you're still keen on the light version, let me know, and I'll see whether I can recreate the repository and prepare a new release for it.

Also, when you mention that it "just won't work": Are you seeing any error messages or experiencing abnormal website behaviour? Is it not blocking anything? Or something else?

Last edited by Maikuolan (2017-06-07 7:02 pm)

Offline

#3 2017-06-07 7:09 pm

Maikuolan
Member
From: Perth, Western Australia
Registered: 2011-08-09
Posts: 799
Website

Re: CIDRAM for PHP5.4.45

Bitdesire wrote:

Anyone can help or give me a valid alternative script to block bad datacenters/bots from my website?

If CIDRAM doesn't work for you, ZB Block and NinjaFirewall are both possible alternatives that might work for you. ZB Block is compatible with PHP => 5.0.0, and I'm not sure about NinjaFirewall offhandedly (I'd need to double-check the docs), but I'm reasonably confident it should be compatible with your PHP version, too.

Those two are good general alternatives that should work with most sites. Depending on what CMS/frameworks/etc you're using, there possibly may be other, more specialised solutions available out there, too.

Offline

#4 2017-06-07 7:33 pm

Bitdesire
Member
Registered: 2017-06-07
Posts: 4

Re: CIDRAM for PHP5.4.45

Maikuolan wrote:

when you mention that it "just won't work": Are you seeing any error messages or experiencing abnormal website behaviour? Is it not blocking anything? Or something else?

(quote edited by Mod to remove excess - please do not repeat full-post quotes)

Hello, thanks for your quick answer.
I placed all the files in a folder on my website, enabled the frontend in the config file and checked the folders permissions. Followed the documentation step by step but when trying to open the loader.php I will just get a blank page; no idea why.

The first thing I thought about was compatibility issues with my php version, but from what you just said it doesn't look to be the case.

I'm working on a slim-php framework, maybe the .htaccess rules might be a problem?

RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [QSA,L]

<Files 403.shtml>
order allow,deny
allow from all
</Files>

Last edited by Bitdesire (2017-06-07 7:36 pm)

Offline

#5 2017-06-08 5:33 am

Maikuolan
Member
From: Perth, Western Australia
Registered: 2011-08-09
Posts: 799
Website

Re: CIDRAM for PHP5.4.45

Looking at your .htaccess, I suspect that this:

RewriteRule ^ index.php [QSA,L]

..may be the cause of the problem, in this case.

I'm guessing that your website normally routes all traffic through your index.php file. Nothing wrong with that, and I've encountered this particular issue before with some other websites (problems accessing the CIDRAM front-end due to traffic being routed through a different file).

Try adding this:

RewriteRule ^path/to/cidram/loader.php(.*)$ path/to/cidram/loader.php$1 [B,L,QSA]

..on its own new line, immediately before this line:

RewriteCond %{REQUEST_FILENAME} !-f

..but not earlier or later in the file, and change "path/to/cidram" as per appropriate (to the complete path of your installation).

When done, try accessing the front-end again and let me know whether that solves the problem. :-)

Last edited by Maikuolan (2017-06-08 5:36 am)

Offline

#6 2017-06-08 8:05 am

Bitdesire
Member
Registered: 2017-06-07
Posts: 4

Re: CIDRAM for PHP5.4.45

Hello and thanks for the assistance, but it looks like that didn't solve the issue.
I added that line to my .htaccess and changed the path to the loader.php position but no luck in getting it to work.

I thought it could be a problem with the path, so I tried all different relative/absolute paths but I'm still getting a blank page. ("/home/mhd/www.*******.**/htdocs/cidram/loader.php", "/cidram/loader.php", "cidram/loader.php"; neither managed to solve it)
I tried temporarily removing that .htaccess rule routing all traffic through index.php aswell, but it didn't work either.. I guess I will just take a look at the alternatives.

Thanks for your time.

Offline

#7 2017-06-08 10:15 am

Bitdesire
Member
Registered: 2017-06-07
Posts: 4

Re: CIDRAM for PHP5.4.45

Alright, I set up ZB Block and it's working good. I edited the .ini to make it a bit less strict and removed some blocks from the signatures (like yandex ban and some others)

I have around 50% traffic from russia and ukraina on my website, is there anything else I could do to make it less strict against them?

Thanks

Offline

Board footer

Powered by FluxBB

Close
Close