mirror of https://github.com/MISP/MISP
parent
ef0f2201ac
commit
e4a812f0ff
|
@ -0,0 +1,19 @@
|
|||
<?php
|
||||
class DbBlacklistSchema extends CakeSchema {
|
||||
|
||||
public $name = 'DbBlacklist';
|
||||
|
||||
public function before($event = array()) {
|
||||
return true;
|
||||
}
|
||||
|
||||
public function after($event = array()) {
|
||||
}
|
||||
|
||||
public $blacklist = array(
|
||||
'id' => array('type' => 'integer', 'null' => false, 'default' => null, 'key' => 'primary'),
|
||||
'name' => array('type' => 'text', 'null' => false, 'default' => null, 'key' => 'index', 'collate' => 'utf8_unicode_ci', 'charset' => 'utf8'),
|
||||
'indexes' => array('PRIMARY' => array('column' => 'id', 'unique' => 1)),
|
||||
'tableParameters' => array('charset' => 'utf8', 'collate' => 'utf8_bin', 'engine' => 'MyISAM')
|
||||
);
|
||||
}
|
|
@ -23,6 +23,9 @@ cd ${PRJCT}
|
|||
# create Whitelist table
|
||||
./Console/cake schema create DbWhitelist
|
||||
|
||||
# create Blacklist table
|
||||
./Console/cake schema create DbBlacklist
|
||||
|
||||
# update Schema, add Users.role_id
|
||||
./Console/cake schema update -s 0.2.2.1
|
||||
|
||||
|
|
Loading…
Reference in New Issue