auditors can view audit records

This commit is contained in:
SJ
2013-07-12 15:02:50 +02:00
parent c44820f0df
commit e7c26dbcc7
11 changed files with 79 additions and 5 deletions

View File

@ -297,6 +297,7 @@ create table if not exists `audit` (
`id` bigint unsigned not null auto_increment,
`ts` int not null,
`email` varchar(128) not null,
`domain` varchar(128) not null,
`action` int not null,
`ipaddr` char(15) not null,
`meta_id` bigint unsigned not null,
@ -309,6 +310,7 @@ create index `audit_idx` on `audit`(`email`);
create index `audit_idx2` on `audit`(`action`);
create index `audit_idx3` on `audit`(`ipaddr`);
create index `audit_idx4` on `audit`(`ts`);
create index `audit_idx5` on `audit`(`domain`);
@ -345,3 +347,14 @@ CREATE TABLE IF NOT EXISTS `counter_stats` (
) ENGINE=InnoDB;
create table if not exists `ldap` (
`id` int not null auto_increment primary key,
`description` varchar(255) not null,
`ldap_type` varchar(255) not null,
`ldap_host` varchar(255) not null,
`ldap_base_dn` varchar(255) not null,
`ldap_bind_dn` varchar(255) not null,
`ldap_bind_pw` varchar(255) not null
) Engine=InnoDB;

View File

@ -0,0 +1,18 @@
alter table `domain` add column `ldap_id` int default 0;
alter table `audit` add column `domain` varchar(128) not null,
create index `audit_idx5` on `audit`(`domain`);
create table if not exists `ldap` (
`id` int not null auto_increment primary key,
`description` varchar(255) not null,
`ldap_type` varchar(255) not null,
`ldap_host` varchar(255) not null,
`ldap_base_dn` varchar(255) not null,
`ldap_bind_dn` varchar(255) not null,
`ldap_bind_pw` varchar(255) not null
) Engine=InnoDB;