表名:MQTT权限表
| 字段标识 | 字段类型 |备注|
| --- | --- |---|---|
| id| int(11)| ID |
| allow| smallint(5)| 0: deny, 1: allow |
| ipaddr| smallint(5)| IpAddress|
| username| tinyint(1)| Username|
| clientid| smallint(5)| ClientId|
| access| varchar(100)| 1: subscribe, 2: publish, 3: pubsub|
| topic| varchar(255)| Topic Filter|
```
CREATE TABLE `sys_mqtt_acl` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`allow` int(1) DEFAULT '1' COMMENT '0: deny, 1: allow',
`ipaddr` varchar(60) DEFAULT NULL COMMENT 'IpAddress',
`username` varchar(100) DEFAULT NULL COMMENT 'Username',
`clientid` varchar(100) DEFAULT NULL COMMENT 'ClientId',
`access` int(2) NOT NULL COMMENT '1: subscribe, 2: publish, 3: pubsub',
`topic` varchar(100) NOT NULL DEFAULT '' COMMENT 'Topic Filter',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COMMENT='MQTT权限表'
```