Example of auditing common users in Linux

Source: Internet
Author: User

More highlights availableWww.leonarding.com



We can audit both SYS users, so we usually audit common users, so the auditing of common users is not so strict, its audit records can be stored in the base table sys of the database. in aud $, we can view it at the database level.

Standard audit content

1) Audit Session

2) Audit Object

3) Audit Operations

4) Audit authorization

Lab

SYS @ LEO1> show user

USER is "SYS"

SYS @ LEO1> alter system setaudit_trail = db, extended scope = spfile; Enable audit chase Database Function

System altered.

SYS @ LEO1> startup force; restart the database to make the static parameters take effect.

ORACLE instance started.

Total System Global Area 471830528 bytes

Fixed Size 2214456 bytes

Variable Size 285214152 bytes

Database Buffers 176160768 bytes

Redo Buffers 8241152 bytes

Database mounted.

Database opened.

We plan to audit the car table of leo1 users

SYS @ LEO1> auditselect, insert, update, delete on leo1.car;

Audit succeeded.

Specify the Audit Object and action. Oracle will audit the select, insert, update, and delete operations.

Insert record

LEO1 @ LEO1> insert into leo1.carvalues ('mini, 150,150 );

1 row created.

LEO1 @ LEO1> commit;

Commit complete.

LEO1 @ LEO1> select * from car;

...... Omitted ......

LEO1 @ LEO1> select userid, obj $ name, sqltextfrom sys. aud $;

Userid obj $ NAME SQLTEXT

Slave --------------------------------------------------------------------------------------------------------------------------------

LEO1 CAR select * from car

LEO1 CAR insert into leo1.carvalues ('Min', 150,150)



Vpd ols db vault audit sys user


Leonarding
2013.6.16
Beijing & summer
Sharing Technology ~ Achieving dreams
Blog: www.leonarding.com

 

This article is from the "leonarding Blog" Blog, please be sure to keep this source http://leonarding.blog.51cto.com/6045525/1223421

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.