Anyone know how to modify zoneminder such that the the making of the event folder is marked as umask 002.
In other words inherit the group permissions of the parent folder when making the directory.
In other words mkdir -m g=rw [next event number]
umask 002
The creating of the directory is done in event.cpp. It looks like this:
This part of the code starts at line# 135 in the latest version on the SVN.
To change the group permissions to rw, you'd want to change the 0755 in the 'mkdir' function call to 0765.
Code: Select all
if ( mkdir( path, 0755 ) )
{
Error( "Can't mkdir %s: %s", path, strerror(errno));
}
To change the group permissions to rw, you'd want to change the 0755 in the 'mkdir' function call to 0765.
-
- Posts: 17
- Joined: Tue Sep 29, 2009 11:19 pm
Worked
That didn't work, I found a few more places in zm_monitor.cpp and zm_events.cpp and I changed those too. I'm running 24.2 version of zoneminder with FreeBSD 7.2
So I did sudo -u www umask and it said 0022
So I tried changing the umask inside of /etc/login.conf (I only had one uncommented umask, the rest were commented out) to 0 and running cap_mkdb /etc/login.conf and the problem still persisted.
Any chance you could point me in the right direction?
So I did sudo -u www umask and it said 0022
So I tried changing the umask inside of /etc/login.conf (I only had one uncommented umask, the rest were commented out) to 0 and running cap_mkdb /etc/login.conf and the problem still persisted.
Any chance you could point me in the right direction?
-
- Posts: 17
- Joined: Tue Sep 29, 2009 11:19 pm
Nevermind
Nevermind, I found it.
I modified umask to 2 in /root/.cshrc
and
added Defaults !umask in /usr/local/etc/sudoers
Thanks again.
Greg
I modified umask to 2 in /root/.cshrc
and
added Defaults !umask in /usr/local/etc/sudoers
Thanks again.
Greg