CN113489623B - Verification code testing method, verification code testing device, electronic equipment, storage medium and program product - Google Patents

Verification code testing method, verification code testing device, electronic equipment, storage medium and program product Download PDF

Info

Publication number
CN113489623B
CN113489623B CN202110745221.1A CN202110745221A CN113489623B CN 113489623 B CN113489623 B CN 113489623B CN 202110745221 A CN202110745221 A CN 202110745221A CN 113489623 B CN113489623 B CN 113489623B
Authority
CN
China
Prior art keywords
account
test
verification
verification code
sending
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110745221.1A
Other languages
Chinese (zh)
Other versions
CN113489623A (en
Inventor
杜锋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202110745221.1A priority Critical patent/CN113489623B/en
Publication of CN113489623A publication Critical patent/CN113489623A/en
Application granted granted Critical
Publication of CN113489623B publication Critical patent/CN113489623B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/14Arrangements for monitoring or testing data switching networks using software, i.e. software packages
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/50Testing arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/08Network architectures or network communication protocols for network security for authentication of entities
    • H04L63/083Network architectures or network communication protocols for network security for authentication of entities using passwords
    • H04L63/0846Network architectures or network communication protocols for network security for authentication of entities using passwords using time-dependent-passwords, e.g. periodically changing passwords

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Computer And Data Communications (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The invention relates to a verification code testing method, a verification code testing device, electronic equipment, a storage medium and a program product, wherein a first account and a second account are generated according to testing round information and a reference account by acquiring the testing round information and the reference account, and the first account and the second account have a difference step value; the method comprises the steps that a sending interface and a verification interface of a verification code are called simultaneously, a sending request and a verification request for obtaining the verification code are sent to a server, so that the server is instructed to verify a first account and a test verification code corresponding to the first account, and sending of the test verification code corresponding to a second account is triggered according to the second account; the sending pressure measurement and the verification pressure measurement are integrated in a set of test program, and the program deployment work is simplified.

Description

Verification code testing method, verification code testing device, electronic equipment, storage medium and program product
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a verification code testing method and apparatus, an electronic device, a storage medium, and a program product.
Background
In a typical service scenario of the verification code, the server provides a verification code with time validity for the user during the user login or transaction process, the user sends the verification code to the server within the valid time, and the server verifies the validity of the user through the received verification code.
In the related art, in order to know the carrying capacity of the server, a pressure test (abbreviated as a pressure test) is generally performed on the server providing the verification code service before the product is brought online. However, the current captcha pressure test method has some impact on the deployment of test programs.
Disclosure of Invention
The present disclosure provides a verification code testing method, device, electronic device, storage medium, and program product, to at least solve the problem of complex deployment of test programs in related technologies. The technical scheme of the disclosure is as follows:
according to a first aspect of the embodiments of the present disclosure, there is provided a verification code testing method applied to a test client, including:
acquiring test round information and a reference account, wherein the reference account is an account reference value used for verification code testing;
generating a first account and a second account according to the test round information and the reference account, wherein the difference between the second account and the first account is a preset difference step value; the first account is used for representing a party to be verified who is verified in the current test round, and the second account is used for representing a sender who sends a request for obtaining a verification code in the current test round;
generating a verification request according to the first account and a test verification code corresponding to the first account, and generating a sending request for acquiring the verification code according to the second account;
calling a verification interface, and sending the verification request to a server, wherein the verification request is used for indicating the server to verify the first account and a test verification code corresponding to the first account;
and calling a sending interface while calling the verification interface, and sending the sending request for acquiring the verification code to the server, wherein the sending request for acquiring the verification code is used for indicating the server to trigger the sending of the test verification code corresponding to the second account according to the second account.
In one embodiment, before the obtaining of the test round information, the method includes:
generating the test round information in response to the starting operation of the pressure test;
the acquiring of the test round information includes:
and when the test round information does not exceed the test round threshold value, acquiring the test round information.
In one embodiment, before the invoking of the verification interface, the method further comprises:
acquiring a real passing rate, wherein the real passing rate is the percentage of passing verification of the real verification codes in a verification code verification service scene;
and randomly acquiring a preset number of characters from the character string corresponding to the first account as a test verification code corresponding to the first account by taking the real passing rate as the probability.
In one embodiment, the test round information includes a round serial number, and after sending the verification request to the server, the method further includes:
receiving a sending result of the second account and a verification result of the first account returned by the server;
and incrementing the turn sequence number according to the sending result and the verification result.
In one embodiment, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number, and the gap step value.
According to a second aspect of the embodiments of the present disclosure, there is provided a verification code testing method applied to a server, including:
receiving a verification request sent by a test client, verifying a first account and a test verification code corresponding to the first account according to the verification request, wherein the verification request is generated by the test client according to the first account and the test verification code corresponding to the first account, and the first account is used for representing a party to be verified in the current test round;
receiving a sending request for acquiring a verification code sent by the test client while receiving the verification request, and triggering sending of the test verification code corresponding to a second account number according to the second account number carried by the sending request for acquiring the verification code, wherein the sending request for acquiring the verification code is generated by the test client according to the second account number, and the second account number is used for representing a sender sending the request for acquiring the verification code in the current test round;
the difference between the second account and the first account is a preset difference step value, the first account and the second account are generated by the test client according to the test round information and a reference account, and the reference account is an account reference value used for verification code testing.
In one embodiment, the verifying the first account and the test verification code corresponding to the first account according to the verification request includes:
the method comprises the steps of obtaining a pre-stored verification code of a first account from a database, and verifying a test verification code corresponding to the first account by using the verification code of the first account.
In one embodiment, the method further comprises:
and deleting the test verification code of the first account from the database after the test verification code corresponding to the first account is verified.
In one embodiment, the triggering, according to the second account carried in the request for sending the verification code, sending the test verification code corresponding to the second account includes:
acquiring a test verification code of the second account based on the second account;
storing a test verification code of the second account to a database, wherein the test verification code of the second account is used for verifying the test verification code corresponding to the second account in a subsequent test turn, and the subsequent test turn is equal to the sum of the current test turn and the difference step length value;
and calling a service interface of a third-party service provider to send the test verification code of the second account.
In one embodiment, the test round information includes a round serial number, and the method further includes:
and returning a verification result and a sending result to the test client, wherein the verification result and the verification result are used for indicating the test client to increase the round serial number.
In one embodiment, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number, and the gap step value.
According to a third aspect of the embodiments of the present disclosure, there is provided a verification code testing apparatus, applied to a test client, including:
the information account acquisition module is configured to execute acquisition of test round information and a reference account, wherein the reference account is an account reference value used for verification code testing;
the test account generation module is configured to execute generation of a first account and a second account according to the test round information and the reference account, wherein the difference between the second account and the first account is a preset difference step value; the first account is used for representing a party to be verified who is verified in the current test round, and the second account is used for representing a sender who sends a request for obtaining a verification code in the current test round;
the verification request generation module is configured to execute a verification request generated according to the first account and a test verification code corresponding to the first account, and generate a sending request for acquiring the verification code according to the second account;
the verification interface calling module is configured to execute calling of a verification interface and send the verification request to a server, wherein the verification request is used for indicating the server to verify the first account and a test verification code corresponding to the first account;
and the sending interface calling module is configured to call a sending interface while calling the verification interface, and send the sending request for obtaining the verification code to the server, wherein the sending request for obtaining the verification code is used for indicating the server to trigger sending of the test verification code corresponding to the second account according to the second account.
In one embodiment, the apparatus further comprises:
a round information generating module configured to perform a start operation in response to a stress test, and generate the test round information;
the information account number obtaining module is further configured to obtain the test round information when the test round information does not exceed a test round threshold.
In one embodiment, the apparatus further comprises:
the passing rate acquisition module is configured to execute the real passing rate acquisition, wherein the real passing rate is the percentage of the real verification codes passing the verification in the verification code verification service scene;
and the test code generation module is configured to execute the step of randomly acquiring a preset number of characters from a character string corresponding to the first account as a test verification code corresponding to the first account by taking the real passing rate as a probability.
In one embodiment, the apparatus further comprises:
a result receiving module configured to perform receiving of a transmission result of the second account and a verification result of the first account returned by the server;
a sequence number incrementing module configured to perform incrementing the round sequence number according to the transmission result and the verification result.
In one embodiment, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number, and the difference step value.
According to a fourth aspect of the embodiments of the present disclosure, there is provided a verification code testing apparatus applied to a server, including:
the verification request receiving module is configured to execute receiving of a verification request sent by a test client, and verify a first account and a test verification code corresponding to the first account according to the verification request, wherein the verification request is generated by the test client according to the first account and the test verification code corresponding to the first account, and the first account is used for representing a party to be verified in the current test round;
the sending request receiving module is configured to execute sending requests for obtaining the verification codes sent by the test client while receiving the verification requests, and trigger sending of the test verification codes corresponding to the second account according to the second account carried by the sending requests for obtaining the verification codes, wherein the sending requests for obtaining the verification codes are generated by the test client according to the second account, and the second account is used for representing a sender sending the requests for obtaining the verification codes in the current test round;
the difference between the second account and the first account is a preset difference step value, the first account and the second account are generated by the test client according to the test round information and a reference account, and the reference account is an account reference value used for verification code testing.
In one embodiment, the verification request receiving module is further configured to execute obtaining a verification code of a first account, which is stored in advance, from a database, and verify a test verification code corresponding to the first account by using the verification code of the first account.
In one embodiment, the apparatus further comprises:
the verification code deleting module is configured to delete the test verification code of the first account from the database after the test verification code corresponding to the first account is verified.
In one embodiment, the sending request receiving module is further configured to execute, based on the second account, obtaining a test verification code of the second account; storing a test verification code of the second account to a database, wherein the test verification code of the second account is used for verifying the test verification code corresponding to the second account in a subsequent test turn, and the subsequent test turn is equal to the sum of the current test turn and the difference step length value; and calling a service interface of a third party service provider to send the test verification code of the second account.
In one embodiment, the test round information includes a round serial number, and the apparatus further includes a result returning module configured to perform returning a verification result and a sending result to the test client, where the verification result and the verification result are used to instruct the test client to increment the round serial number.
In one embodiment, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number, and the gap step value.
According to a fifth aspect of embodiments of the present disclosure, there is provided an electronic apparatus including:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the captcha testing method as described above.
According to a sixth aspect of embodiments of the present disclosure, there is provided a computer-readable storage medium, wherein instructions of the computer-readable storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the verification code testing method as described above.
According to a seventh aspect of the embodiments of the present disclosure, there is provided a test system, including a test client and a server;
the test client comprises a first processor, a memory for storing the first processor executable instructions; wherein the first processor is configured to execute the instructions to implement any of the above described captcha testing methods from the testing client side;
the server comprises a second processor, a memory for storing instructions executable by the second processor; wherein the second processor is configured to execute the instructions to implement any one of the above-mentioned verification code testing methods described from the server side.
According to an eighth aspect of embodiments of the present disclosure, there is provided a computer program product comprising a computer program which, when executed by a processor, implements the above-described verification code testing method.
The technical scheme provided by the embodiment of the disclosure at least brings the following beneficial effects: generating a first account and a second account according to the test round information and the reference account by acquiring the test round information and the reference account, wherein the difference between the first account and the second account is a difference step value; the method comprises the steps that a sending interface and a verification interface of a verification code are called simultaneously, a sending request and a verification request for obtaining the verification code are sent to a server, so that the server is instructed to verify a first account and a test verification code corresponding to the first account, and sending of the test verification code corresponding to a second account is triggered according to the second account; the sending pressure measurement and the verification pressure measurement are integrated in a set of test program, and the program deployment work is simplified.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure and are not to be construed as limiting the disclosure.
FIG. 1 is a diagram illustrating an application environment for a verification code testing method, according to an example embodiment.
FIG. 2 is a flow diagram illustrating a method for verification code testing, according to an example embodiment.
FIG. 3 is a flow diagram illustrating a method for verification code testing, according to an example embodiment.
FIG. 4 is a flow diagram illustrating a method for verification code testing, according to an example embodiment.
FIG. 5 is a flow diagram illustrating a method for verification code testing, according to an example embodiment.
FIG. 6 is a flow diagram illustrating a method for verification code testing, according to an example embodiment.
FIG. 7 is a flow diagram illustrating a method for verification code testing, according to an example embodiment.
Fig. 8 is a flowchart illustrating step S720 according to an exemplary embodiment.
FIG. 9 is a flow diagram illustrating a method for verification code testing, according to an example embodiment.
FIG. 10 is a block diagram illustrating a verification code testing apparatus according to an example embodiment.
FIG. 11 is a block diagram illustrating a verification code testing apparatus according to an example embodiment.
FIG. 12 is a block diagram illustrating an electronic device in accordance with an example embodiment.
Detailed Description
In order to make the technical solutions of the present disclosure better understood by those of ordinary skill in the art, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the above-described drawings are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the disclosure described herein are capable of operation in other sequences than those illustrated or described herein. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
The verification code testing method provided by the disclosure can be applied to the application environment shown in fig. 1. Where test client 110 interacts with server 120 over a network. The test client 110 obtains test round information and a reference account, where the test round information includes a round number, and the reference account is an account reference value for verification code testing. And generating a first account and a second account according to the test round information and the reference account, wherein the first account is used for representing a party to be verified in the current test round for verification, and the second account is used for representing a sender sending a request for acquiring the verification code in the current test round. In the current test round, the sending interface and the verification interface are called at the same time, specifically, the verification interface is called, and a verification request is sent to the server 120, where the verification request is used to instruct the server 120 to verify the first account and the test verification code corresponding to the first account. And calling the sending interface while calling the verification interface, and sending a sending request for acquiring the verification code to the server 120, wherein the sending request for acquiring the verification code is used for indicating the server 120 to trigger sending of the test verification code corresponding to the second account according to the second account. The server 120 receives a sending request and a verification request for obtaining the verification code, which are sent by the test client 110 at the same time. The server 120 verifies the first account and the test verification code corresponding to the first account, and generates a verification result of the first account. The server 120 triggers the sending of the test verification code corresponding to the second account according to the second account carried by the request for sending the verification code, and generates a sending result of the second account. The server 120 returns the verification result and the transmission result to the testing client 110. The test client 110 increments the round number according to the sending result and the verification result.
The testing client 110 may be, but not limited to, various personal computers and notebook computers, or the testing client may also be an electronic device with strong data storage and computing capabilities, and the server 120 may be implemented by an independent server or a server cluster formed by a plurality of servers.
Fig. 2 is a flowchart illustrating a verification code testing method according to an exemplary embodiment, where, as shown in fig. 2, the verification code testing method is used in the test client 110, and includes the following steps:
in step S210, test round information and a reference account number are acquired.
And the reference account is an account reference value used for verification code testing. Specifically, the verification code test comprises the test of a transmission interface and a verification interface of the verification code. And carrying out multi-round pressure test on the sending interface and the verification interface of the verification code, wherein the test round information is used for representing the round information for carrying out the pressure test on the sending interface and the verification interface, and the test round information can be a test round identifier or a test round serial number. The multiple rounds of tests on the interface and the verification interface require a series of test account numbers to be generated, and the test account numbers can be a sender for sending a request for obtaining a verification code and can also be used for a party to be verified which needs to be verified. The reference account is selected as a reference value and used for generating the test account, so that the test can be performed orderly, and the range of the test account can be effectively controlled. Therefore, the test client needs to obtain the test round information and the reference account number. The format of the test account can be determined by using the format of the reference account, and the format of the test account can be a communication account format, such as a mobile phone number format, an instant communication account format, and the like.
In step S220, a first account and a second account are generated according to the test round information and the reference account.
The difference between the second account and the first account is a preset difference step value. The first account is used for representing a party to be verified who is verified in the current test round, and the second account is used for representing a sender who sends a request for obtaining a verification code in the current test round. The gap step value can be flexibly set by combining actual conditions or experience, so that the time difference between the first account and the second account can ensure that the test verification code of the second account can be successfully verified. The difference step value may be a positive or negative value. The second account number may be obtained by increasing the difference step value based on the first account number, or by decreasing the difference step value based on the first account number. It should be noted that the second account is used to characterize a sender that sends a request for acquiring the verification code in the current test round, and the request for acquiring the verification code may be understood as a request that the second account sends to the server. On one hand, the server can be instructed to call a third-party service, and the verification code is sent to the second account through the third-party service, so that the second account acquires the verification code, and on the other hand, the server can be instructed to send the verification code to the second account, so that the second account acquires the verification code.
Specifically, in one round of pressure measurement, in order to enable a test scene to truly simulate a true service scene of a verification code, it is necessary to ensure that a sending interface and a verification interface of a server are triggered simultaneously, so that a difference step value between a first account and a second account is set. After the test round information and the reference account are obtained, the test client generates a first account by using the test round information and the reference account. For example, the test round information and the reference account number may be directly added, and the added result is used as the first account number. And a compensation value (which can be used for correcting or replacing the account format) can also be set, and the first account is generated by combining the compensation value, the test round information and the reference account. And because a difference of a difference step value needs to be preset between the first account and the second account, the test client generates the second account by using the acquired test round information, the reference account and the preset difference step value. In some embodiments, the second account number may be equal to the sum of the reference account number, the turn number, and the gap step value.
In step S230, a verification request is generated according to the first account and the test verification code corresponding to the first account, and a transmission request for acquiring the verification code is generated according to the second account.
In step S240, an authentication interface is called, and an authentication request is sent to the server.
In step S250, the sending interface is called at the same time as the verification interface is called, and a sending request for obtaining the verification code is sent to the server.
The verification request is used for indicating the server to verify the first account and the test verification code corresponding to the first account. And the sending request for obtaining the verification code is used for indicating the server to trigger the sending of the test verification code corresponding to the second account according to the second account. The test validation code may be a randomly generated validation code, i.e., the test validation code may be a test random code. Specifically, a verification request is generated according to the first account and the test verification code corresponding to the first account, the verification request includes the first account and the test verification code corresponding to the first account, a sending request for obtaining the verification code is generated according to the second account, and the sending request for obtaining the verification code includes the second account. And the test client calls the sending interface and the verification interface of the verification code at the same time. The method comprises the steps that a sending request for obtaining the verification code is sent to a server through a sending interface, the server receives the sending request for obtaining the verification code, and then the server can trigger sending of the test verification code corresponding to the second account according to the second account. The server receives the verification request, and then the server can verify the first account and the test verification code corresponding to the first account according to the server.
According to the verification code testing method, by acquiring the testing round information and the reference account number, a first account number and a second account number are generated according to the testing round information and the reference account number, and the difference step value between the first account number and the second account number is obtained; the method comprises the steps that a sending interface and a verification interface of a verification code are called simultaneously, a sending request and a verification request for obtaining the verification code are sent to a server, so that the server is instructed to verify a first account and a test verification code corresponding to the first account, and sending of the test verification code corresponding to a second account is triggered according to the second account; the sending pressure measurement and the verification pressure measurement are integrated in a set of test program, and the program deployment work is simplified. Furthermore, the flexibility of the pressure test is improved by presetting the difference step value, and the technical cost is reduced. The real service scene of verification of the verification code can be simulated more vividly by calling the sending interface and the verification interface of the verification code in the same turn, and the success rate of test verification is ensured to be close to the success rate in the service scene of verification of the verification code.
In an exemplary embodiment, as shown in fig. 3, before obtaining the test round information, the method includes the steps of:
in step S310, test round information is generated in response to the start operation of the stress test.
Acquiring test round information, comprising:
in step S320, when the test round information does not exceed the test round threshold, the test round information is acquired.
Specifically, at the test client, the start operation of the pressure test is triggered, the test client starts the pressure test, and test round information is generated. And the test client judges whether the test round information exceeds a test round threshold value, if not, the pressure test is required to be continued, and the test client acquires the test round information. If the pressure exceeds the preset value, the pressure test is stopped. For example, the test round information may adopt a round number, and the test round threshold may be a maximum pressure-measuring round number MAX, where the round number of the current test round is compared with the maximum pressure-measuring round number MAX, the pressure test is stopped if the round number of the current test round is greater than MAX, and the pressure test is continued if the round number of the current test round is not greater than MAX.
In this embodiment, the control of the test cost is realized by setting a test round threshold value, generating test round information, and determining whether to stop the pressure test according to a comparison result between the test round information and the test round threshold value.
In an exemplary embodiment, as shown in FIG. 4, prior to invoking the verification interface, the method includes the steps of:
in step S410, a true passing rate is acquired.
In step S420, with the true passing rate as a probability, randomly obtaining a preset number of characters from a character string corresponding to the first account as a test verification code corresponding to the first account.
The real passing rate is the percentage of the real verification codes passing verification in the verification code verification service scene. For example, the real throughput rate may be 70% or 80%. The first account number has a corresponding string. An agreed rule needs to be set on the two sides of the test client and the server in advance, and both the operation of generating the test verification code by the test client and the operation of storing the verification code in the server need to comply with the agreed rule. For example, if the first account is a mobile phone number, the last six digits or the last four digits of the mobile phone number may be agreed as the verification code.
Specifically, the test client obtains a true passing rate in a verification code verification service scenario, and in order to enable the test scenario to approach the verification code verification service scenario, the true passing rate is taken as a probability, and a plurality of characters are randomly obtained from a character string corresponding to the first account to serve as the test verification code corresponding to the first account, where the number of the characters may be agreed in advance. In some embodiments, the true passing rate is used as the probability, some first account numbers are randomly selected from the plurality of first account numbers to serve as target account numbers, a preset number of characters are acquired from the target account numbers according to a preset agreement rule to serve as test verification codes corresponding to the first account numbers, and the verification codes of the target account numbers can pass the verification successfully. It should be noted that the other first account numbers except the target account number may randomly generate test verification codes without complying with the agreed rule, and the test verification codes cannot pass the verification because they do not satisfy the agreed rule.
In the embodiment, by acquiring the real passing rate and taking the real passing rate as the probability, a preset number of characters are randomly acquired from the character string corresponding to the first account as the test verification code of the first account, so that the test scene approaches to the real service scene, and the accuracy of the test result is improved.
In an exemplary embodiment, as shown in fig. 5, the test round information includes a round number. After testing the validation request of the validation code with the server, the method comprises the following steps:
in step S510, a transmission result of the second account and a verification result of the first account returned by the server are received.
In step S520, the round number is incremented according to the transmission result and the verification result.
Specifically, the server receives a sending request and a verification request for acquiring the verification code, which are sent by the test client, and the server can trigger sending of the verification code according to the second account and generate a sending result of the second account. The server may also verify the first account and the test verification code corresponding to the first account, and generate a verification result of the first account. And the server returns the sending result and the verification result to the testing client. And the test client receives the sending result and the verification result, so that the round serial number is increased progressively according to the sending result and the verification result. For example, if the round number of the current round test is K, the round number may be incremented to K +1 according to the sending result and the verification result.
In this embodiment, the control over the range of the test account is realized by receiving the sending result of the second account and the verification result of the first account returned by the server, incrementing the round number according to the sending result and the verification result, and adopting a strict digital type incrementing mode, so that the technical cost is reduced.
In an exemplary embodiment, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number, and the gap step value.
In an exemplary embodiment, the validation request includes a test validation code corresponding to the first account number. The verification request is used for indicating the server to acquire the test verification codes of the first account number which are stored in advance from the database, and the test verification codes corresponding to the first account number are verified by using the test verification codes of the first account number. The verification code sending request is used for indicating the server to store the test verification code of the second account in the database, the test verification code of the second account is used for verifying the test verification code in a subsequent test turn, and the subsequent test turn is equal to the sum of the difference step length value and the turn number.
The test client calls the sending interface and the verification interface of the verification code at the same time, the server receives the sending request and the verification request for obtaining the verification code sent by the test client, and the server can trigger sending of the test verification code corresponding to the second account according to the second account. The server can also verify the first account and the test verification code corresponding to the first account according to the server. Specifically, for the processing flow of the sending interface, first, the server may obtain a test validation code of the second account from a character string corresponding to the second account; then, storing a test verification code of a second account to a database of the server, wherein the test verification code of the second account is used for verifying the test verification code in a subsequent test turn, and the subsequent test turn is equal to the sum of the difference step length value and the turn serial number; and finally, the server calls a service interface of the third-party service provider to send the verification code. And aiming at the processing flow of the verification interface, acquiring the verification code of the first account number which is stored in advance from the database, and verifying the test verification code corresponding to the first account number by using the verification code of the first account number. It is understood that the test validation code of the first account is stored in the database in a previous test round, where the previous test round is equal to the round number minus the difference step value. Taking the short message verification code as an example for illustration, because the second mobile phone number used for sending the verification code is one K step length ahead of the first mobile phone number used for verification, when the pressure test of the round K +1 is executed, the verification code of the second mobile phone number is already stored in the database when the pressure test of the round 1 is executed, therefore, when the pressure test of the round K +1 is executed, the sending interface and the verification interface of the verification code can be called simultaneously, and the test client sends the sending request of obtaining the verification code of the second mobile phone number and the verification request of the first mobile phone number.
Fig. 6 is a flowchart illustrating a verification code testing method according to an exemplary embodiment, where the verification code testing method is used in the test client 110, as shown in fig. 6, and includes the following steps:
in step S602, test round information is generated in response to a start operation of the pressure test.
Specifically, the test round information includes a round number.
In step S604, it is determined whether the round number exceeds a test round threshold.
In step S606, if not, the round number and the reference account number are acquired.
The reference account number is an account number reference value used for verification code testing.
In step S608, a first account is generated from the round number and the reference account.
In step S610, a second account is generated according to the round number, the reference account, and the preset difference step value.
The difference between the first account and the second account is a difference step value. Specifically, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number and the difference step value. The first account is used for representing a party to be verified who is verified in the current test round, and the second account is used for representing a sender who sends a request for obtaining a verification code in the current test round. Generating a verification request according to the first account and the test verification code corresponding to the first account, wherein the verification request comprises the first account and the test verification code corresponding to the first account, generating a sending request for obtaining the verification code according to the second account, and the sending request for obtaining the verification code comprises the second account.
In step S612, a true passing rate is obtained, where the true passing rate is a percentage of the random verification code in the true service scene that passes the verification.
The real service scenario may be an authentication code authentication service scenario.
In step S614, with the true passing rate as a probability, randomly obtaining a preset number of characters from a character string corresponding to the first account as a test verification code of the first account.
In step S616, the sending interface and the verification interface of the verification code are simultaneously called, and a sending request for obtaining the verification code and a verification request are sent to the server.
Specifically, the verification request is used for instructing the server to acquire a verification code of a first account which is stored in advance from the database, and the verification code of the first account is used for verifying a test verification code corresponding to the first account; the sending request is used for instructing the server to store the test verification code of the second account in the database, the test verification code of the second account is used for verifying the test verification code corresponding to the second account in a subsequent test turn, and the subsequent test turn is equal to the sum of the difference step length value and the turn number.
In step S618, the transmission result of the second account and the verification result of the first account returned by the server are received.
In step S620, the round number is incremented according to the transmission result and the verification result.
Fig. 7 is a flowchart illustrating a verification code testing method according to an exemplary embodiment, where the verification code testing method is used in the server 120, as shown in fig. 7, and includes the following steps:
in step S710, a verification request sent by the test client is received, and the first account and the test verification code corresponding to the first account are verified according to the verification request.
In step S720, while receiving the verification request, a request for obtaining the verification code sent by the test client is received, and sending the test verification code corresponding to the second account is triggered according to the second account carried in the request for obtaining the verification code.
The verification request is generated by the testing client according to a first account and a testing verification code corresponding to the first account, and the first account is used for representing a party to be verified in the current testing round. The sending request for obtaining the verification code is generated by the testing client according to the second account, and the second account is used for representing a sender sending the request for obtaining the verification code in the current testing turn. The difference between the second account and the first account is a preset difference step value, the first account and the second account are generated by the test client according to the test round information and a reference account, and the reference account is an account reference value for testing the verification code.
According to the verification code testing method, the verification request sent by the testing client side is received, the sending request of the verification code is obtained, the testing verification code corresponding to the first account number is verified, the sending of the testing verification code corresponding to the second account number is triggered, the difference step length value between the first account number and the second account number is set, the sending pressure test and the verifying pressure test are integrated into one set of testing program, and the program deployment work is simplified. Furthermore, the flexibility of the pressure test is improved by presetting the difference step value, and the technical cost is reduced. The real service scene of verification of the verification code can be simulated more vividly by calling the sending interface and the verification interface of the verification code simultaneously in the same turn, and the success rate of test verification is ensured to be close to that in the service scene of verification code verification.
In an exemplary embodiment, in step S710, verifying the first account and the test verification code corresponding to the first account according to the verification request includes: and acquiring the pre-stored verification code of the first account from the database, and verifying the test verification code corresponding to the first account by using the verification code of the first account.
In an exemplary embodiment, the method further comprises: and after the test verification code corresponding to the first account number is verified, deleting the test verification code of the first account number from the database.
Specifically, the database of the server stores the verification code of the first account in advance. The server acquires the verification code of the first account number which is stored in advance from the database, and verifies the test verification code corresponding to the first account number by using the verification code of the first account number. After the server verifies the test verification code, if the verification is successful, the test verification code of the first account is deleted from the database.
In an exemplary embodiment, as shown in fig. 8, in step S720, triggering, according to a second account carried in a request for obtaining a verification code, transmission of a test verification code corresponding to the second account, includes the following steps:
in step S810, a test verification code of the second account is acquired based on the second account.
In step S820, the test verification code of the second account is stored in the database.
In step S830, a service interface of the third-party service provider is called to send the test verification code of the second account.
The test verification code of the second account is used for verifying the test verification code corresponding to the second account in a subsequent test turn, and the subsequent test turn is equal to the sum of the current test turn and the difference step value. Specifically, the test verification code of the second account may be obtained from a character string corresponding to the second account, where the character string corresponding to the second account may be a character string constituting the second account, or a character string obtained by adjusting the character string of the second account based on the reason that the character string of the second account is in data security, and the like, and the application is not limited to this. And the server transmits the test verification code of the second account to the database. The server can simulate and call a service interface of the third-party service provider so that the third-party service provider can send the test verification code of the second account. It is understood that the test verification code of the second account may be stored in the database as a reference object at the time of verification, and the test verification code corresponding to the second account may be generated based on the true passing rate and the second account and serves as a verified object at the time of verification. The test verification code of the second account is obtained based on the second account according to a predetermined rule and stored in the database. And the test verification code corresponding to the second account is obtained based on the second account according to a predetermined rule. And part of the test verification codes are not obtained based on the second account according to the agreed rule in advance, and the test verification codes which do not comply with the agreed rule cannot pass the verification during the verification.
With regard to the verification code testing method partially applied to the server side in the above embodiment, the specific manner of each step has been described in detail in the above embodiment of the method applied to the testing client side, and will not be described in detail here.
Fig. 9 is a flowchart illustrating a verification code testing method according to an exemplary embodiment, where the verification code testing method is used in the server 120, as shown in fig. 9, and includes the following steps:
in step S902, a sending request and a verification request for obtaining the verification code, which are sent by the test client at the same time, are received.
The verification request is generated by the test client according to the first account and the test verification code corresponding to the first account, and the first account is used for representing a party to be verified who is verified in the current test round. The sending request for obtaining the verification code is generated by the testing client according to the second account, and the second account is used for representing a sender sending the request for obtaining the verification code in the current testing turn. The difference between the second account and the first account is a preset difference step value, the first account and the second account are generated by the test client according to the test round information and a reference account, and the reference account is an account reference value for testing the verification code.
In step S904, the test verification code is verified according to the first account, and a verification result of the first account is generated.
Specifically, a verification code of a first account number which is stored in advance is obtained from a database, and a test verification code corresponding to the first account number is verified by using the verification code of the first account number.
In step S906, after the test validation code corresponding to the first account number is validated, the test validation code of the first account number is deleted from the database.
In step S908, the verification code of the second account is obtained from the character string corresponding to the second account.
In step S910, the test validation code of the second account is stored in the database.
In step S912, a service interface of the third-party service provider is called to send the test validation code of the second account, and a sending result of the second account is generated.
In step S914, the verification result and the transmission result are returned to the test client.
In an exemplary embodiment, the present disclosure provides a verification code testing method for use in the testing client 110 and the server 120 in fig. 1, including the steps of:
in step S1002, in response to the start operation of the stress test, the test client generates test round information.
Specifically, the test round information includes a round number.
In step S1004, the test client determines whether the round number exceeds a test round threshold.
In step S1006, if the number does not exceed the predetermined value, the test client obtains the round number and the reference account number.
In step S1008, the test client generates a first account according to the round number and the reference account.
In step S1010, the test client generates a second account according to the round number, the reference account, and the preset difference step value.
The difference between the first account and the second account is a difference step value. The first account is used for representing a party to be verified who is verified in the current test round, and the second account is used for representing a sender who sends a request for obtaining a verification code in the current test round. Specifically, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number and the difference step value. Generating a verification request according to the first account and the test verification code corresponding to the first account, wherein the verification request comprises the first account and the test verification code corresponding to the first account, generating a sending request for obtaining the verification code according to the second account, and the sending request for obtaining the verification code comprises the second account.
In step S1012, the testing client obtains a true passing rate, where the true passing rate is a percentage of the random verification code passing verification in the true service scenario.
In step S1014, with the true passing rate as a probability, the test client randomly obtains a preset number of characters from a character string corresponding to the first account as a test verification code corresponding to the first account.
In step S1016, the sending interface and the verification interface of the verification code are simultaneously called, and the test client sends a sending request for obtaining the verification code and a verification request to the server.
In step S1018, the server receives the transmission request and the verification request simultaneously transmitted by the test client.
Specifically, the verification request is used for instructing the server to acquire a verification code of a first account which is stored in advance from the database, and the verification code of the first account is used for verifying a test verification code corresponding to the first account; the sending request for obtaining the verification code is used for instructing the server to store the verification code of the second account in the database, the verification code of the second account is used for verifying the test verification code corresponding to the second account in the subsequent test turn, and the subsequent test turn is equal to the sum of the difference step length value and the turn number.
In step S1020, the server verifies the first account and the test verification code corresponding to the first account, and generates a verification result of the first account.
In step S1022, after verifying the test verification code corresponding to the first account, the server deletes the test verification code of the first account from the database.
In step S1024, the server obtains the test validation code of the second account from the character string corresponding to the second account.
In step S1026, the server stores the test validation code of the second account in the database.
In step S1028, the server invokes a service interface of the third-party service provider to send the verification code corresponding to the second account, and generates a sending result of the second account.
In step S1030, the server returns the verification result and the transmission result to the test client.
In step S1032, the test client receives the transmission result of the second account and the verification result of the first account returned by the server.
In step S1034, the test client increments the round number according to the transmission result and the verification result.
It should be understood that, although the steps in the above-described flowcharts are shown in sequence as indicated by the arrows, the steps are not necessarily performed in sequence as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a part of the steps in the above-mentioned flowcharts may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of performing the steps or the stages is not necessarily performed in sequence, but may be performed alternately or alternately with other steps or at least a part of the steps or the stages in other steps.
FIG. 10 is a block diagram illustrating a verification code testing apparatus according to an example embodiment. Referring to fig. 10, the apparatus 1000 includes an information account acquisition module 1010, a test account generation module 1020, a verification request generation module 1030, a verification interface calling module 1040, and a sending interface calling module 1050.
The information account acquisition module 1010 is configured to execute acquisition of test turn information and a reference account, wherein the reference account is an account reference value used for verification code testing;
a test account generation module 1020 configured to execute generating a first account and a second account according to the test round information and the reference account, where the second account and the first account differ by a preset difference step value; the first account is used for representing a party to be verified who is verified in the current test round, and the second account is used for representing a sender who sends a request for obtaining a verification code in the current test round;
a verification request generating module 1030 configured to execute generating a verification request according to the first account and a test verification code corresponding to the first account, and generate a sending request for acquiring a verification code according to the second account;
the verification interface calling module 1040 is configured to execute calling a verification interface, and send the verification request to a server, where the verification request is used to instruct the server to verify the first account and the test verification code corresponding to the first account;
the sending interface calling module 1050 is configured to call a sending interface while calling the verification interface, and send the sending request for obtaining the verification code to the server, where the sending request for obtaining the verification code is used to instruct the server to trigger sending of the test verification code corresponding to the second account according to the second account.
In an exemplary embodiment, the apparatus further comprises:
a round information generating module configured to perform a start operation in response to a stress test, and generate the test round information;
the information account number obtaining module is further configured to obtain the test round information when the test round information does not exceed a test round threshold.
In an exemplary embodiment, the apparatus further comprises:
the passing rate acquisition module is configured to execute the real passing rate acquisition, wherein the real passing rate is the percentage of the real verification codes passing the verification in the verification code verification service scene;
and the test code generation module is configured to execute the step of randomly acquiring a preset number of characters from a character string corresponding to the first account as a test verification code corresponding to the first account by taking the real passing rate as a probability.
In an exemplary embodiment, the apparatus further comprises:
a result receiving module configured to perform receiving of a transmission result of the second account and a verification result of the first account returned by the server;
a sequence number incrementing module configured to perform incrementing the round sequence number according to the transmission result and the verification result.
In an exemplary embodiment, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number, and the gap step value.
FIG. 11 is a block diagram illustrating a captcha testing apparatus, according to an example embodiment. Referring to fig. 11, the apparatus includes an authentication request receiving module 1110 and a transmission request receiving module 1120.
A verification request receiving module 1110, configured to execute receiving a verification request sent by a test client, and verify a first account and a test verification code corresponding to the first account according to the verification request, where the verification request is generated by the test client according to the first account and the test verification code corresponding to the first account, and the first account is used to represent a party to be verified in a current test round;
a sending request receiving module 1120, configured to execute receiving, while receiving the verification request, a sending request for obtaining a verification code sent by the test client, and trigger sending of the test verification code corresponding to a second account according to the second account carried in the sending request for obtaining the verification code, where the sending request for obtaining the verification code is generated by the test client according to the second account, and the second account is used to characterize a sender sending the request for obtaining the verification code in a current test round;
the difference between the second account and the first account is a preset difference step value, the first account and the second account are generated by the test client according to the test round information and a reference account, and the reference account is an account reference value used for verification code testing.
In an exemplary embodiment, the verification request receiving module is further configured to execute obtaining a verification code of a first account, which is stored in advance, from a database, and verify a test verification code corresponding to the first account by using the verification code of the first account.
In an exemplary embodiment, the apparatus further comprises:
the verification code deleting module is configured to delete the test verification code of the first account from the database after the test verification code corresponding to the first account is verified.
In an exemplary embodiment, the sending request receiving module is further configured to execute, based on the second account, obtaining a test verification code of the second account; storing a test verification code of the second account to a database, wherein the test verification code of the second account is used for verifying the test verification code corresponding to the second account in a subsequent test turn, and the subsequent test turn is equal to the sum of the current test turn and the difference step length value; and calling a service interface of a third party service provider to send the test verification code of the second account.
In an exemplary embodiment, the test round information includes a round serial number, and the apparatus further includes a result returning module configured to perform returning a verification result and a sending result to the test client, where the verification result and the verification result are used to instruct the test client to increment the round serial number.
In an exemplary embodiment, the first account number is equal to the sum of the reference account number and the round number, and the second account number is equal to the sum of the reference account number, the round number, and the gap step value.
With regard to the apparatus in the above embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be described in detail here.
FIG. 12 is a block diagram illustrating an apparatus 1200 for captcha testing, according to an example embodiment. For example, device 1200 may be a server. Referring to fig. 12, device 1200 includes a processing component 1220 that further includes one or more processors, and memory resources, represented by memory 1222, for storing instructions, such as application programs, that are executable by processing component 1220. The application programs stored in memory 1222 may include one or more modules that each correspond to a set of instructions. Further, the processing component 1220 is configured to execute instructions to perform the above-described method of captcha testing.
The device 1200 may also include a power supply component 1224 configured to perform power management of the device 1200, a wired or wireless network interface 1226 configured to connect the device 1200 to a network, and an input-output (I/O) interface 1228. The device 1200 may operate based on an operating system stored in memory 1222, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, or the like.
In an exemplary embodiment, a computer-readable storage medium comprising instructions, such as memory 1222 comprising instructions, executable by a processor of device 1200 to perform the above-described method is also provided. The storage medium may be a computer-readable storage medium, which may be, for example, a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
In an exemplary embodiment, there is also provided a test system, comprising a test client and a server; wherein:
the test client comprises a first processor, a memory for storing the first processor executable instructions; wherein the first processor is configured to execute the instructions to implement any of the above described captcha testing methods from the testing client side.
The server comprises a second processor, a memory for storing instructions executable by the second processor; wherein the second processor is configured to execute the instructions to implement any one of the above-mentioned verification code testing methods described from the server side.
In an exemplary embodiment, a computer program product is also provided, comprising a computer program which, when executed by a processor, implements the above-described method.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This disclosure is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements 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 disclosure is limited only by the appended claims.

Claims (25)

1. A verification code testing method is applied to a testing client side and comprises the following steps:
acquiring test round information and a reference account, wherein the reference account is an account reference value used for verification code testing;
generating a first account and a second account according to the test round information and the reference account, wherein the difference between the second account and the first account is a preset difference step value; the first account number is used for representing a party to be verified for verification in the current testing turn, and the second account number is used for representing a sender sending a request for obtaining a verification code in the current testing turn;
generating a verification request according to the first account and a test verification code corresponding to the first account, and generating a sending request for acquiring the verification code according to the second account;
calling a verification interface, and sending the verification request to a server, wherein the verification request is used for indicating the server to verify the first account and a test verification code corresponding to the first account;
and calling a sending interface while calling the verification interface, and sending the sending request for acquiring the verification code to the server, wherein the sending request for acquiring the verification code is used for indicating the server to trigger the sending of the test verification code corresponding to the second account according to the second account.
2. The captcha testing method of claim 1, wherein prior to the obtaining of the test round information, the method comprises:
generating the test round information in response to the starting operation of the pressure test;
the acquiring of the test round information includes:
and when the test round information does not exceed the test round threshold value, acquiring the test round information.
3. The captcha testing method of claim 1, wherein prior to the invoking of the validation interface, the method further comprises:
acquiring a real passing rate, wherein the real passing rate is the percentage of passing verification of the real verification codes in a verification code verification service scene;
and randomly acquiring a preset number of characters from the character string corresponding to the first account as a test verification code corresponding to the first account by taking the real passing rate as the probability.
4. The captcha testing method of any one of claims 1 to 3, wherein the test round information includes a round number, and after sending the verification request to the server, the method further comprises:
receiving a sending result of the second account and a verification result of the first account returned by the server;
and incrementing the turn sequence number according to the sending result and the verification result.
5. The verification code testing method according to claim 4, wherein the first account number is equal to a sum of the reference account number and the round number, and the second account number is equal to a sum of the reference account number, the round number, and the difference step value.
6. A verification code testing method is applied to a server and comprises the following steps:
receiving a verification request sent by a test client, verifying a first account and a test verification code corresponding to the first account according to the verification request, wherein the verification request is generated by the test client according to the first account and the test verification code corresponding to the first account, and the first account is used for representing a party to be verified in the current test round;
receiving a sending request for acquiring a verification code sent by the test client while receiving the verification request, and triggering sending of the test verification code corresponding to a second account according to the second account carried by the sending request for acquiring the verification code, wherein the sending request for acquiring the verification code is generated by the test client according to the second account, and the second account is used for representing a sender sending the request for acquiring the verification code in the current test round;
the difference between the second account and the first account is a preset difference step value, the first account and the second account are generated by the test client according to the test round information and a reference account, and the reference account is an account reference value used for verification code testing.
7. The verification code testing method according to claim 6, wherein the verifying the first account and the test verification code corresponding to the first account according to the verification request includes:
the method comprises the steps of obtaining a pre-stored verification code of a first account from a database, and verifying a test verification code corresponding to the first account by using the verification code of the first account.
8. The method for verification code testing according to claim 7, wherein the method further comprises:
and deleting the test verification code of the first account from the database after the test verification code corresponding to the first account is verified.
9. The method for testing the verification code according to claim 6, wherein the triggering of the sending of the test verification code corresponding to the second account according to the second account carried in the request for sending the verification code includes:
acquiring a test verification code of the second account based on the second account;
storing a test verification code of the second account to a database, wherein the test verification code of the second account is used for verifying the test verification code corresponding to the second account in a subsequent test turn, and the subsequent test turn is equal to the sum of the current test turn and the difference step length value;
and calling a service interface of a third party service provider to send the test verification code of the second account.
10. The method of claim 6, wherein the test round information comprises a round number, the method further comprising:
and returning a verification result and a sending result to the test client, wherein the verification result and the verification result are used for indicating the test client to increase the round serial number.
11. The verification code testing method according to claim 10, wherein the first account number is equal to a sum of the reference account number and the round number, and the second account number is equal to a sum of the reference account number, the round number, and the difference step value.
12. The utility model provides a verification code testing arrangement which characterized in that is applied to test client, includes:
the information account acquisition module is configured to execute acquisition of test round information and a reference account, wherein the reference account is an account reference value used for verification code testing;
the test account generation module is configured to execute generation of a first account and a second account according to the test round information and the reference account, wherein the difference between the second account and the first account is a preset difference step value; the first account is used for representing a party to be verified who is verified in the current test round, and the second account is used for representing a sender who sends a request for obtaining a verification code in the current test round;
the verification request generation module is configured to execute a verification request generated according to the first account and a test verification code corresponding to the first account, and generate a sending request for acquiring the verification code according to the second account;
the verification interface calling module is configured to execute calling of a verification interface and send the verification request to a server, wherein the verification request is used for indicating the server to verify the first account and a test verification code corresponding to the first account;
and the sending interface calling module is configured to call a sending interface while calling the verification interface, and send the sending request for obtaining the verification code to the server, wherein the sending request for obtaining the verification code is used for indicating the server to trigger sending of the test verification code corresponding to the second account according to the second account.
13. The captcha testing apparatus of claim 12, further comprising:
a round information generating module configured to perform a start operation in response to a stress test, and generate the test round information;
the information account number obtaining module is further configured to obtain the test round information when the test round information does not exceed a test round threshold.
14. The captcha testing apparatus of claim 12, wherein the apparatus further comprises:
the passing rate acquisition module is configured to execute the real passing rate acquisition, wherein the real passing rate is the percentage of the real verification codes passing the verification in the verification code verification service scene;
and the test code generation module is configured to execute the step of randomly acquiring a preset number of characters from a character string corresponding to the first account as a test verification code corresponding to the first account by taking the real passing rate as a probability.
15. The apparatus according to any one of claims 12 to 14, wherein the test round information includes a round number, the apparatus further comprising:
a result receiving module configured to perform receiving, after the verification request is sent to the server, a sending result of the second account and a verification result of the first account returned by the server;
a sequence number incrementing module configured to perform incrementing the round sequence number according to the transmission result and the verification result.
16. The verification code testing device of claim 15, wherein the first account number is equal to a sum of the reference account number and the round number, and the second account number is equal to a sum of the reference account number, the round number, and the difference step value.
17. The utility model provides a verification code testing arrangement which characterized in that, is applied to the server, includes:
the verification request receiving module is configured to execute receiving of a verification request sent by a test client, and verify a first account and a test verification code corresponding to the first account according to the verification request, wherein the verification request is generated by the test client according to the first account and the test verification code corresponding to the first account, and the first account is used for representing a party to be verified in the current test round;
the sending request receiving module is configured to execute sending requests for obtaining the verification codes sent by the test client while receiving the verification requests, and trigger sending of the test verification codes corresponding to the second account according to the second account carried by the sending requests for obtaining the verification codes, wherein the sending requests for obtaining the verification codes are generated by the test client according to the second account, and the second account is used for representing a sender sending the requests for obtaining the verification codes in the current test round;
the difference between the second account and the first account is a preset difference step value, the first account and the second account are generated by the test client according to the test round information and a reference account, and the reference account is an account reference value used for verification code testing.
18. The verification code testing device according to claim 17, wherein the verification request receiving module is further configured to execute obtaining a verification code of a first account that has been stored in advance from a database, and verify the test verification code corresponding to the first account by using the verification code of the first account.
19. The captcha testing apparatus of claim 18, wherein the apparatus further comprises:
the verification code deleting module is configured to delete the test verification code of the first account from the database after the test verification code corresponding to the first account is verified.
20. The verification code testing device of claim 17, wherein the sending request receiving module is further configured to execute obtaining a test verification code of the second account based on the second account; storing a test verification code of the second account to a database, wherein the test verification code of the second account is used for verifying the test verification code corresponding to the second account in a subsequent test turn, and the subsequent test turn is equal to the sum of the current test turn and the difference step length value; and calling a service interface of a third party service provider to send the test verification code of the second account.
21. The apparatus according to claim 17, wherein the test round information includes a round serial number, the apparatus further comprising a result returning module configured to perform returning a verification result and a sending result to the test client, where the verification result and the verification result are used to instruct the test client to increment the round serial number.
22. The verification code testing device of claim 21, wherein the first account number is equal to a sum of the reference account number and the round number, and the second account number is equal to a sum of the reference account number, the round number, and the difference step value.
23. A test system is characterized by comprising a test client and a server;
the test client comprises a first processor, a memory for storing executable instructions of the first processor; wherein the first processor is configured to execute the instructions to implement the captcha testing method of any of claims 1 to 5;
the server comprises a second processor, a memory for storing instructions executable by the second processor; wherein the second processor is configured to execute the instructions to implement the captcha testing method of any of claims 6 to 11.
24. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the captcha testing method of any of claims 1 to 11.
25. A computer-readable storage medium, wherein instructions in the computer-readable storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the captcha testing method of any of claims 1 to 11.
CN202110745221.1A 2021-06-30 2021-06-30 Verification code testing method, verification code testing device, electronic equipment, storage medium and program product Active CN113489623B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110745221.1A CN113489623B (en) 2021-06-30 2021-06-30 Verification code testing method, verification code testing device, electronic equipment, storage medium and program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110745221.1A CN113489623B (en) 2021-06-30 2021-06-30 Verification code testing method, verification code testing device, electronic equipment, storage medium and program product

Publications (2)

Publication Number Publication Date
CN113489623A CN113489623A (en) 2021-10-08
CN113489623B true CN113489623B (en) 2022-07-01

Family

ID=77940015

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110745221.1A Active CN113489623B (en) 2021-06-30 2021-06-30 Verification code testing method, verification code testing device, electronic equipment, storage medium and program product

Country Status (1)

Country Link
CN (1) CN113489623B (en)

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100930577B1 (en) * 2006-11-13 2009-12-09 한국전자통신연구원 Message authentication code generation method using stream cipher, authentication encryption method using stream cipher, and authentication decryption method using stream cipher
US8402438B1 (en) * 2007-12-03 2013-03-19 Cadence Design Systems, Inc. Method and system for generating verification information and tests for software
CN104618315B (en) * 2013-12-30 2019-02-15 腾讯科技(深圳)有限公司 A kind of method, apparatus and system of verification information push and Information Authentication
WO2016118158A1 (en) * 2015-01-23 2016-07-28 Innovative Pressure Testing, Llc System and method for improving pressure test efficiency
CN207817785U (en) * 2018-02-12 2018-09-04 杭州攀登者科技有限公司 A kind of anti-counterfeiting platform
CN110049062B (en) * 2019-04-30 2021-08-13 北京达佳互联信息技术有限公司 Verification code verification method, device, system, server, electronic equipment and storage medium
CN110177378A (en) * 2019-05-21 2019-08-27 深圳壹账通智能科技有限公司 A kind of automated testing method and relevant device

Also Published As

Publication number Publication date
CN113489623A (en) 2021-10-08

Similar Documents

Publication Publication Date Title
CN113452719B (en) Application login method and device, terminal equipment and storage medium
CN109787991A (en) Exempt from close login method, device, equipment and storage medium based on mobile terminal
CN107911222B (en) Digital signature generating method, digital signature verifying method, digital signature generating apparatus, digital signature verifying apparatus, and storage medium storing digital signature verifying program
CN110661829B (en) File downloading method and device, client and computer readable storage medium
CN108055238A (en) A kind of account verification method and system
CN107241336A (en) Auth method and device
CN110311895A (en) Session authorization check method, system and the electronic equipment of identity-based verifying
CN110912689A (en) Method and system for generating and verifying unique value
CN108366176A (en) A kind of charging method of terminal applies, apparatus and system
CN108574658B (en) Application login method and device
CN111835773B (en) User identity authentication system based on edge calculation
CN113489623B (en) Verification code testing method, verification code testing device, electronic equipment, storage medium and program product
CN113067802A (en) User identification method, device, equipment and computer readable storage medium
CN116916310A (en) Verification code generation and verification method and device and electronic equipment
CN109348472B (en) OTA (over the air) upgrading method and system based on single-point pushing
CN108882230B (en) Call record management method, device and system
CN109005143B (en) Method and device for adjusting website load
CN111835504A (en) Identification code generation method and server
CN110809001B (en) Identity authentication method, device, equipment and storage medium
CN110087201B (en) Information processing method, device and storage medium
CN111310130A (en) Authorization authentication processing method, device, storage medium and electronic device
CN111835734A (en) Information processing method, information processing device, electronic equipment, server and storage medium
CN110751033A (en) Offline login method and related product
CN110807181A (en) Method, device and system for logging in and verifying database in enterprise
CN110248326A (en) A kind of data processing method and its device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant