Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The use of Percona8.0.17 's data masking plug-in

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

The data masking function in MySQL Enterprise Edition is implemented by open source in Percona 8.0.17.

For details, please refer to the following three documents:

Https://dev.mysql.com/doc/mysql-security-excerpt/8.0/en/data-masking-installation.html

Https://www.percona.com/doc/percona-server/LATEST/security/data-masking.html 、

Https://www.percona.com/blog/2020/01/06/data-masking-in-percona-server-for-mysql-to-protect-sensitive-data/

For the convenience of our demonstration here, use dbdeployer to deploy:

Dbdeployer unpack-prefix=ps Percona-Server-8.0.18-9-Linux.x86_64.ssl101.tar.gzdbdeployer deploy single ps8.0.18-bind-address='0.0.0.0'-gtid-init-general-log-enable-genera-log-disable-mysqlx-force

Cd / sandboxes/msb_ps8_0_18/

Cat my.sandbox.cnf modifies the user of client segment to root (low-privilege account is deployed by default dbdeployer)

[client] user = root

# install the data_masking plug-in

. / use Log in to mysql console mysql [localhost:8018] {root} (test) > INSTALL PLUGIN data_masking SONAME 'data_masking.so';Query OK, 0 rows affected (0.02 sec)

# demonstrate the data barrier function

Mysql [localhost:8018] {root} (test) > SELECT mask_outer ('This is a string', 5,1) # first 5 characters and last 1 character Replace +-- + with mask | mask_outer ('This is a string', 5 1) | +-+ | XXXXXis a strinX | +-+ 1 row in set (0.00 sec) mysql [localhost:8018] {root} (test) > SELECT mask_pan_relaxed (gen_rnd_pan ()) +-- + | mask_pan_relaxed (gen_rnd_pan ()) | +-- + | 545151XXXXXX1753 | +-+ 1 row in set (0.00 sec)

There are many more details, just refer to the three connections above.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report