Data encryption and decryption method, system, device, medium and program product
By deploying encryption/decryption containers and applications on Kubernetes, and using the sidecar pattern to dynamically select encryption/decryption algorithms and keys independently of application code, the security issues of data encryption/decryption across different languages are resolved, improving the security and efficiency of data encryption/decryption.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HUNAN FUMI INFORMATION TECH CO LTD
- Filing Date
- 2022-03-07
- Publication Date
- 2026-05-29
AI Technical Summary
In existing technologies, data encryption methods rely on encryption algorithms of programming languages. This can lead to different code maintainers for different languages, increasing the risk of algorithm exposure and reducing data security.
The sidecar pattern is used to deploy encryption and decryption containers and applications on Kubernetes. Data encryption and decryption are performed using multiple encryption and decryption algorithms and preset keys in the encryption and decryption containers, independently of the application code, and the target encryption and decryption algorithm and key are dynamically selected for encryption and decryption operations.
It reduces the development cost of multi-language implementation of data encryption and decryption, enhances the security of encryption and decryption algorithms, controls access permissions to the algorithms, and improves the security of data encryption/decryption.
Smart Images

Figure CN116781291B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of data processing technology, and in particular to a data encryption / decryption method, system, device, medium, and program product. Background Technology
[0002] As enterprise systems become increasingly complex, the demands for data security protection are also rising. To improve the security and confidentiality of information systems and data, and to prevent confidential data from being deciphered by external parties, it is necessary to encrypt and store core data. However, because different systems are implemented using different programming languages, different data encryption and decryption algorithms need to be developed. Furthermore, if the core encryption algorithm is not sufficiently secure, the encryption algorithm used may be exposed to individuals with code access, increasing security risks.
[0003] In existing related technologies, data encryption methods are implemented through algorithms built into program code or by relying on third-party certificates. Data is encrypted using an encryption algorithm and an encryption key before being stored. The reader queries the encrypted data and uses a decryption key to decrypt the ciphertext, restoring it to plaintext. This method relies on the encryption algorithm of the programming language, and this algorithm is publicly available to developers. The code maintainers may differ across languages, increasing the risk of algorithm exposure and revealing algorithm details to more people, thus increasing security vulnerabilities. Summary of the Invention
[0004] To overcome the problems existing in related technologies, this disclosure provides a data encryption / decryption method, system, device, medium, and program product.
[0005] According to a first aspect of the present disclosure, a data encryption / decryption method is provided, comprising:
[0006] The encryption / decryption function container receives encryption / decryption requests sent by the application execution container. The encryption / decryption function container and the application execution container are pre-deployed on the node. The encryption / decryption request includes data to be encrypted / decrypted. The application execution container includes an application program. The encryption / decryption function container includes multiple encryption / decryption algorithms.
[0007] The encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from a plurality of encryption / decryption algorithms according to pre-configured environment variables;
[0008] The encrypted / decrypted data is returned to the application execution container.
[0009] In some embodiments, before the encryption / decryption function container receives the encryption / decryption request sent by the application execution container, the method further includes:
[0010] Based on the sidecar pattern, the application is deployed as an application pod on the Kubernetes node, and the multiple encryption and decryption algorithms are deployed as encryption and decryption sidecars on the Kubernetes node. The application pod is the application execution container, and the encryption and decryption sidecar is the encryption and decryption function container.
[0011] In some embodiments, before encrypting / decrypting the data based on the target encryption / decryption algorithm and a preset key, the method further includes:
[0012] The encryption / decryption function container reads the environment variables, wherein the environment variables include configuration information, and the configuration information corresponds to an encryption / decryption algorithm;
[0013] The corresponding encryption and decryption algorithm is selected from the plurality of encryption and decryption algorithms based on the configuration information.
[0014] In some embodiments, the plurality of encryption and decryption algorithms are implemented in a plurality of different programming languages and / or correspond to a plurality of different types of systems.
[0015] In some embodiments, encrypting / decrypting the data based on the target encryption / decryption algorithm and a preset key includes:
[0016] The key is obtained from the preset key management system, and the encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and the preset key.
[0017] In some embodiments, the sidecar-based deployment of the application as an application pod on the node's Kubernetes cluster, and the deployment of the multiple encryption / decryption algorithms as encryption / decryption sidecars on the node's Kubernetes cluster, includes:
[0018] Create a deploymen resource on the Kubernetes cluster. The deploymen resource contains two containers: one container deploys the application and serves as the application pod, and the other container deploys the multiple encryption and decryption algorithms and serves as the encryption and decryption sidecar.
[0019] Configure the environment variables used by the encryption / decryption sidecar.
[0020] According to a second aspect of the present disclosure, a data encryption / decryption system is provided, comprising an encryption / decryption function container and an application execution container, wherein:
[0021] The encryption / decryption function container receives encryption / decryption requests sent by the application execution container. The encryption / decryption function container and the application execution container are pre-deployed on the node. The encryption / decryption request includes data to be encrypted / decrypted. The application execution container includes an application program. The encryption / decryption function container includes multiple encryption / decryption algorithms.
[0022] The encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from a plurality of encryption / decryption algorithms according to pre-configured environment variables;
[0023] The encrypted / decrypted data is returned to the application execution container.
[0024] An embodiment of the third aspect of this application provides an electronic device, including a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set, or an instruction set, the instruction, the program, the code set, or the instruction set being loaded and executed by the processor to implement the data encryption and decryption method provided by the embodiment of the first aspect of this application described above.
[0025] An embodiment of the fourth aspect of this application provides a non-transitory computer-readable storage medium, which, when the instructions in the storage medium are executed by the processor of a mobile terminal, enables the mobile terminal to perform the steps of the data encryption / decryption method provided in the embodiment of the first aspect of this application described above.
[0026] An embodiment of the fifth aspect of this application provides a computer program product that, when the instructions in the computer program product are executed by the processor of a mobile terminal, enables the mobile terminal to perform steps implementing the data encryption / decryption method provided in the embodiment of the first aspect of this application described above.
[0027] The technical solutions provided by the embodiments of this disclosure may include the following beneficial effects: The encryption and decryption function container developed by this application based on the sidecar pattern reduces the development cost of data encryption and decryption in multiple languages. At the same time, it separates the encryption and decryption algorithms, so that the key, encryption and decryption algorithm and application code are isolated from each other, and the access permissions of the algorithm are controlled to the minimum, thereby enhancing the strength of the encryption and decryption algorithm and improving the security of data encryption / decryption.
[0028] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0029] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0030] Figure 1 This is a flowchart illustrating a data encryption / decryption method according to an exemplary embodiment.
[0031] Figure 2 This is a block diagram illustrating a data encryption / decryption system according to an exemplary embodiment.
[0032] Figure 3 This is a block diagram illustrating the connection between a data encryption / decryption system and a key management system according to an exemplary embodiment.
[0033] Figure 4 An internal structural diagram of an electronic device is shown according to an exemplary embodiment. Detailed Implementation
[0034] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatuses and methods consistent with some aspects of the invention as detailed in the appended claims.
[0035] The following describes a data encryption / decryption method, system, device, medium, and program product according to an embodiment of the present invention, with reference to the accompanying drawings.
[0036] Figure 1 This is a flowchart illustrating a data encryption / decryption method according to an exemplary embodiment, such as... Figure 1 As shown, it includes the following steps:
[0037] In step S101, the encryption / decryption function container receives an encryption / decryption request sent by the application execution container. The encryption / decryption function container and the application execution container are pre-deployed on the node. The encryption / decryption request includes data to be encrypted / decrypted. The application execution container includes an application program. The encryption / decryption function container includes multiple encryption / decryption algorithms.
[0038] Specifically, when data needs to be encrypted or decrypted, the execution container starts and sends an encryption / decryption request to the encryption / decryption function container, where " / " represents "or". The encryption / decryption request includes the data to be encrypted / decrypted, and the encryption / decryption function container includes multiple encryption / decryption algorithms. These algorithms are used to encrypt / decrypt the data contained in the encryption / decryption request.
[0039] In some embodiments, before the encryption / decryption function container receives the encryption / decryption request sent by the application execution container, the method further includes:
[0040] Based on the sidecar pattern, the application is deployed as an application pod on the Kubernetes node, and the multiple encryption and decryption algorithms are deployed as encryption and decryption sidecars on the Kubernetes node. The application pod is the application execution container, and the encryption and decryption sidecar is the encryption and decryption function container.
[0041] Specifically, a sidecar is a design pattern that decouples application functionality from the application itself as a separate process. This allows for non-intrusive addition of features to the application, avoiding the need to add extra code to meet third-party requirements. Furthermore, a sidecar is essentially an independent program providing a universal interface that can be called by different languages to obtain the necessary information, without requiring different languages to implement the functionality. This interface is essentially a local method call, eliminating the performance overhead of network transmission. Kubernetes, on the other hand, is an open-source container orchestration engine from Google that supports automated deployment, large-scale scalability, and containerized application management. When deploying an application in a production environment, multiple instances of the application are typically deployed to load balance application requests.
[0042] Therefore, the sidecar pattern allows you to deploy the application, i.e. the application execution container, onto the Kubernetes node, while simultaneously deploying multiple encryption / decryption algorithms, i.e. encryption / decryption function containers, onto the Kubernetes node.
[0043] Furthermore, the method of deploying the application as an application pod on the Kubernetes node based on the sidecar pattern, and deploying the multiple encryption / decryption algorithms as encryption / decryption sidecars on the Kubernetes node, includes:
[0044] Create a deploymen resource on the Kubernetes cluster. The deploymen resource contains two containers: one container deploys the application and serves as the application pod, and the other container deploys the multiple encryption and decryption algorithms and serves as the encryption and decryption sidecar.
[0045] Configure the environment variables used by the encryption / decryption sidecar.
[0046] Specifically, by creating a deploymen resource on Kubernetes, the deploymen resource contains two containers: one container hosts the application, and the other hosts multiple encryption / decryption algorithms, isolating the application and the algorithms from each other. For example... Figure 3 As shown, the configuration information in the environment variables used for encrypting and decrypting the sidecar is also configured.
[0047] In some embodiments, before encrypting / decrypting the data based on the target encryption / decryption algorithm and a preset key, the method further includes:
[0048] The encryption / decryption function container reads the environment variables, wherein the environment variables include configuration information, and the configuration information corresponds to an encryption / decryption algorithm;
[0049] The corresponding encryption and decryption algorithm is selected from the plurality of encryption and decryption algorithms based on the configuration information.
[0050] Specifically, since different configuration information in the environment variables corresponds to different algorithms, when the encryption / decryption function container reads the environment variables, it can select the corresponding encryption / decryption algorithm according to the current environment variables to encrypt / decrypt the data.
[0051] Furthermore, the multiple encryption and decryption algorithms are implemented in multiple different programming languages and / or correspond to multiple different types of systems.
[0052] Specifically, multiple encryption and decryption algorithms are implemented in multiple different programming languages and / or correspond to multiple different types of systems. The encryption and decryption function container dynamically selects different encryption and decryption algorithms through environment variables, which shields the implementation differences between different encryption and decryption languages and reduces the difficulty of code development.
[0053] In step S102, the encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from a plurality of encryption / decryption algorithms according to pre-configured environment variables.
[0054] Specifically, when encryption / decryption of data is required, the encryption / decryption container reads pre-configured environment variables and dynamically selects the target encryption / decryption algorithm based on these variables. The target encryption / decryption algorithm and a preset key are then used to encrypt / decrypt the data. This dual encryption / decryption mechanism, using both the target algorithm and the preset key, provides better data protection and enhances the security of the encrypted / decrypted data.
[0055] In some embodiments, encrypting / decrypting the data based on the target encryption / decryption algorithm and a preset key includes:
[0056] The key is obtained from the preset key management system, and the encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and the preset key.
[0057] Specifically, when it is necessary to encrypt / decrypt data, the encryption / decryption function container communicates with the preset key management system to obtain the key stored in the key management system, and encrypts / decrypts the data using the target encryption / decryption algorithm and the preset key.
[0058] In step S103, the encrypted / decrypted data is returned to the application execution container.
[0059] Specifically, when the encryption / decryption of the data using the key and the target encryption / decryption algorithm is completed, the completed encryption / decryption data is returned to the application execution container, which then stores / receives the encrypted / decrypted data.
[0060] To further illustrate the technical concept of this invention, the technical solution of this invention will now be described in conjunction with specific application scenarios.
[0061] The data encryption process involves the following steps:
[0062] The first step is to start the encryption / decryption function container and establish communication with the receiving application execution container to receive encryption requests sent by the application execution container. The encryption requests contain the data to be encrypted.
[0063] The second step involves the encryption / decryption container selecting the corresponding encryption algorithm based on the information configured in the environment variables.
[0064] The third step is to establish communication between the encryption / decryption container and the key management system, such as... Figure 3 As shown, the corresponding key is obtained and stored in the memory of the encryption / decryption function container.
[0065] The fourth step involves the encryption / decryption container encrypting the data to be encrypted using the selected target encryption algorithm and key, and then sending the encrypted result to the receiving application execution container.
[0066] The fifth step is for the receiving application execution container to write the received result data into the corresponding database.
[0067] The data decryption process involves the following steps:
[0068] The first step is to start the encryption / decryption function container and establish communication with the receiving application execution container. The receiving application execution container sends a decryption request, which contains the data to be decrypted. This data is read from the database by the receiving application execution container.
[0069] The second step involves the encryption / decryption container selecting the corresponding decryption algorithm based on the information configured in the environment variables.
[0070] The third step is for the encryption / decryption container to establish communication with the key management system, obtain the corresponding key, and store it in the memory of the encryption / decryption container.
[0071] The fourth step involves the encryption / decryption container decrypting the data to be decrypted using the selected target decryption algorithm and key, and then sending the decrypted result data to the receiving application execution container.
[0072] Figure 2 This is a block diagram illustrating a data encryption / decryption system according to an exemplary embodiment. (Refer to...) Figure 2 The system includes: an encryption / decryption function container and an application execution container, wherein:
[0073] The encryption / decryption function container receives encryption / decryption requests sent by the application execution container. The encryption / decryption function container and the application execution container are pre-deployed on the node. The encryption / decryption request includes data to be encrypted / decrypted. The application execution container includes an application program. The encryption / decryption function container includes multiple encryption / decryption algorithms.
[0074] The encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from a plurality of encryption / decryption algorithms according to pre-configured environment variables;
[0075] The encrypted / decrypted data is returned to the application execution container.
[0076] In summary, the data encryption / decryption system provided in this application is an encryption / decryption function container developed based on the sidecar pattern. This reduces the development cost of implementing data encryption / decryption in multiple languages. At the same time, it separates the encryption / decryption algorithms, isolating the keys, encryption / decryption algorithms, and application code, minimizing the access permissions of the algorithms, enhancing the strength of the encryption / decryption algorithms, and thus improving the security of data encryption / decryption.
[0077] Regarding the systems in the above embodiments, the specific ways in which each container performs operations have been described in detail in the embodiments related to the method, and will not be elaborated here.
[0078] In one embodiment, an electronic device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 4 As shown, the electronic device includes a processor, memory, communication interface, display screen, and input device connected via a system bus. The processor provides computing and control capabilities. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, carrier networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements an image denoising method. The display screen can be an LCD screen or an e-ink screen. The input device can be a touch layer covering the display screen, buttons, a trackball, or a touchpad mounted on the device's casing, or an external keyboard, touchpad, or mouse.
[0079] Those skilled in the art will understand that Figure 4 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0080] In one embodiment, the data encryption / decryption system provided in this application can be implemented as a computer program, which can be used in various ways, such as... Figure 4 The electronic device shown operates on this device. The electronic device's memory can store the various containers that make up the encryption / decryption system that constitutes the data, for example... Figure 2 The encryption / decryption function container and application execution container are shown. The computer program composed of these containers causes the processor to execute the steps of a data encryption / decryption method according to various embodiments of this application described in this specification.
[0081] For example, Figure 4 The electronic device shown can be used as follows Figure 2The data encryption / decryption system shown includes an encryption / decryption function container and an application execution container. The encryption / decryption function container receives encryption / decryption requests sent by the application execution container. Both the encryption / decryption function container and the application execution container are pre-deployed on nodes. The encryption / decryption request includes data to be encrypted / decrypted. The application execution container includes an application program. The encryption / decryption function container includes multiple encryption / decryption algorithms. The system encrypts / decrypts the data based on a target encryption / decryption algorithm and a preset key. The target encryption / decryption algorithm is selected by the encryption / decryption function container from the multiple encryption / decryption algorithms according to pre-configured environment variables. The encrypted / decrypted data is then returned to the application execution container.
[0082] The electronic device provided in this application can open various containers in the data encryption and decryption system through memory and processor, realizing encryption and decryption function containers developed based on the sidecar pattern. This reduces the development cost of data encryption and decryption in multiple languages. At the same time, it separates the encryption and decryption algorithms, making the key, encryption and decryption algorithm and application code isolated from each other, controlling the access permissions of the algorithm to the minimum, enhancing the strength of the encryption and decryption algorithm, and thus improving the security of data encryption / decryption.
[0083] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When executed by a processor, the computer program performs the following steps: an encryption / decryption function container receives an encryption / decryption request sent by an application execution container, wherein the encryption / decryption function container and the application execution container are pre-deployed on a node, the encryption / decryption request includes data to be encrypted / decrypted, the application execution container includes an application program, and the encryption / decryption function container includes multiple encryption / decryption algorithms; encrypting / decrypting the data based on a target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from the multiple encryption / decryption algorithms according to pre-configured environment variables; and returning the encrypted / decrypted data to the application execution container.
[0084] The non-transitory computer-readable storage medium provided in this application can execute a data encryption / decryption method from the above embodiments through instructions in the storage medium. It realizes an encryption / decryption function container developed based on the sidecar pattern, reduces the development cost of data encryption / decryption in multiple languages, and separates the encryption / decryption algorithm, so that the key, encryption / decryption algorithm and application code are isolated from each other, controls the access permissions of the algorithm to a minimum, enhances the strength of the encryption / decryption algorithm, and thus improves the security of data encryption / decryption.
[0085] In one embodiment, a computer program product is provided that, when instructions in the computer program product are executed by a processor of a mobile terminal, enables the mobile terminal to perform the following steps: an encryption / decryption function container receives an encryption / decryption request sent by an application execution container, wherein the encryption / decryption function container and the application execution container are pre-deployed on a node, the encryption / decryption request includes data to be encrypted / decrypted, the application execution container includes an application program, and the encryption / decryption function container includes multiple encryption / decryption algorithms; encrypting / decrypting the data based on a target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from the multiple encryption / decryption algorithms according to pre-configured environment variables; and returning the encrypted / decrypted data to the application execution container.
[0086] The computer program product provided in this application enables a mobile terminal to execute the data encryption and decryption methods described in the above embodiments. It implements an encryption and decryption function container developed based on the sidecar pattern, reducing the development cost of data encryption and decryption in multiple languages. At the same time, it separates the encryption and decryption algorithms, isolating the key, encryption and decryption algorithm and application code, keeping the access permissions of the algorithm to a minimum, enhancing the strength of the encryption and decryption algorithm, and thus improving the security of data encryption / decryption.
[0087] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, or optical storage, etc. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static random access memory (SRAM) and dynamic random access memory (DRAM), etc.
[0088] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0089] The above embodiments merely illustrate several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.
Claims
1. A data encryption / decryption method, characterized in that, include: The encryption / decryption function container receives encryption / decryption requests sent by the application execution container. The encryption / decryption function container and the application execution container are pre-deployed on the node. The encryption / decryption request includes data to be encrypted / decrypted. The application execution container includes an application program. The encryption / decryption function container includes multiple encryption / decryption algorithms. The encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from a plurality of encryption / decryption algorithms according to pre-configured environment variables; The encrypted / decrypted data is returned to the application execution container; the application execution container interacts with the database and writes the encrypted data into the database or reads the encrypted data from the database for decryption; The process includes, before the encryption / decryption function container receives the encryption / decryption request sent by the application execution container, the following: Based on the sidecar pattern, the application is deployed as an application pod on the Kubernetes node, and the multiple encryption and decryption algorithms are deployed as encryption and decryption sidecars on the Kubernetes node. The application pod is the application execution container, and the encryption and decryption sidecar is the encryption and decryption function container. The sidecar-based approach, which deploys the application as an application pod on the Kubernetes node and deploys the multiple encryption / decryption algorithms as encryption / decryption sidecars on the Kubernetes node, includes: Create a deploymen resource on the Kubernetes cluster. The deploymen resource contains two containers: one container deploys the application and serves as the application pod, and the other container deploys the multiple encryption and decryption algorithms and serves as the encryption and decryption sidecar. Configure the environment variables used by the encryption / decryption sidecar.
2. The encryption / decryption method according to claim 1, characterized in that, Before encrypting / decrypting the data based on the target encryption / decryption algorithm and a preset key, the process also includes: The encryption / decryption function container reads the environment variables, wherein the environment variables include configuration information, and the configuration information corresponds to an encryption / decryption algorithm; The corresponding encryption and decryption algorithm is selected from the plurality of encryption and decryption algorithms based on the configuration information.
3. The encryption / decryption method according to claim 2, characterized in that, The multiple encryption and decryption algorithms are implemented in multiple different programming languages and / or correspond to multiple different types of systems.
4. The encryption / decryption method according to claim 1, characterized in that, The encryption / decryption of the data based on the target encryption / decryption algorithm and a preset key includes: The key is obtained from the preset key management system, and the encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and the preset key.
5. A data encryption / decryption system, characterized in that, include: Encryption / decryption function containers and application execution containers, wherein: The encryption / decryption function container receives encryption / decryption requests sent by the application execution container. The encryption / decryption function container and the application execution container are pre-deployed on the node. The encryption / decryption request includes data to be encrypted / decrypted. The application execution container includes an application program. The encryption / decryption function container includes multiple encryption / decryption algorithms. The encrypted / decrypted data is encrypted / decrypted based on the target encryption / decryption algorithm and a preset key, wherein the target encryption / decryption algorithm is selected by the encryption / decryption function container from a plurality of encryption / decryption algorithms according to pre-configured environment variables; The encrypted / decrypted data is returned to the application execution container; the application execution container interacts with the database and writes the encrypted data into the database or reads the encrypted data from the database for decryption; The process includes, before the encryption / decryption function container receives the encryption / decryption request sent by the application execution container, the following: Based on the sidecar pattern, the application is deployed as an application pod on the Kubernetes node, and the multiple encryption and decryption algorithms are deployed as encryption and decryption sidecars on the Kubernetes node. The application pod is the application execution container, and the encryption and decryption sidecar is the encryption and decryption function container. The sidecar-based approach, which deploys the application as an application pod on the Kubernetes node and deploys the multiple encryption / decryption algorithms as encryption / decryption sidecars on the Kubernetes node, includes: Create a deploymen resource on the Kubernetes cluster. The deploymen resource contains two containers: one container deploys the application and serves as the application pod, and the other container deploys the multiple encryption and decryption algorithms and serves as the encryption and decryption sidecar. Configure the environment variables used by the encryption / decryption sidecar.
6. An electronic device, characterized in that, The device includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set, or an instruction set, and the instruction, program, code set, or instruction set is loaded and executed by the processor to implement the data encryption / decryption method according to any one of claims 1-4.
7. A non-transitory computer-readable storage medium, characterized in that, When the instructions in the storage medium are executed by the processor of the mobile terminal, the mobile terminal is able to perform the data encryption / decryption method according to any one of claims 1-4.
8. A computer program product, characterized in that, When the instructions in the computer program product are executed by the processor of the mobile terminal, the mobile terminal is able to execute the data encryption / decryption method according to any one of claims 1-4.