A file data encryption method for enterprise office systems

By analyzing the text data of office documents in the enterprise office system, calculating the importance index of non-stop words and paragraphs, and calculating the sensitivity index in combination with the difference between files, dynamically adjusting the finite domain parameters of the encryption algorithm, the existing technology is solved The problems of encryption security and inefficiency achieve efficient protection of adaptive encryption.

CN119066684BActive Publication Date: 2025-02-07QIFEI BIG DATA (SHANDONG) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411545098.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-01
Publication Date
2025-02-07
Estimated Expiration
2044-11-01

AI Technical Summary

Technical Problem

When encrypting file data in corporate office systems, the use of a single parameter method leads to insecurity and inefficiency in encryption, and it is impossible to effectively protect the importance of different degrees of privacy of different files.

Method used

By analyzing the text data of each office document, the first importance index of non-stop words and the second importance index of paragraphs are determined, the sensitivity index is calculated based on the difference between files, and the finite domain parameters of the encryption algorithm are dynamically adjusted to achieve self-important Adapt to encryption.

Benefits of technology

It improves the encryption security and efficiency of different office documents, and realizes targeted encryption processing based on the different degrees of privacy importance of the file content.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119066684B_ABST
    Figure CN119066684B_ABST
Patent Text Reader

Abstract

The present application relates to the field of data encryption technology, and specifically to a file data encryption method for an enterprise office system, the method comprising: based on the proportion of all highly sensitive words in each paragraph in the text data of each office document among all non-stop words in the corresponding paragraph, and the similarity at the semantic level between any two sentences in each paragraph, combined with the distance of each paragraph to all table data and all image data, determine the second importance index of each paragraph in the text data of each office document, and determine the sensitivity index of each office document in combination with the difference between each office document and other office documents, so as to encrypt each office document. The present application determines the encryption degree of different office documents by analyzing the importance of different subwords in office documents, thereby improving the security and efficiency of encrypting different office documents.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data encryption technology, and in particular to a file data encryption method for an enterprise office system. Background Art

[0002] With the continuous development of enterprise informatization, a large amount of sensitive information exists in the form of electronic documents. The characteristics of electronic documents such as easy operation, easy copying and reusability make the electronic file data of enterprise offices easy to spread, becoming a major hidden danger to enterprise data security. In order to ensure the security of sensitive information of enterprises, in addition to adopting network security measures such as deploying firewalls at network entrances and exits, there are also some necessary physical isolation and rules and regulations, as well as data information management methods based on encryption technology.

[0003] Elliptic curve encryption algorithms are often used in the field of data encryption due to their high security. In the process of encrypting corporate file data, conventional methods use a single parameter for encryption. However, corporate office file data information is diverse, including company policies, meeting record reports, project plans, financial statements, and technical specification documents, etc. Different files have different degrees of privacy importance. If only fixed parameters are used to encrypt corporate files, the security and efficiency of file encryption will be reduced. Summary of the invention

[0004] In order to solve the above technical problems, the present application provides a file data encryption method for an enterprise office system to solve the existing problems.

[0005] The present application adopts the following technical solution for a file data encryption method for an enterprise office system:

[0006] An embodiment of the present application provides a file data encryption method for an enterprise office system, the method comprising the following steps:

[0007] Obtain all table data, all image data, and all non-stop words in the text data and their respective semantic vectors for each office document in the enterprise office system;

[0008] Determine the first importance index of each non-stop word in the text data of each office document according to the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where the non-stop word is located, the similarity of the semantic vectors of each non-stop word in the sentence where the non-stop word is located, and the frequency of occurrence of each non-stop word in the corresponding text data;

[0009] Clustering the first importance indexes of all non-stop words in the text data of each office document to obtain multiple clusters, and recording all non-stop words corresponding to the first importance index in the cluster with the largest first importance index as highly sensitive words;

[0010] Based on the similarity at the semantic level between any two sentences in each paragraph in the text data of each office document, the semantic similarity of each paragraph in the text data of each office document is determined, and combined with the proportion of all highly sensitive words in each paragraph in the text data of each office document in all non-stop words in the corresponding paragraph, and the distance of each paragraph to all table data and all image data, the second importance index of each paragraph in the text data of each office document is determined;

[0011] The difference degree of each office document is determined based on the difference between each office document and other office documents, and the sensitivity index of each office document is determined in combination with the second importance index of all paragraphs in the text data of each office document; the approximate value of the finite field parameter of each office document is determined based on the sensitivity index, and each office document is encrypted in combination with the encryption algorithm.

[0012] Preferably, the method for determining the first importance index of each non-stop word in the text data of each office document is:

[0013] Determine the information importance of each non-stop word in the text data of each office document based on the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where it is located, the similarity of the semantic vectors of each non-stop word and the other non-stop words in the sentence where it is located, and the frequency of occurrence of each non-stop word in the corresponding text data;

[0014] The first importance index of each non-stop word in the text data of each office document is a result of merging the information importance of each non-stop word in the text data of each office document with the word frequency-inverse document frequency.

[0015] Preferably, the expression of the information importance of each non-stop word in the text data of each office document is: ; In the formula, represents the information importance of the i-th non-stop word in the text data of the x-th office document; represents the difference in the corresponding order of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; represents the sum of the word frequencies of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; Represents the similarity between the semantic vectors of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; Represents the number of all non-stop words in the sentence containing the i-th non-stop word in the text data of the x-th office document.

[0016] Preferably, the method for determining the semantic similarity of each paragraph in the text data of each office document is:

[0017] The semantic vectors of all non-stop words in each sentence in the text data of each office document are averaged in each dimension to form the sentence meaning vector of each sentence;

[0018] The semantic similarity of each paragraph in the text data of each office document is the cumulative sum of the sentence meaning vectors of any two sentences in each paragraph in the text data of each office document.

[0019] Preferably, the method for determining the second importance index of each paragraph in the text data of each office document is:

[0020] The ratio of the number of all highly sensitive words in each paragraph in the text data of each office document to all non-stop words in the corresponding paragraph is recorded as the ratio of highly sensitive words in each paragraph in the text data of each office document;

[0021] Determine a first distance between each paragraph in the text data of each office document based on the distance between each paragraph in the text data of each office document and all the table data and all the image data;

[0022] Based on the proportion of highly sensitive words, the semantic similarity, and the first distance, a second importance index of each paragraph in the text data of each office document is determined.

[0023] Preferably, the method for determining the first distance of each paragraph in the text data of each office document is:

[0024] Obtain the enclosing rectangles of all the paragraphs in all the table data, all the image data and the text data of each office document, wherein the first distance of each paragraph in the text data of each office document is the cumulative sum of the distances from the upper left vertex of the enclosing rectangle of each paragraph in the text data of each office document to the upper left vertex of the enclosing rectangle of all the table data and all the image data.

[0025] Preferably, the expression of the second importance index of each paragraph in the text data of each office document is: ; In the formula, , , , They respectively represent the second importance index, the proportion of highly sensitive words, the semantic similarity, and the first distance of the kth paragraph in the text data of the xth office document.

[0026] Preferably, the method for determining the degree of difference of each office document is:

[0027] Each office document is used as an input of the fingerprint generation algorithm to obtain the fingerprint of each office document. The difference degree of each office document is the average of the differences between the fingerprint of each office document and the fingerprints of all other office documents.

[0028] Preferably, the sensitivity index of each office document is the ratio of the sum of the second importance indexes of all paragraphs in the text data of each office document to the degree of difference.

[0029] Preferably, the determining of the approximate value of the finite field parameter of each office document and encrypting each office document in combination with an encryption algorithm further comprises:

[0030] The expression for the approximate value of the finite field parameter of each office document is: ; In the formula, represents the approximate value of the finite field parameter of the x-th office document; Indicates the sensitivity index of the xth office document; represents an exponential function with a natural constant as base; , All are preset constants greater than 0;

[0031] The text data of the office document to be encrypted is encoded, and the encoded data is used as the input of the encryption algorithm, wherein the prime number closest to the approximate value of the finite field parameter is used as the finite field parameter of the encryption algorithm when the corresponding office document is encrypted, and the encrypted office document is output.

[0032] This application has at least the following beneficial effects:

[0033] The present application determines the first importance index of each non-stop word in the text data of each office document based on the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where it is located, the similarity between the semantic vectors of each non-stop word and the other non-stop words in the sentence where it is located, and the frequency of occurrence of each non-stop word in the corresponding text data, thereby achieving a division of the importance of all non-stop words in the text data of the office document.

[0034] This application determines the second importance index of each paragraph in the text data of each office document based on the proportion of all highly sensitive words in each paragraph in all non-stop words in the corresponding paragraph, and the similarity at the semantic level between any two sentences in each paragraph, combined with the distance of each paragraph to all table data and all image data, so as to further limit the importance of non-stop words; based on the difference between each office document and other office documents, combined with the second importance index of all paragraphs in the text data of each office document, the sensitivity index of each office document is determined to realize the adaptive encryption function of the encryption algorithm for different office documents.

[0035] The present application determines the encryption degree of different office documents by analyzing the importance of different subwords in the office documents, and allocates adaptive finite field parameters to different office documents, thereby improving the security and encryption efficiency of different office documents. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present application or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0037] Figure 1 A flowchart of a method for encrypting file data in an enterprise office system provided by an embodiment of the present application;

[0038] Figure 2 A flowchart of extracting the second important index provided by one embodiment of the present application;

[0039] Figure 3 A schematic diagram of a finite field parameter approximation value extraction process provided for one embodiment of the present application. DETAILED DESCRIPTION

[0040] In order to further explain the technical means and effects adopted by the present application to achieve the predetermined invention purpose, the following is a detailed description of the file data encryption method for an enterprise office system proposed in accordance with the present application, its specific implementation method, structure, features and effects, in combination with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.

[0041] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs.

[0042] The following is a detailed description of a specific solution of a file data encryption method for an enterprise office system provided by the present application in conjunction with the accompanying drawings.

[0043] An embodiment of the present application provides a file data encryption method for an enterprise office system. Specifically, the following file data encryption method for an enterprise office system is provided. Figure 1 , the method comprises the following steps:

[0044] Step S1: Obtain text data, table data and image data of each office document in the enterprise office system; obtain all non-stop words in the text data of each office document and their respective semantic vectors.

[0045] The corporate office files include a variety of data types. The files involved in this embodiment are all in the form of electronic documents, which can be divided into text data, table data and image data. Each type of data corresponds to a layout element, which may belong to the company's private information.

[0046] First, it is necessary to distinguish the various layout elements in the office document. Therefore, each office document is used as the input of the convolutional recurrent neural network model to identify the various layout elements in the office document, and each layout element in each office document has a corresponding enclosing rectangular box. The loss function of the convolutional recurrent neural network model is set to the CTC loss function, and the optimization model is the gradient descent (SGD) model. The text data, table data and image data in each office document are output, as well as the enclosing rectangular boxes of each paragraph in the text data, the enclosing rectangular boxes of all table data and the enclosing rectangular boxes of all image data.

[0047] Among them, the working principles of the convolutional recurrent neural network model, CTC loss function and gradient descent model are all well-known technologies, and the specific process of the convolutional recurrent neural network operation will not be repeated here.

[0048] Furthermore, because the semantic information of text data in corporate office data is a key factor in assessing the sensitivity of files, the text data in each office document is used as the input of the BERT word segmentation model, and all subwords and their respective semantic vectors of all text data in each office document after word segmentation are output. The semantic vector of each subword contains not only the meaning of the word itself, but also the semantic information of the context.

[0049] Among them, the process of word segmentation processing of text data by the BERT word segmentation model is a well-known technology, and the specific process will not be repeated here.

[0050] Step S2: Determine the first importance index of each non-stop word in the text data of each office document based on the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where it is located, the similarity between the semantic vectors of each non-stop word and the other non-stop words in the sentence where it is located, and the frequency of occurrence of each non-stop word in the corresponding text data.

[0051] S201: Determine the information importance of each non-stop word in the text data of each office document based on the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where it is located, the similarity between the semantic vectors of each non-stop word and the other non-stop words in the sentence where it is located, and the frequency of occurrence of each non-stop word in the corresponding text data.

[0052] Corporate office documents may contain some high-frequency subwords, which may reveal topics and content that are frequently discussed or concerned in the documents, and some of these subwords may be associated with sensitive information. For example, corporate documents may frequently contain subwords related to finance, customer information, business strategies, etc. The information referred to by these subwords may be considered sensitive information and needs to be properly encrypted.

[0053] (1) First, in order to determine the importance of non-stop words and thus protect sensitive and confidential information, we can count the frequency of occurrence of each subword in the office document to determine whether the corresponding subword belongs to confidential information. Specifically:

[0054] The jieba library of Python is used to remove stop words from all subwords in each office document, that is, to remove words that appear frequently in the text but have little meaning, such as prepositions, pronouns, conjunctions, etc., to obtain all non-stop words in each office document after preprocessing.

[0055] Furthermore, the TF-IDF algorithm is used to perform word frequency statistics on subwords in office documents. All non-stop words in the text data of each office document are used as input to the TF-ITD algorithm, and the word frequency (TF) and word frequency-inverse document frequency (TF-IDF) of each identical non-stop word in the text data of each office document are output.

[0056] (2) Furthermore, among all non-stop words in the text data of office documents, high-frequency subwords that still appear more frequently may belong to sensitive information of corporate documents. However, the frequency of non-stop words in text data alone is not sufficient to support that high-frequency non-stop words belong to sensitive confidential information. Therefore, by further analyzing the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where it is located, and the similarity between the semantic vectors of each non-stop word and the other non-stop words in the sentence where it is located, the probability that a non-stop word is sensitive confidential information is measured from the perspective of position difference and semantic similarity. Specifically:

[0057] The expression of the information importance of each non-stop word in the text data of each office document is: ; In the formula, represents the information importance of the i-th non-stop word in the text data of the x-th office document; represents the difference in the corresponding order of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; represents the sum of the word frequencies of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; Represents the similarity between the semantic vectors of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; Represents the number of all non-stop words in the sentence containing the i-th non-stop word in the text data of the x-th office document.

[0058] Among them, regarding the method of measuring the difference between the orders of non-stop words, in this embodiment, the difference between the orders of non-stop words is measured by calculating the absolute value of the difference between the orders of two non-stop words. The implementer may also use other methods of measuring the difference such as ratio. Regarding the method of measuring the difference between the orders of non-stop words, this embodiment does not make any special restrictions.

[0059] In addition, regarding the calculation of the similarity between the semantic vectors of non-stop words, this embodiment measures the similarity between the semantic vectors of non-stop words by calculating the cosine similarity between the semantic vectors of non-stop words in different orders. As other implementation methods, the implementer can also measure the similarity between the semantic vectors by calculating the inverse of the Euclidean distance between the semantic vectors. This embodiment does not impose any special restrictions on the method of measuring the similarity between semantic vectors.

[0060] Furthermore, according to the information importance of each non-stop word in each office document, it can be understood that the smaller the order difference between two non-stop words in the same sentence in the text data, the closer the two non-stop words are and the stronger their syntactic dependency may be; the larger the sum of the word frequencies of the two non-stop words in the same sentence, the higher the frequency of the corresponding two non-stop words in the text data; the greater the similarity between the semantic vectors of two non-stop words of different orders in the same sentence, the closer the semantic information of the two non-stop words is, and finally the greater the importance of each non-stop word, that is, the greater the information importance of each non-stop word; conversely, if the order difference between the two non-stop words in the same sentence in the text data is greater, the smaller the sum of the word frequencies of the two non-stop words in the same sentence, and the smaller the similarity between the semantic vectors of two non-stop words of different orders in the same sentence, the smaller the information importance of each non-stop word is.

[0061] S202: Determine a first importance index of each non-stop word in the text data of each office document based on the information importance of each non-stop word in the text data of each office document and the frequency information of the corresponding non-stop word appearing in the text data.

[0062] In order to further define the importance of non-stop words in text data, the information importance of each non-stop word in each office document is fused with the result of word frequency-inverse document frequency as the first importance index of each non-stop word in each office document.

[0063] Preferably, in the present embodiment, the first importance index of each non-stop word in the text data of each office document is the product of the information importance of each non-stop word in the text data of each office document and the word frequency-inverse document probability. In actual application, as another implementation method, the first importance index of each non-stop word in the text data of each office document is an exponential function value with a natural constant as the base and the sum of the information importance of each non-stop word in the text data of each office document and the word frequency-inverse document probability as the independent variable.

[0064] Information importance reflects the importance of non-stop words in the text data of office documents through semantic information, contextual relevance, and the frequency of each non-stop word in the same sentence in the text data, while word frequency inverse document frequency reflects the importance of non-stop words in the text data of office documents through frequency information. Therefore, the greater the information importance of non-stop words, the higher the frequency of non-stop words in the text data, and the larger the first importance index of non-stop words, indicating that the corresponding non-stop words are more important and sensitive information.

[0065] Step S3: Based on the proportion of all highly sensitive words in each paragraph in the text data of each office document among all non-stop words in the corresponding paragraph, and the similarity between any two sentences in each paragraph at the semantic level, combined with the distance from each paragraph to all table data and all image data, determine the second importance index of each paragraph in the text data of each office document.

[0066] In the corporate office system, the data with high sensitivity includes the following parts, such as internal core management data, market operation data, equipment identification, etc. These data will contain more tables and images. Therefore, in the vicinity of table data or image data in office documents, the sensitivity of non-stop words in text data is usually relatively high. In addition, sensitive words in corporate office data may appear in some files or some paragraphs in the files. Therefore, the importance of text data can be analyzed in combination with the distribution status of sensitive words in the file.

[0067] Therefore, by analyzing the distance information between non-stop words with higher sensitivity and image data and table data in office documents, the importance of non-stop words is further defined, specifically:

[0068] (1) First, the first importance index of all non-stop words in the text data of each office document is used as the input of the clustering algorithm, and multiple clusters are output. All non-stop words corresponding to the first importance index in the cluster with the largest first importance index are recorded as highly sensitive words.

[0069] (2) Furthermore, the importance of highly sensitive words is determined by analyzing the proportion of highly sensitive words in all non-stop words in a paragraph. Specifically, the ratio of the number of all highly sensitive words in each paragraph in the text data of each office document to all non-stop words in the corresponding paragraph is recorded as the proportion of highly sensitive words in each paragraph in the text data of each office document.

[0070] (3) In addition, the semantic similarity features between different sentences in text data can further reflect the degree of relevance of the text content.

[0071] Therefore, firstly, the sentence meaning vector of the sentence is constructed based on the semantic vector of the non-stop words, specifically: the average of each dimension in the semantic vector of all non-stop words in each sentence in the text data of each office document is calculated respectively, and recorded as the sentence meaning vector of each sentence in the text data of each office document;

[0072] Furthermore, the cumulative sum of the similarities of the sentence meaning vectors of any two sentences in each paragraph in the text data of each office document is analyzed, and recorded as the semantic similarity of each paragraph in the text data of each office document.

[0073] It should be noted that there are many methods to measure the similarity between vectors. In this embodiment, the similarity between sentence meaning vectors is measured by calculating the cosine similarity of the sentence meaning vectors of all pairwise sentence combinations in each paragraph. As another implementation method, the implementer may also measure the similarity between sentence meaning vectors by calculating the inverse of the Euclidean distance between the sentence meaning vectors. This embodiment does not impose any special restrictions.

[0074] The calculation process of cosine similarity is a well-known technology, and its specific calculation process will not be repeated here.

[0075] (4) Furthermore, since the sensitivity of non-stop words in text data is usually relatively high in the vicinity of table data or image data in office documents, the distance between each paragraph and the table data or image data in the text data of each office document is analyzed to select the text data to be encrypted. Specifically:

[0076] A rectangular coordinate system is constructed with the upper left corner of the first page of each office document as the origin, and the cumulative distance from the upper left vertex of the enclosing rectangular box of each paragraph in the text data of each office document to the upper left vertex of the enclosing rectangular box of all table data and all image data is analyzed, and recorded as the first distance of each paragraph in the text data of each office document.

[0077] It should be noted that, in the calculation process of the above-mentioned first distance, the first distance is obtained by calculating the distance from the upper left vertex of the enclosing rectangular box of the paragraph to the upper left vertex of the enclosing rectangular box of all table data and image data. This is only a specific implementation method in this embodiment. In actual application, the implementer may also choose the upper right vertex, lower right vertex or lower left vertex to calculate the first distance. This embodiment does not impose any special restrictions.

[0078] It should be understood that there are many methods for calculating distance. In this embodiment, the first distance is measured by calculating the Manhattan distance between the upper left vertex of the enclosing rectangular box of the paragraph and the upper left vertex of the enclosing rectangular box of all table data and the upper left vertex of the enclosing rectangular box of all image data. The implementer may also use other methods for calculating distance such as Euclidean distance, and this embodiment does not impose any special restrictions.

[0079] The calculation process of Manhattan distance is a well-known technology and is not particularly limited in this embodiment.

[0080] (5) Further, according to the proportion of highly sensitive words in each paragraph in the text data of each office document, the semantic similarity of each paragraph, and the first distance of each paragraph, the second importance index of each paragraph in the text data of each office document is determined, specifically:

[0081] The expression of the second importance index of each paragraph in the text data of each office document is: ; In the formula, represents the second importance index of the kth paragraph in the text data of the xth office document; represents the proportion of highly sensitive words in the kth paragraph of the text data of the xth office document; represents the semantic similarity of the kth paragraph in the text data of the xth office document; Indicates the first distance of the k-th paragraph in the text data of the x-th office document.

[0082] If there is no table data and image data in the office document, the first distance is set to a first preset value.

[0083] It should be noted that the value of the first preset value is artificially set in order to prevent the first distance from being 0. Therefore, a larger value is set to reduce the value of the second importance index so as not to affect the subsequent calculation effect. In this embodiment, the value of the first preset value is The implementer can also set it according to the specific situation, and this embodiment does not impose any special restrictions.

[0084] Furthermore, according to the second importance index of each paragraph in the text data of each office document, it can be understood that the greater the proportion of highly sensitive words in the paragraph in the text data, the greater the semantic similarity, and the smaller the first distance, indicating that the degree of appearance of the highly sensitive word set is higher, the content described by the corresponding paragraph is closer and the sensitivity of the described content is higher, and the second importance index of the corresponding paragraph is larger; conversely, the smaller the proportion of highly sensitive words in the paragraph in the text data, the smaller the semantic similarity, and the larger the first distance, indicating that the degree of appearance of the highly sensitive word set is lower, the content described by the corresponding paragraph is less closely related and the sensitivity of the described content is lower, and the second importance index of the corresponding paragraph is smaller.

[0085] Preferably, the second important index extraction flow chart provided in this embodiment is as follows: Figure 2 shown.

[0086] Step S4: Based on the difference between each office document and other office documents, combined with the second importance index of all paragraphs in the text data of each office document, the sensitivity index of each office document is determined.

[0087] Different departments of an enterprise may store different types of sensitive files. Some files will be circulated between departments and contain cross-information between departments. This cross-information has a certain degree of privacy.

[0088] Therefore, in order to analyze the degree of information overlap between files, each office document is used as the input of the Simhash algorithm, and the fingerprint of each office document (i.e., Simhash value) is output.

[0089] The fingerprint is a binary number of a fixed length, and the Simhash algorithm is a well-known technology, and the specific process of obtaining the fingerprint of each office document is not described in detail.

[0090] Furthermore, based on the difference between each office document and other office documents, combined with the second importance index of all paragraphs in the text data of each office document, the sensitivity index of each office document is determined, specifically:

[0091] Analyze the difference between the fingerprint of each office document and the fingerprints of all other office documents and take the average value, which is recorded as the degree of difference of each office document;

[0092] The expression of the sensitivity index of each office document is: ; In the formula, Indicates the sensitivity index of the xth office document; represents the cumulative sum of the second importance indexes of all paragraphs in the text data of the x-th office document; Indicates the degree of difference of the xth office document.

[0093] It should be noted that there are many ways to measure differences. In this embodiment, the Hamming distance between the fingerprint of each office document and the fingerprints of other office documents is calculated to measure the differences between different office document fingerprints, thereby further measuring the differences between different office documents. Implementers can also use other methods of measuring differences such as Euclidean distance and Manhattan distance based on specific circumstances. This embodiment does not impose any special restrictions.

[0094] The calculation process of the Hamming distance is a well-known technology, and its specific calculation process will not be repeated here.

[0095] Furthermore, according to the sensitivity index of each office document, it can be understood that the greater the difference between the fingerprints of different office documents, the greater the difference between the different office documents, and the larger the cumulative sum of the second importance indexes of all paragraphs in the text data, which means that the importance of the corresponding text data is greater, the more strict encryption is required, and ultimately the sensitivity index of each office document will be greater; conversely, the smaller the difference between the fingerprints of different office documents, the smaller the difference between the different office documents, and the smaller the cumulative sum of the second importance indexes of all paragraphs in the text data, which means that the importance of the corresponding text data is smaller, and ultimately the sensitivity index of each office document will be smaller.

[0096] Step S5: Encrypt each office document based on the sensitivity index of each office document in combination with an encryption algorithm.

[0097] This embodiment analyzes the text semantic information of files in the enterprise office system, combines the distribution characteristics of text near sensitive table data and image data in enterprise files, and considers the cross-features of file contents between departments to calculate the sensitivity index of each file. The sensitivity index reflects the privacy importance of the file to the enterprise to a certain extent.

[0098] This embodiment uses the elliptic curve cryptography (ECC) algorithm to encrypt enterprise files. During the encryption process, the higher the sensitivity index of a file, the greater the privacy importance. The larger the finite field parameter in the ECC algorithm should be set to provide higher security. For files with a lower sensitivity index, the privacy importance is relatively low. In this case, the finite field parameter in the ECC algorithm can be reduced to provide a faster encryption rate. The specific encryption process is as follows:

[0099] First, determine the finite field parameters of the encryption algorithm. Specifically, the expression of the approximate value of the finite field parameters of each office document is: ; In the formula, represents the approximate value of the finite field parameter of the x-th office document; Indicates the sensitivity index of the xth office document; represents an exponential function with a natural constant as the base; where, , are all preset constants greater than 0, and are used to limit the range of the approximate value of the finite field parameter of each office document.

[0100] Preferably, the schematic diagram of the finite field parameter approximation extraction process provided in this embodiment is as follows: Figure 3 shown.

[0101] Furthermore, the text data of the office document to be encrypted is encoded using UTF-8 technology to obtain encoded data, and the encoded data is used as input to the elliptic curve encryption algorithm. Since the finite field parameter is a prime number, the prime number closest to the approximate value of the finite field parameter of each office document is used as the finite field parameter of the encryption algorithm when encrypting the corresponding office document, and the encrypted office document is output.

[0102] It should be understood that in order to ensure the security of encryption technology, the value of the finite field parameter is preferably not less than 163. A smaller finite field parameter may provide insufficient security against modern attacks. In this embodiment, in order to ensure relatively high security while maintaining encryption efficiency, the approximate value of the finite field parameter is set to about 200. Therefore, as an implementation method, in this embodiment , The values ​​of are set to 160 and 80 respectively. This can also be set according to the specific situation. This embodiment does not impose any special restrictions. In addition, The 1 and exponential function are used to ensure normalization.

[0103] Among them, UTF-8 technology and elliptic curve encryption algorithm are well-known technologies in the encoding field and encryption field respectively, and the specific encoding and encryption process will not be described in detail.

[0104] At this point, this embodiment analyzes the importance of different sub-words in office documents to judge the privacy importance of office documents and determine the sensitivity index of different office documents. It combines the elliptic curve encryption algorithm to perform corresponding levels of encryption processing on office documents of different sensitivities, thereby ensuring encryption security while providing higher encryption efficiency.

[0105] It should be noted that the above sequence of the embodiments of the present application is for description only and does not represent the advantages and disadvantages of the embodiments. The above is a description of a specific embodiment of this specification. In addition, the processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0106] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referenced to each other, and each embodiment focuses on the differences from other embodiments.

[0107] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Modifications to the technical solutions recorded in the aforementioned embodiments, or equivalent replacement of some of the technical features therein, do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.

Claims

1. A file data encryption method for an enterprise office system, characterized in that: The method comprises the following steps: Obtain all table data, all image data, and all non-stop words in the text data and their respective semantic vectors for each office document in the enterprise office system; Determine the first importance index of each non-stop word in the text data of each office document according to the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where the non-stop word is located, the similarity of the semantic vectors of each non-stop word in the sentence where the non-stop word is located, and the frequency of occurrence of each non-stop word in the corresponding text data; Clustering the first importance indexes of all non-stop words in the text data of each office document to obtain multiple clusters, and recording all non-stop words corresponding to the first importance index in the cluster with the largest first importance index as highly sensitive words; Based on the similarity at the semantic level between any two sentences in each paragraph in the text data of each office document, the semantic similarity of each paragraph in the text data of each office document is determined, and combined with the proportion of all highly sensitive words in each paragraph in the text data of each office document in all non-stop words in the corresponding paragraph, and the distance of each paragraph to all table data and all image data, the second importance index of each paragraph in the text data of each office document is determined; Determine the degree of difference of each office document based on the difference between each office document and other office documents, and determine the sensitivity index of each office document in combination with the second importance index of all paragraphs in the text data of each office document; determine the approximate value of the finite field parameter of each office document based on the sensitivity index, and encrypt each office document in combination with the encryption algorithm; The sensitivity index of each office document is the ratio of the sum of the second importance indexes of all paragraphs in the text data of each office document to the degree of difference; The step of determining the approximate value of the finite field parameter of each office document and encrypting each office document in combination with an encryption algorithm further includes: The expression for the approximate value of the finite field parameter of each office document is: ; In the formula, represents the approximate value of the finite field parameter of the x-th office document; represents the sensitivity index of the xth office document; represents an exponential function with a natural constant as base; , All are preset constants greater than 0; The text data of the office document to be encrypted is encoded, and the encoded data is used as the input of the encryption algorithm, wherein the prime number closest to the approximate value of the finite field parameter is used as the finite field parameter of the encryption algorithm when the corresponding office document is encrypted, and the encrypted office document is output.

2. A file data encryption method for an enterprise office system as claimed in claim 1, characterized in that: The method for determining the first importance index of each non-stop word in the text data of each office document is: Determine the information importance of each non-stop word in the text data of each office document based on the difference in the corresponding order of each non-stop word in the text data of each office document and the other non-stop words in the sentence where it is located, the similarity of the semantic vectors of each non-stop word and the other non-stop words in the sentence where it is located, and the frequency of occurrence of each non-stop word in the corresponding text data; The first importance index of each non-stop word in the text data of each office document is a result of merging the information importance of each non-stop word in the text data of each office document with the word frequency-inverse document frequency.

3. A file data encryption method for an enterprise office system as claimed in claim 2, characterized in that: The expression of the information importance of each non-stop word in the text data of each office document is: ; In the formula, represents the information importance of the i-th non-stop word in the text data of the x-th office document; represents the difference in the corresponding order of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; represents the sum of the word frequencies of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; Represents the similarity between the semantic vectors of the i-th non-stop word in the text data of the x-th office document and the j-th non-stop word in the sentence in which it is located; Represents the number of all non-stop words in the sentence containing the i-th non-stop word in the text data of the x-th office document.

4. A file data encryption method for an enterprise office system as claimed in claim 1, characterized in that: The method for determining the semantic similarity of each paragraph in the text data of each office document is as follows: The semantic vectors of all non-stop words in each sentence in the text data of each office document are averaged in each dimension to form the sentence meaning vector of each sentence; The semantic similarity of each paragraph in the text data of each office document is the cumulative sum of the sentence meaning vectors of any two sentences in each paragraph in the text data of each office document.

5. The file data encryption method for an enterprise office system as claimed in claim 1, characterized in that: The method for determining the second importance index of each paragraph in the text data of each office document is as follows: The ratio of the number of all highly sensitive words in each paragraph in the text data of each office document to all non-stop words in the corresponding paragraph is recorded as the ratio of highly sensitive words in each paragraph in the text data of each office document; Determine a first distance between each paragraph in the text data of each office document based on the distance between each paragraph in the text data of each office document and all the table data and all the image data; Based on the proportion of highly sensitive words, the semantic similarity, and the first distance, a second importance index of each paragraph in the text data of each office document is determined.

6. A file data encryption method for an enterprise office system as claimed in claim 5, characterized in that: The method for determining the first distance of each paragraph in the text data of each office document is: Obtain the enclosing rectangles of all the paragraphs in all the table data, all the image data and the text data of each office document, wherein the first distance of each paragraph in the text data of each office document is the cumulative sum of the distances from the upper left vertex of the enclosing rectangle of each paragraph in the text data of each office document to the upper left vertex of the enclosing rectangle of all the table data and all the image data.

7. A file data encryption method for an enterprise office system as claimed in claim 5, characterized in that: The expression of the second importance index of each paragraph in the text data of each office document is: ; In the formula, , , , They respectively represent the second importance index, the proportion of highly sensitive words, the semantic similarity, and the first distance of the kth paragraph in the text data of the xth office document.

8. The file data encryption method for an enterprise office system as claimed in claim 1, characterized in that: The method for determining the degree of difference of each office document is as follows: Each office document is used as an input of the fingerprint generation algorithm to obtain the fingerprint of each office document. The difference degree of each office document is the average of the differences between the fingerprint of each office document and the fingerprints of all other office documents.

Citation Information

Patent Citations

  • Document secret level automatic recognition method

    CN106845265A

  • Text clustering method for open source security intelligence

    CN115687960A