MRatWork Forum by Mustafa Ramadhan

Sawo Project - Kloxo-MR Discussions => Kloxo-MR Technical Helps => Topic started by: crossing on 2014-01-04, 19:55:14

Title: 'Statistics Page Password' have no effect
Post by: crossing on 2014-01-04, 19:55:14
'Statistics Page Password' set have no effect and everyone can access my stats.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-05, 06:39:51
Did you reset httpd after you changed the password?   I will test as well.
Title: Re: 'Statistics Page Password' have no effect
Post by: crossing on 2014-01-05, 11:41:09
I reboot it the server with no results.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-05, 17:24:05
Mustafa, there is a bug / problem with stats password now.  Servers that had password protection already, it works.  On new installs or new domains the password stays null.  I tried both templates, feather and default (6.5.0f 20140103).  If I try to change an existing password it sets it to null.

So the problem is not with httpd, but with setting the actual passwords in KloxoMR.   Please fix, this is actually a security bug.

Thank you
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-01-06, 02:29:55
Look like something wrong with mechanism to save password and create __stats file.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-06, 03:47:56
I don't know when it stopped working.  Please advise, a fix here is important.
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-01-06, 04:05:27
Still investigate for this issue.
Title: Re: 'Statistics Page Password' have no effect
Post by: crossing on 2014-01-06, 20:21:14
Mustafa did you managed to fix this bug ?
Title: Re: 'Statistics Page Password' have no effect
Post by: crossing on 2014-01-08, 15:07:07
Any chance to fix this problem ? I have one competitor keep accesing stats page.
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-01-08, 15:34:28
Temporary solution:

For apache, copy domains.conf.tpl to custom.conf.tpl and then modified:
Code: [Select]
<?php
            
if ($statsprotect) {
?>


    <Location "/awstats/">
        AuthType Basic
        AuthName "Awstats"
        #AuthUserFile "/home/<?php echo $user?>/__dirprotect/__stats"
        AuthUserFile "/home/httpd/<?php echo $domainname ?>/__dirprotect/__stats"
        require valid-user
    </Location>
<?php
            
}

to:
Code: [Select]
<?php
            
//if ($statsprotect) {
?>


    <Location "/awstats/">
        AuthType Basic
        AuthName "Awstats"
        #AuthUserFile "/home/<?php echo $user?>/__dirprotect/__stats"
        AuthUserFile "/home/httpd/<?php echo $domainname ?>/__dirprotect/__stats"
        require valid-user
    </Location>
<?php
            
//}

the same trick for nginx and lighttpd.

With this trick no one able to access to stats (including you) except knowing username and password.
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-01-08, 15:37:37
Above code for awstats. Find out also for webalizer.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-08, 17:51:33
Mustafa, this is not a good solution.  Clients want to password protect stats.  How do they set password? KloxoMR not allowing setting of password.  This worked in previous versions of KloxoMR, as my older sites have it enabled,

Please fix the panel way, so clients can use.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-10, 17:18:28
Mustafa any progress on fixing this issue?
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-14, 16:40:28
There has been three KloxoMR updates since this issue was discovered.  Mustafa, please fix this.
Title: Re: 'Statistics Page Password' have no effect
Post by: crossing on 2014-01-15, 13:59:24
Any news about this problem ?
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-16, 19:55:19
This issue is not resolved,  it needs fixed.  Thank you
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-01-17, 06:08:02
There are something trouble where add stats password not save in kloxo database. Still investigate.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-19, 21:34:18
Is this issue too complex?
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-01-22, 16:14:13
Any closer to a solution Mustafa?
Title: Re: 'Statistics Page Password' have no effect
Post by: crossing on 2014-02-01, 13:20:06
Any solution for this yet ?
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-02-01, 14:46:59
Did you update to latest version?.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-02-01, 15:45:12
Mustafa, on 6.5.1a the stats password now saves, but when going to the awstats you get this:

Error: Access to statistics is only allowed from an authenticated session to authenticated users.

Setup ('/etc/awstats/awstats.<domain>.conf' file, web server or permissions) may be wrong.
Check config file, permissions and AWStats documentation (in 'docs' directory).

It doesn't ask for authorization.  Please advise.
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-02-01, 15:49:14
Awstats using perl. Perl itself not work on nginx and hiawatha.

Latest version of 6.5.0.f and 6.5.1.a already disable perl functions.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-02-01, 16:03:39
it works fine.  I had to wait for the webserver to restart, or for KloxoMR to finish, it works good. :)

Kloxo-MR 6.5.1.a-2014013101
You disabled cgi-bin for clients, perl still works for Apache.  Awstats works fine.

Also, so those who don't know, username is the domain name. ;)  (not admin or the client name)
Title: Re: 'Statistics Page Password' have no effect
Post by: MRatWork on 2014-02-01, 16:05:29
Only perl in /home/<user>/<domain>/cgi-bin not work. Awstart is in different path and not able touch from user.
Title: Re: 'Statistics Page Password' have no effect
Post by: chrisf on 2014-02-01, 16:10:15
I know Mustafa, was just letting you know it does work. ;)