当前位置:网站首页>数据泄露怎么办?'华生·K'7招消灭安全威胁
数据泄露怎么办?'华生·K'7招消灭安全威胁
2022-07-05 12:51:00 【墨天轮】
欢迎收听西虹市电台早间晨报:
T公司系统在 3 月18 日遭到了网络犯罪攻击,数百万客户和潜在客户的数据因此泄密。
C研究院在4月29日报告,一个含有约3500万个人详细信息的神秘营销数据库泄露在网上,居然未设密码。
......
安全事件频发
数据安全应该怎么做?


寻医问药
金仓KES带来新生机!

然而,针对KingbaseES数据库的安全方案,蔡小x仍旧存在着一些疑惑:
七问七答
金仓KES筑牢企业数据安全之盾!
一问:防仿冒
用户标识与鉴别
KingbaseES默认的口令加密算法为SCRAM-SHA-256。它是按照RFC 7677中的描述执行SCRAM-SHA-256认证,可以防止在不可信连接上对口令的嗅探并且支持在服务器上以一种加密哈希的方式存放口令。
KingbaseES数据库的用户信息及密码存储在一个名为sys_authid的数据表中。以下是KES数据库中口令的加密形式,sys_authid表的rolpassword字段显示了加密后的密钥:
test=# select usename,passwd from sys_user where usename in('system','sao','sso');
usename | passwd
---------+----------
system | ********
sao | ********
sso | ********
(3 行记录)
alter system set passwordcheck.enable=on;
alter system set passwordcheck.password_length = 10;
alter system set passwordcheck.password_condition_letter = 3;
alter system set passwordcheck.password_condition_digit = 3;
alter system set passwordcheck.password_condition_punct = 1;
select sys_reload_conf();

alter system set sys_audlog.max_error_user_connect_times = 10;
alter system set sys_audlog.error_user_connect_times = 6;
alter system set sys_audlog.error_user_connect_interval = 60;
select sys_reload_conf();
[test@4-34 bin]$ ./ksql test -U testu1 -p 54324 -h 127.0.0.1
用户 testu1 的口令:
[test@4-34 bin]$ ./ksql test -U testu1 -p 54324 -W -h 127.0.0.1
口令:
ksql: 错误: 无法连接到服务器:致命错误: password authentication failed for user "testu1"
NOTICE: This is the 2 login failed. There are 4 left.
[test@4-34 bin]$ ./ksql test -U testu1 -p 54324 -W -h 127.0.0.1
口令:
ksql: 错误: 无法连接到服务器:致命错误: password authentication failed for user "testu1"
NOTICE: This is the 3 login failed. There are 3 left.
[test@4-34 bin]$ ./ksql test -U testu1 -p 54324 -W -h 127.0.0.1
口令:
ksql: 错误: 无法连接到服务器:致命错误: password authentication failed for user "testu1"
NOTICE: This is the 4 login failed. There are 2 left.
[test@4-34 bin]$ ./ksql test -U testu1 -p 54324 -W -h 127.0.0.1
口令:
ksql: 错误: 无法连接到服务器:致命错误: password authentication failed for user "testu1"
NOTICE: This is the 5 login failed. There are 1 left.
[test@4-34 bin]$ ./ksql test -U testu1 -p 54324 -W -h 127.0.0.1
口令:
ksql: 错误: 无法连接到服务器:致命错误: The user "testu1" is locked.please wait 60 minutes to retry
访问控制
--系统权限实际为创建用户时指定的一些属性权限
--system
--授权
create user u1 with superuser;
--或
alter user u1 with superuser;
create user u2 with createrole;
--或
alter user u2 with createrole;
create user u3 with login;
--或
alter user u3 with login;
create user u4 with createdb;
--或
alter user u4 with createdb;
--列举不全,具体可以查看create user/alter user 语句。
--撤销
alter user u1 with nosuperuser;
alter user u2 with nocreaterole;
alter user u3 with nologin;
alter user u4 with nocreatedb;
--对象权限就是存在于数据库对象上的权限
--准备
--system
create user u1;
create user u2;
--u1
\c test u1
create table testu1(id int);
insert into testu1 values(123);
--u2
\c test u2
select * from testu1; --error
--授权
--u1
\c test u1
--列级权限
grant select(id) on testu1 to u2;
--表级权限
grant select all on testu1 to u2;
--u2
\c test u2
select id from test; -- success
select * from test; -- success
--撤销
revoke select(id) on testu1 from u2;
revoke select all on testu1 from u2;
二问:防篡改
三问:防信息泄露
透明存储加密
create tablespace ts location '/home/kingbase/ts' with(encryption = true, enckey ='k1eyenc2');
--encryption: 标识当前表空间为加密表空间
--enckey: 用户自定义的表空间加密密钥
--sysencrypt.encrypt_user_tablespace
--这个属于加密插件里面的参数,true 为创建的表空间为默认加密表空间,false 则关闭此参数
--如何确认数据是否被加密
--首先确认数据所在加密对象的物理文件位置
--示例:
select oid,relname, relfilenode from sys_class where relname = 'test';
--然后根据此语句查询出来的relfilenode 号找到物理文件所在位置,或是
select sys_relation_filepath(sys_relation_filenode('test'));
--找到数据文件的具体位置
--hexdump -c 数据库文件如果对比其他明文文件是可以很明显的看到数据是加密的,都是一些不可见字符或乱码,证明加密成功。
四问:防抵赖
审计
--数据库审计员设置语句级审计规则,审计类型为select table 语句,审计用户为数据库管理员system,审计对象为public 模式下的tab1
select sysaudit.set_audit_stmt('select table','system','public','tab1');
--数据库安全员设置对象级审计规则,审计类型为table 对象,审计用户为普通用户user1,审计对象为public 模式下的tab2
select sysaudit.set_audit_object('table','user1','public','tab2');
--数据库审计员需要查询视图sysaudit_record_sao,可以查看超级用户(包括数据库管理员system)和数据库安全员的审计日志
select * from sysaudit_record_sao;
--数据库安全员需要查询视图sysaudit_record_sso,可以查看普通用户和数据库审计员的审计日志
select * from sysaudit_record_sso;
五问:防权限提升
三权分立
\c test system
alter user sao rename to sao2;
alter user sso rename to sso2;
\du
select * from sys_authid;
六问:防拒绝服务
七问:安全资质

结语
KingbaseES 是自主研发的高安全性数据库产品,通过全新的结构化系统设计和强化的多样化强制访问控制模型框架,开发了多个高等级的安全特性,并完整实现包括特权分立、身份鉴别、多样化访问控制、用户数据保护、审计等在内的全部结构化保护级的技术和功能要求。KingbaseES纵深防御,为数据库安全保驾护航!

END

边栏推荐
- Four common problems of e-commerce sellers' refund and cash return, with solutions
- How to realize batch sending when fishing
- 自然语言处理系列(一)入门概述
- How do e-commerce sellers refund in batches?
- Introduction to sap ui5 flexiblecolumnlayout control
- Research: data security tools cannot resist blackmail software in 60% of cases
- HiEngine:可媲美本地的云原生内存数据库引擎
- Le rapport de recherche sur l'analyse matricielle de la Force des fournisseurs de RPA dans le secteur bancaire chinois en 2022 a été officiellement lancé.
- ABAP editor in SAP segw transaction code
- 百日完成国产数据库opengausss的开源任务--openGuass极简版3.0.0安装教程
猜你喜欢

数据湖(七):Iceberg概念及回顾什么是数据湖

Introduction to sap ui5 flexiblecolumnlayout control

潘多拉 IOT 开发板学习(HAL 库)—— 实验7 窗口看门狗实验(学习笔记)
![leetcode:221. Maximum square [essence of DP state transition]](/img/ea/158e8659657984794c52a0449e0ee5.png)
leetcode:221. Maximum square [essence of DP state transition]

Get to know linkerd project for the first time

Write macro with word

OpenHarmony应用开发之Navigation组件详解

CF:A. The Third Three Number Problem【关于我是位运算垃圾这个事情】

Notes for preparation of information system project manager --- information knowledge

关于 SAP UI5 getSAPLogonLanguage is not a function 的错误消息以及 API 版本的讨论
随机推荐
Introduction to sap ui5 flexiblecolumnlayout control
Halcon template matching actual code (I)
Run, open circuit
DNS的原理介绍
A small talk caused by the increase of sweeping
谈谈我写作生涯的画图技巧
解决uni-app配置页面、tabBar无效问题
初识Linkerd项目
RHCSA4
我在滴滴做开源
Concurrent performance test of SAP Spartacus with JMeter
Talk about my drawing skills in my writing career
RHCSA9
关于 SAP UI5 floating footer 显示与否的单步调试以及使用 SAP UI5 的收益
Introduction aux contrôles de la page dynamique SAP ui5
RHCSA2
How do e-commerce sellers refund in batches?
CVPR 2022 | single step 3D target recognizer based on sparse transformer
逆波兰表达式
SAP SEGW 事物码里的 ABAP Editor
