]> WPIA git - gigi.git/blobdiff - doc/tableStructure.sql
ADD: User groups table
[gigi.git] / doc / tableStructure.sql
index 6b2806da4cf1f46159ccf67a0cb6bcb2dfca9e16..b2e3b068e079409efdba8888ada5244e0b58559c 100644 (file)
@@ -13,6 +13,7 @@ CREATE TABLE `users` (
   `regid` int(5) NOT NULL DEFAULT '0',
   `locid` int(7) NOT NULL DEFAULT '0',
   `listme` int(1) NOT NULL DEFAULT '0',
+  `contactinfo` varchar(255) NOT NULL DEFAULT '',
   `admin` tinyint(1) NOT NULL DEFAULT '0',
   `language` varchar(5) NOT NULL DEFAULT '',
   `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
@@ -78,6 +79,7 @@ CREATE TABLE `pingconfig` (
   `domainid` int(11) NOT NULL,
   `type` enum('email', 'ssl', 'http', 'dns') NOT NULL,
   `info` varchar(255) NOT NULL,
+  `reping` enum('y','n') NOT NULL DEFAULT 'n',
   PRIMARY KEY (`id`)
 ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
 
@@ -87,7 +89,8 @@ CREATE TABLE `domainPinglog` (
   `when` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
   `configId` int(13) NOT NULL,
   `state` enum('open', 'success', 'failed') NOT NULL,
-  `result` varchar(255) NOT NULL
+  `challenge` varchar(16),
+  `result` varchar(255)
 ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
 
 DROP TABLE IF EXISTS `baddomains`;
@@ -212,20 +215,25 @@ CREATE TABLE `notary` (
   `id` int(11) NOT NULL AUTO_INCREMENT,
   `from` int(11) NOT NULL DEFAULT '0',
   `to` int(11) NOT NULL DEFAULT '0',
-  `awarded` int(3) NOT NULL DEFAULT '0',
+# total points that have been entered
   `points` int(3) NOT NULL DEFAULT '0',
-  `method` enum('Face to Face Meeting','Trusted Third Parties','Thawte Points Transfer','Administrative Increase','CT Magazine - Germany','Temporary Increase','Unknown','TOPUP','TTP-Assisted') NOT NULL DEFAULT 'Face to Face Meeting',
+# awarded and the "experience points" are calculated virtually
+# Face to Face is default, TOPUP is for the remaining 30Points after two TTP
+# TTP is default ttp assurance
+  `method` enum('Face to Face Meeting', 'TOPUP', 'TTP-Assisted') NOT NULL DEFAULT 'Face to Face Meeting',
   `location` varchar(255) NOT NULL DEFAULT '',
   `date` varchar(255) NOT NULL DEFAULT '',
+# date when assurance was entered
   `when` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+#?
   `expire` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+#?????????????????
   `sponsor` int(11) NOT NULL DEFAULT '0',
+# date when assurance was deleted (or 0)
   `deleted` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
   PRIMARY KEY (`id`),
   KEY `from` (`from`),
   KEY `to` (`to`),
-  KEY `from_2` (`from`),
-  KEY `to_2` (`to`),
   KEY `stats_notary_when` (`when`),
   KEY `stats_notary_method` (`method`)
 ) ENGINE=InnoDB AUTO_INCREMENT=0 DEFAULT CHARSET=latin1;
@@ -254,3 +262,22 @@ CREATE TABLE `cats_type` (
   PRIMARY KEY (`id`),
   UNIQUE KEY `type_text` (`type_text`)
 ) ENGINE=InnoDB AUTO_INCREMENT=0 DEFAULT CHARSET=latin1;
+
+DROP TABLE IF EXISTS `arbitrations`;
+CREATE TABLE IF NOT EXISTS `arbitrations` (
+  `user` int(11) NOT NULL,
+  `arbitration` varchar(20) NOT NULL,
+  PRIMARY KEY (`user`,`arbitration`)
+) ENGINE=InnoDB DEFAULT CHARSET=latin1;
+
+DROP TABLE IF EXISTS `user_groups`;
+CREATE TABLE IF NOT EXISTS `user_groups` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `user` int(11) NOT NULL,
+  `permission` enum('supporter','arbitrator','blockedassuree','blockedassurer','ttp-assuer','codesigning') NOT NULL,
+  `granted` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
+  `deleted` timestamp NULL DEFAULT NULL,
+  `grantedby` int(11) NOT NULL,
+  `revokedby` int(11) DEFAULT NULL,
+  PRIMARY KEY (`id`)
+) ENGINE=InnoDB DEFAULT CHARSET=latin1;