• Resolved nam1962

    (@nam1962)


    Hi there,
    Folliowing previous questions, my ninjafirewalls seems working, I still have a question : I have a domain on www and other domains in their own folders (www/domain1/ – www/domains2/ – etc)
    Thus, I also have a .htninja on / and another on /www/
    All WP with, as you told me in previous threads, ninjafirewall on each site (that I installed bottom-up).
    When I check my logs, each domain reports correctly, but, the www domain logs events of the other domains.
    Is that logical ?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author nintechnet

    (@nintechnet)

    Hi,

    It shouldn’t.
    Are you using php.ini or .user.ini format?
    If you use the former format, can you try to rename them all to .user.ini and check again if that solved the issue?

    Thread Starter nam1962

    (@nam1962)

    Thank for this answer.
    All my installs where using php.ini (I followed your install instructions for a shared hosting 😛 )
    I amended them all for .user.ini via filezilla.
    I’ll check my logs during a couple of days.
    Best.

    Thread Starter nam1962

    (@nam1962)

    Well…
    I modified all my php.ini as said (by the way I also did it for my non-WP subdomains, is that ok ?)
    But I still see logs of the subdomains on the main one.
    Might this be because of my hosting setup ?

    (PS : I went from F to C or B – depending on domain specific NF setup – on Mozilla Observatory, thanks to ninjafirewall 😉 )

    Plugin Author nintechnet

    (@nintechnet)

    Normally, PHP should not load the INI file from the main domain when you access an add-on domain such as /www/addondomain/.
    Maybe you could exclude all add-on domains with a .htninja script. However, it would need to be located in the folder above the main domain document root, not inside the document root (otherwise, addon domains will use it too because they would look for it in the document root folder or the one above it, which is the main domain document root).
    Example:
    /home/user/www > your main domain
    /home/user/www/addondomain_1
    /home/user/www/addondomain_2

    The .htninja for your main domain would need to be /home/user/.htninja.
    Then you could check the value of $_SERVER[“SERVER_NAME”] and if it does not match the main domain, return the ‘ALLOW’ directive so that it will be ignore by the copy of NinjaFirewall installed on the main domain.

    Thread Starter nam1962

    (@nam1962)

    Well, i don’t know if it really disturbs.
    I wonder if it’s not the sites architecture.
    There is a “main domain” that I created when i started the hosting :
    blabla.com

    Then a few others, that are labelled “companion domains”
    tructruc.fr
    blublu.com
    huphup.be

    But they also exist in cpanel under :
    tructruc.blabla.com
    blublu.blabla.com
    huphup.blabla.com

    In addition, I also have some
    blabla.com/blog
    blog.blublu.com
    huphup.be/blog

    ..as you see, fairly complex.

    What is strange nevertheless is tha blabla.com (the “main” site) logs some stuff relating to the other ones, but not all of it (while each individual other domains logs its problems)

    • This reply was modified 9 years, 4 months ago by nam1962.
    Plugin Author nintechnet

    (@nintechnet)

    As long as you don’t see any issue with the sites and everything is working, I would not worry more than that.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘ninjafirewall redundancy ?’ is closed to new replies.