A text encryption method and device

By splitting the target text into characters, forming a character ring and encrypting, the problem of limitations in the selection of search terms in the prior art is solved, and flexible matching and high security of encrypted text are achieved.

CN114611119BActive Publication Date: 2025-03-07BEIJING VRV SOFTWARE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210072851.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-21
Publication Date
2025-03-07
Estimated Expiration
2042-01-21

AI Technical Summary

Technical Problem

In the prior art, when selecting search terms in different encrypted batches for searching, the encrypted search terms cannot match the ciphertext, and the selection of search terms is very limited.

Method used

By splitting the target text into characters, selecting a subset of the matching encoding format, arranging the characters to form a character ring, and encrypting the text characters based on the character ring and offset to form a spliced ​​encrypted text.

Benefits of technology

The arbitrary selection of search terms can be matched with the ciphertext, so that the encrypted text still exists in the encoding format that matches the target text, improving the flexibility and security of encryption.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114611119B_ABST
    Figure CN114611119B_ABST
Patent Text Reader

Abstract

The present invention provides a text encryption method and device, wherein the method comprises: splitting a target text to obtain characters of the target text; selecting a first subset of the encoding format matched by the target text; arranging the characters in the first subset to obtain a first character ring of the first subset; encrypting the characters of the target text based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters; splicing the encrypted characters to obtain an encrypted text corresponding to the target text. By encrypting each character of the target text through the first character ring and the corresponding first offset, the encrypted text can still exist in the encoding format matched by the target text, and any selected search term can be successfully matched with the encrypted text corresponding to the target text after encryption.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data encryption, and in particular to a text encryption method and device. Background Art

[0002] With the rapid development of the Internet, network security has become a focus of attention. Since network threats launch malicious attacks on the Internet, the information stored in the database may be leaked. Based on this, encrypting the text information stored in the database can effectively prevent information leakage.

[0003] The current encryption method is to encrypt text data in batches according to a fixed length. This method has certain defects: for example, if the search term is not selected in the same encryption batch, the encrypted search term cannot be matched with the ciphertext, and the selection of search terms in this encryption method is very limited. Summary of the invention

[0004] The present invention provides a text encryption method and device, which are used to solve the defect in the prior art that search terms are selected in different encryption batches for retrieval, making it impossible to match the search terms with ciphertexts, and can achieve matching of any selected search terms with ciphertexts.

[0005] In a first aspect, the present invention provides a text encryption method, comprising: splitting a target text to obtain characters of the target text; selecting a first subset of an encoding format that matches the target text; arranging the characters in the first subset to obtain a first character ring of the first subset; encrypting the characters of the target text based on the first character ring and a corresponding first offset to obtain corresponding encrypted characters; and concatenating the encrypted characters to obtain an encrypted text corresponding to the target text.

[0006] According to the text encryption method provided by the present invention, arranging the characters in the first subset to obtain the first character ring of the first subset includes: converting the characters in the first subset into digital codes; and arranging the characters in the first subset based on the arrangement rules of the digital codes to obtain the first character ring.

[0007] According to the text encryption method provided by the present invention, the characters of the target text are encrypted based on the first character ring and the corresponding first offset to obtain the corresponding encrypted characters, including: judging whether the characters of the target text exist on the first character ring; if the characters of the target text exist on the first character ring, determining the encrypted characters corresponding to the characters of the target text on the first character ring according to the first offset; if the characters of the target text do not exist on the first character ring, the characters of the target text are the encrypted characters corresponding to the characters of the target text.

[0008] According to the text encryption method provided by the present invention, after the encrypted characters are concatenated to obtain the encrypted text corresponding to the target text, the method further includes: splitting the encrypted text into the encrypted characters; judging whether the encrypted characters exist on the first character ring; if the encrypted characters exist on the first character ring, determining the characters of the target text corresponding to the encrypted characters on the first character ring based on the opposite number of the first offset; if the encrypted characters do not exist on the first character ring, the encrypted characters are the characters of the target text corresponding to the encrypted characters; concatenating the characters of the target text to obtain the target text, and displaying the target text.

[0009] According to the text encryption method provided by the present invention, after encrypting the characters of the target text based on the first character ring and the corresponding first offset to obtain the encrypted characters, the method further includes: selecting a second subset of the encoding format matching the target text; arranging the characters in the second subset to obtain a second character ring of the second subset; encrypting the encrypted characters based on the second character ring and the corresponding second offset to obtain new encrypted characters; accordingly, concatenating the encrypted characters to obtain the encrypted text corresponding to the target text includes: concatenating the new encrypted characters to obtain the new encrypted text corresponding to the target text.

[0010] According to the text encryption method provided by the present invention, before encrypting the characters of the target text based on the first character ring and the corresponding first offset, it also includes: setting the first offset; before encrypting the encrypted characters based on the second character ring and the corresponding second offset, it also includes: setting the second offset.

[0011] In the second aspect, the present invention also provides a text encryption device, comprising: a splitting module, used to split the target text to obtain the characters of the target text; a selection module, used to select a first subset of the encoding format matching the target text; an arrangement module, used to arrange the characters in the first subset to obtain a first character ring of the first subset; an encryption module, used to encrypt the characters of the target text based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters; a splicing module, used to splice the encrypted characters to obtain the encrypted text corresponding to the target text.

[0012] In a third aspect, an embodiment of the present invention further provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of the text encryption method described in the first aspect are implemented.

[0013] In a fourth aspect, an embodiment of the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the text encryption method as described in the first aspect.

[0014] In a fifth aspect, an embodiment of the present invention further provides a computer program product having executable instructions stored thereon, which, when executed by a processor, enables the processor to implement the steps of the text encryption method as described in the first aspect.

[0015] The text encryption method and device provided by the present invention splits the target text to obtain the characters of the target text; selects the first subset of the encoding format matched by the target text; arranges the characters in the first subset to obtain the first character ring of the first subset; encrypts the characters of the target text based on the first character ring and the corresponding first offset to obtain the corresponding encrypted characters; and concatenates the encrypted characters to obtain the encrypted text corresponding to the target text. By encrypting each character of the target text through the first character ring and the corresponding first offset, the encrypted text can still exist in the encoding format matched by the target text, and any selected search term can be successfully matched with the encrypted text corresponding to the target text after encryption. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0017] Figure 1 A schematic diagram of a flow chart of an embodiment of a text encryption method provided by the present invention;

[0018] Figure 2 A schematic diagram of a flow chart of an embodiment of a method for obtaining a first character ring provided by the present invention;

[0019] Figure 3 A schematic diagram of the first character ring provided by the present invention;

[0020] Figure 4 A schematic diagram of a flow chart of an embodiment of a character encryption method provided by the present invention;

[0021] Figure 5 A schematic diagram of the structure of an embodiment of a text encryption device provided by the present invention;

[0022] Figure 6 An example physical structure diagram of an electronic device is provided. DETAILED DESCRIPTION

[0023] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0024] Figure 1 The following is a flow chart of an embodiment of the text encryption method provided by the present invention. Figure 1 As shown, the text encryption method may include the following steps:

[0025] S101, split the target text to obtain characters of the target text.

[0026] S102, selecting a first subset of encoding formats that matches the target text.

[0027] In step S102, the encoding format can be regarded as a dictionary, which can be utf8, gbk, or gd2313. The embodiment of the present invention does not limit the encoding format. The encoding format including the target text is the encoding format matched by the target text.

[0028] S103, arranging the characters in the first subset to obtain a first character ring of the first subset.

[0029] In step S103, the characters in the first subset may be continuous characters or discontinuous characters, which is not limited in the embodiment of the present invention.

[0030] S104: Encrypt characters of the target text based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters.

[0031] In step S104, the first offset may be a non-zero value, such as 2, 4, or -2. A positive first offset represents a clockwise offset, and a negative first offset represents a counterclockwise offset. If the first offset is 2, it represents a clockwise offset of two positions; if the first offset is -2, it represents a counterclockwise offset of two positions.

[0032] S105, concatenating the encrypted characters to obtain the encrypted text corresponding to the target text.

[0033] In step S105, strcat or sprintf may be used to concatenate encrypted characters, and the present invention does not limit the concatenation method of encrypted characters. The encrypted characters are concatenated according to the arrangement order of the characters in the preset encoding format obtained by splitting to obtain the encrypted text corresponding to the target text.

[0034] The text encryption method provided by the embodiment of the present invention splits the target text to obtain the characters of the target text; selects the first subset of the encoding format that matches the target text; arranges the characters in the first subset to obtain the first character ring of the first subset; encrypts the characters of the target text based on the first character ring and the corresponding first offset to obtain the corresponding encrypted characters; and concatenates the encrypted characters to obtain the encrypted text corresponding to the target text. By encrypting each character of the target text through the first character ring and the corresponding first offset, the encrypted text can still exist in the encoding format, and any selected search term can be successfully matched with the encrypted text corresponding to the target text after encryption.

[0035] Figure 2 This is a flow chart of an embodiment of the method for obtaining the first character ring provided by the present invention. Figure 2 As shown, the method for obtaining the first character ring may include the following steps:

[0036] S201, converting characters in the first subset into digital codes.

[0037] In step S201, since the characters in the first subset are characters in a coded format, the characters in the coded format may be converted into corresponding digital codes, such as binary codes or decimal codes, which is not limited in this embodiment of the present invention.

[0038] S202: Arrange the characters in the first subset based on the arrangement rule of the digital code to obtain a first character ring.

[0039] In step S202, the characters in the first subset may be arranged according to the size of the digital codes of the characters in the first subset so that they are connected end to end to form a first character ring, which may be denoted as Char Ring. The characters in the first subset may be characters with continuous digital codes or characters with discontinuous digital codes, which is not limited in the embodiment of the present invention.

[0040] The Char Ring may consist of one binary range, or may consist of multiple binary ranges, which is not limited in the embodiment of the present invention. Figure 3As shown, the Char Ring consists of multiple binary ranges such as 0x0100-0x02ff, 0x1000-0x12ff, 0x1500-0x1aff, and 0xb100-0xb1ff.

[0041] The method for obtaining a character ring provided by the present invention can quickly obtain the corresponding first character ring by arranging the characters in the first subset according to the arrangement order of the digital codes.

[0042] Figure 4 The following is a flow chart of an embodiment of the character encryption method provided by the present invention. Figure 4 As shown, the character encryption method may include the following steps:

[0043] S401, determining whether characters of the target text exist on the first character ring.

[0044] S402: If the characters of the target text exist on the first character ring, determine the encrypted characters corresponding to the characters of the target text on the first character ring according to the first offset.

[0045] S403: If the character of the target text does not exist on the character ring, the character of the target text is the encrypted character corresponding to the character of the target text.

[0046] In step S401 to step S403, first determine whether the characters of the target text exist on the first character ring; if the characters of the target text exist on the first character ring, locate the characters of the target text on the first character ring, and search for the encrypted characters corresponding to the characters of the target text on the first character ring based on the located characters and the first offset. For example, when the characters of the target text are located on the first character ring, since the first offset is 2, then the located position is used as the starting point, and the characters at the position are offset by two positions in the clockwise direction, and the characters found are the encrypted characters of the located characters. For another example, when the characters of the target text are located on the first character ring, since the first offset is -2, then the located position is used as the starting point, and the characters at the position are offset by two positions in the counterclockwise direction, and the characters found are the encrypted characters of the located characters.

[0047] If the character of the target text does not exist in the first character ring, the character of the target text is used as the encrypted character of the character.

[0048] The character encryption method provided by the embodiment of the present invention can make the encrypted characters still exist in the encoding format by searching for encrypted characters on the first character ring or using characters of the target text as encrypted characters. The search terms can be arbitrarily selected to encrypt them, so that the encrypted search terms can be successfully matched with the encrypted characters.

[0049] In some optional embodiments, after encrypting the characters of the target text based on the first character ring and the corresponding first offset to obtain the encrypted characters, it may also include: selecting a second subset of the encoding format matching the target text; arranging the characters in the second subset to obtain a second character ring of the second subset; encrypting the encrypted characters based on the second character ring and the corresponding second offset to obtain new encrypted characters; accordingly, splicing the encrypted characters to obtain the encrypted text corresponding to the target text may include: splicing the new encrypted characters to obtain the new encrypted text corresponding to the target text.

[0050] The first subset and the second subset may be the same or different, and the embodiment of the present invention does not make a selection. The second offset and the first offset may be the same or different, and the embodiment of the present invention does not limit this. The encrypted characters are encrypted again based on the second character ring and the second offset to obtain new encrypted characters. According to the steps of the second encryption, the new encrypted characters can also be encrypted for a third time and more times, and the embodiment of the present invention does not limit the number of encryptions. The final encrypted characters are spliced ​​to obtain a new encrypted text corresponding to the target text.

[0051] The embodiment provided by the present invention can improve the encryption strength of the encrypted text and improve the encryption security by encrypting the encrypted characters multiple times to obtain the encrypted text.

[0052] In some optional embodiments, before encrypting the characters of the target text based on the first character ring and the corresponding first offset, it may also include: setting the first offset; before encrypting the encrypted characters based on the second character ring and the corresponding second offset, it may also include: setting the second offset.

[0053] In some optional embodiments, the target text is encrypted to obtain an encrypted text and stored in a database. When the encrypted text receives a viewing request, the encrypted text needs to be decrypted and displayed in the form of the target text. The decryption process may include:

[0054] If the encrypted text is encrypted once, split the encrypted text into encrypted characters; determine whether the encrypted character exists on the first character ring; if the encrypted character exists on the first character ring, determine the character of the target text corresponding to the encrypted character on the first character ring based on the opposite number of the first offset; if the encrypted character does not exist on the first character ring, the encrypted character is the character of the target text corresponding to the encrypted character; concatenate the characters of the target text to obtain the target text, and display the target text; if the encrypted text is encrypted multiple times, based on the above decryption steps, decrypt in order from the last encryption to the first encryption, determine the character of the target text corresponding to the encrypted character, and concatenate the characters to obtain the target text.

[0055] Figure 5 The following is a schematic diagram of the structure of the text encryption device embodiment provided by the present invention. Figure 5 As shown, the text encryption device comprises:

[0056] The splitting module 501 is used to split the target text to obtain characters of the target text;

[0057] A selection module 502 is used to select a first subset of encoding formats that match the target text;

[0058] An arrangement module 503, configured to arrange the characters in the first subset to obtain a first character ring of the first subset;

[0059] An encryption module 504 is used to encrypt characters of the target text based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters;

[0060] The concatenation module 505 is used to concatenate the encrypted characters to obtain the encrypted text corresponding to the target text.

[0061] Optionally, the arrangement module 503 includes:

[0062] An acquisition unit, used for converting characters in the first subset into digital codes;

[0063] The arrangement unit is used to arrange the characters in the first subset based on the arrangement rule of the digital code to obtain a first character ring.

[0064] Optionally, the encryption module 504 includes:

[0065] A judging unit, used for judging whether the characters of the target text exist on the first character ring;

[0066] A first determining unit, configured to determine, if the character of the target text exists on the first character ring, an encrypted character corresponding to the character of the target text on the first character ring according to a first offset;

[0067] The second determining unit is used for determining, if the character of the target text does not exist in the first character ring, that the character of the target text is an encrypted character corresponding to the character of the target text.

[0068] Optionally, the splitting module 501 is further used to split the encrypted text into encrypted characters;

[0069] A decryption module, used to determine whether the encrypted character exists on the first character ring; if the encrypted character exists on the first character ring, determine the character of the target text corresponding to the encrypted character on the first character ring based on the opposite number of the first offset; if the encrypted character does not exist on the first character ring, the encrypted character is the character of the target text corresponding to the encrypted character;

[0070] The splicing module 505 is also used to splice the characters of the target text to obtain the target text and display the target text.

[0071] Optionally, the selection module 502 is further configured to select a second subset of encoding formats that matches the target text;

[0072] The arrangement module 503 is further used to arrange the characters in the second subset to obtain a second character ring of the second subset;

[0073] The encryption module 504 is further used to encrypt the encrypted character based on the second character ring and the corresponding second offset to obtain a new encrypted character;

[0074] The splicing module 505 is also used to splice the new encrypted characters to obtain a new encrypted text corresponding to the target text.

[0075] Optionally, the text encryption device further includes:

[0076] The setting module is used to set the first offset and the second offset.

[0077] Figure 6 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 6 As shown, the electronic device may include: a processor 601, a communications interface 602, a memory 603 and a communication bus 604, wherein the processor 601, the communications interface 602 and the memory 603 communicate with each other via the communication bus 604. The processor 601 may call the logic instructions in the memory 603 to execute the following text encryption method:

[0078] The target text is split to obtain characters of the target text; a first subset of the encoding format matching the target text is selected; the characters in the first subset are arranged to obtain a first character ring of the first subset; the characters of the target text are encrypted based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters; the encrypted characters are concatenated to obtain an encrypted text corresponding to the target text.

[0079] In addition, the logic instructions in the above-mentioned memory 603 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.

[0080] On the other hand, an embodiment of the present invention further provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions, and when the program instructions are executed by a computer, the computer can execute the text encryption method provided in the above embodiments:

[0081] The target text is split to obtain characters of the target text; a first subset of the encoding format matching the target text is selected; the characters in the first subset are arranged to obtain a first character ring of the first subset; the characters of the target text are encrypted based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters; the encrypted characters are concatenated to obtain an encrypted text corresponding to the target text.

[0082] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to execute the text encryption method provided in the above embodiments:

[0083] The target text is split to obtain characters of the target text; a first subset of the encoding format matching the target text is selected; the characters in the first subset are arranged to obtain a first character ring of the first subset; the characters of the target text are encrypted based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters; the encrypted characters are concatenated to obtain an encrypted text corresponding to the target text.

[0084] The device embodiments described above are merely illustrative, wherein the modules described as separate components may or may not be separated from the second, and the components displayed as modules may or may not be the second modules, that is, they may be located in one place, or they may be distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without paying creative labor.

[0085] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods of each embodiment or some parts of the embodiment.

[0086] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A text encryption method, characterized in that: include: Splitting the target text to obtain characters of the target text; Selecting a first subset of encoding formats that matches the target text; Arranging the characters in the first subset to obtain a first character ring of the first subset; Encrypting characters of the target text based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters; Concatenating the encrypted characters to obtain an encrypted text corresponding to the target text; After encrypting the characters of the target text based on the first character ring and the corresponding first offset to obtain the corresponding encrypted characters, the method further includes: Selecting a second subset of encoding formats that matches the target text; Arranging the characters in the second subset to obtain a second character ring of the second subset; Encrypting the encrypted character based on the second character ring and the corresponding second offset to obtain a new encrypted character; Correspondingly, the step of concatenating the encrypted characters to obtain the encrypted text corresponding to the target text includes: The new encrypted characters are concatenated to obtain a new encrypted text corresponding to the target text.

2. The text encryption method according to claim 1, characterized in that: The step of arranging the characters in the first subset to obtain a first character ring of the first subset includes: Converting characters in the first subset into digital codes; The characters in the first subset are arranged based on the arrangement rule of the digital code to obtain the first character ring.

3. The text encryption method according to claim 1, characterized in that: The step of encrypting the characters of the target text based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters includes: Determining whether the characters of the target text exist on the first character ring; If the character of the target text exists on the first character ring, determining the encryption character corresponding to the character of the target text on the first character ring according to the first offset; If the characters of the target text do not exist on the first character ring, the characters of the target text are encrypted characters corresponding to the characters of the target text.

4. The text encryption method according to claim 1, characterized in that: After the encrypted characters are concatenated to obtain the encrypted text corresponding to the target text, the method further includes: Splitting the encrypted text into the encrypted characters; Determining whether the encrypted character exists on the first character ring; If the encrypted character exists on the first character ring, determining the character of the target text corresponding to the encrypted character on the first character ring based on the inverse of the first offset; If the encrypted character does not exist on the first character ring, the encrypted character is the character of the target text corresponding to the encrypted character; The characters of the target text are concatenated to obtain the target text, and the target text is displayed.

5. The text encryption method according to claim 1, characterized in that: Before encrypting the characters of the target text based on the first character ring and the corresponding first offset, the method further includes: Setting the first offset; Before encrypting the encrypted character based on the second character ring and the corresponding second offset, the method further includes: Set the second offset.

6. A text encryption device, characterized in that: include: A splitting module is used to split the target text to obtain characters of the target text; A selection module, used for selecting a first subset of encoding formats matching the target text; an arrangement module, configured to arrange the characters in the first subset to obtain a first character ring of the first subset; An encryption module, used for encrypting characters of the target text based on the first character ring and the corresponding first offset to obtain corresponding encrypted characters; A concatenation module, used for concatenating the encrypted characters to obtain an encrypted text corresponding to the target text; The selection module is further used to select a second subset of encoding formats matching the target text; The arrangement module is further used to arrange the characters in the second subset to obtain a second character ring of the second subset; The encryption module is further used to encrypt the encrypted character based on the second character ring and the corresponding second offset to obtain a new encrypted character; The splicing module is also used to splice the new encrypted characters to obtain a new encrypted text corresponding to the target text.

7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the steps of the text encryption method as described in any one of claims 1 to 5 are implemented.

8. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the text encryption method as described in any one of claims 1 to 5 are implemented.

9. A computer program product having executable instructions stored thereon, characterized in that: When the instruction is executed by the processor, the processor implements the steps of the text encryption method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Ciphertext processing method and device, equipment and storage medium

    CN113221173A

  • Lightweight text rapid encryption and decryption method

    CN113935051A