X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?a=blobdiff_plain;f=debian%2Fpostinst;h=7afafdf0286889a8c9f014f53fbd453eed1a942f;hb=0105f1709981e786d9e6e111548defaf944e8ef9;hp=b481091f36c679ff6a3d3bb15d92baf2a1a65b7f;hpb=1f05bc53303e823057455f8a6a408f2eee96576b;p=ossec-hids.git diff --git a/debian/postinst b/debian/postinst index b481091..7afafdf 100755 --- a/debian/postinst +++ b/debian/postinst @@ -49,7 +49,7 @@ if ! getent group $OSSEC_GROUP >/dev/null; then addgroup --system $OSSEC_GROUP fi -# fix the permissions +# fix ownership chown -R root:$OSSEC_GROUP $DIRECTORY chown -R $OSSEC_USER:$OSSEC_GROUP $DIRECTORY/queue/alerts chown -R $OSSEC_USER:$OSSEC_GROUP $DIRECTORY/queue/ossec @@ -69,6 +69,25 @@ chown root:$OSSEC_GROUP $DIRECTORY/etc/internal_options.conf chown root:$OSSEC_GROUP $DIRECTORY/etc/shared/* chown root:$OSSEC_GROUP $DIRECTORY/etc/ossec.conf +# fix perms +chmod -R 550 $DIRECTORY +chmod -R 770 $DIRECTORY/queue/alerts +chmod -R 770 $DIRECTORY/queue/ossec +chmod -R 750 $DIRECTORY/queue/fts +chmod -R 750 $DIRECTORY/queue/syscheck +chmod -R 750 $DIRECTORY/queue/rootcheck +chmod -R 750 $DIRECTORY/queue/diff +chmod -R 755 $DIRECTORY/queue/agent-info +chmod -R 755 $DIRECTORY/queue/rids +chmod -R 755 $DIRECTORY/queue/agentless +chmod -R 750 $DIRECTORY/stats +chmod -R 750 $DIRECTORY/logs +chmod -R 550 $DIRECTORY/rules +chmod 770 $DIRECTORY/var/run +chmod 550 $DIRECTORY/etc +chmod 770 $DIRECTORY/etc/shared +chmod 700 $DIRECTORY/.ssh + # copy timezone and localtime if [ -e /etc/timezone ]; then cmp -s /etc/timezone $DIRECTORY/etc/timezone || \ @@ -89,4 +108,9 @@ else /etc/init.d/ossec-hids restart fi +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + exit 0