Secure payment method, device and storage medium

By generating and delaying the display of payment codes on the terminal device in mobile payment until the proximity of the scanning device is detected, the risk that the user will be copied or scanned while waiting for payment is solved, and the security of payment is improved.

CN111967871BActive Publication Date: 2025-02-18SHENZHEN TRANSSION HLDG CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202010841973.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-08-20
Publication Date
2025-02-18
Estimated Expiration
2040-08-20

AI Technical Summary

Technical Problem

When using mobile payment, users may open the payment code interface in advance while waiting for payment, resulting in the payment code being copied or scanned by criminals, causing property damage.

Method used

By receiving the payment code display request on the terminal device and generating the original payment code, but not directly displaying it, the original payment code is not displayed until it is detected that the terminal device is scanned and the distance between the scanning device and the terminal device is less than or equal to the preset value. .

Benefits of technology

Ensure that the payment code is displayed only when the user brings the terminal device close to the scanning device, avoiding the payment code being maliciously scanned or copied, and improving the security of payment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111967871B_ABST
    Figure CN111967871B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a secure payment method, device and storage medium. The method includes: receiving a payment code display request and generating an original payment code; when detecting that a terminal device is scanned, if the distance between the scanning device and the terminal device is less than or equal to a first preset value, displaying the original payment code. The method improves payment security.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to mobile payment technology, and more particularly to a secure payment method, device and storage medium. Background Art

[0002] With the development of mobile payment technology, more and more users are gradually using terminal devices to make daily consumption payments to replace traditional cash payments or card payments.

[0003] When using a terminal device to make a payment, the user usually directly opens his or her payment code interface on the terminal device, and the payee uses a scanning device to scan the user's payment code to directly deduct the money. However, a problem with this payment method is that when the user is ready to pay, he or she often opens the payment code interface in advance. For example, the user may open the payment code in advance while waiting in line. At this time, criminals may copy or scan the user's payment code, causing the user's property to suffer losses. Therefore, a safer payment method is urgently needed.

[0004] The preceding description is intended to provide general background information and does not necessarily constitute prior art. Summary of the invention

[0005] The present application provides a secure payment method, device and storage medium to improve the security of mobile payment.

[0006] In a first aspect, the present application provides a secure payment method, applied to a terminal device, comprising:

[0007] Receive payment code display request and generate original payment code;

[0008] When it is detected that the terminal device is scanned, if the distance between the scanning device and the terminal device is less than or equal to a first preset value, the original payment code is displayed.

[0009] Optionally, before displaying the original payment code, it also includes: performing user authentication, and only displaying the original payment code if it passes; and / or, if it fails, not displaying the original payment code and / or outputting prompt information.

[0010] Optionally, after generating the original payment code, the method further includes:

[0011] The image of the original payment code is processed to obtain a secure payment code, and optionally, the secure payment code is a payment code or pattern that cannot be correctly recognized;

[0012] displaying said secure payment code;

[0013] Optionally, displaying the original payment code includes:

[0014] The secure payment code is switched to the original payment code.

[0015] Optionally, the detecting that the terminal device is scanned includes:

[0016] If the terminal device receives the scanning light signal from the scanning device, it is determined that the terminal device is scanned; the method further includes: determining the distance between the scanning device and the terminal device.

[0017] Optionally, the terminal device receives a scanning light signal from a scanning device, including:

[0018] If the intensity change of the optical signal received by the terminal device is greater than or equal to a second preset value, it is determined that the terminal device has received the scanning optical signal of the scanning device.

[0019] Optionally, determining the distance between the scanning device and the terminal device includes:

[0020] Determine the obstacle closest to the terminal device;

[0021] The distance between the closest obstacle and the terminal device is determined as the distance between the scanning device and the terminal device.

[0022] Optionally, determining the distance between the scanning device and the terminal device includes:

[0023] capturing an image of the direction of the scanning light signal;

[0024] The distance between the scanning device and the terminal device is determined according to the image of the scanning light signal direction.

[0025] Optionally, before the image of the original payment code is processed to obtain a secure payment code, the method further includes:

[0026] Make sure that the payment code security protection mode of the terminal device is turned on.

[0027] Optionally, the method further comprises:

[0028] If the distance is greater than a first preset value, a prompt message is output, wherein the prompt message is used to prompt the user that the payment code has been illegally scanned.

[0029] Optionally, the prompt information is at least one of text information, voice information and light information.

[0030] Optionally, the processing of the original payment code to obtain a secure payment code includes at least one of the following:

[0031] Performing image blurring processing on the whole or part of the image of the original payment code to obtain a secure payment code with a lower definition than the original payment code;

[0032] Encrypting the image of the original payment code to obtain the secure payment code;

[0033] Covering the entire or partial image of the original payment code to obtain the secure payment code;

[0034] The whole or part of the image of the original payment code is subjected to image stretching and deformation processing to obtain the secure payment code.

[0035] Optionally, the payment code is a barcode or a QR code.

[0036] In a second aspect, the present application provides a secure payment device, comprising:

[0037] A generation module, used for receiving a payment code display request and generating an original payment code;

[0038] The display module is used to display the original payment code when it is detected that the terminal device is scanned and if the distance between the scanning device and the terminal device is less than or equal to a first preset value.

[0039] In a third aspect, the present application provides a terminal device, including: a memory and a processor;

[0040] The memory is used to store computer programs;

[0041] When the processor is used to execute the computer program, the method as described in the first aspect is implemented.

[0042] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method as described in the first aspect is implemented.

[0043] The present application provides a secure payment method, device and storage medium. After receiving a payment code display request, only the original payment code is generated but not directly displayed. The original payment code is displayed only when it is detected that the terminal device is scanned and the distance between the scanning device and the terminal device is less than or equal to a first preset value, thereby ensuring that the payment code is displayed when the user brings the terminal device close to the scanning device, avoiding the payment code from being maliciously scanned or copied due to the early display of the payment code, and improving payment security. In addition, the secure payment method does not increase the user's operation complexity, and the user experience is good. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0045] Figure 1 A schematic diagram of the hardware structure of a mobile terminal for implementing various embodiments of the present application;

[0046] Figure 2 A communication network system architecture diagram provided for an embodiment of the present application;

[0047] Figure 3 An application scenario diagram of a secure payment method provided for this application;

[0048] Figure 4 A schematic diagram of a secure payment method provided for this application Figure 1 ;

[0049] Figure 5 A user interface of a terminal device provided for this application Figure 1 ;

[0050] Figure 6 A schematic diagram of a secure payment method provided for this application Figure 2 ;

[0051] Figure 7 A user interface of a terminal device provided for this application Figure 2 ;

[0052] Figure 8 A user interface of a terminal device provided for this application Figure 3 ;

[0053] Fig. 9 A schematic diagram of the structure of a secure payment method provided for this application;

[0054] Fig.10 A schematic diagram of the structure of a terminal device provided for this application.

[0055] The above drawings have shown clear embodiments of the present application, which will be described in more detail later. These drawings and text descriptions are not intended to limit the scope of the present application in any way, but to illustrate the concept of the present application to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0056] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.

[0057] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.

[0058] It should be understood that, although the terms first, second, third, etc. may be used to describe various information in this article, these information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of this article, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein can be interpreted as "at the time of..." or "when..." or "in response to determination". Furthermore, as used in this article, the singular forms "one", "one" and "the" are intended to also include plural forms, unless there is an opposite indication in the context. It should be further understood that the terms "comprising", "including" indicate that there are described features, steps, operations, elements, components, projects, kinds, and / or groups, but do not exclude the existence, occurrence or addition of one or more other features, steps, operations, elements, components, projects, kinds, and / or groups. The terms "or" and "and / or" used herein are interpreted as inclusive, or mean any one or any combination. Thus, “A, B, or C” or “A, B and / or C” means “any of the following: A; B; C; A and B; A and C; B and C; A, B, and C.” An exception to this definition will occur only when a combination of elements, functions, steps, or operations are inherently mutually exclusive in some manner.

[0059] It should be understood that, although the various steps in the flowcharts in the above-described embodiments are sequentially displayed according to the indications of the arrows, these steps are not necessarily executed sequentially in the order indicated by the arrows. Unless there is a clear description in this article, the execution of these steps is not strictly limited in order, and they can be executed in other orders. Moreover, at least a portion of the steps in the figure may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily to be carried out sequentially, but can be executed in turn or alternately with other steps or at least a portion of the sub-steps or stages of other steps.

[0060] It should be noted that in this article, step codes such as S201, S202, etc. are used for the purpose of expressing the corresponding content more clearly and concisely, and do not constitute a substantial limitation on the sequence. When implementing the step, those skilled in the art may execute S202 first and then S201, etc., but these should all be within the scope of protection of this application.

[0061] It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0062] In the subsequent description, the suffixes such as "module", "component" or "unit" used to represent elements are only used to facilitate the description of the present application, and have no specific meanings. Therefore, "module", "component" or "unit" can be used in a mixed manner.

[0063] The device may be implemented in various forms. For example, the device described in this application may include mobile terminals such as mobile phones, tablet computers, laptop computers, PDAs, portable media players (PMPs), navigation devices, wearable devices, smart bracelets, pedometers, etc., and fixed terminals such as digital TVs and desktop computers.

[0064] The following description will be made by taking a mobile terminal as an example, and those skilled in the art will understand that, in addition to components specifically used for mobile purposes, the construction according to the embodiments of the present application can also be applied to fixed-type terminals.

[0065] See also Figure 1, which is a schematic diagram of the hardware structure of a mobile terminal for implementing various embodiments of the present application, the mobile terminal 100 may include: RF (Radio Frequency, radio frequency) unit 101, WiFi module 102, audio output unit 103, A / V (audio / video) input unit 104, sensor 105, display unit 106, user input unit 107, interface unit 108, memory 109, processor 110, and power supply 111 and other components. Those skilled in the art can understand that Figure 1 The structure of the mobile terminal shown in the figure does not constitute a limitation on the mobile terminal. The mobile terminal may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.

[0066] Combine the following Figure 1 The following is a detailed introduction to the various components of the mobile terminal:

[0067] The radio frequency unit 101 can be used for receiving and sending signals during information transmission or communication. Specifically, after receiving the downlink information of the base station, it is sent to the processor 110 for processing; in addition, the uplink data is sent to the base station. Generally, the radio frequency unit 101 includes but is not limited to an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, etc. In addition, the radio frequency unit 101 can also communicate with the network and other devices through wireless communication. The above-mentioned wireless communication can use any communication standard or protocol, including but not limited to GSM (Global System of Mobile communication), GPRS (General Packet Radio Service), CDMA2000 (Code Division Multiple Access 2000), WCDMA (Wideband Code Division Multiple Access), TD-SCDMA (Time Division-Synchronous Code Division Multiple Access), FDD-LTE (Frequency Division Duplexing-Long Term Evolution) and TDD-LTE (Time Division Duplexing-Long Term Evolution), etc.

[0068] WiFi is a short-range wireless transmission technology. Mobile terminals can help users send and receive emails, browse web pages, and access streaming media through WiFi module 102. It provides users with wireless broadband Internet access. Figure 1 The WiFi module 102 is shown, but it is understandable that it is not an essential component of the mobile terminal and can be omitted as required without changing the essence of the invention.

[0069] The audio output unit 103 can convert the audio data received by the RF unit 101 or the WiFi module 102 or stored in the memory 109 into an audio signal and output it as sound when the mobile terminal 100 is in a call signal reception mode, a talk mode, a recording mode, a voice recognition mode, a broadcast reception mode, etc. Moreover, the audio output unit 103 can also provide audio output related to a specific function performed by the mobile terminal 100 (for example, a call signal reception sound, a message reception sound, etc.). The audio output unit 103 may include a speaker, a buzzer, etc.

[0070] The A / V input unit 104 is used to receive audio or video signals. The A / V input unit 104 may include a graphics processor (GPU) 1041 and a microphone 1042, and the graphics processor 1041 processes the image data of a static picture or video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The processed image frame can be displayed on the display unit 106. The image frame processed by the graphics processor 1041 can be stored in the memory 109 (or other storage medium) or sent via the radio frequency unit 101 or the WiFi module 102. The microphone 1042 can receive sound (audio data) via the microphone 1042 in a telephone call mode, a recording mode, a voice recognition mode, and other operating modes, and can process such sound into audio data. The processed audio (voice) data can be converted into a format output that can be sent to a mobile communication base station via the radio frequency unit 101 in the case of a telephone call mode. The microphone 1042 can implement various types of noise elimination (or suppression) algorithms to eliminate (or suppress) noise or interference generated in the process of receiving and sending audio signals.

[0071] The mobile terminal 100 also includes at least one sensor 105, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor, wherein the ambient light sensor can adjust the brightness of the display panel 1061 according to the brightness of the ambient light, and the proximity sensor can turn off the display panel 1061 and / or the backlight when the mobile terminal 100 is moved to the ear. As a type of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in all directions (generally three axes), and can detect the magnitude and direction of gravity when stationary. It can be used for applications that identify the posture of the mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc.; as for other sensors that can also be configured on the mobile phone, such as fingerprint sensors, pressure sensors, iris sensors, molecular sensors, gyroscopes, barometers, hygrometers, thermometers, infrared sensors, etc., they will not be repeated here.

[0072] The display unit 106 is used to display information input by the user or information provided to the user. The display unit 106 may include a display panel 1061, which may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like.

[0073] The user input unit 107 can be used to receive input digital or character information, and to generate key signal input related to the user settings and function control of the mobile terminal. Specifically, the user input unit 107 may include a touch panel 1071 and other input devices 1072. The touch panel 1071, also known as a touch screen, can collect the user's touch operation on or near it (such as the user's operation on the touch panel 1071 or near the touch panel 1071 using any suitable object or accessory such as a finger, stylus, etc.), and drive the corresponding connection device according to a pre-set program. The touch panel 1071 may include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into the touch point coordinates, and then sends it to the processor 110, and can receive and execute the command sent by the processor 110. In addition, the touch panel 1071 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch panel 1071, the user input unit 107 may also include other input devices 1072. Specifically, the other input devices 1072 may include, but are not limited to, one or more of a physical keyboard, a function key (such as a volume control key, a switch key, etc.), a trackball, a mouse, a joystick, etc., which are not specifically limited here.

[0074] Furthermore, the touch panel 1071 may cover the display panel 1061. When the touch panel 1071 detects a touch operation on or near it, it transmits the information to the processor 110 to determine the type of the touch event. Then, the processor 110 provides a corresponding visual output on the display panel 1061 according to the type of the touch event. Figure 1 In the figure, the touch panel 1071 and the display panel 1061 are used as two independent components to implement the input and output functions of the mobile terminal. However, in some embodiments, the touch panel 1071 and the display panel 1061 can be integrated to implement the input and output functions of the mobile terminal, which is not limited here.

[0075] The interface unit 108 serves as an interface through which at least one external device can be connected to the mobile terminal 100. For example, the external device may include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, an audio input / output (I / O) port, a video I / O port, a headphone port, etc. The interface unit 108 may be used to receive input (e.g., data information, power, etc.) from an external device and transmit the received input to one or more elements within the mobile terminal 100 or may be used to transmit data between the mobile terminal 100 and an external device.

[0076] The memory 109 can be used to store software programs and various data. The memory 109 can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area can store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory 109 can include a high-speed random access memory, and can also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0077] The processor 110 is the control center of the mobile terminal. It uses various interfaces and lines to connect various parts of the entire mobile terminal. It executes various functions of the mobile terminal and processes data by running or executing software programs and / or modules stored in the memory 109, and calling data stored in the memory 109, so as to monitor the mobile terminal as a whole. The processor 110 may include one or more processing units; preferably, the processor 110 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, etc., and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 110.

[0078] The mobile terminal 100 may also include a power supply 111 (such as a battery) for supplying power to various components. Preferably, the power supply 111 may be logically connected to the processor 110 via a power management system, thereby implementing functions such as charging, discharging, and power consumption management through the power management system.

[0079] although Figure 1 Not shown, the mobile terminal 100 may further include a Bluetooth module, etc., which will not be described in detail here.

[0080] In order to facilitate understanding of the embodiments of the present application, the communication network system on which the mobile terminal of the present application is based is described below.

[0081] See also Figure 2 , Figure 2 A communication network system architecture diagram is provided for an embodiment of the present application, wherein the communication network system is an LTE system of universal mobile communication technology, and the LTE system includes a UE (User Equipment) 201, an E-UTRAN (Evolved UMTS Terrestrial Radio Access Network) 202, an EPC (Evolved Packet Core) 203 and an operator's IP service 204, which are connected in sequence for communication.

[0082] Specifically, UE201 may be the above-mentioned terminal 100, which will not be described in detail here.

[0083] E-UTRAN 202 includes eNodeB 2021 and other eNodeBs 2022 , etc. Among them, eNodeB 2021 can be connected to other eNodeBs 2022 through a backhaul (eg, an X2 interface), and eNodeB 2021 is connected to EPC 203 , and eNodeB 2021 can provide UE 201 with access to EPC 203 .

[0084] EPC203 may include MME (Mobility Management Entity) 2031, HSS (Home Subscriber Server) 2032, other MMEs 2033, SGW (Serving Gate Way) 2034, PGW (PDN Gate Way) 2035 and PCRF (Policy and Charging Rules Function) 2036, etc. Among them, MME2031 is a control node that processes signaling between UE201 and EPC203, and provides bearer and connection management. HSS2032 is used to provide some registers to manage functions such as home location register (not shown in the figure), and save some user-specific information such as service features and data rates. All user data can be sent through SGW2034, PGW2035 can provide IP address allocation and other functions for UE 201, PCRF2036 is the policy and charging control policy decision point for service data flow and IP bearer resources, which selects and provides available policy and charging control decisions for the policy and charging execution function unit (not shown in the figure).

[0085] The IP service 204 may include the Internet, an intranet, an IMS (IP Multimedia Subsystem) or other IP services.

[0086] Although the above introduction takes the LTE system as an example, those skilled in the art should know that the present application is not only applicable to the LTE system, but also to other wireless communication systems, such as GSM, CDMA2000, WCDMA, TD-SCDMA and future new network systems, etc., which are not limited here.

[0087] Based on the above-mentioned mobile terminal hardware structure and communication network system, various embodiments of the present application are proposed.

[0088] The secure payment method provided in the embodiment of the present application is applied in a mobile payment scenario. For example, Figure 3 As shown in , the user holds a terminal device 10 to pay the recipient, and the recipient completes the payment by scanning the payment code on the user terminal device 10 through the scanning device 20. The user terminal device 10 can be a mobile phone, a wearable smart device, a tablet computer, etc.; the scanning device 20 can be a barcode scanner, a scanning gun, a smart cash register device, a vehicle-mounted terminal, etc., which is not limited in this application.

[0089] When a user uses a terminal device to make a payment, the usual process is that the user directly opens his or her payment code interface on the terminal device, and the payee uses a scanning device to scan the user's payment code to directly deduct the money. In actual use, users often open the payment code interface in advance and wait for the merchant to scan it. For example, the user may open the payment code in advance while waiting in line. This may cause the user's payment code to be scanned and deducted by criminals or copied and used, causing the user's property to suffer losses.

[0090] In order to improve the security of payment codes, the relevant technology proposes that the terminal device outputs a verification interface before presenting the payment code, and after receiving the verification information output by the user on the verification interface, it matches it with the pre-stored information, and only after the match is successful will the payment code be presented. Alternatively, after the payment code is scanned, the terminal device outputs a verification interface, and after receiving the verification information output by the user on the verification interface, it matches it with the pre-stored information, and only after the match is successful will the deduction be triggered. Both of the above solutions improve the security of the payment code to a certain extent by adding a verification process. However, this solution increases the user's operation process, making the payment process complicated and time-consuming, and is not convenient for use in places with large traffic.

[0091] In order to solve the above problems, the present application proposes a secure payment method. When a user uses a terminal device to make a payment, in order to ensure that the payment scanning operation is performed with the user's knowledge, the payment code is displayed when the distance between the user device and the scanning device is less than a preset value, ensuring that the payment operation is safe and controllable.

[0092] The following specific embodiments are used to describe in detail the technical solutions of the embodiments of the present application and how the technical solutions of the present application solve the above-mentioned technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0093] Figure 4 A schematic diagram of a secure payment method provided for this application Figure 1 The execution subject of this method is the terminal device. Figure 4 As shown, the method includes:

[0094] S201. Receive a payment code display request and generate an original payment code.

[0095] The payment code display request in this embodiment may be triggered by a user operation, for example, Figure 5 As shown in , the user clicks the payment control in the operation interface of the application of the terminal device to trigger the payment code display request.

[0096] It should be noted that in this step, after the terminal device receives the payment code display request, it generates an original payment code, but the terminal device does not display the original payment code at this time.

[0097] The payment code in the embodiment of the present application may be a barcode, a QR code, or a payment code in other encoding methods that may be used in the future, and the present application does not limit this.

[0098] S202: When it is detected that the terminal device is scanned, if the distance between the scanning device and the terminal device is less than or equal to a first preset value, the original payment code is displayed.

[0099] The terminal device can detect whether it is scanned through a sensor and / or a camera. For example, the terminal device receives a scanning light signal from a scanning device through a light sensor, and then determines that the terminal device is scanned. When the scanning is detected, the terminal device further determines whether to display the original payment code based on the distance between the scanning device and the terminal device.

[0100] When the terminal device is scanned, if the distance between the scanning device and the terminal device is less than or equal to a first preset value, the original payment code is displayed; and / or, if the distance between the scanning device and the terminal device is greater than the first preset value, a prompt message is output to prompt the user that the payment code has been illegally scanned.

[0101] Optionally, before displaying the original payment code, the system further includes: performing user authentication, which may be performed by user fingerprint, face, iris, voice, or password (such as graphics or text), etc., and only displaying the original payment code if the user passes the authentication; and / or not displaying the original payment code and / or outputting a prompt message if the user fails the authentication. In this way, security can be further improved.

[0102] The size of the first preset value can be set according to actual needs, for example, the first preset value is 10cm, 20cm, etc. Usually, when a user uses a payment code to pay, he will hold the terminal device and move it close to the scanning device to scan the code. Therefore, the first preset value is set to ensure that the payment code is displayed only when the distance between the scanning device and the terminal device is small, that is, when the user moves the terminal device close to the scanning device, so as to ensure that the operation of scanning the payment code is visible and knowable to the user, thereby improving payment security.

[0103] On the contrary, if the distance between the scanning device and the terminal device is greater than the first preset value when the terminal device is scanned, it means that the user has not moved the terminal device close to the scanning device, so the scanning operation may be malicious scanning of the user's terminal device by other persons from a distance. Therefore, in this case, the terminal device does not display the original payment code, and the terminal device can prompt the user by outputting a prompt message. The prompt message can be at least one of text message, voice message and light message. For example, Figure 5 As shown, the user interface of the terminal device displays "Illegal scan detected, please confirm", or a voice message "Illegal scan detected, please confirm" is played through the speaker, or prompts are given through flashing of the screen, flashing of the flash light, flashing of the breathing light, etc.

[0104] The secure payment method provided in this embodiment, after receiving the payment code display request, only generates the original payment code but does not display it directly. The original payment code is displayed only when it is detected that the terminal device is scanned and the distance between the scanning device and the terminal device is less than or equal to the first preset value, thereby ensuring that the payment code is displayed when the user brings the terminal device close to the scanning device, avoiding the payment code from being maliciously scanned or copied due to the early display of the payment code, and improving payment security. In addition, the secure payment method does not increase the user's operation complexity, and the user experience is good.

[0105] Based on the above embodiments, the present application also provides a secure payment method, which further improves the user experience while ensuring secure payment. Figure 6 A schematic diagram of a secure payment method provided for this application Figure 2 .like Figure 6 As shown, the method includes:

[0106] S401. Receive a payment code display request and generate an original payment code.

[0107] This step is similar to S201 in the above embodiment and will not be described again here.

[0108] S402: Process the image of the original payment code to obtain a secure payment code, and display the secure payment code.

[0109] Optionally, the secure payment code is a payment code or pattern that cannot be correctly recognized.

[0110] In the previous step, after the user triggers the payment code display request, the terminal device generates the original payment code. However, for the purpose of improving security, the terminal device does not directly display the original payment code after generating it. Therefore, for the user, after the user triggers the payment code display request, the user cannot immediately see the payment code displayed on the user interface of the terminal device, and the user experience may be poor.

[0111] Therefore, in this step, after the original payment code is generated, the terminal device processes the image of the original payment code to obtain a secure payment code that cannot be correctly identified, and displays the secure payment code. Therefore, from the perspective of user experience, after the user triggers the payment code display request, the payment code can be seen displayed on the terminal device, and the user can know that the payment code is a secure payment code displayed for security needs, which provides a good user experience.

[0112] The terminal device may process the image of the original payment code in one or more ways to obtain a secure payment code that cannot be correctly recognized.

[0113] For example, in one method, the terminal device performs image blurring processing on all or part of the image of the original payment code to obtain a secure payment code with lower clarity than the original payment code. In another method, the terminal device performs encryption processing on the image of the original payment code to obtain a secure payment code, for example, using a specific encryption encoding method to generate an encrypted two-dimensional code graphic as a secure payment code. In yet another method, the terminal device performs image stretching and deformation processing on all or part of the image of the original payment code to obtain a secure payment code.

[0114] It is understandable that when the terminal device processes the original payment code, one or more of the above methods can be used at the same time. The example terminal device can first blur the original payment code and then further cover it to obtain a secure payment code, which is not limited in this embodiment. It should also be noted that the above methods are only examples, and the embodiment of the present application does not limit the method of generating a secure payment code, as long as the secure payment code obtained from the original payment code cannot be correctly identified.

[0115] Optionally, when the terminal device displays the secure payment code, a message may also be displayed on the terminal device to remind the user that the secure payment code is currently displayed. For example, Figure 7 As shown in , the terminal device displays a blurred secure payment code and displays the message "The secure payment code is currently displayed. When the terminal device is close to the scanning device, it will automatically switch to the original payment code." Therefore, after the user triggers the payment code display request and sees the secure payment code, the user can know to directly bring the secure payment code close to the scanning device.

[0116] S403: When it is detected that the terminal device is scanned, if the distance between the scanning device and the terminal device is less than or equal to a first preset value, the secure payment code is switched to the original payment code.

[0117] Similar to S202, when the terminal device detects that it is being scanned, if the distance between the scanning device and the terminal device is less than or equal to the first preset value, it means that the user has moved the terminal device close to the scanning device, thereby ensuring that the scanning operation is visible to the user. At this time, the secure payment code is switched to the original payment code for payment. For example, Figure 8 as shown in .

[0118] On the contrary, if the distance between the scanning device and the terminal device is greater than the first preset value when the terminal device is scanned, it means that the user has not moved the terminal device close to the scanning device, and the scanning operation may be that other people maliciously scan the user's terminal device from a distance. Therefore, in this case, the terminal device still displays the security payment code. Since the security payment code cannot be correctly recognized, the payment security is improved.

[0119] Optionally, before displaying the original payment code, the system further includes: performing user authentication, which may be performed by user fingerprint, face, iris, voice, or password (such as graphics or text), etc., and only displaying the original payment code if the user passes the authentication; and / or not displaying the original payment code and / or outputting a prompt message if the user fails the authentication. In this way, security can be further improved.

[0120] In this embodiment, after receiving the payment code display request, the terminal device generates an original payment code and converts it into a secure payment code for display. When it is detected that the terminal device is scanned and the distance between the scanning device and the terminal device is less than or equal to a first preset value, the secure payment code is switched to the original payment code. This not only ensures payment security, but also the secure payment method does not increase the complexity of the user's operation. It can also prompt the user by displaying the secure payment code, thereby improving the user experience.

[0121] In order to allow the user to choose to use or not use the payment method of displaying the secure payment code in the above embodiment, the terminal device may provide a payment code security protection mode switch for the user to choose. If the user chooses to turn on the payment code security protection mode, the terminal device will display the payment code according to the Figure 6 The method of the illustrated embodiment displays the secure payment code. If the user turns off the payment code security protection mode, the secure payment code will not be displayed.

[0122] exist Figure 4 and Figure 6 Based on the illustrated embodiment, how the terminal device detects that it is scanned and how to determine the distance between the scanning device and the terminal device are described.

[0123] In a feasible implementation, if the intensity change of the optical signal received by the terminal device is greater than or equal to the second preset value, it is determined that the terminal device receives the scanning optical signal of the scanning device, thereby determining that the terminal device is scanned.

[0124] There are usually relatively fixed optical signals in the use environment of the terminal device. For example, when the terminal device is used indoors, the indoor lighting is turned on and the terminal device will continue to receive the optical signal of the lighting, or when the terminal device is used outdoors, the terminal device will continue to receive the sunlight signal. When the scanning device scans the terminal device, the scanning device will also send out a scanning optical signal, so that the intensity of the optical signal received by the terminal device when being scanned will suddenly change.

[0125] The terminal device can determine the intensity change of the received optical signal through the sensor. At the same time, in order to distinguish the intensity change of the optical signal received by the terminal device from the slight fluctuation of light in the normal environment, a second preset value is set in the present application. When the intensity change of the optical signal received by the terminal device is greater than or equal to the second preset value, it is determined that the terminal device has received the scanning optical signal of the scanning device. The size of the second preset value can be set according to actual conditions, for example, the second preset value can be set according to the intensity of the scanning optical signal of the scanning device.

[0126] In the above method, by detecting the intensity change of the optical signal received by the terminal device, it is determined whether the terminal device is scanned, so that on the basis of the terminal device being scanned, it is further determined whether to display the original payment code according to the distance between the scanning device and the terminal device, thereby improving the security of payment. The following is an explanation of how the terminal device determines the distance between the scanning device and the terminal device.

[0127] In a feasible implementation, the terminal device determines the obstacle closest to the terminal device; and determines the distance between the closest obstacle and the terminal device as the distance between the scanning device and the terminal device.

[0128] In this implementation, the terminal device determines the distance between the scanning device and the terminal device through a sensor. For example, the sensor may be an ultrasonic distance sensor, an infrared distance sensor, a laser distance sensor, etc., and the present application does not specifically limit the sensor type.

[0129] In actual scenarios, when the user moves the terminal device to a position close to the scanning device, there are basically no other obstructions between the terminal device and the scanning device. Therefore, the terminal device can determine the nearest obstacle detected as the scanning device, and thus determine the distance between the nearest obstacle and the terminal device as the distance between the scanning device and the terminal device.

[0130] In another feasible implementation manner, the terminal device captures an image in the direction of the scanning light signal, and determines the distance between the scanning device and the terminal device based on the image in the direction of the scanning light signal.

[0131] In this implementation, when the terminal device detects the scanning light signal of the scanning device and determines that it is being scanned, it captures an image in the direction of the scanning light signal through a camera, so that the image necessarily includes the scanning device. The terminal device identifies the captured image and determines the distance between the scanning device and the terminal device. The specific implementation method of the terminal device measuring the distance through the image captured by the camera can be the same as the method of monocular camera ranging or binocular camera ranging in the prior art.

[0132] In the above method, by detecting the intensity change of the light signal received by the terminal device, it is determined that the terminal device has been scanned, and the image taken by the sensor or camera is used to determine the distance between the scanning device and the terminal device, thereby determining whether to display the original payment code, thereby improving the security of payment.

[0133] Fig. 9 This is a schematic diagram of the structure of a secure payment device provided by this application. Fig. 9 As shown, the secure payment device 70 includes:

[0134] The generating module 701 is used to receive a payment code display request and generate an original payment code;

[0135] The display module 702 is used to display the original payment code when it is detected that the terminal device is scanned and if the distance between the scanning device and the terminal device is less than or equal to a first preset value.

[0136] In a feasible implementation, the secure payment device 70 further includes:

[0137] The security processing module 703 is used to process the image of the original payment code to obtain a secure payment code. Optionally, the secure payment code is a payment code or pattern that cannot be correctly recognized;

[0138] The display module 702 is also used to display the secure payment code;

[0139] The display module 702 is also used to switch the secure payment code to the original payment code.

[0140] In a feasible implementation, the display module 702 is used to determine that the terminal device is scanned when the terminal device receives a scanning light signal from the scanning device, and to determine the distance between the scanning device and the terminal device.

[0141] In a feasible implementation, the display module 702 is used to determine that the terminal device has received a scanning light signal from the scanning device when a change in the intensity of the light signal received by the terminal device is greater than or equal to a second preset value.

[0142] In a feasible implementation, the display module 702 is used to:

[0143] Determine the obstacle closest to the terminal device;

[0144] The distance between the nearest obstacle and the terminal device is determined as the distance between the scanning device and the terminal device.

[0145] In a feasible implementation, the display module 702 is used to:

[0146] capturing an image of the direction of the scanning light signal;

[0147] The distance between the scanning device and the terminal device is determined based on the image of the scanning light signal direction.

[0148] In a feasible implementation, the security processing module 703 is further used for:

[0149] Make sure the payment code security protection mode of the terminal device is turned on.

[0150] In a feasible implementation, the display module 702 is used to:

[0151] If the distance is greater than the first preset value, a prompt message is output, and the prompt message is used to remind the user that the payment code has been illegally scanned.

[0152] In a feasible implementation, the prompt information is at least one of text information, voice information and light information.

[0153] In a feasible implementation, the security processing module 703 is used to:

[0154] Performing image blurring on all or part of the original payment code to obtain a secure payment code image with lower definition than the original payment code;

[0155] Encrypt the image of the original payment code to obtain a secure payment code;

[0156] Cover all or part of the original payment code image to obtain a secure payment code;

[0157] Perform image stretching and deformation processing on all or part of the original payment code to obtain a secure payment code.

[0158] In a feasible implementation, the payment code is a barcode or a QR code.

[0159] The device of this embodiment can be used to execute the secure payment method of any of the above method embodiments. Its implementation principle and technical effects are similar and will not be described in detail here.

[0160] Fig.10 This is a schematic diagram of the structure of a terminal device provided by this application. Fig.10 As shown, the terminal device 80 includes: a memory 801, a processor 802, and a computer program stored in the memory 801 and executable on the processor 802. When the computer program is executed by the processor 802, the steps of the method in any of the above embodiments are implemented. The memory 801 and the processor 802 may be connected via a bus 803.

[0161] The present application also provides a device, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the steps of the above method when executed by the processor.

[0162] The present application also provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the steps of the method in any of the above embodiments are implemented.

[0163] An embodiment of the present application further provides a computer program product, which includes a computer program code. When the computer program code runs on a computer, the computer executes the methods in the above various possible implementation modes.

[0164] An embodiment of the present application also provides a chip, including a memory and a processor, wherein the memory is used to store a computer program, and the processor is used to call and run the computer program from the memory, so that a device equipped with the chip executes the methods in various possible implementation modes as described above.

[0165] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the invention disclosed herein. The embodiments of the present application are intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present application. The specification and embodiments are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.

[0166] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.

Claims

1. A secure payment method, applied to a terminal device, characterized in that: include: Receive payment code display request and generate original payment code; Processing the image of the original payment code to obtain a secure payment code; The security payment code is a payment code or pattern that cannot be correctly recognized; displaying said secure payment code; When detecting that the terminal device is scanned, if the distance between the scanning device and the terminal device is less than or equal to a first preset value, switching the secure payment code to the original payment code; If the distance is greater than a first preset value, the secure payment code is displayed and a prompt message is output, wherein the prompt message is used to prompt the user that the payment code has been illegally scanned; The detecting that the terminal device is scanned includes: If the terminal device receives the scanning light signal from the scanning device, it is determined that the terminal device is scanned; The method further comprises: Determining the distance between the scanning device and the terminal device; The terminal device receives a scanning light signal from a scanning device, including: If the intensity change of the optical signal received by the terminal device is greater than or equal to a second preset value, it is determined that the terminal device has received the scanning optical signal of the scanning device.

2. The method according to claim 1, characterized in that The determining the distance between the scanning device and the terminal device includes: Determine the obstacle closest to the terminal device; The distance between the closest obstacle and the terminal device is determined as the distance between the scanning device and the terminal device.

3. The method according to claim 1, characterized in that The determining the distance between the scanning device and the terminal device includes: capturing an image of the direction of the scanning light signal; The distance between the scanning device and the terminal device is determined according to the image of the scanning light signal direction.

4. The method according to claim 1, characterized in that Before the image of the original payment code is processed to obtain a secure payment code, the method further includes: Make sure that the payment code security protection mode of the terminal device is turned on.

5. The method according to claim 1, characterized in that The processing of the original payment code to obtain a secure payment code includes at least one of the following: Performing image blurring processing on the whole or part of the image of the original payment code to obtain a secure payment code with a lower definition than the original payment code; Encrypting the image of the original payment code to obtain the secure payment code; Covering the entire or partial image of the original payment code to obtain the secure payment code; The whole or part of the image of the original payment code is subjected to image stretching and deformation processing to obtain the secure payment code.

6. A terminal device, characterized in that: include: Memory and processor; The memory is used to store computer programs; When the processor is used to execute the computer program, the method according to any one of claims 1 to 5 is implemented.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.

8. A computer program product, comprising a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.

Citation Information

Patent Citations

  • A security confirmation method of a scanning code payment environment and a server

    CN109102280A

  • Two-dimensional code display method, mobile terminal and computer-readable storage medium

    CN109214810A

  • Payment transaction method, payment terminal and computer readable storage medium

    CN111008833A