CN110188532B - Password protection method and device - Google Patents

Password protection method and device Download PDF

Info

Publication number
CN110188532B
CN110188532B CN201910366166.8A CN201910366166A CN110188532B CN 110188532 B CN110188532 B CN 110188532B CN 201910366166 A CN201910366166 A CN 201910366166A CN 110188532 B CN110188532 B CN 110188532B
Authority
CN
China
Prior art keywords
abscissa
character
cursor
determining
click
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
Application number
CN201910366166.8A
Other languages
Chinese (zh)
Other versions
CN110188532A (en
Inventor
吕滨
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Gree Electric Appliances Inc of Zhuhai
Original Assignee
Gree Electric Appliances Inc of Zhuhai
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Gree Electric Appliances Inc of Zhuhai filed Critical Gree Electric Appliances Inc of Zhuhai
Priority to CN201910366166.8A priority Critical patent/CN110188532B/en
Publication of CN110188532A publication Critical patent/CN110188532A/en
Application granted granted Critical
Publication of CN110188532B publication Critical patent/CN110188532B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/30Authentication, i.e. establishing the identity or authorisation of security principals
    • G06F21/45Structures or tools for the administration of authentication

Abstract

The application discloses a password protection method and a password protection device, which belong to the technical field of information security, and the method comprises the following steps: detecting that a cursor is positioned in a control for inputting a password, if the position number of the position where the cursor is positioned is determined to be positioned in a position number set of a predetermined position to be interfered, after a received character is added to the position where the cursor is positioned, determining position information of a simulated click position, sending the position information to a currently used input method application, and triggering the input method application to determine the character which is simulated click on a currently displayed input interface according to the position information; the method comprises the steps of receiving information of characters sent by an input method application, and controlling not to add the characters into the control, so that some characters are inserted in the process of inputting the password, the inserted characters are not added into the control for inputting the password, the password character string memorized by a third-party input method can be disturbed, and normal password input is not influenced, and therefore the safety of the terminal can be improved.

Description

Password protection method and device
Technical Field
The present application relates to the field of information security technologies, and in particular, to a password protection method and apparatus.
Background
At present, the variety of terminals, such as mobile phones and ipads, is increasing, and various terminals have become essential electronic products in daily life.
Generally, a terminal is provided with a third-party input method, such as a dog searching input method, a Baidu input method and the like, and the third-party input methods have the following characteristics: the character strings frequently input by the user are recorded, and the character strings frequently input by the user and beginning with the character are automatically prompted as soon as the user inputs the first character, see figure 1, FIG. 1 is a diagram of a character string with a first character as a beginning part frequently input by a user prompted by a third-party input method after the user inputs the first character in a control for inputting a password provided by the prior art, in fig. 1, the user sets a screen-locking password of "qwe 147", and after a plurality of inputs, the third-party input method records the character string, and then once the user inputs the initial letter "q" in the password input box, the third-party input method prompts the commonly-used character string "qwe 147", which facilitates the user to input the password, however, the third-party input method has great potential safety hazard when remembering the password of the user, and if the terminal loses the third-party input method, the correct screen locking password can be easily reminded for others.
Therefore, the problem that the security of the terminal is low due to the fact that the third-party input method in the terminal remembers the password of the user exists in the prior art.
Disclosure of Invention
The embodiment of the application provides a password protection method and device, which are used for solving the problem that in the prior art, a third-party input method in a terminal can remember a password of a user, so that the security of the terminal is low.
In a first aspect, an embodiment of the present application provides a password protection method, including:
detecting that a cursor is positioned in a control for inputting a password;
if the position number of the current cursor position is determined to be in a position number set of a predetermined position to be interfered, after a received character is added to the cursor position, position information of a simulated click position is determined, the position information is sent to a currently used input method application, and the input method application is triggered to determine the character simulated click on a currently displayed input interface according to the position information;
and receiving the information of the characters sent by the input method application, and controlling not to add the characters into the control.
In the embodiment of the application, a cursor is detected to be positioned in a control for inputting a password, if the position number of the position where the cursor is positioned is determined to be positioned in a position number set of a predetermined position to be interfered, after a received character is added to the position where the cursor is positioned, the position information of a simulated click position is determined, the position information is sent to a currently used input method application, the input method application is triggered to determine the character which is simulated to click on a currently displayed input interface according to the position information, the information of the character sent by the input method application is received, and the character is controlled not to be added into the control, so that some characters are inserted in the process of inputting the password, the inserted characters are not added into the control for inputting the password, normal password input is not influenced, and character strings forming the password memorized by a third-party input method can be disordered, even if the third-party input method has the input character reminding function, password information of the user cannot be easily revealed, and therefore the safety of the terminal can be improved.
Optionally, determining the position information of the simulated click position includes:
and determining the position information of the simulated click position according to the position information of the click position of the character added to the position of the cursor.
Optionally, determining the position information of the simulated click position according to the position information of the click position added to the character at the position of the cursor includes:
determining a vertical coordinate of a click position added to a character at a position where the cursor is located as a vertical coordinate of the simulated click position; and
if the abscissa of the clicking position of the character added to the position of the cursor is determined to be larger than or equal to half of the width of the terminal screen, determining the abscissa of the simulated clicking position according to the abscissa; and if the abscissa of the click position of the character added to the position of the cursor is smaller than half of the width of the terminal screen, determining the abscissa of the simulated click position according to the abscissa and the width of the terminal screen.
By adopting the scheme, the position of the simulated click can be positioned in the input interface, and the reality of the simulated click is higher.
Optionally, determining the abscissa of the simulated click position according to the abscissa includes:
and determining one M of the abscissa as the abscissa of the simulated click position, wherein M is an integer greater than 1.
Optionally, determining the abscissa of the simulated click position according to the abscissa and the width of the terminal screen includes:
and determining one N of the sum of the abscissa and the width of the terminal screen as the abscissa of the simulated click position, wherein N is an integer greater than 1.
Optionally, determining the position information of the simulated click position includes:
selecting a character from a target character set, wherein each character in the target character set meets the set requirement of being used as a password character in the control;
and determining the position information of the click position corresponding to the selected character according to the corresponding relation between the stored character and the position information of the click position.
By adopting the scheme, the position of the simulated click can be positioned in the input interface, and the reality of the simulated click is higher.
In a second aspect, an embodiment of the present application provides a password protection device, including:
the detection module is used for detecting that a cursor is positioned in a control for inputting a password;
the simulation module is used for determining position information of a simulated click position after a received character is added to the position of the cursor if the position number of the position of the cursor is determined to be in a position number set of a predetermined position to be interfered, sending the position information to a currently used input method application, and triggering the input method application to determine the character which is simulated click on a currently displayed input interface according to the position information;
and the control module is used for receiving the information of the characters sent by the input method application and controlling not to add the characters into the control.
Optionally, the simulation module is specifically configured to:
and determining the position information of the simulated click position according to the position information of the click position of the character added to the position of the cursor.
Optionally, the simulation module is specifically configured to:
determining a vertical coordinate of a click position added to a character at a position where the cursor is located as a vertical coordinate of the simulated click position; and
if the abscissa of the clicking position of the character added to the position of the cursor is determined to be larger than or equal to half of the width of the terminal screen, determining the abscissa of the simulated clicking position according to the abscissa; and if the abscissa of the click position of the character added to the position of the cursor is smaller than half of the width of the terminal screen, determining the abscissa of the simulated click position according to the abscissa and the width of the terminal screen.
Optionally, the simulation module is specifically configured to:
and determining one M of the abscissa as the abscissa of the simulated click position, wherein M is an integer greater than 1.
Optionally, the simulation module is specifically configured to:
and determining one N of the sum of the abscissa and the width of the terminal screen as the abscissa of the simulated click position, wherein N is an integer greater than 1.
Optionally, the simulation module is specifically configured to:
selecting a character from a target character set, wherein each character in the target character set meets the set requirement of being used as a password character in the control;
and determining the position information of the click position corresponding to the selected character according to the corresponding relation between the stored character and the position information of the click position.
In a third aspect, an electronic device provided in an embodiment of the present application includes: at least one processor, and a memory communicatively coupled to the at least one processor, wherein:
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the above-described password protection method.
In a fourth aspect, an embodiment of the present application provides a computer-readable medium storing computer-executable instructions for performing the above password protection method.
In addition, for technical effects brought by any one of the design manners in the second aspect to the fourth aspect, reference may be made to technical effects brought by different implementation manners in the first aspect, and details are not described here.
These and other aspects of the present application will be more readily apparent from the following description of the embodiments.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
FIG. 1 is a schematic diagram of a character string with a first character as a beginning part, which is frequently input by a user and is reminded by a third-party input method after the user inputs the first character in a control for inputting a password, provided by the prior art;
fig. 2 is a schematic structural diagram of a terminal for implementing a password protection method according to an embodiment of the present application;
fig. 3 is a flowchart of a password protection method provided in an embodiment of the present application;
fig. 4 is a schematic diagram illustrating determining position information of a simulated click position according to position information of a click position of a character added to a control according to an embodiment of the present application;
fig. 5 is a schematic diagram of a character string, which is first of a character and is frequently input by a user prompted by a third-party input method after the user inputs the first character in a control for inputting a password according to an embodiment of the present application;
fig. 6 is a schematic hardware structure diagram of an electronic device for implementing a password protection method according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of a password protection device according to an embodiment of the present application.
Detailed Description
In order to solve the problem that in the prior art, a third-party input method in a terminal can remember a password of a user, so that the security of the terminal is low, the embodiment of the application provides a password protection method and a password protection device.
The preferred embodiments of the present application will be described below with reference to the accompanying drawings of the specification, it should be understood that the preferred embodiments described herein are merely for illustrating and explaining the present application, and are not intended to limit the present application, and that the embodiments and features of the embodiments in the present application may be combined with each other without conflict.
In the embodiment of the application, a cursor is detected to be positioned in a control for inputting a password, if the position number of the position where the cursor is positioned is determined to be positioned in a position number set of a predetermined position to be interfered, after a received character is added to the position where the cursor is positioned, the position information of a simulated click position is determined, the position information is sent to a currently used input method application, the input method application is triggered to determine the character which is simulated to click on a currently displayed input interface according to the position information, the information of the character sent by the input method application is received, and the character is controlled not to be added into the control, so that some characters are inserted in the process of inputting the password, the inserted characters are not added into the control for inputting the password, normal password input is not influenced, and character strings forming the password memorized by a third-party input method can be disordered, even if the third-party input method has the input character reminding function, password information of the user cannot be easily revealed, and therefore the safety of the terminal can be improved.
The terminal in the embodiment of the present application may be a mobile terminal, such as a mobile phone, an IPad, and the like, and fig. 2 shows a schematic structural diagram of a terminal 200. Referring to fig. 2, the terminal 200 includes: a processor 210, a memory 220, a display unit 230, an input unit 240, a sensor 250, a Radio Frequency (RF) circuit 260, and a power supply 270, etc.
The processor 210 is a control center of the terminal device 200, connects various components by using various interfaces and lines, and executes various functions of the terminal device 200 by running or executing software programs and/or data stored in the memory 220, thereby performing overall monitoring of the terminal device.
The memory 220 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, various application programs, and the like; the storage data area may store data created according to the use of the terminal device 200, and the like. Further, the memory 220 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device, among others.
The Display unit 230 may be used to Display information input by or provided to the user and various menus and the like of the terminal apparatus 200, and the Display unit 230 may include a Display panel 231, and the Display panel 231 may be configured in the form of a Liquid Crystal Display (LCD), an organic light-Emitting Diode (OLED), and the like.
The input unit 240 may be used to receive information such as numbers or characters input by a user. The input unit 240 may include a touch panel 241 and other input devices 242, wherein the touch panel 241, also referred to as a touch screen, may collect touch operations by a user on or near the touch panel 241 (such as operations by a user on or near the touch panel 241 using any suitable object or accessory such as a finger, a stylus, etc.). Specifically, the touch panel 241 may detect a touch operation of a user, detect signals caused by the touch operation, convert the signals into touch point coordinates, transmit the touch point coordinates to the processor 220, receive a command transmitted from the processor 220, and execute the command. In addition, the touch panel 241 may be implemented by various types, such as a resistive type, a capacitive type, an infrared ray, and a surface acoustic wave. Other input devices 242 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, power on/off keys, etc.), a trackball, a mouse, a joystick, and the like.
Of course, the touch panel 241 may cover the display panel 231, and when the touch panel 241 detects a touch operation on or near the touch panel 241, the touch panel is transmitted to the processor 220 to determine the type of the touch event, and then the processor 220 provides a corresponding visual output on the display panel 231 according to the type of the touch event. Although in fig. 2, the touch panel 241 and the display panel 231 are implemented as two separate components to implement the input and output functions of the terminal device 200, in some embodiments, the touch panel 241 may be integrated with the display panel 231 to implement the input and output functions of the terminal device 200.
The terminal 200 may also include one or more sensors 250, such as acceleration sensors, light sensors, and distance sensors, among others.
The terminal 200 may also include RF circuitry 260 that may be used for transmitting and receiving information or data to and from base stations. Generally, the RF circuit 260 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In the present embodiment, the RF circuitry 260 may communicate with the network and other electronic devices via wireless communications using any communications standard or protocol.
Terminal 200 also includes a power supply 270 (e.g., a battery) for powering the various components, which may be logically coupled to processor 220 via a power management system to manage charging, discharging, and power consumption via the power management system.
Of course, the terminal 200 may also include other components such as an earphone, a camera, an audio circuit, a speaker, etc., which are not shown in fig. 2 and will not be described in detail herein, according to the requirements of a specific application.
Referring to fig. 3, fig. 3 is a flowchart of a password protection method provided in the present application, and in the following description, taking the application of the method to the terminal 200 shown in fig. 2 as an example, a specific implementation flow of the method is as follows:
s301: a cursor is detected in a control for entering a password.
S302: judging whether the position number of the position of the current cursor is in a position number set of a predetermined position to be interfered, if so, entering S303; otherwise, S306 is entered.
In a possible implementation manner, the position numbers in the position number set of the positions to be interfered have the same value after a preset value is left, wherein the preset value is an integer larger than 1 and smaller than Q, Q is the total number of positions in the control, and generally Q is an even number.
For example, if the preset value is 2, the values obtained by subtracting 2 from the position numbers in the position number set of the positions to be interfered are all 0, the position number set of the positions to be interfered is {2,4,6,8 … … Q }, the values obtained by subtracting 2 from the position numbers in the position number set of the positions to be interfered are all 1, and the position number set of the positions to be interfered is {1,3,5,7 … … Q-1 }.
In another possible implementation, each number in the position number set of the to-be-interfered position may also be randomly selected from integers between 1 and Q, for example, the position number set of the to-be-interfered position is {1,2,4,5 … … Q-1}, or {1,2,3 }.
S303: after adding the received one character to the position where the cursor is located, position information simulating the click position is determined.
In specific implementation, after a terminal detects that a user clicks a certain position on a screen, the position information of the position can be sent to an input method application, the input method application determines a character clicked on a current input interface by the user according to the position information, sends the character to the terminal, and adds the character to a control for inputting a password by the terminal, so that the input of one character is completed.
In one possible embodiment, the position information of the simulated click position may be determined from position information added to the click position of the character at the position of the cursor.
For example, if the coordinates of the click position added to the character at the position of the cursor are (x, y) and the interval between two adjacent characters is (Δ x, Δ y), then (x + Δ x, y) may be used as the coordinate information of the simulated click position, and (x- Δ x, y) may also be used as the coordinate information of the simulated click position.
For another example, when the origin of coordinates is located on the long side of the terminal screen, the ordinate of the click position of the character added to the position where the cursor is located may be determined as the ordinate of the simulated click position; if the abscissa of the click position of the character added to the position of the cursor is determined to be greater than or equal to half of the width W of the terminal screen, determining the abscissa of the simulated click position according to the abscissa, for example, determining one M of the abscissa as the abscissa of the simulated click position, wherein M is an integer greater than 1; if it is determined that the abscissa of the click position of the character added to the position of the cursor is smaller than half the width W of the terminal screen, the abscissa of the simulated click position may be determined according to the abscissa and the width W of the terminal screen, for example, one-N part of the sum of the abscissa and the width of the terminal screen is determined as the abscissa of the simulated click position, where N is an integer greater than 1.
Specifically, referring to fig. 4, fig. 4 is a schematic diagram of determining position information of a simulated click position according to position information of a click position of a character added to a control according to an embodiment of the present application, where an origin of coordinates is located at an upper left vertex of a terminal screen, and assuming that the coordinate information of the click position of the character added to a position where a cursor is located is (x, y), if x < W, the coordinate of the simulated click position may be (x + (W-x)/2, y); if x > W/2, the coordinates of the simulated click position may be (x/2, y), wherein if the abscissa x/2, x + (W-x)/2 of the simulated click position is exactly between two character keys, the abscissa x/2 may be shifted to the right by a predetermined number of pixels, e.g., 5 pixels, to ensure that one character can be fetched.
Continuing with FIG. 4, if the character entered at a certain time is q, the coordinate of the click position of q is (x1, y1), since x1< W, the coordinate of the simulated click position is (x1+ (W-x1)/2, y1), if the character entered at a certain time is k, the coordinate of the click position of k is (x2, y2), since x2> W/2, the coordinate of the simulated click position is (x2/2, y 2).
Generally, the characters that can be used as the password are letters, numbers and underlines, so some characters can be selected from the characters to form a target character set, and then the character to be clicked is selected from the target character set, so in one possible implementation, the position information of the simulated click position is also determined according to the following steps: selecting a character from the target character set, and determining the position information of the click position corresponding to the selected character according to the corresponding relation between the stored character and the position information of the click position, wherein each character in the target character set meets the set requirement of being used as the password character in the control.
S304: and sending the position information to the input method application which is currently used, and triggering the input method application to determine the character which is simulated to be clicked on the input interface which is currently displayed according to the position information.
In specific implementation, the input method application cannot sense whether the terminal screen is clicked, and can determine the character clicked by the user only according to the position information of the click position sent by the terminal.
S305: and receiving information of characters simulating clicks, sent by the input method application, and controlling not to add the characters into the control.
In specific implementation, the character of the simulated click is used for disturbing the password information memorized by the input method application and is not contained in the password characters set by the user, so that the character of the simulated click sent by the received input method application can be controlled not to be added into the control, the normal password input of the user cannot be influenced, and the user experience is better.
S306: adding the received character to the position of the cursor.
Subsequently, if a password submission request is received, all characters in the control are submitted.
The above process is described below with reference to specific embodiments.
Assuming that the total number of positions of the control for inputting the lock screen password is 8, the position numbers are position 1, position 2 … … and position 8 from left to right, the position number set of the predetermined positions to be interfered is {1,3,5, 7}, and the lock screen password set by the user is assumed to be "qwe 147".
In a specific implementation, when the cursor is located in the control for inputting the password, the cursor is located at position 1 first, and position 1 is located in the position number set {1,3,5, 7} of the to-be-interfered position, then the terminal may determine position information of the simulated click position after adding a character "q" of the received user input to position 1 of the cursor, where the coordinate information of the click position of "q" is (x1, y1) and x1< W, and therefore, the coordinate information of the simulated click position is (x1+ (W-x1)/2, y1), and then the terminal may transmit the coordinate information (x1+ (W-x1)/2, y1) to the currently used input method application, trigger the input method application to determine the character simulated click on the currently displayed input interface according to (x1+ (W-x1)/2, y1), the character is sent to the terminal, the terminal controls not to add the character to the control after receiving the character, and if the character at (x1+ (W-x1)/2, y1) is 'y', the third-party input method remembers 'qy'.
Further, the cursor moves to the position 2 in the control, and the position 2 is not located in the position number set {1,3,5, 7} of the position to be interfered, so the terminal only needs to add the character "w" of the received user input to the position 2 where the cursor is located, and at this time, the third-party input method remembers "qyw".
Further, the cursor moves to the position 3 in the control, the position 3 is located in the position number set {1,3,5, 7} of the position to be interfered, at this time, after adding the received character "e" to the position 3 where the cursor is located, the terminal re-determines the position information of the simulated click position, wherein the coordinate information of the click position of "e" is (x3, y3), x3< W, and therefore, the coordinate information of the simulated click position is (x3+ (W-x3)/2, y3), sends the coordinate information (x3+ (W-x3)/2, y3) to the currently used input method application, triggers the input method application to determine the character simulated click on the currently displayed input interface according to (x3+ (W-x3)/2, y3), sends the character to the terminal, and the terminal controls not to add the character to the control after receiving the character, assuming that the character at (x3+ (W-x3)/2, y3) is "u", then the third-party input method remembers "qyweu".
Further, the cursor moves to the position 4 in the control, the position 4 is not located in the position number set {1,3,5, 7} of the position to be interfered, the terminal only needs to add the received character "1" input by the user to the position 4 where the cursor is located, and at this time, the third-party input method remembers "qyweu 1".
Further, the cursor moves to the position 5 in the control, the position 5 is located in the position number set {1,3,5, 7} of the position to be interfered, representing that the terminal needs to re-determine the position information of the simulated click position after adding the received character "4" to the position 5 where the cursor is located, wherein the coordinate information of the click position of "4" is (x4, y4), x4< W, and therefore, the coordinate information of the simulated click position is (x4+ (W-x4)/2, y4), then the terminal sends the coordinate information (x4+ (W-x4)/2, y4) to the currently used input method application, the triggering input method application determines the character simulated click on the currently displayed input interface according to (x4+ (W-x4)/2, y4), sends the character to the terminal, and the terminal controls not to add the character to the control after receiving the character, assuming that the character at (x4+ (W-x4)/2, y4) is "6", then the third-party input method remembers "qyweu 146".
Further, the cursor moves to a position 6 in the control, the position 6 is not located in the position number set {1,3,5, 7} of the position to be interfered, the terminal only needs to add one character "7" of the received user input to the position 6 where the cursor is located, and at this time, the third-party input method remembers "qyweu 1467".
By this time, the user completes the input of the screen-locking password, and through the process, the third-party input method eventually remembers the character string "qyweu 1467", and then, once the initial character "q" input by the user is detected, the third-party input method prompts "qyweu 1467", as shown in fig. 5.
According to the method and the device, the password memorized by the third-party input method can be inserted into some characters, so that the correct character string related to the user password cannot be prompted by the third-party input method, and related operations cannot be performed naturally, and therefore the safety of the terminal can be improved.
Referring to fig. 6, a schematic structural diagram of an electronic device provided in this embodiment of the present disclosure includes a transceiver 601 and a processor 602, where the processor 602 may be a Central Processing Unit (CPU), a microprocessor, an application specific integrated circuit, a programmable logic circuit, a large scale integrated circuit, or a digital processing unit. The transceiver 601 is used for data transmission and reception between the electronic device and other devices.
The electronic device may further comprise a memory 603 for storing software instructions executed by the processor 602, but may also store some other data required by the electronic device, such as identification information of the electronic device, encryption information of the electronic device, user data, etc. The memory 603 may be a volatile memory (volatile memory), such as a random-access memory (RAM); the memory 603 may also be a non-volatile memory (non-volatile memory) such as a read-only memory (ROM), a flash memory (flash memory), a Hard Disk Drive (HDD) or a solid-state drive (SSD), or the memory 603 may be any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited to this. The memory 603 may be a combination of the above memories.
The specific connection medium between the processor 602, the memory 603 and the transceiver 601 is not limited in the embodiment of the present application. In fig. 6, the embodiment of the present application is described by taking only the case where the memory 603, the processor 602, and the transceiver 601 are connected by the bus 604 as an example, the bus is shown by a thick line in fig. 6, and the connection manner between other components is merely illustrative and not limited. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in FIG. 6, but this is not intended to represent only one bus or type of bus.
The processor 602 may be dedicated hardware or a processor running software, and when the processor 602 may run software, the processor 602 reads software instructions stored in the memory 603 and executes the password protection method involved in the foregoing embodiments under the drive of the software instructions.
When the method provided in the embodiments of the present application is implemented in software or hardware or a combination of software and hardware, a plurality of functional modules may be included in the electronic device, and each functional module may include software, hardware or a combination of software and hardware. Specifically, referring to fig. 7, a schematic structural diagram of a password protection device provided in the embodiment of the present application includes a detection module 701, an analog module 702, and a control module 703.
A detecting module 701, configured to detect that a cursor is located in a control for inputting a password;
a simulation module 702, configured to determine, after adding a received character to the position of the cursor, position information of a simulated click position if it is determined that the position number of the position of the cursor is located in a position number set of a predetermined to-be-interfered position, send the position information to a currently used input method application, and trigger the input method application to determine, according to the position information, a character to be simulated click on a currently displayed input interface;
the control module 703 is configured to receive information of the character sent by the input method application, and control not to add the character to the control.
Optionally, the simulation module 702 is specifically configured to:
and determining the position information of the simulated click position according to the position information of the click position of the character added to the position of the cursor.
Optionally, the simulation module 702 is specifically configured to:
determining a vertical coordinate of a click position added to a character at a position where the cursor is located as a vertical coordinate of the simulated click position; and
if the abscissa of the clicking position of the character added to the position of the cursor is determined to be larger than or equal to half of the width of the terminal screen, determining the abscissa of the simulated clicking position according to the abscissa; and if the abscissa of the click position of the character added to the position of the cursor is smaller than half of the width of the terminal screen, determining the abscissa of the simulated click position according to the abscissa and the width of the terminal screen.
Optionally, the simulation module 702 is specifically configured to:
and determining one M of the abscissa as the abscissa of the simulated click position, wherein M is an integer greater than 1.
Optionally, the simulation module 702 is specifically configured to:
and determining one N of the sum of the abscissa and the width of the terminal screen as the abscissa of the simulated click position, wherein N is an integer greater than 1.
Optionally, the simulation module 702 is specifically configured to:
selecting a character from a target character set, wherein each character in the target character set meets the set requirement of being used as a password character in the control;
and determining the position information of the click position corresponding to the selected character according to the corresponding relation between the stored character and the position information of the click position.
The division of the modules in the embodiments of the present application is schematic, and only one logical function division is provided, and in actual implementation, there may be another division manner, and in addition, each functional module in each embodiment of the present application may be integrated in one processor, may also exist alone physically, or may also be integrated in one module by two or more modules. The coupling of the various modules to each other may be through interfaces that are typically electrical communication interfaces, but mechanical or other forms of interfaces are not excluded. Thus, modules described as separate components may or may not be physically separate, may be located in one place, or may be distributed in different locations on the same or different devices. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode.
An embodiment of the present application further provides a terminal including the apparatus in any one of the above embodiments.
The embodiment of the present application further provides a computer-readable storage medium, which stores computer-executable instructions required to be executed by the processor, and includes a program required to be executed by the processor.
In some possible embodiments, the various aspects of the password protection method provided in the present application may also be implemented in the form of a program product, which includes program code for causing an electronic device to perform the steps in the password protection method according to various exemplary embodiments of the present application described above in this specification, when the program product is run on the electronic device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
The program product for password protection of embodiments of the present application may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a computing device. However, the program product of the present application is not limited thereto, and in this document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
A readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations of the present application may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device over any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., over the internet using an internet service provider).
It should be noted that although several units or sub-units of the apparatus are mentioned in the above detailed description, such division is merely exemplary and not mandatory. Indeed, the features and functions of two or more units described above may be embodied in one unit, according to embodiments of the application. Conversely, the features and functions of one unit described above may be further divided into embodiments by a plurality of units.
Further, while the operations of the methods of the present application are depicted in the drawings in a particular order, this does not require or imply that these operations must be performed in this particular order, or that all of the illustrated operations must be performed, to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step execution, and/or one step broken down into multiple step executions.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all alterations and modifications as fall within the scope of the application.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present application without departing from the spirit and scope of the application. Thus, if such modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is intended to include such modifications and variations as well.

Claims (9)

1. A method of password protection, comprising:
detecting that a cursor is positioned in a control for inputting a password;
if the position number of the current cursor position is determined to be in a position number set of a predetermined position to be interfered, after a received character is added to the cursor position, position information of a simulated click position is determined according to the position information of the click position of the character added to the cursor position, the position information is sent to the input method application used currently, and the input method application is triggered to determine the character simulated click on the input interface displayed currently according to the position information;
receiving the information of the characters sent by the input method application, and controlling not to add the characters into the control;
determining position information of a simulated click position according to position information of a click position added to a character at a position where the cursor is located, including:
determining a vertical coordinate of a click position added to a character at a position where the cursor is located as a vertical coordinate of the simulated click position; and
if the abscissa of the clicking position of the character added to the position of the cursor is determined to be larger than or equal to half of the width of a terminal screen, determining the abscissa of the simulated clicking position according to the abscissa; and if the abscissa of the click position of the character added to the position of the cursor is smaller than half of the width of the terminal screen, determining the abscissa of the simulated click position according to the abscissa and the width of the terminal screen.
2. The method of claim 1, wherein determining the abscissa of the simulated click location from the abscissa comprises:
and determining one M of the abscissa as the abscissa of the simulated click position, wherein M is an integer greater than 1.
3. The method of claim 1, wherein determining the abscissa of the simulated click position based on the abscissa and the width of the terminal screen comprises:
and determining one N of the sum of the abscissa and the width of the terminal screen as the abscissa of the simulated click position, wherein N is an integer greater than 1.
4. A password protection device, comprising:
the detection module is used for detecting that a cursor is positioned in a control for inputting a password;
the simulation module is used for determining position information of a simulated click position according to the position information of the click position of the character added to the position of the cursor after adding a received character to the position of the cursor if the position number of the position of the cursor is determined to be in a position number set of a predetermined position to be interfered, sending the position information to a currently used input method application, and triggering the input method application to determine the character simulated click on a currently displayed input interface according to the position information;
the control module is used for receiving the information of the characters sent by the input method application and controlling not to add the characters into the control;
the simulation module is specifically configured to:
determining a vertical coordinate of a click position added to a character at a position where the cursor is located as a vertical coordinate of the simulated click position; and
if the abscissa of the clicking position of the character added to the position of the cursor is determined to be larger than or equal to half of the width of a terminal screen, determining the abscissa of the simulated clicking position according to the abscissa; and if the abscissa of the click position of the character added to the position of the cursor is smaller than half of the width of the terminal screen, determining the abscissa of the simulated click position according to the abscissa and the width of the terminal screen.
5. The apparatus of claim 4, wherein the simulation module is specifically configured to:
and determining one M of the abscissa as the abscissa of the simulated click position, wherein M is an integer greater than 1.
6. The apparatus of claim 4, wherein the simulation module is specifically configured to:
and determining one N of the sum of the abscissa and the width of the terminal screen as the abscissa of the simulated click position, wherein N is an integer greater than 1.
7. An electronic device, comprising: at least one processor, and a memory communicatively coupled to the at least one processor, wherein:
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1 to 3.
8. A computer-readable medium having stored thereon computer-executable instructions for performing the method of any of claims 1 to 3.
9. A terminal, characterised in that it comprises an apparatus according to any one of claims 4 to 6.
CN201910366166.8A 2019-05-05 2019-05-05 Password protection method and device Active CN110188532B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910366166.8A CN110188532B (en) 2019-05-05 2019-05-05 Password protection method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910366166.8A CN110188532B (en) 2019-05-05 2019-05-05 Password protection method and device

Publications (2)

Publication Number Publication Date
CN110188532A CN110188532A (en) 2019-08-30
CN110188532B true CN110188532B (en) 2020-12-15

Family

ID=67715673

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910366166.8A Active CN110188532B (en) 2019-05-05 2019-05-05 Password protection method and device

Country Status (1)

Country Link
CN (1) CN110188532B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111914248B (en) * 2020-08-18 2023-10-27 科大讯飞股份有限公司 Password input method, device, equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101101625A (en) * 2007-08-07 2008-01-09 江雨 Input data safe treatment method and device
CN104143068A (en) * 2014-07-16 2014-11-12 宇龙计算机通信科技(深圳)有限公司 Password authentication method and system
CN107633174A (en) * 2016-07-18 2018-01-26 中兴通讯股份有限公司 A kind of user inputs management method and device, terminal
CN108280374A (en) * 2018-02-27 2018-07-13 惠州Tcl移动通信有限公司 A kind of safe input control method of Mobile terminal keyboard, system and storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004138933A (en) * 2002-10-21 2004-05-13 Hitachi Ltd Digital image scrambling system, descrambling system, and program realizing the system
US10474807B2 (en) * 2005-08-01 2019-11-12 Danilo E. Fonseca Password/encryption protection
EP2054836B1 (en) * 2006-07-19 2019-05-29 Advanced Track And Trace Methods and devices for securing and authenticating documents
KR20150072679A (en) * 2013-12-20 2015-06-30 노틸러스효성 주식회사 Method of providing personal password input pad at ATM
CN105160215A (en) * 2015-06-30 2015-12-16 努比亚技术有限公司 Digital unlocking method and apparatus

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101101625A (en) * 2007-08-07 2008-01-09 江雨 Input data safe treatment method and device
CN104143068A (en) * 2014-07-16 2014-11-12 宇龙计算机通信科技(深圳)有限公司 Password authentication method and system
CN107633174A (en) * 2016-07-18 2018-01-26 中兴通讯股份有限公司 A kind of user inputs management method and device, terminal
CN108280374A (en) * 2018-02-27 2018-07-13 惠州Tcl移动通信有限公司 A kind of safe input control method of Mobile terminal keyboard, system and storage medium

Also Published As

Publication number Publication date
CN110188532A (en) 2019-08-30

Similar Documents

Publication Publication Date Title
CN103914646B (en) Touch event processing method and the portable device for realizing the method
US9703971B2 (en) Sensitive operation verification method, terminal device, server, and verification system
CN106126015B (en) A kind of application program launching control method and terminal
CN108156508B (en) Barrage information processing method and device, mobile terminal, server and system
CN106502703B (en) Function calling method and device
US9411640B2 (en) Method for efficiently managing application and electronic device implementing the method
WO2017211205A1 (en) Method and device for updating whitelist
CN103634294A (en) Information verifying method and device
CN106649010B (en) terminal equipment test method and terminal equipment
WO2015062413A1 (en) Terminal account managing method and device cross-reference to related applications
CN104025560A (en) Method and apparatus for providing data entry content to a remote environment
CN104852885A (en) Method, device and system for verifying verification code
CN103763112A (en) User identity protection method and apparatus
CN108090345B (en) Linux system external command execution method and device
CN103853583A (en) Method for providing application information and mobile terminal thereof
CN104536782A (en) Guide content display method, and file generation method and device
KR20150001095A (en) Method for processing character input and apparatus for the same
CN111966491A (en) Method for counting occupied memory and terminal equipment
CN108615158B (en) Risk detection method and device, mobile terminal and storage medium
CN110188532B (en) Password protection method and device
CN108462580B (en) Numerical value transferring method and device
CN106709330B (en) Method and device for recording file execution behaviors
CN107102913A (en) Data back up method, device and computer equipment
CN106484480A (en) A kind of determination method of application of attending to anything else, device and terminal
CN111262737B (en) Port configuration management method and device, storage medium and terminal

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