Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Native MySQL data source view desensitization failed #475

Closed
sl01388797 opened this issue Oct 11, 2023 · 4 comments
Closed

[Bug]: Native MySQL data source view desensitization failed #475

sl01388797 opened this issue Oct 11, 2023 · 4 comments
Assignees
Labels
priority-medium type-bug Something isn't working
Milestone

Comments

@sl01388797
Copy link
Collaborator

sl01388797 commented Oct 11, 2023

ODC version

odc422

OB version

not have

What happened?

00d817b8c2c9d24c77cfea7b2c586e65
6d3f09976a6ad7161077817d78617483

What did you expect to happen?

View desensitization successful

How can we reproduce it (as minimally and precisely as possible)?

  1. Create Table
    DDL:
    CREATE TABLE a5 (
    col遮掩 varchar(120) DEFAULT NULL,
    col姓名汉字 varchar(120) DEFAULT NULL,
    col姓名字母 varchar(120) DEFAULT NULL,
    col昵称 varchar(120) DEFAULT NULL,
    col地址 varchar(120) DEFAULT NULL,
    col手机 varchar(120) DEFAULT NULL,
    col电话 varchar(120) DEFAULT NULL,
    col证件 varchar(120) DEFAULT NULL,
    col银行卡 varchar(120) DEFAULT NULL,
    col车牌号 varchar(120) DEFAULT NULL,
    col设备 varchar(120) DEFAULT NULL,
    colip varchar(120) DEFAULT NULL,
    colmac varchar(120) DEFAULT NULL,
    colmd5 varchar(120) DEFAULT NULL,
    colsha256 varchar(120) DEFAULT NULL,
    colsha512 varchar(120) DEFAULT NULL,
    col数值 varchar(120) DEFAULT NULL,
    col置空 varchar(120) DEFAULT NULL,
    col缺省 varchar(120) DEFAULT NULL,
    col邮箱 varchar(120) DEFAULT NULL,
    colSM3 varchar(120) DEFAULT NULL
    ) DEFAULT CHARSET = utf8mb4 ROW_FORMAT = DYNAMIC COMPRESSION = 'zstd_1.3.8' REPLICA_NUM = 1 BLOCK_SIZE = 16384 USE_BLOOM_FILTER = FALSE TABLET_SIZE = 134217728 PCTFREE = 0
  2. Create View
    CREATE ALGORITHM = UNDEFINED DEFINER = root@ % SQL SECURITY DEFINER VIEW A22 AS
    select
    a5.col遮掩 AS col遮掩,
    a5.col姓名汉字 AS col姓名汉字,
    a5.col姓名字母 AS col姓名字母,
    a5.col昵称 AS col昵称,
    a5.col地址 AS col地址,
    a5.col手机 AS col手机,
    a5.col电话 AS col电话,
    a5.col证件 AS col证件,
    a5.col银行卡 AS col银行卡,
    a5.col车牌号 AS col车牌号,
    a5.col设备 AS col设备,
    a5.colip AS colip,
    a5.colmac AS colmac,
    a5.colmd5 AS colmd5,
    a5.colsha256 AS colsha256,
    a5.colsha512 AS colsha512,
    a5.col数值 AS col数值,
    a5.col置空 AS col置空,
    a5.col缺省 AS col缺省,
    a5.col邮箱 AS col邮箱,
    a5.colSM3 AS colSM3
    from
    a5;
  3. Create View Sensitive Columns

Anything else we need to know?

No response

Cloud

No response

@sl01388797 sl01388797 added type-bug Something isn't working priority-medium labels Oct 11, 2023
@sl01388797 sl01388797 added this to the ODC 4.2.2 milestone Oct 11, 2023
@smallsheeeep
Copy link
Contributor

It works for me:
image

@smallsheeeep
Copy link
Contributor

This issue is duplicated with #481

@smallsheeeep
Copy link
Contributor

The View with uppercase name still masking failed

@sl01388797
Copy link
Collaborator Author

Image

pass

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority-medium type-bug Something isn't working
Projects
Archived in project
Development

No branches or pull requests

2 participants