CN106570405B - Method and device for encrypting/decrypting characters in input method - Google Patents
Method and device for encrypting/decrypting characters in input method Download PDFInfo
- Publication number
- CN106570405B CN106570405B CN201610965362.3A CN201610965362A CN106570405B CN 106570405 B CN106570405 B CN 106570405B CN 201610965362 A CN201610965362 A CN 201610965362A CN 106570405 B CN106570405 B CN 106570405B
- Authority
- CN
- China
- Prior art keywords
- user
- characters
- encrypted
- decrypted
- input
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/602—Providing cryptographic facilities or services
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/606—Protecting data by securing the transmission between two devices or processes
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- General Health & Medical Sciences (AREA)
- Computer Hardware Design (AREA)
- Computer Security & Cryptography (AREA)
- Health & Medical Sciences (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Bioethics (AREA)
- User Interface Of Digital Computer (AREA)
- Storage Device Security (AREA)
Abstract
The invention aims to provide a method and a device for encrypting/decrypting characters in an input method; acquiring characters to be encrypted/decrypted input by a user in an input box of an input method; based on the encryption/decryption operation of the user on an input panel corresponding to the input method, correspondingly encrypting/decrypting the characters to be encrypted/decrypted to obtain the encrypted/decrypted characters; and providing the encrypted/decrypted characters to the user in an input box of the input method. By the method and the device, the sending user sending the information can encrypt the original information of the sending user and convert the original information into the text irrelevant to the original information, and the receiving user receiving the information can see the original information only after decoding the information, so that the chatting information cannot be leaked even if equipment such as a mobile phone of the user falls into other people or the information is seen by other people, the personal privacy of the user is greatly protected, and the use experience of the user is improved.
Description
Technical Field
The invention relates to the technical field of computers, in particular to a technology for encrypting/decrypting characters in an input method.
Background
Privacy is a focus of attention of people in the internet age, wherein chat information becomes a secret that people are least willing to be snooped by others. Because the chat information of our people often contains a lot of personal privacy or important personal information, such as telephone, password, family information, etc. Once the chat information is seen by others at will, the personal privacy of the people is likely to be leaked, and huge loss is brought to the people.
However, in the prior art, the chat information of people is directly displayed without any protective measures, the content of the chat information is easily seen by others, and the privacy of people is not well protected.
Therefore, it is one of the technical problems that people need to solve to provide a technology for encrypting/decrypting characters in an input method.
Disclosure of Invention
The invention aims to provide a method and a device for encrypting/decrypting characters in an input method.
According to one aspect of the present invention, there is provided a method of encrypting/decrypting text in an input method, wherein the method includes:
a, acquiring characters to be encrypted/decrypted input by a user in an input box of an input method;
b, performing corresponding encryption/decryption processing on the characters to be encrypted/decrypted based on the encryption/decryption operation of the user on an input panel corresponding to the input method to obtain encrypted/decrypted characters;
c, providing the encrypted/decrypted characters to the user in an input box of the input method.
Preferably, the user is a sending user who needs encrypted text, wherein the method further comprises:
and sending the encrypted characters to corresponding receiving users based on the sending operation of the sending users on the encrypted characters.
More preferably, the step b includes:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and by combining the aging information of the encryption operation to obtain the encrypted characters.
Preferably, the step b includes:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on an input panel corresponding to the input method and by combining the identification information of the sending user to obtain the encrypted characters.
Preferably, the step b includes:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and by combining the character strings with semantic logic stored in the password library to obtain the encrypted characters.
Preferably, the user is a receiving user who needs to decrypt text, wherein the step a includes:
acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise identification information of a corresponding sending user;
wherein the step b comprises:
judging whether a sending user corresponding to the identification information and the receiving user are in the same conversation process based on the decryption operation of the receiving user on an input panel corresponding to the input method;
if so, carrying out corresponding decryption processing on the characters to be decrypted to obtain the decrypted characters.
Preferably, the user is a receiving user who needs to decrypt text, wherein the step a includes:
acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise aging information;
wherein the step b comprises:
judging whether the time efficiency information is effective or not based on the decryption operation of the receiving user on an input panel corresponding to the input method;
and if so, carrying out corresponding encryption/decryption processing on the characters to be decrypted to obtain the decrypted characters.
Preferably, the user is a receiving user who needs to decrypt the text, wherein the method further comprises:
receiving characters to be decrypted sent by a corresponding sending user, wherein the characters to be decrypted are displayed in a preset format;
wherein the step a comprises:
and acquiring the characters to be decrypted, which are input by the receiving user in the input frame of the input method and are displayed in the preset format.
According to another aspect of the present invention, there is also provided an apparatus for encrypting/decrypting text in an input method, wherein the apparatus includes:
the device comprises an acquisition device, a processing device and a display device, wherein the acquisition device is used for acquiring characters to be encrypted/decrypted, which are input in an input box of an input method by a user;
the processing device is used for carrying out corresponding encryption/decryption processing on the characters to be encrypted/decrypted based on the encryption/decryption operation of the user on the input panel corresponding to the input method to obtain the encrypted/decrypted characters;
and the providing device is used for providing the encrypted/decrypted characters to the user in an input box of the input method.
Preferably, the user is a sending user who needs encrypted text, wherein the device further comprises:
and the sending device is used for sending the encrypted characters to corresponding receiving users based on the sending operation of the sending users on the encrypted characters.
More preferably, the processing means is for:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and by combining the aging information of the encryption operation to obtain the encrypted characters.
Preferably, the processing means is for:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on an input panel corresponding to the input method and by combining the identification information of the sending user to obtain the encrypted characters.
Preferably, the processing means is for:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and by combining the character strings with semantic logic stored in the password library to obtain the encrypted characters.
Preferably, the user is a receiving user who needs to decrypt a text, wherein the obtaining device is configured to:
acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise identification information of a corresponding sending user;
wherein the processing device is configured to:
judging whether a sending user corresponding to the identification information and the receiving user are in the same conversation process based on the decryption operation of the receiving user on an input panel corresponding to the input method;
if so, carrying out corresponding decryption processing on the characters to be decrypted to obtain the decrypted characters.
Preferably, the user is a receiving user who needs to decrypt a text, wherein the obtaining device is configured to:
acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise aging information;
wherein the processing device is configured to:
judging whether the time efficiency information is effective or not based on the decryption operation of the receiving user on an input panel corresponding to the input method;
and if so, carrying out corresponding encryption/decryption processing on the characters to be decrypted to obtain the decrypted characters.
Preferably, the user is a receiving user who needs to decrypt the text, wherein the device further comprises:
the receiving device is used for receiving characters to be decrypted sent by a corresponding sending user, wherein the characters to be decrypted are displayed in a preset format;
wherein the obtaining means is configured to:
and acquiring the characters to be decrypted, which are input by the receiving user in the input frame of the input method and are displayed in the preset format.
According to yet another aspect of the present invention, there is also provided a computer apparatus, comprising:
one or more processors;
a memory for storing one or more computer programs;
the one or more computer programs, when executed by the one or more processors, cause the one or more processors to implement the method of any preceding claim.
Compared with the prior art, the invention provides a method and a device for encrypting/decrypting characters in an input method, through the method and the device, a sending user sending information can encrypt own original information and convert the original information into a text irrelevant to the original information, and a receiving user receiving the information can see the original information only after decoding the information, so that chatting information cannot be leaked even if equipment such as a mobile phone of the user falls into other people or the information is seen by other people, thereby greatly protecting the personal privacy of the user and improving the use experience of the user.
Furthermore, when the encryption processing is carried out on the characters to be encrypted, the aging information of the encryption operation is considered in a combined manner, and only when the aging information is effective, the encrypted characters can be decrypted, so that the personal privacy of the user is further protected, and the use experience of the user is improved.
Furthermore, when the characters to be encrypted are encrypted, the identification information of the sending user is considered, and only when the identification information is valid, the identity of the sending user is verified, the encrypted characters can be decrypted, so that the personal privacy of the user is further protected, and the use experience of the user is improved.
Furthermore, the invention combines the password library stored with the character string with the semantic logic to encrypt the character to be encrypted, and the encrypted character is the character string with the semantic logic and is not disorderly, so that even if the chat conversation between the sending user and the receiving user is seen by others, the sending user and the receiving user cannot know that the chat information is encrypted, the personal privacy of the user is further protected, and the use experience of the user is improved.
Furthermore, the encrypted characters sent by the sending user are displayed to the receiving user in a preset format, so that the receiving user is prompted to decrypt and check the message, and the use experience of the user is further improved.
The invention can be applied to input method projects of all platforms and other products related to input.
Drawings
Other features, objects and advantages of the invention will become more apparent upon reading of the detailed description of non-limiting embodiments made with reference to the following drawings:
FIG. 1 illustrates a block diagram of an apparatus for encrypting/decrypting text in an input method, according to one aspect of the present invention;
FIG. 2 is a diagram illustrating the encryption of text in an input method in accordance with a preferred embodiment of the present invention;
FIG. 3 is a diagram illustrating the encryption of text in an input method in accordance with a preferred embodiment of the present invention;
FIG. 4 is a diagram illustrating the decryption of text in an input method in accordance with another preferred embodiment of the present invention;
FIG. 5 is a diagram illustrating the decryption of text in an input method in accordance with another preferred embodiment of the present invention;
FIG. 6 illustrates a flow diagram of a method for encrypting/decrypting text in an input method in accordance with another aspect of the subject innovation.
The same or similar reference numbers in the drawings identify the same or similar elements.
Detailed Description
Before discussing exemplary embodiments in more detail, it should be noted that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although a flowchart may describe the operations as a sequential process, many of the operations can be performed in parallel, concurrently, or simultaneously. In addition, the order of the operations may be re-arranged. The process may be terminated when its operations are completed, but may have additional steps not included in the figure. The processes may correspond to methods, functions, procedures, subroutines, and the like.
The term "computer device" or "computer" in this context refers to an intelligent electronic device that can execute predetermined processes such as numerical calculation and/or logic calculation by running predetermined programs or instructions, and may include a processor and a memory, wherein the processor executes a pre-stored instruction stored in the memory to execute the predetermined processes, or the predetermined processes are executed by hardware such as ASIC, FPGA, DSP, or a combination thereof. Computer devices include, but are not limited to, servers, personal computers, laptops, tablets, and the like.
The computer equipment comprises user equipment and network equipment. Wherein the user equipment includes but is not limited to personal computers, notebook computers, tablet computers, and the like; the network device includes, but is not limited to, a single network server, a server group consisting of a plurality of network servers, or a Cloud Computing (Cloud Computing) based Cloud consisting of a large number of computers or network servers, wherein Cloud Computing is one of distributed Computing, a super virtual computer consisting of a collection of loosely coupled computers. Wherein the computer device can be operated alone to implement the invention, or can be accessed to a network and implement the invention through interoperation with other computer devices in the network. The network in which the computer device is located includes, but is not limited to, the internet, a wide area network, a metropolitan area network, a local area network, a VPN network, and the like.
It should be noted that the user equipment, the network device, the network, etc. are only examples, and other existing or future computer devices or networks may also be included in the scope of the present invention, and are included by reference.
The methods discussed below, some of which are illustrated by flow diagrams, may be implemented by hardware, software, firmware, middleware, microcode, hardware description languages, or any combination thereof. When implemented in software, firmware, middleware or microcode, the program code or code segments to perform the necessary tasks may be stored in a machine or computer readable medium such as a storage medium. The processor(s) may perform the necessary tasks.
Specific structural and functional details disclosed herein are merely representative and are provided for purposes of describing example embodiments of the present invention. The present invention may, however, be embodied in many alternate forms and should not be construed as limited to only the embodiments set forth herein.
It will be understood that, although the terms first, second, etc. may be used herein to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another. For example, a first element may be termed a second element, and, similarly, a second element may be termed a first element, without departing from the scope of example embodiments. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
It will be understood that when an element is referred to as being "connected" or "coupled" to another element, it can be directly connected or coupled to the other element or intervening elements may be present. In contrast, when an element is referred to as being "directly connected" or "directly coupled" to another element, there are no intervening elements present. Other words used to describe the relationship between elements (e.g., "between" versus "directly between", "adjacent" versus "directly adjacent to", etc.) should be interpreted in a similar manner.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of example embodiments. As used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises" and/or "comprising," when used herein, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It should also be noted that, in some alternative implementations, the functions/acts noted may occur out of the order noted in the figures. For example, two figures shown in succession may, in fact, be executed substantially concurrently, or the figures may sometimes be executed in the reverse order, depending upon the functionality/acts involved.
The present invention is described in further detail below with reference to the attached drawing figures.
Fig. 1 shows a schematic configuration of an apparatus for encrypting/decrypting text in an input method according to an aspect of the present invention.
The apparatus 1 is located, for example, in a computer device, comprising acquisition means 101, processing means 102 and providing means 103. Specifically, the obtaining device 101 obtains a character to be encrypted/decrypted, which is input by a user in an input box of an input method; the processing device 102 performs corresponding encryption/decryption processing on the characters to be encrypted/decrypted based on the encryption/decryption operation of the user on the input panel corresponding to the input method, so as to obtain encrypted/decrypted characters; the providing device 103 provides the encrypted/decrypted text to the user in the input box of the input method.
The obtaining device 101 obtains the text to be encrypted/decrypted, which is input by the user in the input box of the input method.
Specifically, a user inputs a text to be encrypted/decrypted in an input box of an input method of the user equipment through interaction with the user equipment, and the obtaining device 101 obtains the text to be encrypted/decrypted, which is input by the user in the input box of the input method, for example, by calling an Application Program Interface (API) or other appointed communication methods provided by the user equipment one or more times.
Here, the user may be a sending user who needs to encrypt the text, or may be a receiving user who needs to decrypt the text, and the way in which the user inputs the text to be encrypted/decrypted into the input box of the input method includes, but is not limited to, typing in, copy and paste, or even voice input. For example, a sending user inputs a to-be-encrypted character in an input frame of an input method by typing and the like, the device 1 encrypts the to-be-encrypted character, and then the sending user sends the encrypted character to a corresponding receiving user; the receiving user obtains the encrypted character, that is, the encrypted character is used as a character to be decrypted, and the character is input into an input box of the input method through modes such as copying and pasting, and the device 1 can perform corresponding decryption processing on the character to be decrypted.
It should be understood by those skilled in the art that the above-mentioned method for obtaining the text to be encrypted/decrypted by the user is only an example, and other existing or future methods for obtaining the text to be encrypted/decrypted by the user, such as applicable to the present invention, are also included in the scope of the present invention and are hereby incorporated by reference.
The processing device 102 performs corresponding encryption/decryption processing on the text to be encrypted/decrypted based on the encryption/decryption operation of the user on the input panel corresponding to the input method, so as to obtain the encrypted/decrypted text.
Specifically, after the user inputs the text to be encrypted/decrypted into the input box of the input method, the user performs an encryption/decryption operation on the input panel by, for example, clicking a specific button, and the processing device 102 performs a corresponding encryption/decryption process on the text to be encrypted/decrypted based on the encryption/decryption operation of the user, for example, performs a corresponding encryption/decryption process on the text to be encrypted/decrypted by using technologies such as a symmetric key and an asymmetric key, so as to obtain the encrypted/decrypted text.
Here, the input panel may have, for example, an "encryption button" and a "decryption button" corresponding to each other, and when the user clicks the encryption button, the processing device 102 performs a corresponding encryption operation on the text to be encrypted, and when the user clicks the decryption button, the processing device 102 performs a corresponding decryption operation on the text to be decrypted, and preferably, the encryption button and the decryption button may also be the same button, for example.
In a preferred embodiment, the processing device 102 performs corresponding encryption/decryption operations for the text to be encrypted/decrypted of the user, for example, through a password library. For example, a character string is stored in the password library, when a user needs to encrypt a character to be encrypted (an original character), the processing device 102 selects a character string from the password library for the character to be encrypted, uses the character string as a character after the character to be encrypted is encrypted, and establishes a temporary mapping relationship between the character to be encrypted and the character string, when a receiving user receives the encrypted character, that is, the character string, uses the character string as a character to be decrypted and performs decryption, and the processing device 102 finds a corresponding original character from the password library according to the character string and the temporary mapping relationship, uses the original character as a decrypted character, and provides the decrypted character to the receiving user. Preferably, the character string stored in the password library may be a character string having semantic logic, such as "i eat roasted meat meal today", "weather is good today", etc., so that even if the chat conversation between the sending user and the receiving user is seen by others, the piece of chat information is not known to be encrypted.
It should be understood by those skilled in the art that the above-mentioned manner for performing corresponding encryption/decryption processing on the text to be encrypted/decrypted is only an example, and other manners for performing corresponding encryption/decryption processing on the text to be encrypted/decrypted, which may exist or may appear in the future, such as applicable to the present invention, should also be included in the scope of the present invention, and are hereby incorporated by reference.
The providing device 103 provides the encrypted/decrypted text to the user in the input box of the input method.
Specifically, the providing device 103 provides the encrypted/decrypted characters to the user in the input box of the input method according to the encrypted/decrypted characters obtained by the processing device 102, so that the user can perform subsequent operations, for example, the user can click a send button to send the encrypted characters, or delete the decrypted characters in the input box, thereby inputting other characters that the user wants to input. When the user clicks the encryption/decryption button on the input panel of the input method, the characters to be encrypted/decrypted in the input frame of the input method can be converted into the encrypted/decrypted characters.
It should be understood by those skilled in the art that the above-mentioned manner of providing encrypted/decrypted text is merely exemplary, and other manners of providing encrypted/decrypted text that may exist or may come within the future, such as may be suitable for use with the present invention, are intended to be included within the scope of the present invention and are hereby incorporated by reference.
The sending user who sends the information can encrypt the original information of the sending user, the device 1 converts the original information into a text irrelevant to the original information, and the receiving user who receives the information can see the original information only after decoding the information, so that the chatting information cannot be leaked even if the mobile phone and other equipment of the user fall into other people or the information is seen by other people, the personal privacy of the user is greatly protected, and the use experience of the user is improved.
Preferably, the user is a sending user who needs ciphertext, wherein the apparatus 1 further comprises sending means (not shown). The sending device sends the encrypted characters to corresponding receiving users based on sending operation of the sending users on the encrypted characters.
Specifically, if the user is a sending user who needs to encrypt a text, the sending user types and inputs a text to be encrypted in an input box of an input method of the user equipment through a physical keyboard, a virtual keyboard and the like through interaction with the user equipment, and the obtaining device 101 obtains the text to be encrypted, which is input in the input box of the input method by the sending user, for example, by calling an Application Program Interface (API) provided by the user equipment or other appointed communication manners one or more times; subsequently, the processing device 102 performs corresponding encryption processing on the text to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method, so as to obtain encrypted text; the providing device 103 provides the encrypted text to the user in an input box of the input method; next, the transmitting user performs a transmission operation on the encrypted character by, for example, clicking a transmission button, and the transmitting apparatus transmits the encrypted character to the corresponding receiving user based on the transmission operation of the transmitting user.
More preferably, the processing device 102 performs corresponding encryption processing on the text to be encrypted based on an encryption operation of the sending user on an input panel corresponding to the input method and in combination with the aging information of the encryption operation, so as to obtain the encrypted text.
Specifically, the encryption operation may have certain aging information, and the processing device 102 may add the aging information of the encryption operation to a specific field of the encrypted text when the text to be encrypted is encrypted. The time information may be, for example, only time information indicating a specific time at which the sending user clicks a specific button on an input panel of the input method to perform an encryption operation; or a time period threshold information, which may specify that the encrypted text is valid to be decrypted within a time period threshold, for example, within 5 minutes, when the receiving user receives the encrypted text; alternatively, the time-based information may be a combination of time information and time-based threshold information, which may include a specific time indicating that the sending user performed the encryption operation on the input panel of the input method, or a time-based threshold specifying that the receiving user is valid to decrypt the encrypted text within a time-based threshold after the specific time that the sending user performed the encryption operation.
For example, if the sending user inputs the text to be encrypted in the input box of the input method, that is, "my password is 11223344", and the time for clicking the encryption button on the input panel corresponding to the input method is 2016, 11, 3, and 12:00 "in beijing time, the processing device 102 adds the time information of the encryption operation, that is," 2016, 11, 3, and 12:00 "in beijing time, 2016, to the specific field of the encrypted text, when encrypting the information to be encrypted. Further, the processing device 102 may add corresponding time period threshold information of the decryption operation to the specific field of the encrypted text, for example, within 5 minutes, so that the original text information can be decrypted only when the corresponding receiving user performs the decryption operation on the encrypted text within 5 minutes after the time that the sending user performs the encryption operation, that is, before 2016, 11, 3, 12:05 in beijing.
Here, when the device 1 encrypts the text to be encrypted, the aging information of the encryption operation is considered in combination, and only when the aging information is effective, the encrypted text can be decrypted, so that the personal privacy of the user is further protected, and the use experience of the user is improved.
Preferably, the processing device 102 performs corresponding encryption processing on the text to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and in combination with the identification information of the sending user, so as to obtain the encrypted text.
Specifically, the sending user may further have corresponding identification information, such as identification information of an account information, an IP address, an equipment number, and the like of the sending user, when the sending user performs an encryption operation on an input panel corresponding to an input method by clicking an encryption button, the processing device 102 obtains the identification information of the sending user based on the encryption operation of the sending user, and when performing an encryption process on a text to be encrypted, adds the identification information of the sending user to a specific field of the encrypted text. Therefore, when the corresponding receiving user receives the encrypted characters, the identification information of the sending user can be extracted, so that the identity of the sending user is verified, and whether the encrypted characters can be decrypted or not is judged.
Here, when the device 1 encrypts the text to be encrypted, the identification information of the sending user is considered, and only when the identification information is valid, the identity of the sending user is verified, so that the encrypted text can be decrypted, the personal privacy of the user is further protected, and the use experience of the user is improved.
Preferably, the processing device 102 performs corresponding encryption processing on the text to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and in combination with the character string with semantic logic stored in the password library, so as to obtain the encrypted text.
Specifically, a character string with semantic logic is stored in the password library, such as "i eat roasted pork rice today", "weather is good today", and the like, when a sending user needs to encrypt a text to be encrypted (original text), "my password is 11223344" which is input in an input box of an input method, for example, as shown in fig. 2, and an encryption operation is performed by clicking an encryption button or the like in an input panel corresponding to the input method; the obtaining device 101 obtains the characters to be encrypted, which are input by the sending user in the input box; the processing device 102 selects a character string with semantic logic for the character to be encrypted from the password library according to the character to be encrypted, for example, "i eat roasted pork rice" today, takes the character string with semantic logic as the character after encryption processing of the character to be encrypted, and establishes a temporary mapping relationship between the character to be encrypted, "i's password is 11223344" and the character string with semantic logic, "i eat roasted pork rice" today; the providing device 103 provides the encrypted text "i eat roasted pork rice today" to the sending user in the input box of the input method, as shown in fig. 3, the sending user may continue to send the encrypted text to the corresponding receiving user by clicking a send button or the like on the input panel of the input method. When the receiving user receives the encrypted text, that is, the character string "i eat roasted pork rice today", it is used as the text to be decrypted and decrypted, and it is input into the input box of the input method by copying and pasting, as shown in fig. 4, the processing device 102 finds the corresponding original text "i have roasted pork rice today" from the password library according to the temporary mapping relationship, and it is used as the decrypted text, and the providing device 103 provides the decrypted text "i have 11223344" to the receiving user in the input box of the input method, as shown in fig. 5; further, after the processing device 102 completes the decryption process, the mapping relationship temporarily established between the text to be encrypted, "my password is 11223344" and the string with semantic logic, "i eat roasted meat rice today", may be released.
Here, the code library stores a character string with semantic logic, and a mapping relationship between the text to be encrypted and the character string with semantic logic may be established as needed, and the code library may be located in the apparatus 1 or in a third-party device connected to the apparatus 1 via a network.
Here, the device 1 performs encryption processing on the text to be encrypted in combination with the password library in which the character string having semantic logic is stored, and since the encrypted text is the character string having semantic logic, even if the chat conversation between the sending user and the receiving user is seen by others, the chat information is not known to be encrypted, thereby further protecting the personal privacy of the user and improving the use experience of the user.
Preferably, the sending user and the receiving user use the same input method, and the apparatus 1 may be located in a server corresponding to the input method, for example, so that the messages of the sending user and the receiving user can be encrypted/decrypted.
Preferably, the user is a receiving user who needs to decrypt the text, wherein the obtaining device 101 obtains the text to be decrypted input by the receiving user in the input box of the input method, wherein the text to be decrypted includes the identification information of the corresponding sending user; the processing device 102 determines whether a sending user corresponding to the identification information and the receiving user are in the same conversation process based on a decryption operation of the receiving user on an input panel corresponding to the input method; if so, carrying out corresponding decryption processing on the characters to be decrypted to obtain the decrypted characters.
Specifically, if the user is a receiving user who needs to decrypt a text, when the receiving user receives an encrypted text sent by a corresponding sending user, the encrypted text is used as a text to be decrypted, and is input into an input box of an input method, for example, by means of copying and pasting, and the like, and the obtaining device 101 obtains the text to be decrypted input into the input box of the input method by the receiving user, for example, by calling an Application Program Interface (API) provided by the user equipment or other agreed communication manners one or more times, where the text to be decrypted includes identification information of the corresponding sending user, such as identification information of an account number, an IP address, a device number, and the like of the sending user; then, the receiving user performs decryption operation by, for example, clicking a decryption button on an input panel corresponding to an input method, the processing device 102 extracts corresponding identification information of the sending user, such as account information, an IP address, an equipment number, and the like of the sending user, from a specific field of the text to be decrypted based on the decryption operation of the receiving user on the input panel corresponding to the input method, and further, the processing device 102 determines whether the sending user corresponding to the identification information is in the same conversation process with the receiving user, that is, determines whether the sending user and the receiving user are communicating; if yes, the processing device 102 performs corresponding decryption processing on the text to be decrypted to obtain decrypted text, and then the providing device 103 provides the decrypted text to the receiving user in the input box of the input method; if not, the processing device 102 does not perform any processing on the text to be decrypted.
Preferably, the user is a receiving user who needs to decrypt characters, wherein the obtaining device 101 obtains the characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted include time-dependent information; the processing device 102 determines whether the aging information is valid based on a decryption operation of the receiving user on an input panel corresponding to the input method; and if so, carrying out corresponding encryption/decryption processing on the characters to be decrypted to obtain the decrypted characters.
Specifically, if the user is a receiving user who needs to decrypt a text, when the receiving user receives an encrypted text sent by a corresponding sending user, the encrypted text is used as a text to be decrypted, and is input into an input box of an input method, for example, by copying and pasting, and the like, and the obtaining device 101 obtains the text to be decrypted, which is input into the input box of the input method by the receiving user, for example, by calling an Application Program Interface (API) provided by the user equipment or other agreed communication methods one or more times, where the text to be decrypted includes aging information. Here, the time-based information may be, for example, only time information indicating a specific time at which the sending user performs an encryption operation by clicking a specific button on an input panel of the input method; or a time period threshold information, which may specify that the encrypted text is valid to be decrypted within a time period threshold, for example, within 5 minutes, when the receiving user receives the encrypted text; alternatively, the time-based information may be a combination of time information and time-based threshold information, which may include a specific time indicating that the sending user performed the encryption operation on the input panel of the input method, or a time-based threshold specifying that the receiving user is valid to decrypt the encrypted text within a time-based threshold after the specific time that the sending user performed the encryption operation.
Then, the receiving user performs decryption operation by, for example, clicking a decryption button on an input panel corresponding to the input method, and the processing device 102 extracts corresponding aging information from the specific field of the character to be decrypted based on the decryption operation of the receiving user on the input panel corresponding to the input method, and determines whether the aging information is valid based on the current time; if yes, the processing device 102 performs corresponding decryption processing on the text to be decrypted to obtain decrypted text, and then the providing device 103 provides the decrypted text to the receiving user in the input box of the input method; if not, the processing device 102 does not perform any processing on the text to be decrypted.
For example, in the process that the receiving user carries out a chat conversation with the corresponding sending user, the receiving user receives the encrypted text "i eat roasted pork rice today" sent by the sending user, wherein the encrypted text comprises aging information, for example, the specific time "11 months, 3 months, 12:00 days in beijing, 2016", that the sending user clicks an encryption button in an input panel corresponding to an input method is included, and of course, the aging information may not be displayed to the receiving user; subsequently, the receiving user inputs the encrypted text "i eat roasted pork rice today" into an input box of an input method by means of copying, pasting, and the like, and takes the encrypted text as a text to be decrypted, and the obtaining device 101 obtains the text to be decrypted, wherein the text to be decrypted includes age information "12: 00 12/3/11/2016/11/beijing time"; then, the receiving user clicks a decryption button in an input panel of the input method of the receiving user, and the processing device 102 extracts corresponding aging information "12: 00/11/3/11/2016 beijing" in beijing time from a specific field of the character "i eat roasted pork rice" to be decrypted based on the decryption button; assuming that the time period threshold preset by the system is 10 minutes, that is, the system is preset within 10 minutes after the specific time of the sending user for performing the encryption operation, and it is only valid that the receiving user decrypts the encrypted text, the processing device 102 determines that the aging information is valid according to the current time, for example, the current time is 2016, 11, 3, 12:08 in beijing; subsequently, the processing device 102 performs corresponding decryption processing on the text to be decrypted to obtain a decrypted text.
For another example, the aging information included in the encrypted text (text to be decrypted) received by the receiving user includes not only the specific time "beijing time 2016, 11, 3, 12: 00" when the sending user clicks the encryption button in the input panel corresponding to the input method, but also the corresponding time period threshold information of the decryption operation, such as 5 minutes, that is, only if the receiving user performs the decryption operation on the encrypted text within 5 minutes after the time when the sending user performs the encryption operation, the original text information can be decrypted; the processing device 102 determines that the aging information is invalid according to the current time, if the current time is 2016, 11, 3, 12:08 in beijing, and the processing device 102 does not perform any processing on the character to be decrypted.
Preferably, the user is a receiving user who needs to decrypt text, wherein the device further comprises a receiving device (not shown). The receiving device receives characters to be decrypted sent by a corresponding sending user, wherein the characters to be decrypted are displayed in a preset format; the obtaining device 101 obtains the text to be decrypted, which is input by the receiving user in the input box of the input method and is displayed in the predetermined format.
Specifically, if the user is a receiving user who needs to decrypt the text, the receiving device receives the encrypted text sent by the corresponding sending user as the text to be decrypted, for example, by calling an Application Program Interface (API) provided by the user equipment or other agreed communication manners one or more times, where the text to be decrypted is presented in a predetermined format, for example, in a predetermined format different from other normal conversations, such as in different fonts and font sizes, or in a form of thickening, tilting, or in a form of shading with a predetermined color, so as to be different from other messages, so as to prompt the receiving user to decrypt the message. Subsequently, the receiving user inputs the to-be-decrypted text displayed in the predetermined format into an input box of the input method by copying and pasting, and the obtaining device 101 obtains the to-be-decrypted text displayed in the predetermined format input by the receiving user in the input box of the input method, for example, by calling an Application Program Interface (API) provided by the user equipment or other appointed communication manners one or more times.
Here, the device 1 presents the encrypted text sent by the sending user to the receiving user in a predetermined format, so as to prompt the receiving user to decrypt and view the message, thereby further improving the use experience of the user.
FIG. 6 illustrates a flow diagram of a method for encrypting/decrypting text in an input method in accordance with another aspect of the subject innovation.
In step S601, the apparatus 1 acquires a character to be encrypted/decrypted, which is input by the user in the input box of the input method.
Specifically, the user inputs the text to be encrypted/decrypted in the input box of the input method of the user equipment through interaction with the user equipment, and in step S601, the apparatus 1 obtains the text to be encrypted/decrypted, which is input by the user in the input box of the input method, for example, by calling an Application Program Interface (API) or other appointed communication method provided by the user equipment one or more times.
Here, the user may be a sending user who needs to encrypt the text, or may be a receiving user who needs to decrypt the text, and the way in which the user inputs the text to be encrypted/decrypted into the input box of the input method includes, but is not limited to, typing in, copy and paste, or even voice input. For example, a sending user inputs a to-be-encrypted character in an input frame of an input method by typing and the like, the device 1 encrypts the to-be-encrypted character, and then the sending user sends the encrypted character to a corresponding receiving user; the receiving user obtains the encrypted character, that is, the encrypted character is used as a character to be decrypted, and the character is input into an input box of the input method through modes such as copying and pasting, and the device 1 can perform corresponding decryption processing on the character to be decrypted.
It should be understood by those skilled in the art that the above-mentioned method for obtaining the text to be encrypted/decrypted by the user is only an example, and other existing or future methods for obtaining the text to be encrypted/decrypted by the user, such as applicable to the present invention, are also included in the scope of the present invention and are hereby incorporated by reference.
In step S602, the device 1 performs corresponding encryption/decryption processing on the text to be encrypted/decrypted based on the encryption/decryption operation of the user on the input panel corresponding to the input method, so as to obtain the encrypted/decrypted text.
Specifically, after the user inputs the text to be encrypted/decrypted into the input box of the input method, the user performs an encryption/decryption operation on the input panel by, for example, clicking a specific button, and in step S602, the device 1 performs corresponding encryption/decryption processing on the text to be encrypted/decrypted based on the encryption/decryption operation of the user, for example, performs corresponding encryption/decryption processing on the text to be encrypted/decrypted by using technologies such as a symmetric key and an asymmetric key, so as to obtain the encrypted/decrypted text.
Here, the input panel may have, for example, an "encryption button" and a "decryption button" corresponding thereto, and the user clicks the encryption button, and in step S602, the device 1 performs an encryption operation corresponding to the character to be encrypted, and if the user clicks the decryption button, in step S602, the device 1 performs a decryption operation corresponding to the character to be decrypted, and preferably, the encryption button and the decryption button may be, for example, the same button.
In a preferred embodiment, in step S602, the apparatus 1 performs corresponding encryption/decryption operations on the text to be encrypted/decrypted of the user, for example, through a password library. For example, a character string is stored in the password library, when a user needs to encrypt a character to be encrypted (original character), in step S602, the device 1 selects a character string from the password library for the character to be encrypted, uses the character string as a character after encryption processing of the character to be encrypted, and establishes a temporary mapping relationship between the character to be encrypted and the character string, and when a receiving user receives the encrypted character, that is, the character string, uses the character string as a character to be decrypted and performs decryption processing, in step S602, the device 1 finds a corresponding original character from the password library according to the temporary mapping relationship according to the character string, and uses the original character as a decrypted character and provides the decrypted character to the receiving user. Preferably, the character string stored in the password library may be a character string having semantic logic, such as "i eat roasted meat meal today", "weather is good today", etc., so that even if the chat conversation between the sending user and the receiving user is seen by others, the piece of chat information is not known to be encrypted.
It should be understood by those skilled in the art that the above-mentioned manner for performing corresponding encryption/decryption processing on the text to be encrypted/decrypted is only an example, and other manners for performing corresponding encryption/decryption processing on the text to be encrypted/decrypted, which may exist or may appear in the future, such as applicable to the present invention, should also be included in the scope of the present invention, and are hereby incorporated by reference.
In step S603, the apparatus 1 provides the encrypted/decrypted text to the user in the input box of the input method.
Specifically, in step S603, the device 1 provides the encrypted/decrypted characters to the user in the input box of the input method according to the encrypted/decrypted characters obtained in step S602, so that the user can perform subsequent operations, for example, the user can click a send button to send the encrypted characters, or delete the decrypted characters in the input box, thereby inputting other characters that the user wants to input. When the user clicks the encryption/decryption button on the input panel of the input method, the characters to be encrypted/decrypted in the input frame of the input method can be converted into the encrypted/decrypted characters.
It should be understood by those skilled in the art that the above-mentioned manner of providing encrypted/decrypted text is merely exemplary, and other manners of providing encrypted/decrypted text that may exist or may come within the future, such as may be suitable for use with the present invention, are intended to be included within the scope of the present invention and are hereby incorporated by reference.
The sending user who sends the information can encrypt the original information of the sending user, the device 1 converts the original information into a text irrelevant to the original information, and the receiving user who receives the information can see the original information only after decoding the information, so that the chatting information cannot be leaked even if the mobile phone and other equipment of the user fall into other people or the information is seen by other people, the personal privacy of the user is greatly protected, and the use experience of the user is improved.
Preferably, the user is a sending user who needs ciphertext, wherein the method further comprises step S604 (not shown). In step S604, the device 1 transmits the encrypted text to the corresponding receiving user based on the transmitting operation of the transmitting user on the encrypted text.
Specifically, if the user is a sending user who needs to encrypt a text, the sending user types and inputs a text to be encrypted in an input box of an input method of the user equipment through a physical keyboard, a virtual keyboard and the like through interaction with the user equipment, in step S601, the apparatus 1 obtains the text to be encrypted, which is input in the input box of the input method by the sending user, for example, by calling an Application Program Interface (API) or other appointed communication methods provided by the user equipment one or more times; subsequently, in step S602, the device 1 performs corresponding encryption processing on the text to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method, so as to obtain an encrypted text; in step S603, the apparatus 1 provides the encrypted text to the user in the input box of the input method; next, the transmitting user performs a transmission operation on the encrypted text by, for example, clicking a transmission button, and the device 1 transmits the encrypted text to the corresponding receiving user based on the transmission operation of the transmitting user in step S604.
More preferably, in step S602, the device 1 performs corresponding encryption processing on the text to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and in combination with the aging information of the encryption operation, so as to obtain an encrypted text.
Specifically, the encryption operation may have certain aging information, and in step S602, when the device 1 encrypts the text to be encrypted, the aging information of the encryption operation may be added to a specific field of the encrypted text. The time information may be, for example, only time information indicating a specific time at which the sending user clicks a specific button on an input panel of the input method to perform an encryption operation; or a time period threshold information, which may specify that the encrypted text is valid to be decrypted within a time period threshold, for example, within 5 minutes, when the receiving user receives the encrypted text; alternatively, the time-based information may be a combination of time information and time-based threshold information, which may include a specific time indicating that the sending user performed the encryption operation on the input panel of the input method, or a time-based threshold specifying that the receiving user is valid to decrypt the encrypted text within a time-based threshold after the specific time that the sending user performed the encryption operation.
For example, if the sending user inputs the text to be encrypted in the input box of the input method, that is, "my password is 11223344", and the time for clicking the encryption button on the input panel corresponding to the input method is 2016, 11, 3, 12:00 "in beijing, then in step S602, when the device 1 encrypts the information to be encrypted, the time information of the encryption operation, that is," 2016, 11, 3, 12:00 "in beijing is added to the specific field of the encrypted text. Further, in step S602, the apparatus 1 may further add corresponding time period threshold information of the decryption operation to the specific field of the encrypted text, for example, within 5 minutes, so that the original text information can be decrypted only if the corresponding receiving user performs the decryption operation on the encrypted text within 5 minutes after the time that the transmitting user performs the encryption operation, that is, before 2016, 11, 3, 12:05 in beijing.
Here, when the device 1 encrypts the text to be encrypted, the aging information of the encryption operation is considered in combination, and only when the aging information is effective, the encrypted text can be decrypted, so that the personal privacy of the user is further protected, and the use experience of the user is improved.
Preferably, in step S602, the device 1 performs corresponding encryption processing on the text to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and in combination with the identification information of the sending user, so as to obtain encrypted text.
Specifically, the sending user may further have corresponding identification information, such as identification information of an account information, an IP address, an equipment number, and the like of the sending user, and when the sending user performs an encryption operation by clicking an encryption button or the like on an input panel corresponding to an input method, in step S602, the device 1 acquires the identification information of the sending user based on the encryption operation of the sending user, and when performing encryption processing on a character to be encrypted, adds the identification information of the sending user to a specific field of the encrypted character. Therefore, when the corresponding receiving user receives the encrypted characters, the identification information of the sending user can be extracted, so that the identity of the sending user is verified, and whether the encrypted characters can be decrypted or not is judged.
Here, when the device 1 encrypts the text to be encrypted, the identification information of the sending user is considered, and only when the identification information is valid, the identity of the sending user is verified, so that the encrypted text can be decrypted, the personal privacy of the user is further protected, and the use experience of the user is improved.
Preferably, in step S602, the device 1 performs corresponding encryption processing on the text to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and in combination with the character string with semantic logic stored in the password library, so as to obtain the encrypted text.
Specifically, a character string with semantic logic is stored in the password library, such as "i eat roasted pork rice today", "weather is good today", and the like, when a sending user needs to encrypt a text to be encrypted (original text), "my password is 11223344" which is input in an input box of an input method, for example, as shown in fig. 2, and an encryption operation is performed by clicking an encryption button or the like in an input panel corresponding to the input method; in step S601, the device 1 obtains the to-be-encrypted text input by the sending user in the input box; in step S602, the device 1 selects a character string with semantic logic, such as "i eat roasted pork rice" today, from the password library for the to-be-encrypted character according to the to-be-encrypted character, takes the character string with semantic logic as the character after encryption processing of the to-be-encrypted character, and establishes a temporary mapping relationship between the to-be-encrypted character "i ' e ' i eat roasted pork rice" and the character string with semantic logic "i ' i eat roasted pork rice" today; in step S603, the device 1 provides the encrypted text "i eat roasted pork rice today" to the sending user in the input box of the input method, as shown in fig. 3, and the sending user may continue to send the encrypted text to the corresponding receiving user by clicking a send button or the like on the input panel of the input method. When the receiving user receives the encrypted text, that is, the character string "i eat roasted pork rice today", it is used as the text to be decrypted and decrypted, and it is input into the input box of the input method by copying and pasting, as shown in fig. 4, then in step S602, the device 1 finds out the corresponding original text "my password is 11223344" from the password library according to the temporary mapping relation, and uses it as the decrypted text, in step S603, the device 1 provides the decrypted text "my password is 11223344" to the receiving user in the input box of the input method, as shown in fig. 5; further, after the device 1 completes the decryption process in step S602, the mapping relationship temporarily established between the text to be encrypted "my password is 11223344" and the string with semantic logic "i eat roasted pork rice today" may be released.
Here, the code library stores a character string with semantic logic, and a mapping relationship between the text to be encrypted and the character string with semantic logic may be established as needed, and the code library may be located in the apparatus 1 or in a third-party device connected to the apparatus 1 via a network.
Here, the device 1 performs encryption processing on the text to be encrypted in combination with the password library in which the character string having semantic logic is stored, and since the encrypted text is the character string having semantic logic, even if the chat conversation between the sending user and the receiving user is seen by others, the chat information is not known to be encrypted, thereby further protecting the personal privacy of the user and improving the use experience of the user.
Preferably, the sending user and the receiving user use the same input method, and the apparatus 1 may be located in a server corresponding to the input method, for example, so that the messages of the sending user and the receiving user can be encrypted/decrypted.
Preferably, the user is a receiving user who needs to decrypt the text, wherein in step S601, the device 1 obtains the text to be decrypted input by the receiving user in the input box of the input method, wherein the text to be decrypted includes the identification information of the corresponding sending user; in step S602, the device 1 determines whether the sending user corresponding to the identification information and the receiving user are in the same session process based on the decryption operation of the receiving user on the input panel corresponding to the input method; if so, carrying out corresponding decryption processing on the characters to be decrypted to obtain the decrypted characters.
Specifically, if the user is a receiving user who needs to decrypt a text, when the receiving user receives an encrypted text sent by a corresponding sending user, the encrypted text is used as a text to be decrypted, and is input into an input box of an input method, for example, by means of copying and pasting, and the like, in step S601, the device 1 obtains the text to be decrypted input into the input box of the input method by the receiving user, for example, by calling an Application Program Interface (API) provided by the user equipment or other agreed communication manners one or more times, where the text to be decrypted includes identification information of the corresponding sending user, such as identification information of an account number, an IP address, a device number, and the like of the sending user; subsequently, the receiving user performs decryption operation by, for example, clicking a decryption button on an input panel corresponding to an input method, in step S602, the device 1 extracts, based on the decryption operation of the receiving user on the input panel corresponding to the input method, identification information of a corresponding sending user, such as account information, an IP address, an equipment number, and the like of the sending user, from a specific field of the text to be decrypted, and further, in step S602, the device 1 determines whether the sending user corresponding to the identification information is in the same session with the receiving user, that is, determines whether the sending user and the receiving user are communicating; if yes, in step S602, the device 1 performs corresponding decryption processing on the text to be decrypted to obtain a decrypted text, and then, in step S603, the device 1 provides the decrypted text to the receiving user in the input box of the input method; if not, in step S602, the device 1 does not perform any processing on the text to be decrypted.
Preferably, the user is a receiving user who needs to decrypt characters, wherein in step S601, the device 1 obtains characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted include time-based information; in step S602, the device 1 determines whether the aging information is valid based on the decryption operation of the receiving user on the input panel corresponding to the input method; and if so, carrying out corresponding encryption/decryption processing on the characters to be decrypted to obtain the decrypted characters.
Specifically, if the user is a receiving user who needs to decrypt a text, when the receiving user receives an encrypted text sent by a corresponding sending user, the encrypted text is used as a text to be decrypted, and is input into an input box of an input method, for example, by means of copying and pasting, and in step S601, the apparatus 1 obtains the text to be decrypted, which is input into the input box of the input method by the receiving user, for example, by calling an Application Program Interface (API) provided by the user equipment or other agreed communication methods one or more times, where the text to be decrypted includes aging information. Here, the time-based information may be, for example, only time information indicating a specific time at which the sending user performs an encryption operation by clicking a specific button on an input panel of the input method; or a time period threshold information, which may specify that the encrypted text is valid to be decrypted within a time period threshold, for example, within 5 minutes, when the receiving user receives the encrypted text; alternatively, the time-based information may be a combination of time information and time-based threshold information, which may include a specific time indicating that the sending user performed the encryption operation on the input panel of the input method, or a time-based threshold specifying that the receiving user is valid to decrypt the encrypted text within a time-based threshold after the specific time that the sending user performed the encryption operation.
Subsequently, the receiving user performs decryption operation by, for example, clicking a decryption button on an input panel corresponding to the input method, in step S602, the apparatus 1 extracts corresponding aging information from the specific field of the text to be decrypted based on the decryption operation of the receiving user on the input panel corresponding to the input method, and determines whether the aging information is valid based on the current time; if yes, in step S602, the device 1 performs corresponding decryption processing on the text to be decrypted to obtain a decrypted text, and then, in step S603, the device 1 provides the decrypted text to the receiving user in the input box of the input method; if not, in step S602, the device 1 does not perform any processing on the text to be decrypted.
For example, in the process that the receiving user carries out a chat conversation with the corresponding sending user, the receiving user receives the encrypted text "i eat roasted pork rice today" sent by the sending user, wherein the encrypted text comprises aging information, for example, the specific time "11 months, 3 months, 12:00 days in beijing, 2016", that the sending user clicks an encryption button in an input panel corresponding to an input method is included, and of course, the aging information may not be displayed to the receiving user; subsequently, the receiving user inputs the encrypted text "i eat roasted pork rice today" into an input box of the input method, for example, by copying and pasting, and takes it as a text to be decrypted, and in step S601, the device 1 obtains the text to be decrypted, wherein the text to be decrypted includes age information "12: 00 12/11/3/2016/11/beijing time"; next, the receiving user clicks the decryption button in the input panel of the input method, and in step S602, the device 1 extracts the corresponding aging information "12: 00/3/11/2016/11/3/beijing" in beijing time from the specific field of the text "i eat roasted pork rice" to be decrypted based on this; assuming that the time period threshold preset by the system is 10 minutes, that is, the system is preset within 10 minutes after the specific time of the sending user for performing the encryption operation, and the decryption of the encrypted text by the receiving user is valid, in step S602, the apparatus 1 determines that the aging information is valid according to the current time, for example, the current time is 2016, 11, 3, 08 in beijing; subsequently, in step S602, the apparatus 1 performs corresponding decryption processing on the text to be decrypted, so as to obtain a decrypted text.
For another example, the aging information included in the encrypted text (text to be decrypted) received by the receiving user includes not only the specific time "beijing time 2016, 11, 3, 12: 00" when the sending user clicks the encryption button in the input panel corresponding to the input method, but also the corresponding time period threshold information of the decryption operation, such as 5 minutes, that is, only if the receiving user performs the decryption operation on the encrypted text within 5 minutes after the time when the sending user performs the encryption operation, the original text information can be decrypted; then in step S602, the device 1 determines that the aging information is invalid according to the current time, if the current time is 2016, 11, 3, 12:08 in beijing, and then in step S602, the device 1 does not perform any processing on the text to be decrypted.
Preferably, the user is a receiving user who needs to decrypt the text, wherein the method further comprises step S605 (not shown). In step S605, the device 1 receives the text to be decrypted sent by the corresponding sending user, where the text to be decrypted is displayed in a predetermined format; in step S601, the device 1 obtains the text to be decrypted, which is input by the receiving user in the input box of the input method and is displayed in the predetermined format.
Specifically, if the user is a receiving user who needs to decrypt the text, in step S605, the apparatus 1 receives the encrypted text sent by the corresponding sending user as the text to be decrypted, for example, by calling an Application Program Interface (API) provided by the user equipment or other appointed communication manners one or more times, where the text to be decrypted is displayed in a predetermined format, for example, in a predetermined format different from other normal conversations, such as in different fonts and font sizes, or in a form of thickening, tilting, or in a form of shading with a predetermined color, so as to distinguish from other messages, so as to prompt the receiving user to decrypt the message. Subsequently, the receiving user inputs the to-be-decrypted text displayed in the predetermined format into the input box of the input method by copying and pasting, and in step S601, the apparatus 1 obtains the to-be-decrypted text displayed in the predetermined format input by the receiving user in the input box of the input method, for example, by calling an Application Program Interface (API) provided by the user equipment or other appointed communication manners one or more times.
Here, the device 1 presents the encrypted text sent by the sending user to the receiving user in a predetermined format, so as to prompt the receiving user to decrypt and view the message, thereby further improving the use experience of the user.
Preferably, the present invention also provides a computer apparatus comprising one or more processors and memory for storing one or more computer programs; the one or more computer programs, when executed by the one or more processors, cause the one or more processors to perform operations as recited in any of steps S601-S605.
It is noted that the present invention may be implemented in software and/or in a combination of software and hardware, for example, the various means of the invention may be implemented using Application Specific Integrated Circuits (ASICs) or any other similar hardware devices. In one embodiment, the software program of the present invention may be executed by a processor to implement the steps or functions described above. Also, the software programs (including associated data structures) of the present invention can be stored in a computer readable recording medium, such as RAM memory, magnetic or optical drive or diskette and the like. Further, some of the steps or functions of the present invention may be implemented in hardware, for example, as circuitry that cooperates with the processor to perform various steps or functions.
It will be evident to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, and that the present invention may be embodied in other specific forms without departing from the spirit or essential attributes thereof. The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any reference sign in a claim should not be construed as limiting the claim concerned. Furthermore, it is obvious that the word "comprising" does not exclude other elements or steps, and the singular does not exclude the plural. A plurality of units or means recited in the system claims may also be implemented by one unit or means in software or hardware. The terms first, second, etc. are used to denote names, but not any particular order.
Claims (13)
1. A method of encrypting/decrypting text in an input method, wherein the method comprises:
a, acquiring characters to be encrypted/decrypted input by a user in an input box of an input method, wherein the user is a receiving user needing to decrypt the characters, and the step a comprises the following steps: acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise identification information of a corresponding sending user;
b, based on the encryption/decryption operation of the user on the input panel corresponding to the input method, performing corresponding encryption/decryption processing on the characters to be encrypted/decrypted to obtain the encrypted/decrypted characters, wherein the encryption operation comprises combining character strings with semantic logic stored in a password library, selecting a character string for the characters to be encrypted from the password library, establishing a temporary mapping relation between the characters to be encrypted and the character string, performing corresponding encryption processing on the characters to be encrypted to obtain the encrypted characters, wherein the user is a receiving user needing to decrypt the characters, and the step b comprises: judging whether a sending user corresponding to the identification information and the receiving user are in the same conversation process based on the decryption operation of the receiving user on an input panel corresponding to the input method; if so, carrying out corresponding decryption processing on the characters to be decrypted to obtain decrypted characters;
c, providing the encrypted/decrypted characters for the user in an input box of the input method, wherein the user comprises a sending user needing to encrypt the characters and a receiving user needing to decrypt the characters, and the sending user and the receiving user use the same input method.
2. The method of claim 1, wherein the user is a sending user who needs ciphertext, wherein the method further comprises:
and sending the encrypted characters to corresponding receiving users based on the sending operation of the sending users on the encrypted characters.
3. The method of claim 2, wherein the step b comprises:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and by combining the aging information of the encryption operation to obtain the encrypted characters.
4. A method according to claim 2 or 3, wherein said step b comprises:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on an input panel corresponding to the input method and by combining the identification information of the sending user to obtain the encrypted characters.
5. The method of claim 1, wherein the user is a receiving user who needs to decrypt text, wherein the step a comprises:
acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise aging information;
wherein the step b comprises:
judging whether the time efficiency information is effective or not based on the decryption operation of the receiving user on an input panel corresponding to the input method;
and if so, carrying out corresponding encryption/decryption processing on the characters to be decrypted to obtain the decrypted characters.
6. The method of claim 1 or 5, wherein the user is a recipient user who needs to decrypt text, wherein the method further comprises:
receiving characters to be decrypted sent by a corresponding sending user, wherein the characters to be decrypted are displayed in a preset format;
wherein the step a comprises:
and acquiring the characters to be decrypted, which are input by the receiving user in the input frame of the input method and are displayed in the preset format.
7. An apparatus for encrypting/decrypting text in an input method, wherein the apparatus comprises:
an obtaining device, configured to obtain a to-be-encrypted/decrypted text input by a user in an input box of an input method, where the user is a receiving user who needs to decrypt the text, and the obtaining device is configured to: acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise identification information of a corresponding sending user;
a processing device, configured to perform corresponding encryption/decryption processing on the text to be encrypted/decrypted based on an encryption/decryption operation of the user on an input panel corresponding to the input method, to obtain the encrypted/decrypted text, where the encryption operation includes combining a stored character string with semantic logic in a password library, selecting a character string from the password library for the text to be encrypted, establishing a temporary mapping relationship between the text to be encrypted and the character string, and performing corresponding encryption processing on the text to be encrypted to obtain the encrypted text, where the user is a receiving user who needs to decrypt the text, and the processing device is configured to: judging whether a sending user corresponding to the identification information and the receiving user are in the same conversation process based on the decryption operation of the receiving user on an input panel corresponding to the input method; if so, carrying out corresponding decryption processing on the characters to be decrypted to obtain decrypted characters;
and the providing device is used for providing the encrypted/decrypted characters to the users in the input frame of the input method, wherein the users comprise a sending user needing to encrypt the characters and a receiving user needing to decrypt the characters, and the sending user and the receiving user use the same input method.
8. The apparatus of claim 7, wherein the user is a sending user who needs ciphertext, wherein the apparatus further comprises:
and the sending device is used for sending the encrypted characters to corresponding receiving users based on the sending operation of the sending users on the encrypted characters.
9. The apparatus of claim 8, wherein the processing means is to:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on the input panel corresponding to the input method and by combining the aging information of the encryption operation to obtain the encrypted characters.
10. The apparatus of claim 8 or 9, wherein the processing means is to:
and performing corresponding encryption processing on the characters to be encrypted based on the encryption operation of the sending user on an input panel corresponding to the input method and by combining the identification information of the sending user to obtain the encrypted characters.
11. The apparatus of claim 7, wherein the user is a receiving user who needs to decrypt text, and wherein the obtaining means is configured to:
acquiring characters to be decrypted input by the receiving user in an input box of the input method, wherein the characters to be decrypted comprise aging information;
wherein the processing device is configured to:
judging whether the time efficiency information is effective or not based on the decryption operation of the receiving user on an input panel corresponding to the input method;
and if so, carrying out corresponding encryption/decryption processing on the characters to be decrypted to obtain the decrypted characters.
12. The apparatus of claim 7 or 11, wherein the user is a receiving user who needs to decrypt text, wherein the apparatus further comprises:
the receiving device is used for receiving characters to be decrypted sent by a corresponding sending user, wherein the characters to be decrypted are displayed in a preset format;
wherein the obtaining means is configured to:
and acquiring the characters to be decrypted, which are input by the receiving user in the input frame of the input method and are displayed in the preset format.
13. A computer device, the computer device comprising:
one or more processors;
a memory for storing one or more computer programs;
the one or more computer programs, when executed by the one or more processors, cause the one or more processors to implement the method of any of claims 1-6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610965362.3A CN106570405B (en) | 2016-11-04 | 2016-11-04 | Method and device for encrypting/decrypting characters in input method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610965362.3A CN106570405B (en) | 2016-11-04 | 2016-11-04 | Method and device for encrypting/decrypting characters in input method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106570405A CN106570405A (en) | 2017-04-19 |
CN106570405B true CN106570405B (en) | 2020-10-27 |
Family
ID=58535862
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610965362.3A Active CN106570405B (en) | 2016-11-04 | 2016-11-04 | Method and device for encrypting/decrypting characters in input method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106570405B (en) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109598143A (en) * | 2018-12-06 | 2019-04-09 | 叶云龙 | A kind of the Internet chat method for secret protection, device, equipment and storage medium |
CN111639323A (en) * | 2019-03-01 | 2020-09-08 | 北京搜狗科技发展有限公司 | Privacy confidentiality method and device |
CN111212065B (en) * | 2019-12-31 | 2021-08-27 | 海信集团有限公司 | Household appliance communication encryption method, household appliance and server |
CN111212068B (en) * | 2019-12-31 | 2022-02-08 | 北京升鑫网络科技有限公司 | Method for encrypting and decrypting characters by input method |
CN111371773A (en) * | 2020-02-28 | 2020-07-03 | 北京百度网讯科技有限公司 | Information sending and displaying method, device, equipment and storage medium |
CN112163239A (en) * | 2020-09-29 | 2021-01-01 | 维沃移动通信有限公司 | Privacy information protection method and device and electronic equipment |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101626294A (en) * | 2008-07-07 | 2010-01-13 | 华为技术有限公司 | Certifying method based on identity, method, equipment and system for secure communication |
CN102169535A (en) * | 2011-04-11 | 2011-08-31 | 桂林电子科技大学 | Text steganographic method based on keyword replacement |
CN102355353A (en) * | 2011-08-12 | 2012-02-15 | 无锡城市云计算中心有限公司 | Encrypted input method and encrypted communication method and device |
CN104270517A (en) * | 2014-09-23 | 2015-01-07 | 中兴通讯股份有限公司 | Information encryption method and mobile terminal |
CN104660589A (en) * | 2015-01-20 | 2015-05-27 | 中兴通讯股份有限公司 | Method and system for controlling encryption of information and analyzing information as well as terminal |
CN105898740A (en) * | 2016-06-12 | 2016-08-24 | Tcl集团股份有限公司 | Information encryption and decryption method and system based on mobile device communication |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
DE60236094D1 (en) * | 2001-08-13 | 2010-06-02 | Univ R | Identity-based encryption systems and methods and related cryptographic techniques |
US7546465B2 (en) * | 2002-10-17 | 2009-06-09 | At&T Intellectual Property I, L.P. | Instant messaging private tags |
CN102098391B (en) * | 2011-04-01 | 2014-12-03 | 华为数字技术(成都)有限公司 | Communication terminal and communication information processing method thereof |
CN104980397B (en) * | 2014-04-03 | 2019-04-26 | 腾讯科技(深圳)有限公司 | Instant communicating method, system and terminal |
CN105554741A (en) * | 2015-06-30 | 2016-05-04 | 宇龙计算机通信科技(深圳)有限公司 | Communication information transmission method and system, and apparatus |
CN105898736A (en) * | 2016-05-25 | 2016-08-24 | 努比亚技术有限公司 | Mobile terminal and control method |
-
2016
- 2016-11-04 CN CN201610965362.3A patent/CN106570405B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101626294A (en) * | 2008-07-07 | 2010-01-13 | 华为技术有限公司 | Certifying method based on identity, method, equipment and system for secure communication |
CN102169535A (en) * | 2011-04-11 | 2011-08-31 | 桂林电子科技大学 | Text steganographic method based on keyword replacement |
CN102355353A (en) * | 2011-08-12 | 2012-02-15 | 无锡城市云计算中心有限公司 | Encrypted input method and encrypted communication method and device |
CN104270517A (en) * | 2014-09-23 | 2015-01-07 | 中兴通讯股份有限公司 | Information encryption method and mobile terminal |
CN104660589A (en) * | 2015-01-20 | 2015-05-27 | 中兴通讯股份有限公司 | Method and system for controlling encryption of information and analyzing information as well as terminal |
CN105898740A (en) * | 2016-06-12 | 2016-08-24 | Tcl集团股份有限公司 | Information encryption and decryption method and system based on mobile device communication |
Also Published As
Publication number | Publication date |
---|---|
CN106570405A (en) | 2017-04-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106570405B (en) | Method and device for encrypting/decrypting characters in input method | |
US10972908B2 (en) | Wireless network connection method, apparatus, and system | |
US8769260B1 (en) | Messaging system with user-friendly encryption and decryption | |
CN109214201B (en) | Data sharing method, terminal equipment and computer readable storage medium | |
CN112287372B (en) | Method and apparatus for protecting clipboard privacy | |
US9659189B2 (en) | Systems and methods of safeguarding user information while interacting with online service providers | |
CN101534311A (en) | Information security method and program | |
JP2019503533A5 (en) | ||
CN107026824A (en) | A kind of message encryption, decryption method and device | |
WO2016045464A1 (en) | Decryption method and mobile terminal | |
CN104660589A (en) | Method and system for controlling encryption of information and analyzing information as well as terminal | |
US11245530B2 (en) | System and method for secure communication | |
US12120098B2 (en) | Encrypting e-mail and other digital data using quantum random number generator | |
CN104573548A (en) | Information encryption and decryption methods and devices and terminal | |
CN109977703A (en) | A kind of encryption method of safety keyboard, storage medium and terminal device | |
US20140095319A1 (en) | Text-Based Communication Services Based On User-Specified Privacy Settings | |
CN103701586A (en) | Method and device for acquiring secret key | |
Al-Sanjary et al. | A new approach to optimum steganographic algorithm for secure image | |
JP2023532976A (en) | Method and system for verification of user identity | |
TW201720093A (en) | Secure input method, device and system | |
Fahl et al. | Trustsplit: usable confidentiality for social network messaging | |
CN109120576B (en) | Data sharing method and device, computer equipment and storage medium | |
GB2562288A (en) | Methods and systems for intelligently conducting encryption in chat room communications | |
US20160294787A1 (en) | Secure and confidential messaging systems | |
CN116112172B (en) | Android client gRPC interface security verification method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |