Data security processing method and device based on sensitive data identification
By constructing data source connection pool instances and three-level structured data directory objects, and combining them with an integrated sensitive identification model and permission policy table, the problems of accuracy and security in sensitive data identification caused by manual labeling are solved, and the automated processing and security control of sensitive data are realized.
Patent Information
- Application Number
- CN202610589098.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-04-30
- Publication Date
- 2026-11-10
- Estimated Expiration
- 2046-04-30
AI Technical Summary
In existing technologies, the method of identifying sensitive data that relies on manual labeling results in poor accuracy and security, and it is difficult to flexibly restrict data access permissions according to user identity and needs, leading to poor access control security.
By generating a data source connection pool instance, constructing a three-level data directory object, sampling data to generate a two-dimensional numerical feature matrix, using an integrated sensitive identification model to generate a set of sensitive marked record objects, and generating an access control policy table based on a preset permission policy template, the system can automatically discover, mark, and protect sensitive data.
It improves the accuracy of sensitive data identification and the security of access control, reduces manual intervention, and realizes fully automatic discovery, marking and protection of sensitive data, thereby improving the accuracy of identification and the security of access control.
Smart Images

Figure CN122451949B_ABST
Abstract
Description
Technical Field
[0001] The embodiments disclosed herein relate to the field of computer technology, and specifically to a data security processing method and apparatus based on sensitive data identification. Background Technology
[0002] With the rapid development of information technology, data security issues have become increasingly prominent, making the protection of sensitive data particularly important. Data security processing based on sensitive data identification is a technology that involves processing sensitive data securely after it has been identified. Currently, the common approach is to rely on manual labeling of sensitive data. For example, large amounts of sensitive data are manually classified and labeled to control access permissions.
[0003] However, when using the above methods to securely process sensitive data, the following technical problems often arise: different data sources require different connection methods and identification tools; reliance on manual labeling often carries a high degree of subjectivity, leading to poor accuracy and security in sensitive data identification. Furthermore, the difficulty in flexibly restricting data access permissions according to user identity and needs results in poor access control security. Summary of the Invention
[0004] The summary portion of this disclosure is intended to provide a brief overview of the concepts, which will be described in detail in the detailed description portion. This summary portion is not intended to identify key or essential features of the claimed technical solutions, nor is it intended to limit the scope of the claimed technical solutions.
[0005] Some embodiments of this disclosure propose a data security processing method and apparatus based on sensitive data identification to solve the technical problems mentioned in the background section above.
[0006] In a first aspect, some embodiments of this disclosure provide a data security processing method based on sensitive data identification. The method includes: connecting an acquired set of target data sources to a connection pool to generate a data source connection pool instance, wherein the data source types of each target data source in the target data source set are different; generating a three-level structured data directory object based on the data source connection pool instance; sampling data from the three-level structured data directory object to generate a sampled query string set; generating a two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set, wherein the number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns in the two-dimensional numerical feature matrix represents the feature dimension; generating a set of sensitive marked record objects based on the two-dimensional numerical feature matrix; generating an access control policy table based on the set of sensitive marked record objects and a preset permission policy template; and generating a secure data access result based on the access control policy table in response to receiving a data access request from a user terminal.
[0007] Secondly, some embodiments of this disclosure provide a data security processing apparatus based on sensitive data identification. The apparatus includes: a connection unit configured to connect to a target data source set via a connection pool to generate a data source connection pool instance, wherein the data source types of each target data source in the target data source set are different; a first generation unit configured to generate a three-level structured data directory object based on the data source connection pool instance; a sampling unit configured to sample data from the three-level structured data directory object to generate a sampled query string set; a second generation unit configured to generate a two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set, wherein the number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns in the two-dimensional numerical feature matrix represents the feature dimension; a third generation unit configured to generate a sensitive marker record object set based on the two-dimensional numerical feature matrix; a fourth generation unit configured to generate an access control policy table based on the sensitive marker record object set and a preset permission policy template; and a fifth generation unit configured to generate a secure data access result based on the access control policy table in response to receiving a data access request from a user terminal.
[0008] Thirdly, some embodiments of this disclosure provide an electronic device, including: one or more processors; and a storage device having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any implementation of the first aspect above.
[0009] Fourthly, some embodiments of this disclosure provide a computer-readable medium having a computer program stored thereon, wherein the program, when executed by a processor, implements the method described in any of the implementations of the first aspect above.
[0010] The above embodiments of this disclosure have the following beneficial effects: the data security processing method based on sensitive data identification in some embodiments of this disclosure improves the accuracy of sensitive data identification and the security of access control. Specifically, the reason for the poor accuracy and security of sensitive data identification is that different data sources require different connection methods and identification tools, and the subjectivity of manual labeling is often strong, resulting in poor accuracy and security of sensitive data identification. Furthermore, the difficulty in flexibly restricting data access permissions according to user identity and needs leads to poor access control security. Based on this, the data security processing method based on sensitive data identification in some embodiments of this disclosure first connects the acquired target data source set using a connection pool to generate a data source connection pool instance, wherein the data source types of the various target data sources in the target data source set are different. Second, a three-level structured data directory object is generated based on the data source connection pool instance. Thus, it is possible to generate a unified data source connection pool instance without relying on manual labeling for connection pooling of different data source types, allowing subsequent sensitive identification and security protection to be transparently applied to various data sources. Then, data sampling is performed on the three-level structured data directory object to generate a set of sampled query strings. Next, based on the aforementioned data source connection pool instance and the aforementioned sampled query string set, a two-dimensional numerical feature matrix is generated. The number of rows in this matrix represents the number of samples, and the number of columns represents the feature dimension. This generation of the two-dimensional numerical feature matrix improves the recognition accuracy. Then, based on the aforementioned two-dimensional numerical feature matrix, a sensitive data record object set is generated. Next, based on the sensitive data record object set and a preset permission policy template, an access control policy table is generated. This eliminates the need for manually marking sensitive fields or manually configuring permission policies. Finally, in response to a data access request received from the user, a secure data access result is generated based on the aforementioned access control policy table. Thus, by establishing a complete chain from the sensitive data record object set to the access control policy table and then to the secure data access result, fully automated discovery, marking, authorization, and protection of sensitive data are achieved, reducing manual intervention. Therefore, the accuracy of sensitive data identification and the security of access control are improved. Attached Figure Description
[0011] The above and other features, advantages, and aspects of the embodiments of this disclosure will become more apparent from the accompanying drawings and the following detailed description. Throughout the drawings, the same or similar reference numerals denote the same or similar elements. It should be understood that the drawings are schematic, and elements are not necessarily drawn to scale.
[0012] Figure 1 This is a schematic diagram illustrating an application scenario of a data security processing method based on sensitive data identification, which is one of the embodiments of this disclosure. Figure 2 This is a flowchart of some embodiments of the data security processing method based on sensitive data identification according to this disclosure; Figure 3 This is a schematic diagram of the structure of some embodiments of the data security processing apparatus based on sensitive data identification according to the present disclosure; Figure 4 This is a schematic diagram of the structure of an electronic device suitable for implementing some embodiments of the present disclosure; Figure 5 This is a schematic diagram of the structure of a three-level data directory object according to some embodiments of the data security processing method based on sensitive data identification in accordance with this disclosure. Detailed Implementation
[0013] Embodiments of this disclosure will now be described in more detail with reference to the accompanying drawings. While some embodiments of this disclosure are shown in the drawings, it should be understood that this disclosure can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this disclosure. It should be understood that the accompanying drawings and embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of protection of this disclosure.
[0014] It should also be noted that, for ease of description, only the parts relevant to the invention are shown in the accompanying drawings. Unless otherwise specified, the embodiments and features described in this disclosure can be combined with each other.
[0015] It should be noted that the concepts of "first" and "second" mentioned in this disclosure are used only to distinguish different devices, modules or units, and are not used to limit the order of functions performed by these devices, modules or units or their interdependencies.
[0016] It should be noted that the terms "a" and "a plurality of" used in this disclosure are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".
[0017] The names of messages or information exchanged between multiple devices in the embodiments of this disclosure are for illustrative purposes only and are not intended to limit the scope of such messages or information.
[0018] This disclosure will now be described in detail with reference to the accompanying drawings and embodiments.
[0019] Figure 1 This is a schematic diagram illustrating an application scenario of a data security processing method based on sensitive data identification, which is one of the embodiments of this disclosure.
[0020] exist Figure 1In application scenarios, integrated sensitive identification models include: a first basis model (e.g., logistic regression), a second basis model (e.g., random forest), a third basis model (e.g., LightGBM), and a fusion output layer (e.g., soft-voting weighted fusion layer). Then, the standardized feature matrix is input into the first, second, and third basis models respectively. Finally, the outputs of the first, second, and third basis models are input into the fusion output layer to obtain the predicted label and confidence score for each sample. It should be understood that... Figure 1 The number of standardized feature matrices in the model can be arbitrary, depending on the implementation requirements.
[0021] Continue to refer to Figure 2 The flowchart 200 illustrates some embodiments of a data security processing method based on sensitive data identification according to the present disclosure. This data security processing method based on sensitive data identification includes the following steps: Step 201: Connect the obtained target data source set to the connection pool to generate a data source connection pool instance.
[0022] In some embodiments, the entity executing the data security processing method based on sensitive data identification (e.g., a computing device) can connect to the acquired target data source set through a connection pool in a database management manner to generate a data source connection pool instance.
[0023] The target data sources in the aforementioned target data source set are of different types. This target data source set can be a collection of multiple data sources requiring sensitive data identification and protection. The data sources can be data origins. The target data source set can include, but is not limited to, at least one of the following: MySQL database, Oracle database, and message queues (e.g., Kafka). The data source connection pool instance can be a pooled object containing multiple database connections.
[0024] It should be noted that the aforementioned database connection management technology avoids the performance overhead caused by frequently creating and destroying connections by pre-creating and maintaining a certain number of database connection objects, retrieving them from the connection pool when needed, and returning them to the pool after use. The connection pool can be implemented using connection pools such as HikariCP, Druid, or C3P0.
[0025] As an example, the aforementioned execution entity can use HikariCP to initialize a connection pool with a maximum number of connections of 20 for the MySQL database in the target data source set, and similarly use HikariCP to initialize a connection pool with a maximum number of connections of 10 for the Oracle database, thereby generating a data source connection pool instance containing both MySQL and Oracle connection pools. The MySQL database can be configured with the address "jdbc:mysql: / / xx / xxx, username "scanner", and password "1234". The Oracle database can be configured with the address "jdbc:oracle:thin:@xx:xxx, username "audit", and password "1111".
[0026] It should be noted that the aforementioned computing devices can be either hardware or software. When the computing device is hardware, it can be implemented as a distributed cluster consisting of multiple servers or terminal devices, or as a single server or a single terminal device. When the computing device is software, it can be installed on the hardware devices listed above. It can be implemented as, for example, multiple software programs or software modules used to provide distributed services, or as a single software program or software module. No specific limitations are made here.
[0027] Optionally, the aforementioned execution entity can generate a data source connection pool instance by connecting to the obtained target data source set through the following steps: The first step is to configure the connection parameters for each target data source in the acquired target data source set to generate target data source connection parameters, thus obtaining the target data source connection parameter set.
[0028] The connection parameter configuration described above can be a series of preset parameters required to connect to a data source. These preset parameters may include, but are not limited to, at least one of the following: data source type (e.g., mysql), driver class name (e.g., com.mysql.cj.jdbc.Driver), connection URL (e.g., jdbc:mysql: / / 10.0.0.1:3306 / corp_hr), username (e.g., scanner), password (e.g., encrypted_pwd), connection pool size (e.g., 20), and connection timeout (e.g., 30000 milliseconds).
[0029] As an example, the aforementioned execution entity can configure each target data source in the acquired target data source set according to preset parameters to generate target data source connection parameters and obtain a target data source connection parameter set.
[0030] The second step is to initialize the connection pool for each target data source in the obtained target data source set according to the above target data source connection parameter set, so as to generate a data source connection pool instance containing each target data source.
[0031] As an example, the aforementioned execution entity can iterate through each parameter object in the target data source connection parameter set and use a connection pooling framework (such as the HikariCP framework) to create an independent connection pool object for each data source. Then, the created multiple connection pool objects are combined into a collection of connection pool instances that can obtain connections to any data source through a unified interface.
[0032] Step 202: Generate a three-level data directory object based on the above data source connection pool instance.
[0033] In some embodiments, the aforementioned execution entity may generate a three-level structured data directory object based on the aforementioned data source connection pool instance.
[0034] The aforementioned three-level data directory object can be a tree-like data structure used to describe the data in the data source connection pool instance. For example... Figure 5 As shown, the three-tiered data directory object described above can include: a database layer, a table layer, and a field layer. The database layer is the first layer, the table layer is the second layer, and the field layer is the third layer.
[0035] As an example, the aforementioned execution entity can obtain the database list (existing in the database layer), the table list under each database (existing in the table layer), and the field list under each table (existing in the field layer) from the aforementioned data source connection pool instance by calling the database metadata interface (such as JDBC's DatabaseMetaData), and finally combine them into a three-level structured data directory object.
[0036] Optionally, the aforementioned execution entity can generate a three-level structured data directory object based on the aforementioned data source connection pool instance through the following steps: The first step is to acquire active connections for the above data source connection pool instances to generate a set of physical database connection objects corresponding to each target data source.
[0037] Each physical database connection object in the aforementioned physical database connection object set corresponds to a target data source.
[0038] As an example, the aforementioned execution entity can call the getConnection() method of the DriverManager class in the Java language to obtain an available database connection for each connection pool in the data source connection pool instance, thereby generating a set of physical database connection objects corresponding to each target data source.
[0039] The second step is to call the database metadata interface for each physical database connection object in the above physical database connection object set to generate a metadata information group, thus obtaining a metadata information group set.
[0040] The aforementioned metadata set includes: a list of database names (e.g., ["corp_hr", "test_db"]), a list of field metadata (e.g., [(id, INT, NO), (name, VARCHAR, NO)]), and a list of table names (e.g., ["employee", "department"]). The field metadata list includes: field name, data type, and numeric type. The data types can be, but are not limited to, integer and floating-point. The numeric types can be 0 and 1, where 0 represents False and 1 represents True.
[0041] As an example, the aforementioned execution entity can call the getMetaData() method of the resultSet interface in the JAVA language for each physical database connection object to obtain a DatabaseMetaData object, and then call various metadata retrieval methods through this object to generate a metadata information group and obtain a metadata information group set.
[0042] The third step is to assemble the above metadata information set into a tree structure to generate a three-level data directory object.
[0043] In this tree structure, the root node is the data source identifier, the second level is the database name, the third level is the table name, and the fourth level (leaf nodes) is the field metadata.
[0044] As an example, the aforementioned execution entity can traverse each information group in the metadata information group set and construct a tree-like data structure according to the hierarchical relationship of "data source-database-table-field" to generate a three-level structured data directory object.
[0045] Step 203: Sample the data from the above three-level structured data directory object to generate a set of sampled query strings.
[0046] In some embodiments, the aforementioned execution entity may sample the data of the aforementioned three-level structure data directory object to generate a set of sampled query strings.
[0047] The aforementioned set of sample query strings can be a collection of query statements that extract sample data from a three-level structured data directory object.
[0048] As an example, the aforementioned execution entity can sample the data of the above three-level structure data directory object by sampling a fixed number of records (e.g., sampling the first 10,000 non-empty records for each field) to generate a set of sampled query strings.
[0049] Optionally, the aforementioned execution entity can sample data from the above-mentioned three-level structure data directory object through the following steps to generate a sampled query string set: The first step is to traverse the three-level data directory object to generate a list of field paths to be sampled.
[0050] The aforementioned list of fields to be sampled can be a list containing the complete paths of all fields that need to be sampled. The format of each field path in the list is "database name.table name.field name". For example, the format of each field path in the list is corp_hr.employee.id_card.
[0051] As an example, the aforementioned execution entity can use a depth-first traversal to traverse the aforementioned three-level structure data directory object to generate a list of field paths to be sampled.
[0052] The second step is to parse each field path in the above list of field paths to be sampled in order to generate field triples and obtain a set of field triples.
[0053] The above field triple includes: database name (e.g., corp_hr), table name (e.g., employee), and field name (e.g., id_card).
[0054] As an example, the above execution entity can split the string of each field path to be sampled according to the delimiter (such as "."), and assign each of the split parts to the database name, table name and field name respectively to generate field triples, thus obtaining a set of field triples.
[0055] The third step is to construct a sampling statement for each field triple in the above field triple set to generate a sampling query string, thus obtaining a set of sampling query strings.
[0056] The template for the above sampling statement can be: SELECT {field name} FROM {table name} WHERE {field name} ISNOT NULL LIMIT {sample number}, where the sample number can be preset to 10000. That is, it finds records from {table name} where {field name} is not empty and returns only the first {sample number} records.
[0057] As an example, the aforementioned execution entity can fill the database name, table name, and field name in each field triplet into the corresponding positions in the sampling statement template to generate a sampling query string and obtain a set of sampling query strings.
[0058] Step 204: Generate a two-dimensional numerical feature matrix based on the above data source connection pool instance and the above sampled query string set.
[0059] In some embodiments, the execution entity can generate a two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set. The number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns represents the feature dimension.
[0060] The aforementioned two-dimensional numerical feature matrix can be a two-dimensional data structure where both rows and columns are numerical. Each row of the matrix corresponds to a data sample (e.g., a record of an ID card number), and each column corresponds to a feature (e.g., string length, percentage of numbers, etc.). The sample size can be the total number of data records sampled from the data source. For example, if 10,000 records are sampled for each field, the sample size is 10,000. The feature dimension can be the number of features used to describe each sample. For example, if 32 features, including length, percentage of numbers, percentage of letters, and regular expression matching results, are used to describe a sample, the feature dimension is 32.
[0061] As an example, the aforementioned execution entity can obtain a connection from the data source connection pool instance, execute each query statement in the sampled query string set, convert the returned raw string data into numerical feature vectors, and then stack all feature vectors horizontally into a matrix.
[0062] Optionally, the aforementioned execution entity can generate a two-dimensional numerical feature matrix based on the aforementioned data source connection pool instance and the aforementioned sampled query string set through the following steps: The first step is to obtain the pre-compiled object corresponding to each sampled query string in the sampled query string set based on the above data source connection pool instance, thus obtaining the pre-compiled object set.
[0063] The aforementioned precompiled object can be an instance of a database prepared statement.
[0064] As an example, the aforementioned execution entity can obtain a database connection from the data source connection pool instance, call the prepareStatement() method in the JAVA language for each sampled query string, create a pre-compiled object, and obtain a set of pre-compiled objects.
[0065] The second step is to iterate through the above pre-compiled object set to generate a list of raw string samples.
[0066] As an example, the aforementioned execution entity can call the `executeQuery()` method in the JDBC API of the Java language to execute a query for each pre-compiled object, obtain a string query result set, and then read the string values in the string query result set line by line, collect them into a list, and obtain the original string sample list. For example, the original string sample list can be ["41010119900307663X", "310101199505124521", ...].
[0067] The third step is to determine the length features of the original string sample list to generate a list of string length numerical features.
[0068] The length feature can be the number of characters in the string. For example, the string "41010119900307663X" has a length of 18.
[0069] As an example, the aforementioned execution entity can iterate through each string in the original string sample list, call the JAVA language's length() method to obtain its length, and store the length value in a list to generate a list of string length numerical features.
[0070] The fourth step is to determine the character composition ratio of each original string sample in the above original string sample list to generate the proportion of numbers, letters and special characters, and to determine the proportion of numbers, letters and special characters as numerical composition features to obtain a set of numerical composition features.
[0071] The aforementioned percentage of numbers can be the proportion of numeric characters (e.g., 0-9) in the string to the total length. The aforementioned percentage of letters can be the proportion of alphabetic characters (e.g., AZ, az) in the string to the total length. The aforementioned percentage of special characters can be the proportion of special characters (e.g., @, #, -, X, etc.) in the string to the total length. Special characters can be characters in the string that are neither numbers nor letters. The aforementioned numerical feature set can be the set of the three feature values: the percentage of numbers, the percentage of letters, and the percentage of special characters for all samples.
[0072] As an example, the aforementioned execution entity can iterate through each string, count the number of numbers, letters, and special characters, and divide each by the total length to obtain three ratio values, thereby generating the percentage of numbers, the percentage of letters, and the percentage of special characters.
[0073] The fifth step is to perform sensitive data validation on each original string sample in the above original string sample list to generate sensitive data Boolean features, thus obtaining a sensitive data Boolean feature set.
[0074] Among them, the aforementioned sensitive data Boolean feature can be the Boolean value output by the verification algorithm, where 1 indicates that the verification passed (the string conforms to the encoding rules of the corresponding sensitive data), and 0 indicates that the verification failed.
[0075] As an example, the aforementioned execution entity can call a verification algorithm function (such as the validateIdCard() function in the JAVA language) to perform sensitive data verification on each original string sample in the original string sample list above, so as to generate sensitive data Boolean features and obtain a sensitive data Boolean feature set.
[0076] The sixth step is to horizontally concatenate the above list of string length numerical features, the above set of numerical composition features, and the above set of sensitive data Boolean features according to the sample dimensions to generate a fixed-dimensional feature vector set.
[0077] The aforementioned fixed-dimensional feature vector set can be a collection of feature vectors from all samples, with each feature vector having the same dimension.
[0078] As an example, the aforementioned execution entity can concatenate the string length numerical feature list, the numerical composition feature set, and the sensitive data Boolean feature set according to the sample dimension in a fixed order to generate a fixed-dimensional feature vector set. For example, the string length numerical feature of sample 1 is 18, the numerical composition feature is [0.944, 0.056, 0], and the sensitive data Boolean feature is [1, 0, 1]. After horizontal concatenation, we get [18, 0.944, 0.056, 0, 1, 0, 1].
[0079] The seventh step is to stack the above fixed-dimensional feature vector sets vertically to generate a two-dimensional numerical feature matrix.
[0080] In this context, the number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns in the two-dimensional numerical feature matrix represents the feature dimension.
[0081] As an example, the aforementioned execution entity can stack the fixed-dimensional feature vector set in the row direction to generate a two-dimensional numerical feature matrix. For instance, if the execution entity has 10,000 samples, each with a 32-dimensional feature vector, stacking these 10,000 32-dimensional vectors in rows generates a 10,000-row × 32-column two-dimensional numerical feature matrix. The first row of this matrix corresponds to all feature values of the first sample, and the first column corresponds to the first feature value of all samples (such as string length).
[0082] Because feature vectors typically extract only simple statistical features (such as length and whether they contain numbers), ignoring finer-grained features (such as character composition ratio, validation algorithm results, and regular expression matching results), their ability to represent sensitive data is insufficient. Furthermore, the inefficiency in processing large-scale data prevents the completion of recognition tasks within an acceptable timeframe. To improve the representational ability of feature vectors for sensitive data, this application first uses pre-compiled objects to batch execute sampling queries. By reusing pre-compiled objects and connection pools, sampling efficiency is significantly improved compared to creating new connections each time, allowing for efficient collection of sample data from large-scale data sources. Second, by combining multi-dimensional features such as length features, composition ratio features, and validation Boolean features, the representational ability of feature vectors for sensitive data is significantly enhanced. Then, through horizontal concatenation and vertical stacking, a two-dimensional numerical feature matrix is generated with the number of rows equal to the number of samples and the number of columns equal to the feature dimensions. This matrix can be directly used as input to machine learning models without additional data transformation. Finally, since the sampling query string set can be executed in parallel, and the sampling and feature extraction of each field are independent, it can be easily scaled to a distributed processing architecture. Therefore, the representational ability of feature vectors for sensitive data is improved, enabling efficient completion of recognition tasks.
[0083] Step 205: Generate a set of sensitive marked record objects based on the above two-dimensional numerical feature matrix.
[0084] In some embodiments, the execution entity can generate a set of sensitive marker record objects based on the two-dimensional numerical feature matrix.
[0085] The aforementioned sensitive marker record object set can be a collection of record objects containing sensitive field identification information. Each sensitive marker record object in the aforementioned sensitive marker record object set may include, but is not limited to, at least one of the following: field path (e.g., corp_hr.employee.id_card), sensitivity type (e.g., ID_CARD), sensitivity level (e.g., L3), confidence score (e.g., 0.965), marker timestamp, and model version number.
[0086] Optionally, the aforementioned execution entity can generate a set of sensitive marked record objects based on the aforementioned two-dimensional numerical feature matrix through the following steps: The first step is to perform standardization preprocessing on the above two-dimensional numerical feature matrix to generate a standardized feature matrix.
[0087] The standardized feature matrix mentioned above can be a matrix obtained after standardized preprocessing, in which each feature dimension follows a standard normal distribution.
[0088] As an example, the aforementioned execution entity can transform the data according to the feature dimension through standardization preprocessing, making its mean 0 and standard deviation 1, to generate a standardized feature matrix. The formula for the above standardization preprocessing is: x'=(x-μ) / σ, where μ is the feature mean, σ is the feature standard deviation, x' is the standardized feature matrix, and x is a two-dimensional numerical feature matrix.
[0089] The second step is to input the standardized feature matrix into the pre-trained ensemble sensitive identification model to generate the predicted label and confidence score for each sample, thus obtaining the predicted label and confidence score for each sample.
[0090] The aforementioned ensemble sensitive identification model includes: a first base model (e.g., logistic regression), a second base model (e.g., random forest), a third base model (e.g., LightGBM), and a fusion output layer (e.g., soft-voting weighted fusion layer). The predicted labels can be the sensitive type categories output by the model. For example, the predicted labels may include, but are not limited to: NON_SENSITIVE, PHONE (phone number), ID_CARD (ID card number), BANK_CARD (bank card number), and SALARY (salary). For example, the executing entity inputs the first row of the standardized feature matrix [0.217, -0.5, 0.3, ...] into the ensemble sensitive identification model. The integrated sensitive identification model calculates the output [0.01, 0.02, 0.95, 0.01, 0.01] through the first base model, [0.00, 0.01, 0.98, 0.00, 0.01] through the second base model, and [0.01, 0.01, 0.97, 0.00, 0.01] through the third base model. After weighted fusion by the output layer, the final probability distribution [0.007, 0.012, 0.967, 0.002, 0.012] is generated. The category ID_CARD corresponding to the maximum value is taken as the predicted label, and the maximum value of 0.967 is taken as the confidence score. The above execution entity can perform the same operation on all samples to obtain the predicted label and confidence score for each sample. The first base model includes an input layer, a fully connected layer, and a softmax activation layer. The input layer is used to receive the feature vector after standardization preprocessing. The fully connected layer performs a linear transformation on the input feature vector, mapping the 32-dimensional features to a 5-dimensional space (5 corresponds to the number of categories of the sensitive type). The softmax activation layer transforms the original logistic vector output by the fully connected layer into a probability distribution, ensuring that the sum of the output probabilities for all categories is 1, and the probability value for each category is between 0 and 1. The second base model includes an input layer, a bootstrap sampling layer, a decision tree construction layer, and a prediction aggregation layer. The input layer receives the standardized preprocessed feature vector. The bootstrap sampling layer performs random sampling with replacement on the original training dataset, generating multiple different bootstrap training subsets. Each bootstrap training subset is the same size as the original dataset, but samples can be repeated. The decision tree construction layer independently constructs a decision tree on each bootstrap training subset. Each decision tree learns the relationship between features and categories through recursive splitting. The prediction aggregation layer outputs a probability distribution vector through arithmetic averaging. The third base model includes an input layer, an iterative layer, and a softmax transformation layer.The input layer receives the standardized preprocessed feature vectors, and the iterative layer uses multiple iterations to build a new decision tree in each round to fit the negative gradient (i.e., residual) predicted by the current model, thereby gradually reducing the prediction error. The softmax transformation layer is used to convert the cumulative predicted values of multiple classes into a probability distribution.
[0091] The third step involves performing the following processing steps for each sample's predicted label and confidence score: The first sub-step involves aggregating the predicted labels and confidence scores to generate a summary of sensitive labels and an average confidence score.
[0092] The aggregated sensitivity labels for the above fields can be labels representing the sensitivity type of the entire field after aggregation. The average confidence score for the above fields can be the arithmetic mean of the confidence scores of all samples belonging to the same field.
[0093] As an example, the aforementioned execution entity can use the majority voting method (taking the label that appears most frequently) to group the samples according to the field path, perform majority voting on the predicted labels within each group, and calculate the average of the confidence scores to generate the field summary sensitive labels and the field average confidence.
[0094] The second sub-step involves extracting feature vectors from the fields corresponding to the aforementioned sensitive tags to obtain context feature vectors.
[0095] The aforementioned context feature vector can be a feature vector of context information for a field.
[0096] The third sub-step involves forward reasoning on the aforementioned context feature vectors to generate false positive correction results.
[0097] The aforementioned false positive correction results can serve as a decision indicating whether the model's recognition results need to be corrected. These results can include: 0 (no correction, retain original label), 1 (correct to non-sensitive), and 2 (correct to await manual confirmation).
[0098] As an example, the aforementioned execution entity can input the context feature vector into a pre-trained false positive correction decision-maker (e.g., a CART decision tree), and make judgments layer by layer according to the node splitting conditions of the decision tree, finally reaching a leaf node and outputting the category of that leaf node. The aforementioned false positive correction decision-maker adopts a binary tree structure, including a start node, internal nodes, and an end node. The start node contains all training samples, the internal nodes contain a splitting condition, and the samples are divided into left or right child nodes according to the splitting condition. The end node stores a category decision (i.e., the false positive correction result 0, 1, or 2).
[0099] The fourth sub-step involves determining the flags for the aforementioned false alarm correction results and the aforementioned field summary sensitive labels to generate a final confirmation label and a false alarm correction flag.
[0100] The aforementioned final confirmation label can be a field sensitivity type label determined after false positive correction. This final confirmation label can be the original field summary sensitivity label, or it can be NON_SENSITIVE or PENDING_REVIEW. The aforementioned false positive correction flag can be a Boolean value used to indicate whether the corresponding field was judged as a false positive. A false positive correction flag of True indicates that the corresponding field has been corrected to be non-sensitive (i.e., originally identified as a false positive), and False indicates that it has not been corrected.
[0101] As an example, the aforementioned executing entity can determine the values of the final confirmation label and the false alarm correction flag based on the value of the false alarm correction result.
[0102] The fourth step is to combine the aforementioned final confirmation label, false alarm correction flag, average field confidence level, and current timestamp to generate a sensitive marker record object.
[0103] As an example, the aforementioned executing entity can merge the aforementioned final confirmation label, the aforementioned false alarm correction flag, the average confidence level of the field, and the current timestamp to obtain a sensitive marker record object.
[0104] The fifth step is to determine the obtained sensitive marker record objects as a sensitive marker record object set.
[0105] Because contextual information is easily overlooked, a large amount of normal data is misclassified as sensitive data, resulting in a high false positive rate, which interferes with data security processing and leads to low security. Furthermore, the inability to pinpoint specific fields during sensitive data identification results in poor accuracy of the final generated sensitive data markers. To improve the security of data security processing and the accuracy of the final generated sensitive data markers, firstly, by integrating a sensitive data identification model (multi-model fusion) and standardized preprocessing, the identification accuracy is significantly improved compared to a single model. Through contextual feature extraction and a false positive correction decision-maker, normal data that is easily misclassified, such as test data and temporary data, can be effectively filtered, making the final generated sensitive data markers accurate to the field level. Next, each sensitive data marker includes a confidence score, allowing downstream systems to adopt different processing strategies based on confidence levels (e.g., automatic processing for high confidence, manual review for low confidence). Finally, by generating false positive correction flags, the system can collect corrected samples as feedback data for incremental training of subsequent models. Therefore, the false positive rate of sensitive data identification is reduced, the security of data security processing is improved, and the accuracy of the final generated sensitive data markers is increased.
[0106] Step 206: Generate an access control policy table based on the above sensitive marker record object set and preset permission policy template.
[0107] In some embodiments, the aforementioned execution entity may generate an access control policy table based on the aforementioned sensitive marker record object set and the preset permission policy template.
[0108] The access control policy table mentioned above can be a database table or an in-memory data structure containing field-level access control rules. Each record in the access control policy table can include, but is not limited to, at least one of the following: role name (e.g., HR_MANAGER), field path (e.g., corp_hr.employee.id_card), operation type (e.g., SELECT), and transformation type (e.g., MASK_ID_CARD or DENY). The preset permission policy template can be a predefined template that maps sensitivity levels to access permission rules. The preset permission policy template can define: for data with sensitivity level L4, only the HR_MANAGER role can read plaintext data, and the DEPT_MANAGER role can read anonymized data; the STAFF role is completely prohibited from reading data; for data with sensitivity level L3, the HR_MANAGER and DEPT_MANAGER roles can read plaintext data, and the STAFF role can read anonymized data, etc.
[0109] As an example, the aforementioned execution entity can traverse each record in the sensitive marker record object set, extract the sensitive field path and sensitivity level, match the corresponding permission rules from the preset permission policy template, and obtain the access control policy table.
[0110] Optionally, the aforementioned executing entity can generate an access control policy table based on the aforementioned sensitive marker record object set and preset permission policy template through the following steps: The first step is to perform the following steps for each sensitive marker record object in the above sensitive marker record object set: The first sub-step involves extracting the sensitive field paths and sensitivity levels from the aforementioned sensitive marked record objects to generate sensitive field paths and sensitivity levels.
[0111] The sensitive field path mentioned above can be the complete path identifier of the location of the sensitive data. The format of the sensitive field path is "database name.table name.field name". The sensitivity level mentioned above can be a level divided according to the type and importance of the sensitive data. The sensitivity level mentioned above can include, but is not limited to: L1 (low sensitivity), L2 (medium sensitivity), L3 (high sensitivity), and L4 (extremely high sensitivity).
[0112] As an example, the aforementioned execution entity can read the sensitive field path and sensitivity level values from the aforementioned sensitive marker record object to obtain the sensitive field path and sensitivity level.
[0113] The second sub-step involves matching the aforementioned sensitivity levels using the preset permission policy template to obtain access control policy groups.
[0114] The access control policy group mentioned above can be multiple control policies related to the sensitivity level. For example, the access control policy group could be {data with sensitivity level L4, plaintext data can only be read by the HR_MANAGER role, de-identified data can be read by the DEPT_MANAGER role, and data can be completely prohibited for the STAFF role}.
[0115] As an example, the aforementioned execution entity can use the sensitivity level as the key to find multiple corresponding control policies in the preset permission policy template to obtain an access control policy group.
[0116] The second step is to integrate the obtained access control policy groups into an access control policy table.
[0117] As an example, the aforementioned execution entity can combine the various access control policies obtained into an access control policy table.
[0118] Step 207: In response to receiving a data access request from the user, generate a secure data access result based on the access control policy table mentioned above.
[0119] In some embodiments, the execution entity may, in response to receiving a data access request from a user, generate a secure data access result based on the access control policy table.
[0120] The user end can be a client or user terminal that initiates the data access request. This user end can be a database client (such as Navicat, DBeaver), an application (such as a web application, API service), or a data visualization tool. The data access request can be an instruction issued by the user end to query or manipulate data. This data access request can be an SQL query statement (such as SELECT name, id_card FROM employee), an API call, or a file read request.
[0121] As an example, the aforementioned execution entity can query the current user role's permissions for the requested field from the access control policy table, perform desensitization or blocking operations on sensitive fields, and generate secure data access results to return to the user.
[0122] Optionally, the aforementioned execution entity may respond to a data access request received from a user terminal by generating a secure data access result based on the aforementioned access control policy table through the following steps: The first step is to respond to the data access request sent by the user and perform a permission query on the access control policy table to generate the query results.
[0123] The query result can be a mapping table, where the key is the field name and the value is the transformation type (such as NONE, MASK_ID_CARD, DENY).
[0124] As an example, the aforementioned execution entity can parse the list of fields in the user request, combine it with the current user role, and query the transformation instructions for each field in the access control policy table one by one.
[0125] The second step is to convert the query results obtained above into data anonymized results by calling the desensitization function.
[0126] The aforementioned de-identification functions can be used to transform sensitive data so that it remains usable without revealing the original information. These de-identification functions may include, but are not limited to: maskIdCard() (retaining the first 6 characters and last 4 characters of the ID card number), maskPhone() (retaining the first 3 characters and last 4 characters of the phone number), maskEmail() (retaining the first 2 characters of the email address prefix and the domain name), and maskSalary() (replacing all with *).
[0127] The third step is to return the data anonymization results to the user terminal to generate secure data access results.
[0128] As an example, the aforementioned executing entity can encapsulate the data anonymization results into a JDBC ResultSet or JSON format and send it to the requesting client via a database protocol or HTTP protocol.
[0129] Further reference Figure 3 As an implementation of the methods shown in the above figures, this disclosure provides some embodiments of a data security processing device based on sensitive data identification. These device embodiments are similar to... Figure 2 Corresponding to the method embodiments shown, this data security processing device based on sensitive data identification can be specifically applied to various electronic devices.
[0130] like Figure 3As shown, a data security processing device 300 based on sensitive data identification in some embodiments includes: a connection unit 301, a first generation unit 302, a sampling unit 303, a second generation unit 304, a third generation unit 305, a fourth generation unit 306, and a fifth generation unit 307. The system comprises the following components: a connection unit 301, configured to connect to the acquired target data source set via a connection pool to generate a data source connection pool instance, wherein the data source types of the target data sources in the target data source set are different; a first generation unit 302, configured to generate a three-level structured data directory object based on the data source connection pool instance; a sampling unit 303, configured to sample data from the three-level structured data directory object to generate a sampled query string set; a second generation unit 304, configured to generate a two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set, wherein the number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns in the two-dimensional numerical feature matrix represents the feature dimension; a third generation unit 305, configured to generate a sensitive marker record object set based on the two-dimensional numerical feature matrix; a fourth generation unit 306, configured to generate an access control policy table based on the sensitive marker record object set and a preset permission policy template; and a fifth generation unit 307, configured to generate a secure data access result in response to a data access request received from a user terminal, based on the access control policy table.
[0131] It is understandable that the units described in the data security processing device 300 based on sensitive data identification are related to the reference. Figure 2 The steps in the described method correspond to each other. Therefore, the operations, features, and beneficial effects described above for the method also apply to the data security processing device 300 based on sensitive data identification and the units contained therein, and will not be repeated here.
[0132] The following is for reference. Figure 4 It shows a schematic diagram of the structure of an electronic device 400 (e.g., a computing device) suitable for implementing some embodiments of the present disclosure. Figure 4 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of the embodiments of this disclosure.
[0133] like Figure 4As shown, the electronic device 400 may include a processing unit 401 (e.g., a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 402 or a program loaded from a storage device 408 into a random access memory (RAM) 403. The RAM 403 also stores various programs and data required for the operation of the electronic device 400. The processing unit 401, ROM 402, and RAM 403 are interconnected via a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.
[0134] Typically, the following devices can be connected to I / O interface 405: input devices 406 including, for example, touchscreens, touchpads, keyboards, mice, cameras, microphones, accelerometers, gyroscopes, etc.; output devices 407 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 408 including, for example, magnetic tapes, hard disks, etc.; and communication devices 409. Communication device 409 allows electronic device 400 to communicate wirelessly or wiredly with other devices to exchange data. Although Figure 4 An electronic device 400 with various devices is shown; however, it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed alternatively. Figure 4 Each box shown can represent a device or multiple devices as needed.
[0135] In particular, according to some embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, some embodiments of this disclosure include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication device 409, or installed from storage device 408, or installed from ROM 402. When the computer program is executed by processing device 401, it performs the functions defined above in the methods of some embodiments of this disclosure.
[0136] It should be noted that, in some embodiments of this disclosure, the computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium may be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In some embodiments of this disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In some embodiments of this disclosure, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (radio frequency), etc., or any suitable combination thereof.
[0137] In some implementations, clients and servers can communicate using any currently known or future-developed network protocol such as HTTP (Hypertext Transfer Protocol) and can interconnect with digital data communication (e.g., communication networks) of any form or medium. Examples of communication networks include local area networks (“LANs”), wide area networks (“WANs”), the Internet (e.g., the Internet of Things), and peer-to-peer networks (e.g., ad hoc peer-to-peer networks), as well as any currently known or future-developed networks.
[0138] The aforementioned computer-readable medium may be included in the aforementioned electronic device; or it may exist independently and not assembled into the electronic device. The aforementioned computer-readable medium carries one or more programs that, when executed by the electronic device, cause the electronic device to: connect to a connection pool of the acquired target data source set to generate a data source connection pool instance, wherein the data source types of each target data source in the target data source set are different; generate a three-level structured data directory object based on the data source connection pool instance; sample data from the three-level structured data directory object to generate a sampled query string set; generate a two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set, wherein the number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns in the two-dimensional numerical feature matrix represents the feature dimension; generate a set of sensitive marked record objects based on the two-dimensional numerical feature matrix; generate an access control policy table based on the set of sensitive marked record objects and a preset permission policy template; and generate a secure data access result based on the access control policy table in response to receiving a data access request from a user terminal.
[0139] Computer program code for performing operations of some embodiments of this disclosure can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, and conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0140] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this disclosure. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0141] The functions described above in this document can be performed at least in part by one or more hardware logic components. For example, exemplary types of hardware logic components that can be used, without limitation, include: field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), system-on-a-chip (SoCs), complex programmable logic devices (CPLDs), and so on.
[0142] The above description is merely a selection of preferred embodiments of this disclosure and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of the invention involved in the embodiments of this disclosure is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the above-described inventive concept. For example, technical solutions formed by substituting the above-described features with (but not limited to) technical features with similar functions disclosed in the embodiments of this disclosure.
Claims
1. A data security processing method based on sensitive data identification, characterized in that, include: Connecting to the acquired target data source set using a connection pool to generate a data source connection pool instance, wherein the data source types of the target data sources in the target data source set are different, and the process of connecting to the acquired target data source set using a connection pool to generate a data source connection pool instance includes: Configure connection parameters for each target data source in the acquired target data source set to generate target data source connection parameters, thus obtaining the target data source connection parameter set; Based on the target data source connection parameter set, the connection pool is initialized for each target data source in the obtained target data source set to generate a data source connection pool instance containing each target data source. Based on the data source connection pool instance, a three-level structured data directory object is generated, wherein the three-level structured data directory object includes: a database layer, a table layer, and a field layer; Data is sampled from the three-level structure data directory object to generate a set of sampled query strings; A two-dimensional numerical feature matrix is generated based on the data source connection pool instance and the sampled query string set, wherein the number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns in the two-dimensional numerical feature matrix represents the feature dimension. The generation of the two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set includes: Based on the data source connection pool instance, obtain the pre-compiled object corresponding to each sampled query string in the sampled query string set to obtain the pre-compiled object set; The precompiled object set is traversed to generate a list of raw string samples; The length features of the original string sample list are determined to generate a list of string length numerical features; For each original string sample in the original string sample list, the character composition ratio is determined to generate the proportion of numbers, the proportion of letters, and the proportion of special characters. The proportion of numbers, the proportion of letters, and the proportion of special characters are determined as numerical composition features to obtain a set of numerical composition features. Sensitive data validation is performed on each original string sample in the original string sample list to generate sensitive data Boolean features, thus obtaining a sensitive data Boolean feature set; The string length numerical feature list, the numerical composition feature set, and the sensitive data Boolean feature set are horizontally concatenated according to the sample dimensions to generate a fixed-dimensional feature vector set; The fixed-dimensional feature vector set is stacked vertically to generate a two-dimensional numerical feature matrix; A set of sensitive marked record objects is generated based on the two-dimensional numerical feature matrix, wherein generating the set of sensitive marked record objects based on the two-dimensional numerical feature matrix includes: The two-dimensional numerical feature matrix is subjected to standardization preprocessing to generate a standardized feature matrix; The standardized feature matrix is input into a pre-trained ensemble sensitive recognition model to generate a predicted label and confidence score for each sample, thereby obtaining the predicted label and confidence score for each sample. The ensemble sensitive recognition model includes: a first base model, a second base model, a third base model, and a fusion output layer. For each sample's predicted label and confidence score, perform the following processing steps: The predicted labels and the confidence scores are aggregated to generate a field summary sensitive label and a field average confidence score. Feature vectors are extracted from the fields corresponding to the aforementioned sensitive tags to obtain context feature vectors; Forward reasoning is performed on the context feature vector to generate false positive correction results; The false alarm correction results and the field summary sensitive labels are flagged to generate a final confirmation label and a false alarm correction flag; The final confirmation label, the false alarm correction flag, the average confidence level of the field, and the current timestamp are combined to generate a sensitive marker record object; Each of the obtained sensitive marker record objects is identified as a sensitive marker record object set; Based on the set of sensitive marker records and the preset permission policy template, an access control policy table is generated; In response to receiving a data access request from a user, a secure data access result is generated based on the access control policy table.
2. The method according to claim 1, characterized in that, The step of generating a three-level structured data directory object based on the data source connection pool instance includes: Active connections are acquired for the data source connection pool instance to generate a set of physical database connection objects corresponding to each target data source; For each physical database connection object in the physical database connection object set, a database metadata interface call is made to generate a metadata information group, resulting in a metadata information group set. The metadata information group set includes: a database name list, a field metadata list, and a table name list. The field metadata list includes: field name, data type, and numeric type. The metadata information set is assembled into a tree structure to generate a three-level structured data directory object.
3. The method according to claim 1, characterized in that, The step of sampling data from the three-level structure data directory object to generate a set of sampled query strings includes: The three-level structure data directory object is traversed to generate a list of field paths to be sampled; Each field path in the list of field paths to be sampled is parsed to generate a field triplet, resulting in a set of field triplets, wherein the field triplet includes: database name, table name, and field name; For each field triple in the set of field triples, a sampling statement is constructed to generate a sampling query string, resulting in a set of sampling query strings.
4. The method according to claim 1, characterized in that, The step of generating an access control policy table based on the sensitive marker record object set and the preset permission policy template includes: For each sensitive marker record object in the set of sensitive marker record objects, perform the following steps: The sensitive field paths and sensitivity levels of the sensitive marked record objects are extracted to generate sensitive field paths and sensitivity levels; By using the preset permission policy template, policy matching is performed on the sensitivity level to obtain the access control policy group; The obtained access control policy groups are integrated into an access control policy table.
5. The method according to claim 1, characterized in that, The step of responding to a data access request received from a user terminal and generating a secure data access result based on the access control policy table includes: In response to receiving a data access request from a user, the access control policy table is queried to generate query results; By calling the desensitization function, the query results are converted into desensitized data results; The data anonymization result is returned to the user terminal to generate a secure data access result.
6. A data security processing device based on sensitive data identification, characterized in that, include: A connection unit is configured to perform connection pooling on the acquired target data source set to generate a data source connection pool instance. The data source types of the target data sources in the target data source set are different. The process of performing connection pooling on the acquired target data source set to generate a data source connection pool instance includes: configuring connection parameters for each target data source in the acquired target data source set to generate target data source connection parameters, thus obtaining a target data source connection parameter set; and initializing the connection pool for each target data source in the acquired target data source set according to the target data source connection parameter set to generate a data source connection pool instance containing each target data source. The first generation unit is configured to generate a three-level structured data directory object based on the data source connection pool instance, wherein the three-level structured data directory object includes: a database layer, a table layer, and a field layer; The sampling unit is configured to sample data from the three-level structure data directory object to generate a set of sampled query strings; The second generation unit is configured to generate a two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set, wherein the number of rows in the two-dimensional numerical feature matrix represents the number of samples, and the number of columns in the two-dimensional numerical feature matrix represents the feature dimension. Generating the two-dimensional numerical feature matrix based on the data source connection pool instance and the sampled query string set includes: obtaining a pre-compiled object corresponding to each sampled query string in the sampled query string set based on the data source connection pool instance, thus obtaining a pre-compiled object set; traversing the pre-compiled object set to generate an original string sample list; determining the length feature of the original string sample list to generate a string length numerical feature list; and further determining the length feature of the sampled query string set. Each original string sample in the original string sample list has its character composition ratio determined to generate the proportion of numbers, letters, and special characters. The proportions of numbers, letters, and special characters are then defined as numerical composition features to obtain a numerical composition feature set. Sensitive data validation is performed on each original string sample in the original string sample list to generate sensitive data Boolean features, resulting in a sensitive data Boolean feature set. The string length numerical feature list, the numerical composition feature set, and the sensitive data Boolean feature set are horizontally concatenated according to the sample dimensions to generate a fixed-dimensional feature vector set. The fixed-dimensional feature vector set is then vertically stacked to generate a two-dimensional numerical feature matrix. The third generation unit is configured to generate a set of sensitive-labeled record objects based on the two-dimensional numerical feature matrix. This generation includes: performing a standardization preprocessing on the two-dimensional numerical feature matrix to generate a standardized feature matrix; inputting the standardized feature matrix into a pre-trained ensemble sensitive identification model to generate a predicted label and confidence score for each sample, thereby obtaining the predicted label and confidence score for each sample. The ensemble sensitive identification model includes a first base model, a second base model, a third base model, and a fusion output layer. For each sample's predicted label and confidence score, the following processing is performed: Processing steps: Perform field aggregation on the predicted labels and the confidence scores to generate a field summary sensitive label and a field average confidence score; extract feature vectors from the fields corresponding to the field summary sensitive labels to obtain context feature vectors; perform forward inference on the context feature vectors to generate false positive correction results; determine the flags of the false positive correction results and the field summary sensitive labels to generate a final confirmation label and a false positive correction flag; combine the final confirmation label, the false positive correction flag, the field average confidence score, and the current timestamp to generate sensitive marker record objects; determine the obtained sensitive marker record objects as a sensitive marker record object set. The fourth generation unit is configured to generate an access control policy table based on the sensitive marker record object set and the preset permission policy template. The fifth generation unit is configured to generate a secure data access result in response to receiving a data access request from a user terminal, based on the access control policy table.
7. An electronic device, characterized in that, include: One or more processors; A storage device on which one or more programs are stored; When the one or more programs are executed by the one or more processors, the one or more processors implement the method as described in any one of claims 1 to 5.
8. A computer-readable medium, characterized in that, It stores a computer program thereon, wherein the computer program, when executed by a processor, implements the method as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Data asset classification modeling and grading protection method based on artificial intelligence technology
CN113590698A
Integrated metadata management method and system based on data source expandability
CN119576863A
