I think you need to change the ownership of the ossec-wui files/directories
to the user that the webserver runs as.

For example, my web server runs as "www-data", and my osui (ossec-wui) dir
permissions/ownerships are as follows:
[EMAIL PROTECTED]:/var/www/osui$ ls -al
total 108
drwxr-xr-x 8 www-data www-data  4096 2008-10-28 11:09 .
drwxr-xr-x 4 www-data root      4096 2008-10-28 11:08 ..
-rwxr-xr-x 1 www-data www-data   278 2008-02-27 17:38 CONTRIB
drwxr-xr-x 3 www-data www-data  4096 2008-03-04 11:24 css
-rw-r--r-- 1 www-data www-data   256 2008-10-28 11:09 .htaccess
-rw-r--r-- 1 www-data www-data   218 2008-02-29 12:21 htaccess_def.txt
-rw-r--r-- 1 www-data www-data    22 2008-10-28 11:09 .htpasswd
drwxr-xr-x 2 www-data www-data  4096 2008-03-04 11:24 img
-rwxr-xr-x 1 www-data www-data  5225 2008-02-27 17:38 index.php
drwxr-xr-x 2 www-data www-data  4096 2008-03-04 11:24 js
drwxr-xr-x 3 www-data www-data  4096 2008-10-28 11:09 lib
-rw-r--r-- 1 www-data www-data 35745 2008-03-03 07:27 LICENSE
-rw-r--r-- 1 www-data www-data   462 2007-03-19 20:36 ossec_conf.php
-rw-r--r-- 1 www-data www-data  1157 2008-02-27 17:38 README
-rw-r--r-- 1 www-data www-data   923 2008-02-27 17:38 README.search
-rwxr-xr-x 1 www-data www-data  1824 2008-02-29 12:21 setup.sh
drwxr-xr-x 2 www-data www-data  4096 2008-10-28 11:09 site
drwxrwxrwx 2 www-data www-data  4096 2008-10-28 11:09 tmp


-Chuck (MdMonk)

On Tue, Oct 28, 2008 at 8:53 AM, Mario Zerbe <[EMAIL PROTECTED]> wrote:

> Hello,
>
> after installing ossec-wui on a CentOS 4.3 Asterisk Box, there is no access
> to http://server-ip/ossec-wui possible.
>
> The well known message:
>
> Warning: opendir(/var/ossec): failed to open dir: Permission denied in
> /var/www/html/ossec-wui/lib/os_lib_handle.php on line 94
> Unable to access ossec directory.
>
> appears.
>
> tmp was set to 770 and belongs to the webserver  (even 777 does not help)
>
> [EMAIL PROTECTED] ossec-wui]# ls -al
> total 112
> drwxr-xr-x   8     1000     1000  4096 Oct 22 20:17 .
> drwxr-xr-x  14 asterisk asterisk  4096 Oct 22 20:16 ..
> -rwxr-xr-x   1     1000     1000   278 Feb 28  2008 CONTRIB
> drwxr-xr-x   3     1000     1000  4096 Mar  5  2008 css
> -rw-r--r--   1 root     root       266 Oct 22 20:16 .htaccess
> -rw-r--r--   1     1000     1000   218 Mar  1  2008 htaccess_def.txt
> -rw-r--r--   1 root     root        26 Oct 22 20:18 .htpasswd
> drwxr-xr-x   2     1000     1000  4096 Mar  5  2008 img
> -rwxr-xr-x   1     1000     1000  5225 Feb 28  2008 index.php
> drwxr-xr-x   2     1000     1000  4096 Mar  5  2008 js
> drwxr-xr-x   3     1000     1000  4096 Oct 22 20:16 lib
> -rw-r--r--   1     1000     1000 35745 Mar  3  2008 LICENSE
> -rw-r--r--   1     1000     1000   462 Mar 20  2007 ossec_conf.php
> -rw-r--r--   1     1000     1000  1157 Feb 28  2008 README
> -rw-r--r--   1     1000     1000   923 Feb 28  2008 README.search
> -rwxr-xr-x   1     1000     1000  1824 Mar  1  2008 setup.sh
> drwxr-xr-x   2     1000     1000  4096 Oct 22 20:16 site
> drwxrwx---   2 root     apache    4096 Oct 22 20:16 tmp
>
>
> /etc/group was changed:
>
> from
> ossec:x:503:
> to
> ossec:x:503:apache:
>
> apache was restarted.
>
> ossec_conf.php is pointing to the correct ossec directory
>
> But I get no access via the webgui. :-(
>
> Any recommendations?
>
> N.B. .htaccess and .htpasswd looking OK, but I am not prompted for a
> passphrase... strange...
>
>
> ____________________________________________________________________
> Psssst! Schon vom neuen WEB.DE MultiMessenger gehört?
> Der kann`s mit allen: http://www.produkte.web.de/messenger/?did=3123
>
>

Reply via email to