A bank card remote fraud protection method and system based on relay attack

By using the location inspection mechanism of payment terminals and card terminals in bank card transactions, the problems of data item requirements, transaction speed impact and low protection accuracy of the existing technology of anti-relay attack methods are solved, and more efficient and accurate protection effects are achieved.

CN119741023APending Publication Date: 2025-04-01金邦达有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510086842.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-20
Publication Date
2025-04-01

AI Technical Summary

Technical Problem

The existing anti-relay attack method based on RRP protocol has many data items requirements, ERRD command sending that affects transaction speed, and calculating the execution time of ERRD commands that are susceptible to network impacts, resulting in low protection accuracy.

Method used

During the consumption transaction process, the payment terminal sends a command to generate an application ciphertext to the card end. The card end checks based on the location data of the bank card and the terminal. If it is not in the same country or location, the transaction will be rejected. The transaction information includes the application ciphertext for verification by the issuing bank.

Benefits of technology

It improves the protection effect of remote bank card stolen based on relay attacks, avoids the network impact of calculating the execution time of ERRD commands, reduces additional data items and command operations during the transaction process, and improves the security and accuracy of transactions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119741023A_ABST
    Figure CN119741023A_ABST
Patent Text Reader

Abstract

The present application discloses a method and system for protecting bank card remote fraud based on relay attack, the method comprising: in the process of consumer transaction, the payment terminal sends a command to generate application ciphertext to the card end, the card end performs a position check according to the bank card position data and the terminal position data carried in the command, if the bank card and the payment terminal are found to be in the same country or the same location, the transaction is approved and the response data is returned to the payment terminal, if the bank card and the payment terminal are found to be not in the same country and the same location, the transaction is rejected; after receiving the response data, the payment terminal performs the same position check as the card end, collects the transaction information and uploads it to the acquiring institution when the transaction continues, and the acquiring institution forwards the transaction information to the issuing bank; the transaction information at least includes the application ciphertext; the issuing bank verifies the application ciphertext, if the verification passes, the transaction is completed, if the verification fails, the transaction is stopped. The present application improves the protection effect against relay attacks and transaction security.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of transaction security technology, and in particular to a method and system for protecting against remote bank card fraud based on relay attacks. Background Art

[0002] Since the issuance of bank cards, transaction security has always been the most concerned issue for card groups, banks and users. The transformation from the initial magnetic stripe card (that is, storing data directly in the magnetic stripe) to the currently widely used chip card (storing all data in the security chip) is a significant change to enhance the security of card data. This change basically prevents the problem of bank card fraud by reading the card information stored in the magnetic stripe card. With the continuous upgrading and optimization of security chips, and the addition of anti-security attack codes to the software, the security performance of chip cards has been greatly improved, the difficulty of attack has also been greatly increased, and the security risks of bank cards have been greatly reduced. However, with the rapid development of the Internet and the iterative update of smartphone functions, a new bank card gang fraud method has begun to emerge. That is, one fraud gang is in China and the other is abroad. The domestic cardholder cooperates with the foreign gang through relay attacks to realize a remote overseas transaction. Then, in a very short time, the cardholder makes another normal consumption locally to prove that the card was stolen abroad, so as to order the issuing bank to compensate for it.

[0003] The above-mentioned gang fraud incidents can be prevented by preventing relay attacks. Relay attacks refer to remote transactions between bank cards and payment terminals that are not face-to-face transactions, but are achieved through an intermediate medium. For example, a relay attack is achieved through NFO software and the NFC function of a mobile phone. The real cardholder and bank card are in China. The cardholder uses a mobile phone to install and register the NFO software, and then holds the card close to the mobile phone. The NFO software reads the card information through NFC technology and transmits the card information to a mobile phone abroad that also has the NFO software installed through the network. At this time, the foreign mobile phone can complete the card swiping consumption at the payment terminal (such as a POS machine) by stealing the card password or tricking the cardholder into providing the card password. The method of preventing relay attacks is currently commonly used based on the Relay Resistance Protocol (RRP), that is, sending the ERRD (Exchange Relay Resistance Data command) command during the transaction and counting the time the card executes this command. If the execution time of the three executions is greater than the preset time threshold, it can be considered that a relay attack has occurred, and the payment terminal terminates the transaction. This method can prevent relay attacks to a certain extent, but it has obvious disadvantages: 1) Both the payment terminal and the card need to have built-in data objects related to the RRP protocol, and there are many data items; 2) It is necessary to send ERRD commands that are not related to the transaction, which affects the transaction speed; 3) Due to factors such as the network, the execution time of ERRD cannot be accurately counted, resulting in low protection accuracy, which affects the normal transaction; 4) Only the payment terminal performs the anti-relay attack risk management process, and the prevention level is relatively weak; 5) If the transaction is successful, it is impossible to verify whether the cardholder's password was provided voluntarily or stolen. Summary of the invention

[0004] The present application provides a method and system for protecting against remote fraudulent use of bank cards based on relay attacks, which are used to improve the technical problems existing in the anti-relay attack method based on the RRP protocol, such as the need to build in multiple data in bank cards and payment terminals, the need to send ERRD commands unrelated to transactions, which affects the transaction speed, and the execution time of the ERRD command is easily affected by the network, resulting in low protection accuracy.

[0005] In view of this, the first aspect of the present application provides a method for protecting bank card remote fraud based on relay attacks, comprising:

[0006] During the consumption transaction process, the payment terminal sends a command to generate application ciphertext to the card end, and the card end performs a location check based on the bank card location data stored in the bank card and the terminal location data carried in the command to generate application ciphertext. If it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction is approved and response data is returned to the payment terminal. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is rejected; the response data includes the application ciphertext and the location information of the bank card;

[0007] After receiving the response data, the payment terminal performs a location check based on the terminal location data and the acquired bank card location data. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is terminated; if it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction information is collected and uploaded to the acquiring institution, and the acquiring institution uploads the transaction information to the issuing bank; the transaction information at least includes the application ciphertext;

[0008] The issuing bank verifies the application ciphertext, and if the verification passes, the transaction is completed; if the verification fails, the transaction is stopped.

[0009] Optionally, the bank card location data includes the issuing bank country code and the location information of the bank card, and the terminal location data includes the payment terminal country code and the location information of the payment terminal;

[0010] Performing a location check according to the bank card location data stored in the bank card and the terminal location data carried in the command to generate the application ciphertext includes:

[0011] Comparing whether the payment terminal country code carried in the generate application ciphertext command is the same as the issuing bank country code stored in the bank card;

[0012] If they are the same, it is determined that the bank card and the payment terminal are in the same country;

[0013] If they are not the same, it is determined that the bank card and the payment terminal are not in the same country, and the location information of the bank card stored in the bank card is compared with the location information of the payment terminal carried in the generate application ciphertext command. If the location distance between the bank card and the payment terminal is within a preset range, it is determined that the bank card and the payment terminal are in the same location; if the location distance between the bank card and the payment terminal exceeds the preset range, it is determined that the bank card and the payment terminal are not in the same location.

[0014] Optionally, the payment terminal sends a generate application ciphertext command to the card terminal, before that, it also includes:

[0015] The payment terminal sends a command to select a short-distance payment system environment to the card terminal, and receives file control information of the short-distance payment system environment returned by the card terminal;

[0016] The payment terminal sends a select application identifier command to the card end, selects a financial application, and receives file control information of the financial application returned by the card end;

[0017] The payment terminal sends an application initialization command to the card end, receives the application interaction characteristics and application file locator returned by the card end, and sends a read record command to the card end according to the application file locator to obtain the country code of the issuing bank.

[0018] Optionally, the transaction information further includes location information of the bank card and location information of the payment terminal;

[0019] The acquiring institution uploads the transaction information to the issuing bank, before which:

[0020] The acquiring institution performs location matching based on the location information of the bank card in the transaction information and the location information of the acquiring institution. If the locations of the bank card and the acquiring institution do not match, the current transaction is marked as an abnormal transaction and the transaction is terminated. If the locations of the bank card and the acquiring institution match, subsequent steps are executed.

[0021] Optionally, the application ciphertext is generated based on the location information of the bank card and the location information of the payment terminal;

[0022] The issuing bank verifies the application ciphertext, and if the verification passes, the transaction is completed; if the verification fails, the transaction is stopped, including:

[0023] The issuing bank verifies the application ciphertext according to the location information of the bank card and the location information of the payment terminal. If the verification passes, the transaction is completed; if the verification fails, the transaction is stopped.

[0024] Optionally, the mobile banking corresponding to the bank card supports modifying the location information of the bank card, and the method further includes:

[0025] After rejecting the transaction, the card terminal responds to the cardholder's login operation and enters the mobile banking interface corresponding to the bank card, and modifies the location information of the bank card to the location of the payment terminal according to the cardholder's modification operation.

[0026] Optionally, the payment terminal has a built-in positioning module, and the positioning module is used to obtain location information of the payment terminal.

[0027] The second aspect of the present application provides a bank card remote fraud protection system based on relay attack, comprising:

[0028] The payment terminal is used to send a command to generate an application ciphertext to the card terminal during a consumption transaction;

[0029] The card terminal is used to perform a location check based on the bank card location data stored in the bank card and the terminal location data carried in the command to generate the application ciphertext. If it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction is approved and response data is returned to the payment terminal. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is rejected; the response data includes the application ciphertext and the location information of the bank card;

[0030] The payment terminal is further used to receive the response data, perform a location check based on the terminal location data and the acquired bank card location data, and terminate the transaction if it is found that the bank card and the payment terminal are not in the same country and the same location; if it is found that the bank card and the payment terminal are in the same country or the same location, collect transaction information and upload it to the acquiring institution; the transaction information at least includes the application ciphertext;

[0031] The acquiring institution is used to upload the transaction information to the issuing bank;

[0032] The issuing bank is used to verify the application ciphertext. If the verification passes, the transaction is completed; if the verification fails, the transaction is stopped.

[0033] Optionally, the bank card location data includes the issuing bank country code and the location information of the bank card, and the terminal location data includes the payment terminal country code and the location information of the payment terminal; the card terminal is specifically used for:

[0034] Comparing whether the payment terminal country code carried in the generate application ciphertext command is the same as the issuing bank country code stored in the bank card;

[0035] If they are the same, it is determined that the bank card and the payment terminal are in the same country, the transaction is approved and response data is returned to the payment terminal;

[0036] If they are not the same, it is determined that the bank card and the payment terminal are not in the same country, and the location information of the bank card stored in the bank card is compared with the location information of the payment terminal carried in the generate application ciphertext command. If the location distance between the bank card and the payment terminal is within a preset range, it is determined that the bank card and the payment terminal are in the same location, the transaction is approved and response data is returned to the payment terminal; if the location distance between the bank card and the payment terminal exceeds the preset range, it is determined that the bank card and the payment terminal are not in the same location, and the transaction is rejected.

[0037] Optionally, the payment terminal has a built-in positioning module, and the positioning module is used to obtain location information of the payment terminal.

[0038] It can be seen from the above technical solutions that this application has the following advantages:

[0039] The present application provides a method for protecting against remote bank card fraud based on relay attacks. The payment terminal sends its own location information to the card side by generating an application ciphertext command related to the transaction, without the need to embed other data items. The payment terminal does not need to send an ERRD command that is not related to the transaction, and does not need to calculate the execution time of the ERRD command during the transaction. The card side does not need to execute additional ERRD commands, which has less impact on the transaction time. Both the card side and the payment terminal can perform a location check through the bank card location data and the terminal location data. If it is found that the card location and the terminal location are different, both the card side and the payment terminal can terminate the transaction. The card side and the payment terminal perform double location information checks, which improves the protection effect against remote bank card fraud based on relay attacks and avoids the technical problem that the use of calculating the execution time of the ERRD command for relay attack protection is easily affected by the network, resulting in low protection accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0041] Figure 1 A flowchart of a method for protecting a bank card from remote fraud based on relay attacks provided in an embodiment of the present application;

[0042] Figure 2 Another flowchart of a bank card remote fraud protection method based on relay attack provided in an embodiment of the present application;

[0043] Figure 3 A diagram of a remote card swiping process based on a relay attack provided in an embodiment of the present application. DETAILED DESCRIPTION

[0044] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0045] For easier understanding, please refer to Figure 1 The embodiment of the present application provides a method for protecting bank card remote fraud based on relay attack, comprising:

[0046] Step 110: During the consumption transaction, the payment terminal sends a command to generate application ciphertext to the card side, and the card side performs a location check based on the bank card location data stored in the bank card and the terminal location data carried in the command to generate application ciphertext. If it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction is approved and response data is returned to the payment terminal. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is rejected.

[0047] In the process of remote bank card fraud based on relay attacks, the domestic cardholder's mobile phone is installed and registered with software that can read card information (such as NFO software). The cardholder holds the bank card close to the mobile phone for NFC identification. At this time, the card will be connected to the overseas mobile phone through the software. The overseas mobile phone is close to the payment terminal of a legitimate merchant (such as a POS terminal) to perform card transactions.

[0048] Please refer to Figure 2 During the consumption transaction, the payment terminal will send transaction-related commands to the card end (card or the mobile device corresponding to the card user, such as a mobile phone), specifically:

[0049] The payment terminal sends a Select PPSE command to the card and receives the FCI (PPSE) returned by the card.

[0050] The payment terminal sends a select application identifier command (SELECT AID) to the card side, selects the financial application, and receives the file control information of the financial application returned by the card side, namely FCI (AID);

[0051] The payment terminal sends an application initialization command (GPO) to the card side, receives the application interaction characteristics (AIP) and application file locator (AFL) returned by the card side, and sends a read record command (READRECORD) to the card side according to the application file locator. The card side returns the relevant record (RECORD), which contains the country code data item of the issuing bank. The payment terminal can obtain the country code of the issuing bank from the country code data item of the issuing bank in the record;

[0052] The payment terminal sends a Generate Application Ciphertext Command (GAC) to the card side. The GAC command carries the terminal location data, which includes the payment terminal country code and the location information of the payment terminal. It should be noted that the payment terminal has a built-in positioning module (such as a GPS chip), which is used to obtain the location information of the payment terminal. After receiving the GAC command, the card side performs a location check based on the terminal location data carried in the GAC command and the bank card location data stored in the bank card to check whether the bank card and the payment terminal are in the same country or the same location. If the bank card and the payment terminal are found to be in the same country or the same location, the transaction is approved and the response data is returned to the payment terminal. If the bank card and the payment terminal are not found to be in the same country and the same location, the transaction is rejected. Among them, the bank card location data includes the issuing bank country code and the location information of the bank card.

[0053] Specifically, after receiving the GAC command, the card terminal compares the payment terminal country code carried in the generated application ciphertext command with the issuing bank country code stored in the bank card to see if they are the same;

[0054] If they are the same, it is determined that the bank card and the payment terminal are in the same country. The card terminal approves the transaction, generates an application ciphertext (AC), and returns response data to the payment terminal; the response data includes the application ciphertext and the location information of the bank card;

[0055] If they are not the same, it is determined that the bank card and the payment terminal are not in the same country. The location information of the bank card stored in the bank card is further compared with the location information of the payment terminal carried in the generated application ciphertext command. If the location distance between the bank card and the payment terminal is within the preset range, it is determined that the bank card and the payment terminal are in the same location. The card side annotates the transaction and returns response data to the payment terminal. If the location distance between the bank card and the payment terminal exceeds the preset range, it is determined that the bank card and the payment terminal are not in the same location. The card side rejects the transaction. At this time, the payment terminal can prompt the reason for the transaction failure.

[0056] Furthermore, after rejecting the transaction, the card terminal responds to the cardholder's login operation and enters the mobile banking interface corresponding to the bank card, and modifies the location information of the bank card to the location of the payment terminal according to the cardholder's modification operation.

[0057] The embodiment of the present application takes into account the situation that the actual cardholder may be rejected for legitimate transactions abroad (the issuing bank country code stored in the card is different from the terminal country code). When the cardholder needs to make a purchase in a different place, in order to make the transaction successful, the mobile banking corresponding to the bank card can be set to support the modification of the bank card's location information. The cardholder can change the card's location information to the location of the payment terminal through the mobile banking APP, and then make the transaction again. At this time, the card terminal will approve the transaction after checking that the bank card's location information is in the same location as the payment terminal's location information. It should be noted that the issuing bank's country code cannot be changed through the mobile banking APP.

[0058] If it is an illegal transaction (i.e. the card is in the local area and the payment terminal is outside the country), the transaction will not be successful as long as the cardholder does not change the actual location information of the card. In other words, remote transactions require the cardholder's confirmation to succeed. Even if the password is stolen, the transaction will not be successful without manually changing the card location information. This can confirm that this transaction is actively cooperated by the cardholder and does not constitute fraudulent use.

[0059] Step 120: After receiving the response data, the payment terminal performs a location check based on the terminal location data and the acquired bank card location data. If it is found that the bank card and the payment terminal are not in the same country and the same location, the transaction is terminated. If it is found that the bank card and the payment terminal are in the same country or the same location, the transaction information is collected and uploaded to the acquiring institution, which then uploads the transaction information to the issuing bank.

[0060] In one embodiment, after the card approves the transaction and the payment terminal receives the response data, it uploads the collected transaction information to the acquiring institution if it can be connected online. The transaction information at least includes the application ciphertext, and the transaction information may also include the location information of the bank card and the terminal location information.

[0061] In another embodiment, in order to further improve the security of the transaction, after receiving the response data, the payment terminal can perform the same location check process as the card terminal, that is, first check whether the issuing bank country code and the terminal country code are the same. If they are the same, collect the transaction information and upload it to the acquiring institution. If they are not the same, further compare the location based on the location information of the bank card and the location information of the terminal. If the location distance between the bank card and the payment terminal is within the preset range, it is determined that the bank card and the payment terminal are in the same location, and collect the transaction information and upload it to the acquiring institution; if the location distance between the bank card and the payment terminal exceeds the preset range, it is determined that the bank card and the payment terminal are not in the same location, and the payment terminal refuses the transaction. By performing location checks on the card and the payment terminal, it is prevented that when the payment terminal sends the GAC command, the terminal country code or the terminal location information in the data field of the GAC command is tampered with during the transmission process, thereby further improving the security of bank card transactions.

[0062] In one embodiment, after receiving the transaction information, the acquirer may directly upload the transaction information to the issuing bank.

[0063] In another embodiment, in order to further improve the security of the transaction, after receiving the transaction information, the acquiring institution can perform location matching based on the location information of the bank card in the transaction information and the location information of the current acquiring institution. If the locations of the bank card and the acquiring institution do not match, it means that there may be a relay attack, and the current transaction is marked as an abnormal transaction and terminated. If the locations of the bank card and the payment terminal match, the transaction information is uploaded to the issuing bank.

[0064] Step 130: The issuing bank verifies the application ciphertext. If the verification passes, the transaction is completed; if the verification fails, the transaction is stopped.

[0065] In one embodiment, when the card side executes the GAC command, the card side may generate the application ciphertext based on the existing composite dynamic data authentication / application ciphertext generation method.

[0066] In another embodiment, when the card side executes the GAC command, based on the existing technology, the location information of the bank card and the location information of the payment terminal can also be used as input data to generate the application ciphertext, that is, when the card side executes the GAC command, the location information of the bank card and the location information of the payment terminal are involved in the AC calculation, which helps to prevent the location information from being tampered with during the transaction process and improve the security of the transaction. After receiving the application ciphertext, the issuing bank verifies the application ciphertext according to the location information of the bank card and the location information of the payment terminal in the transaction information. If the verification is passed, it means that the plain text of the location information has not been tampered with during the transmission process, and the transaction is valid. If the verification fails, the transaction is stopped and the deduction of this transaction fails.

[0067] The present application provides a method for protecting against remote bank card fraud based on relay attacks. The payment terminal sends its own location information to the card side by generating an application ciphertext command related to the transaction, without the need to embed other data items. The payment terminal does not need to send an ERRD command that is not related to the transaction, and does not need to calculate the execution time of the ERRD command during the transaction. The card side does not need to execute additional ERRD commands, which has less impact on the transaction time. Both the card side and the payment terminal can perform a location check through the bank card location data and the terminal location data. If it is found that the card location and the terminal location are different, both the card side and the payment terminal can terminate the transaction. The card side and the payment terminal perform double location information checks, which improves the protection effect against remote bank card fraud based on relay attacks and avoids the technical problem that the use of calculating the execution time of the ERRD command for relay attack protection is easily affected by the network, resulting in low protection accuracy.

[0068] Furthermore, the acquiring institution and the issuing bank in the embodiment of the present application can participate in the relay attack risk protection process. Without increasing the complexity of the transformation of the payment system and without affecting the normal transaction process, through a four-level prevention and control mechanism, namely, position comparison between the card end, payment terminal, and acquiring institution and AC verification by the issuing bank, relay attacks can be effectively identified, illegal transactions can be intercepted, and the security of transactions can be improved.

[0069] Furthermore, for a remote transaction to be successful, the cardholder must modify the card location information through the mobile banking app. This operation can serve as evidence that the cardholder actively cooperated with the transaction.

[0070] The above is an embodiment of a bank card remote fraud protection method based on relay attack provided by the present application. The following is an embodiment of a bank card remote fraud protection system based on relay attack provided by the present application.

[0071] The embodiment of the present application provides a bank card remote fraud protection system based on relay attack, comprising:

[0072] The payment terminal is used to send a command to generate application ciphertext to the card terminal during the consumption transaction;

[0073] The card end is used to perform a location check based on the bank card location data stored in the bank card and the terminal location data carried in the command to generate the application ciphertext. If it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction is approved and response data is returned to the payment terminal. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is rejected; the response data includes the application ciphertext and the location information of the bank card;

[0074] The payment terminal is also used to receive the response data, perform a location check based on the terminal location data and the acquired bank card location data, and terminate the transaction if it is checked that the bank card and the payment terminal are not in the same country and the same location; if it is checked that the bank card and the payment terminal are in the same country or the same location, collect transaction information and upload it to the acquiring institution; the transaction information at least includes the application ciphertext;

[0075] Acquirers are used to upload transaction information to the issuing bank;

[0076] The issuing bank verifies the application ciphertext. If the verification passes, the transaction is completed. If the verification fails, the transaction is stopped.

[0077] Please refer to Figure 3A remote card swiping process based on relay attack is provided. In the remote bank card fraud process based on relay attack, the domestic cardholder's mobile phone is installed and registered with software that can read card information (such as NFO software). The cardholder puts the bank card close to the mobile phone for NFC identification. At this time, the card will be connected to the overseas mobile phone through the software. The overseas mobile phone is close to the payment terminal of the legitimate merchant (such as POS terminal) to perform card swiping transactions.

[0078] During a consumer transaction, the payment terminal sends transaction-related commands to the card terminal (the card or the mobile device corresponding to the card user, such as a mobile phone). Specifically, the payment terminal is used to:

[0079] Send the Select PPSE command to the card side, and receive the file control information of the PPSE environment returned by the card side, namely FCI (PPSE);

[0080] Send a select application identifier command (SELECT AID) to the card side, select a financial application, and receive the file control information of the financial application returned by the card side, namely FCI (AID);

[0081] Send an application initialization command (GPO) to the card side, receive the application interaction characteristics (AIP) and application file locator (AFL) returned by the card side, and send a read record command (READRECORD) to the card side according to the application file locator, and receive the relevant record (RECORD) returned by the card side. The record contains the country code data item of the issuing bank. The payment terminal can obtain the country code of the issuing bank from the country code data item of the issuing bank in the record;

[0082] Furthermore, the card end is specifically used to compare whether the payment terminal country code carried in the command to generate the application ciphertext is the same as the issuing bank country code stored in the bank card;

[0083] If they are the same, it is determined that the bank card and the payment terminal are in the same country, the transaction is approved and response data is returned to the payment terminal; the response data at least includes the application ciphertext, and the response data may also include the location information of the bank card;

[0084] If they are not the same, it is determined that the bank card and the payment terminal are not in the same country, and the location information of the bank card stored in the bank card is compared with the location information of the payment terminal carried in the generated application ciphertext command. If the location distance between the bank card and the payment terminal is within the preset range, it is determined that the bank card and the payment terminal are in the same location, the transaction is approved and response data is returned to the payment terminal; if the location distance between the bank card and the payment terminal exceeds the preset range, it is determined that the bank card and the payment terminal are not in the same location, and the transaction is rejected.

[0085] Furthermore, the mobile banking corresponding to the bank card supports modifying the location information of the bank card. The card end is also used to enter the mobile banking interface corresponding to the bank card in response to the cardholder's login operation after the transaction is rejected, and modify the location information of the bank card to the location of the payment terminal according to the cardholder's modification operation.

[0086] The embodiments of the present application take into account the situation that the actual cardholder may be rejected for legitimate transactions abroad (the issuing bank country code and the terminal country code stored in the card are different). In order to make the transaction successful, the location information of the bank card can be modified through the mobile banking support corresponding to the bank card. The cardholder can change the location information of the card through the mobile banking APP and then conduct the transaction again. At this time, it is checked that the location information of the bank card is in the same location as the location information of the payment terminal, and the card end will approve the transaction.

[0087] If it is an illegal transaction (i.e. the card is in the local area and the payment terminal is outside the country), the transaction will not be successful as long as the cardholder does not change the actual location information of the card. In other words, remote transactions require the cardholder's confirmation to succeed. Even if the password is stolen, the transaction will not be successful without manually changing the card location information. This can confirm that this transaction is actively cooperated by the cardholder and does not constitute fraudulent use.

[0088] After receiving the response data, the payment terminal performs a location check based on the terminal location data and the acquired bank card location data. If it is found that the bank card and the payment terminal are not in the same country or the same location, the transaction is terminated; if it is found that the bank card and the payment terminal are in the same country or the same location, the transaction information is collected and uploaded to the acquiring institution. By performing location checks on the card and the payment terminal, the terminal country code or the terminal location information in the data field of the GAC command is prevented from being tampered with during transmission when the payment terminal sends the GAC command, thereby further improving the security of bank card transactions.

[0089] Furthermore, the acquiring institution is also used to perform location matching based on the location information of the bank card in the transaction information and the location information of the acquiring institution. If the locations of the bank card and the acquiring institution do not match, the current transaction is marked as an abnormal transaction and the transaction is terminated. If the locations of the bank card and the acquiring institution match, the transaction information is collected.

[0090] Furthermore, when the card executes the GAC command, based on the existing technology, the location information of the bank card and the location information of the payment terminal can also be used as input data to generate the application ciphertext, that is, when the card executes the GAC command, the location information of the bank card and the location information of the payment terminal are involved in the AC calculation, which helps to prevent the location information from being tampered with during the transaction and improve the security of the transaction. The issuing bank is specifically used to verify the application ciphertext according to the location information of the bank card and the location information of the payment terminal. If the verification is passed, the transaction is completed. If the verification fails, the transaction is stopped.

[0091] During the transaction, the card side and the payment terminal exchange their respective location data, and each performs a risk management check on the location data. If the card location and the payment terminal location are found to be different, the card or the payment terminal can terminate the transaction. The location data comparison process here is divided into two levels. The first level is to compare the issuing bank country code stored in the card with the terminal country code sent to the card side by the payment terminal. The second level is to compare the current location information of the card with the location information of the terminal. In addition, the card side and the issuing bank have made some adjustments to the card calculation AC process and input data. That is, during the transaction, when the card side executes the GAC command, the card location information and the terminal location information need to participate in the AC calculation to prevent the transaction process from being tampered with. When the transaction information is sent to the acquiring institution, the acquiring institution continues to compare the card location information with the current acquiring institution location to see if it matches. If it does not match, it means that there may be a relay attack, and the transaction is marked as an abnormal transaction and terminated in time. If they match, the transaction information will be sent to the issuing bank, which will verify AC through the location information of the bank card and the location information of the payment terminal. If the verification passes, it means that the plain text location information has not been tampered with during the transmission process and the transaction is valid. If it fails, the transaction deduction fails. In the entire transaction process, there are four levels of prevention and control, namely the card end, payment terminal, acquiring institution and issuing bank, which greatly improves the prevention and control effect of relay attacks.

[0092] The bank card and the issuing bank in the above system need to upgrade the AC calculation method synchronously, that is, the input data includes the location information of the bank card and the location information of the payment terminal. The card side, payment terminal and acquiring institution need to be upgraded synchronously to add the card location and the location check function of the current terminal or acquiring institution. The upgrade and transformation of the existing payment system is relatively simple. According to the existing card logic, the payment terminal sends its location information to the card side through the GAC command, without the need to build in other data items; the card side does not need to execute additional ERRD commands, and can be realized only by relying on the GAC command, which does not affect the time of the entire transaction; the GPS chip obtains the terminal location information, which is less affected by network factors and more accurate than the method of calculating the execution time of the ERRD command; the card side, payment terminal, acquiring institution and issuing bank can all participate in the risk management process of anti-relay attack, and the protection effect is more reliable; if the remote transaction is to be successfully executed, the cardholder must modify the card location information through the mobile banking APP, and this operation can be used as evidence that the cardholder actively cooperates with the transaction.

[0093] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the system described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.

[0094] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of this application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0095] It should be understood that in this application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.

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

Claims

1. A bank card remote fraud protection method based on relay attack, characterized in that: include: During the consumption transaction process, the payment terminal sends a command to generate application ciphertext to the card end, and the card end performs a location check based on the bank card location data stored in the bank card and the terminal location data carried in the command to generate application ciphertext. If it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction is approved and response data is returned to the payment terminal. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is rejected; the response data includes the application ciphertext and the location information of the bank card; After receiving the response data, the payment terminal performs a location check based on the terminal location data and the acquired bank card location data. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is terminated; if it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction information is collected and uploaded to the acquiring institution, and the acquiring institution uploads the transaction information to the issuing bank; the transaction information at least includes the application ciphertext; The issuing bank verifies the application ciphertext, and if the verification passes, the transaction is completed; if the verification fails, the transaction is stopped.

2. The bank card remote fraud protection method based on relay attack according to claim 1 is characterized in that: The bank card location data includes the issuing bank country code and the bank card location information, and the terminal location data includes the payment terminal country code and the payment terminal location information; Performing a location check according to the bank card location data stored in the bank card and the terminal location data carried in the command to generate the application ciphertext includes: Comparing whether the payment terminal country code carried in the generate application ciphertext command is the same as the issuing bank country code stored in the bank card; If they are the same, it is determined that the bank card and the payment terminal are in the same country; If they are not the same, it is determined that the bank card and the payment terminal are not in the same country, and the location information of the bank card stored in the bank card is compared with the location information of the payment terminal carried in the generate application ciphertext command. If the location distance between the bank card and the payment terminal is within a preset range, it is determined that the bank card and the payment terminal are in the same location; if the location distance between the bank card and the payment terminal exceeds the preset range, it is determined that the bank card and the payment terminal are not in the same location.

3. The bank card remote fraud protection method based on relay attack according to claim 1 is characterized in that: The payment terminal sends a command to generate application ciphertext to the card end, and before that, it also includes: The payment terminal sends a command to select a short-distance payment system environment to the card terminal, and receives file control information of the short-distance payment system environment returned by the card terminal; The payment terminal sends a select application identifier command to the card end, selects a financial application, and receives file control information of the financial application returned by the card end; The payment terminal sends an application initialization command to the card end, receives the application interaction characteristics and application file locator returned by the card end, and sends a read record command to the card end according to the application file locator to obtain the country code of the issuing bank.

4. The bank card remote fraud protection method based on relay attack according to claim 1 is characterized in that: The transaction information also includes the location information of the bank card and the location information of the payment terminal; The acquiring institution uploads the transaction information to the issuing bank, before which: The acquiring institution performs location matching based on the location information of the bank card in the transaction information and the location information of the acquiring institution. If the locations of the bank card and the acquiring institution do not match, the current transaction is marked as an abnormal transaction and the transaction is terminated. If the locations of the bank card and the acquiring institution match, subsequent steps are executed.

5. The bank card remote fraud protection method based on relay attack according to claim 4 is characterized in that: The application ciphertext is generated based on the location information of the bank card and the location information of the payment terminal; The issuing bank verifies the application ciphertext, and if the verification passes, the transaction is completed; if the verification fails, the transaction is stopped, including: The issuing bank verifies the application ciphertext according to the location information of the bank card and the location information of the payment terminal. If the verification passes, the transaction is completed; if the verification fails, the transaction is stopped.

6. The bank card remote fraud protection method based on relay attack according to claim 1 is characterized in that: The mobile banking corresponding to the bank card supports modifying the location information of the bank card, and the method further includes: After rejecting the transaction, the card terminal responds to the cardholder's login operation and enters the mobile banking interface corresponding to the bank card, and modifies the location information of the bank card to the location of the payment terminal according to the cardholder's modification operation.

7. The bank card remote fraud protection method based on relay attack according to claim 1 is characterized in that: The payment terminal has a built-in positioning module, and the positioning module is used to obtain the location information of the payment terminal.

8. A bank card remote fraud protection system based on relay attack, characterized in that: include: The payment terminal is used to send a command to generate an application ciphertext to the card terminal during a consumption transaction; The card terminal is used to perform a location check based on the bank card location data stored in the bank card and the terminal location data carried in the command to generate the application ciphertext. If it is checked that the bank card and the payment terminal are in the same country or the same location, the transaction is approved and response data is returned to the payment terminal. If it is checked that the bank card and the payment terminal are not in the same country and the same location, the transaction is rejected; the response data includes the application ciphertext and the location information of the bank card; The payment terminal is further used to receive the response data, perform a location check based on the terminal location data and the acquired bank card location data, and terminate the transaction if it is found that the bank card and the payment terminal are not in the same country and the same location; if it is found that the bank card and the payment terminal are in the same country or the same location, collect transaction information and upload it to the acquiring institution; the transaction information at least includes the application ciphertext; The acquiring institution is used to upload the transaction information to the issuing bank; The issuing bank is used to verify the application ciphertext. If the verification passes, the transaction is completed; if the verification fails, the transaction is stopped.

9. The bank card remote fraud protection system based on relay attack according to claim 8 is characterized in that: The bank card location data includes the issuing bank country code and the bank card location information, and the terminal location data includes the payment terminal country code and the payment terminal location information; the card terminal is specifically used for: Comparing whether the payment terminal country code carried in the generate application ciphertext command is the same as the issuing bank country code stored in the bank card; If they are the same, it is determined that the bank card and the payment terminal are in the same country, the transaction is approved and response data is returned to the payment terminal; If they are not the same, it is determined that the bank card and the payment terminal are not in the same country, and the location information of the bank card stored in the bank card is compared with the location information of the payment terminal carried in the generate application ciphertext command. If the location distance between the bank card and the payment terminal is within a preset range, it is determined that the bank card and the payment terminal are in the same location, the transaction is approved and response data is returned to the payment terminal; if the location distance between the bank card and the payment terminal exceeds the preset range, it is determined that the bank card and the payment terminal are not in the same location, and the transaction is rejected.

10. The bank card remote fraud protection system based on relay attack according to claim 8, characterized in that: The payment terminal has a built-in positioning module, and the positioning module is used to obtain the location information of the payment terminal.