Unix file, folder permissions, security auditing tools.


 
Thread Tools Search this Thread
Operating Systems Solaris Unix file, folder permissions, security auditing tools.
# 8  
Old 03-04-2011
I dont know if this is what you are looking for but something like this will email it too you daily.

Code:
#!/bin/ksh
echo "Permissions to Shadow File" > /home/perm.txt
ls -asl /etc/shadow | awk '{print $2}' >> /home/perm.txt
echo "Permissions to Passwd File" >> /home/perm.txt
ls -asl /etc/passwd | awk '{print $2}' >> /home/perm.txt
cat /home/perm.txt | mailx -s "File Permissions" user@mail.com
rm perm.txt

Dont know if this is on the right track, but it is just a simple script that you can put in cron that will check files and email too you. For any other files you want just put them in there as a new line.
Login or Register to Ask a Question

Previous Thread | Next Thread

7 More Discussions You Might Find Interesting

1. Ubuntu

Folder permissions

Hi Team, I want to set permissions to one folder in such a way that the user can write files or create folder inside that but should not able to delete it. Basically reason behind this is i am using Pidgin Messenger. There is a directory of logs in which, when user chat its store his logs.... (2 Replies)
Discussion started by: paragnehete
2 Replies

2. Tips and Tutorials

Unix File Permissions

Introduction I have seen some misinformation regarding Unix file permissions. I will try to set the record straight. Take a look at this example of some output from ls: $ ls -ld /usr/bin /usr/bin/cat drwxrwxr-x 3 root bin 8704 Sep 23 2004 /usr/bin -r-xr-xr-x 1 bin bin ... (6 Replies)
Discussion started by: Perderabo
6 Replies

3. Shell Programming and Scripting

Unix File Permissions

I want to change one of my Dir permissions to drwx--S--- Can you tell me which number i have to use. Thanks in Advance (4 Replies)
Discussion started by: veeru
4 Replies

4. Cybersecurity

Directory of Security Links (Software Tools)

Hello, If you are interested in security, check out this new directory of unix and linux related software tools. Security - Links If you have any of your favorite tools, feel free to add them to the directory. (0 Replies)
Discussion started by: Neo
0 Replies

5. Windows & DOS: Issues & Discussions

folder permissions

I work for a big company and all the people within my unit share a common drive to save documents to. I am listed in the group(AMS group) that has access rights to folders within this drive. but i'm trying to restrict access to a confidential folder so that only I can access it. when I set the... (0 Replies)
Discussion started by: shed
0 Replies

6. UNIX for Advanced & Expert Users

UNIX File Permissions

Hello, What does the following mean in terms of file permissions. -rw-rwSrw- 1 owner group 999 May 25 2004 file_name What does the "S" stand for. Thanks in advance for your input. :) (3 Replies)
Discussion started by: jerardfjay
3 Replies

7. Cybersecurity

Unix Security and auditing

I am starting an audit of unix security within our company and am looking for any information that may assist me with this. I am looking for any tips or pointers that I should be aware of when looking at unix. I am very new to unix so any help will do. Maybe there is someone out the that has had... (3 Replies)
Discussion started by: GW01
3 Replies
Login or Register to Ask a Question
auditmask(8)						      System Manager's Manual						      auditmask(8)

Name
       auditmask - get or set auditmasks

Syntax
       auditmask [ option ...  ] [ event[:succeed:fail]

Description
       The  command  with  no  arguments displays the system-calls and trusted-events currently being audited for the system, and displays whether
       they are being audited under successful or failed occurrences or both.  The format used for the display is acceptable as input to the  com-
       mand.

       The command with event arguments sets the system-call and trusted-event audit masks for the system.  This is cumulative operation, so it is
       possible to turn on or off audit for one set of events, then turn on or off audit for a second set of events without changing the first set
       of  events (except for intersection between the two sets).  Command line arguments to can include one or more events, each with an optional
       field :succeed:fail, where succeed is either 0 to specify no auditing of successful occurrences of event, or 1 (or any non-zero	character)
       to specify auditing of successful occurrences of event; and fail is either 0 to specify no auditing of failed occurrences of event or 1 (or
       any non-zero character) to specify auditing of failed occurrences of event.  The event name is the system-call name  or	the  trusted-event
       name (see audit.h ).

       The command will also accept redirected input, which can be the output of a previously issued command.  This is a file which contains lines
       of the format event [succeed][fail].  If the keyword succeed is present, successful occurrences of that event will be audited; if the  key-
       word  fail  is  present,  failed  occurrences of that event will be audited; if both are present, successful and failed occurrences will be
       audited; if neither keyword is present, that event will not be audited.

       The auditmask command can also be used to set the audit style characteristics of the audit subsystem.  These  characteristics  control  how
       much information is recorded on exec operations.

       The  command  is  used in to initialize the auditmask at boot time according to the file This makes use of privileged operations within the
       system call.

Options
       -f	   Turns on full auditing for the system.  This list may include events which have no symbolic name and are represented only by  a
		   number (reserved for future use); these events will not be audited, despite their presence in the auditmask.

       -n	   Turns off all auditing for the system.

       -s aud_style
		   An  aud_style  of  "exec_argp" enables the auditing of the argument list to an or syscall.  An aud_style of "exec_envp" enables
		   the auditing of the environment strings to an or syscall.

See Also
       audcntl(2)

																      auditmask(8)