audit useradd, userdel on solaris 10


 
Thread Tools Search this Thread
Operating Systems Solaris audit useradd, userdel on solaris 10
# 1  
Old 02-19-2009
audit useradd, userdel on solaris 10

I just want to audit and log to syslog when a user is added, removed or modified from the system.

According to the docs I have:

#/etc/security/audit_control
dir:/var/audit
flags:ua
minfree:20
naflags:ua
plugin:name=audit_syslog.so.1; p_flags=ua

But neither syslog nor auditreduce -c ua | praudit gives me any log. (after restart or audit -s)

Does anyone have an idea if this is the way to achive what I want and I'm doing something wrong or there is another way to audit adding, removing users to syslog on solaris 10?

Thanks.
# 2  
Old 02-19-2009
Everything looks OK in your audit_control file, do you have something like the following in your syslog.conf file?
audit.debug /var/adm/message

Also, is auditd enabled?
svcadm enable svc:/system/auditd:default

Also you need to enable BSM by running /etc/security/bsmconv then rebooting. You probably already did that, but just checking.

Last edited by seg; 02-19-2009 at 07:45 PM..
# 3  
Old 02-19-2009
Yep, I have
audit.notice /var/adm/messages

It catches the audit when I edit crontab:
Feb 20 00:10:15 server audit: [ID 702911 audit.notice] crontab-modify ok session 2921655314 by root as root:root from 1.104.168.192 obj /var/spool/cron/crontabs/root

But it doesn't catch when I add, delete or change the pass on a user:
# useradd mynewuser

I've found
General Solaris 10 Discussion - user administration auditing
Kernel - bsm audit user administration

But, neither offer a solution from 2006. I'm using Solaris 10 10/08. Smilie
# 4  
Old 02-19-2009
Ah, good to see it's functioning on some level. Very odd that it doesn't log useradd/del- one would think they fit in the ua 'user administration' category. You might try some different flags like 'am' or 'as'. audit_class has the list of flags.

I'm sticking with this issue as long as I can because I'm very interested to find out how to make this work.
# 5  
Old 02-19-2009
I was wrong, passwd got logged with only ua.
Feb 20 00:40:07 server1 audit: [ID 702911 audit.notice] passwd ok session 165926946 by root as root:sys from 1.104.168.192 text stanko2

There is no audit of useradd, userdel.

I've now also added "ad" and "as":
flags:lo,ua,ad,as
naflags:lo,ua,ad,as
plugin:name=audit_syslog.so.1; p_flags=lo,ua,ad,as

But still nothing about useradd, userdel.

Just to note that if I add "ex" useradd, userdell get loged as commands but thats not what I want, as I it logs every command I run and I just want operations on users to get logged.
# 6  
Old 02-24-2009
I have not had a chance to work on this in the past few days. During my last session I got no farther than you in making this work. From everything I've read simply using ua should include useradd/del commands. Either it's a bug or we don't understand it correctly and neither does anyone else on the Internet reachable by Google. I'll continue my work when I can and hope for the best.
# 7  
Old 03-26-2009
I have this issue as well. It's a bug. You can see it on opensolaris.org.

Bug ID: 6178396 useradd(1M), usermod(1M), userdel(1M), groupadd(1M), groupmod(1M), groupdel(1M) do not audit actions

It says they are not really looking at a fix for this and the workaround is to use pfexec. I don't really like the workaround. I really wish they would fix this.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

Audit not working on Solaris 10

hi, I enabled bsm modules (/etc/security/bsmconv) and rebooted Solaris 10. But service is going into maintenance state. I rebooted server and I see one error saying "sys/c2audit:audit_kssl() not defined properly". I am not sure, what it is indicating and how it should be fixed. Please suggest, how... (5 Replies)
Discussion started by: solaris_1977
5 Replies

2. Solaris

Audit useradd/userdel - Solaris 11

Linux audits in syslog, any time a user is deleted or added. However, I'm running a Solaris11 VM, and find no such entries. How can I enable auditing for useradd and userdel? Oracle's documentation on managing the auditing service, has been of no assistance. Thanks. Customizing What Is... (7 Replies)
Discussion started by: Nvizn
7 Replies

3. Solaris

Enabling Solaris Audit log: Solaris 9

Dear All, I have one of my Servers, running Solaris 9. I wanna enable the Audit log enabling, the way I did in Solaris 10 Servers. After running, the bsmconv script, giving the reboots, modifying all the audit files in /etc/security, the audit is enabled, but the audit file which shall be... (3 Replies)
Discussion started by: sumeet1806
3 Replies

4. UNIX for Advanced & Expert Users

Solaris 10 useradd confusion[solved]

I installed Solaris 10 (8/11) and added an account for myself. It lives in /export/home/{name} but /etc/passwd shows it is /home/{name} where it seems to be mounted like a filesystem. I tried to create another account from the command line but it doesn't work the same way. I can't find... (7 Replies)
Discussion started by: dokhebi
7 Replies

5. Solaris

audit useradd userdel usermod in solaris 10

the previous thread on this problem was closed with no resolution/workaround that i could see...have there been any breakthroughs? :wall: (0 Replies)
Discussion started by: lisah66
0 Replies

6. UNIX for Advanced & Expert Users

Problem with useradd, -p option in Solaris 10

Good day all. I'm trying to add a user with useradd and the -p option to assign a project name, but the result is that the user is created with an error message: "UX: useradd: user.root name should be all lower case or numeric." The command: useradd -d /export/home/tester -g rtpgrp -G... (2 Replies)
Discussion started by: BRH
2 Replies

7. Solaris

useradd giving error in solaris 10

Hi, I have installed Solaris 10 in my PC and now installing Oracle10, but while adding a user i am getting following error: useradd -g oinstall -G dba -d /export/home/oracle oracle UX: useradd: ERROR: Inconsistent password files. See pwconv(1M). I have tried pwconv command,... (4 Replies)
Discussion started by: amitanshu.verma
4 Replies

8. Solaris

Audit in Solaris Servers.

Hi Friends I am a Solaries newbie and I am looking out for a software or command or config that can capture all commands run by all users on a server on a daily basis. I believe that this Audit is being done in almost all enterprises and would like to know how the same is done there. Any... (3 Replies)
Discussion started by: Hari_Ganesh
3 Replies

9. Solaris

audit in solaris 10

can you please share what you use to audit what files are deleted, when files are deleted and who deleted them? thx (1 Reply)
Discussion started by: melanie_pfefer
1 Replies

10. Solaris

audit in solaris

How do I know that audit is enabled in soalris. in AIX 'audit query' command gives me the info whether auditing is on or not. Raghav (1 Reply)
Discussion started by: raghavender_sri
1 Replies
Login or Register to Ask a Question