サーバー監査の仕様の作成
サーバー監査の仕様の作成を行うクエリ
code:sql
-- サーバ監査の仕様作成
USE master
CREATE SERVER AUDIT SPECIFICATION サーバー監査仕様 go
-- 監査アクションの追加
ALTER SERVER AUDIT SPECIFICATION サーバー監査仕様 ADD (SERVER_PRINCIPAL_CHANGE_GROUP)
, ADD (LOGIN_CHANGE_PASSWORD_GROUP)
, ADD (SERVER_ROLE_MEMBER_CHANGE_GROUP)
, ADD (SERVER_PERMISSION_CHANGE_GROUP)
, ADD (SERVER_OBJECT_PERMISSION_CHANGE_GROUP)
, ADD (DATABASE_PRINCIPAL_CHANGE_GROUP)
, ADD (DATABASE_ROLE_MEMBER_CHANGE_GROUP)
, ADD (APPLICATION_ROLE_CHANGE_PASSWORD_GROUP)
, ADD (DATABASE_PERMISSION_CHANGE_GROUP)
, ADD (DATABASE_OBJECT_PERMISSION_CHANGE_GROUP)
, ADD (SCHEMA_OBJECT_PERMISSION_CHANGE_GROUP)
, ADD (DATABASE_OWNERSHIP_CHANGE_GROUP)
, ADD (DATABASE_OBJECT_OWNERSHIP_CHANGE_GROUP)
, ADD (SCHEMA_OBJECT_OWNERSHIP_CHANGE_GROUP)
, ADD (DATABASE_OBJECT_CHANGE_GROUP)
, ADD (SCHEMA_OBJECT_CHANGE_GROUP)
, ADD (SERVER_OBJECT_CHANGE_GROUP)
, ADD (BACKUP_RESTORE_GROUP)
, ADD (SERVER_STATE_CHANGE_GROUP)
, ADD (DBCC_GROUP)
, ADD (FAILED_LOGIN_GROUP)
, ADD (SERVER_PRINCIPAL_IMPERSONATION_GROUP)
, ADD (DATABASE_PRINCIPAL_IMPERSONATION_GROUP)
, ADD (AUDIT_CHANGE_GROUP)
, ADD (SERVER_OPERATION_GROUP)
, ADD (SERVER_OBJECT_CHANGE_GROUP)
, ADD (DATABASE_CHANGE_GROUP)
, ADD (DATABASE_OPERATION_GROUP)
go
関連