Disclosure of Invention
The embodiment of the application provides a method for carrying out system safety control, which is used for solving the problem that the accuracy of carrying out safety control on a system in the existing mode is low.
The method for performing system security control provided by the embodiment of the application comprises the following steps:
receiving a transaction request message sent by a user; the transaction request message comprises information of a transaction object transacted with the user;
determining the transaction times between the user and the transaction object in a first set time period and the transaction times between the user and the transaction object in a second set time period according to the stored transaction log; the second set time period is the time within the second set time length from the current time, the time of the first set time period is earlier than the time of the second set time period, and the length of the first set time period is longer than the length of the second set time period;
and performing safety control on the current transaction of the user according to the transaction times in the first set time period and the transaction times in the second set time period.
Optionally, performing security control on the current transaction of the user according to the transaction times in the first set time period and the transaction times in the second set time period, including:
determining a transaction risk coefficient according to the transaction times in the first set time period and the transaction times in the second set time period;
and performing safety control on the current transaction of the user according to the transaction risk coefficient.
Optionally, the transaction risk factor is determined according to the following steps:
determining the sum of the transaction times and a preset value in a first set time period; the preset value is greater than 0;
and determining the ratio of the transaction times to the sum value in a second set time period as the transaction risk coefficient.
Optionally, performing security control on the current transaction of the user according to the transaction risk coefficient, including:
and when the transaction risk coefficient is smaller than a set risk coefficient threshold value, allowing the user to perform the transaction, otherwise, refusing the user to perform the transaction or performing safety information verification on the user.
Optionally, determining whether to allow the user to perform the transaction according to the transaction risk coefficient includes:
inputting a plurality of control parameter values including the transaction risk coefficient into a preset safety control model;
and when the transaction risk score output by the safety control model is smaller than a set risk score threshold value, allowing the user to perform the transaction, otherwise, refusing the user to perform the transaction or performing safety information verification on the user.
The device for carrying out system safety control provided by the embodiment of the application comprises:
the receiving module is used for receiving a transaction request message sent by a user; the transaction request message comprises information of a transaction object transacted with the user;
the determining module is used for determining the transaction times between the user and the transaction object in a first set time period and the transaction times between the user and the transaction object in a second set time period according to the stored transaction log; the second set time period is the time within the second set time length from the current time, the time of the first set time period is earlier than the time of the second set time period, and the length of the first set time period is longer than the length of the second set time period;
and the control module is used for carrying out safety control on the current transaction of the user according to the transaction times in the first set time period and the transaction times in the second set time period.
In the embodiment of the application, the transaction object which is required to be transacted by the user currently is bound with the user, the transaction times of the two users in the previous first set time period and the transaction times of the two users in the latest second set time period are respectively determined, and the current transaction of the user is safely controlled according to the transaction times of the two users in the two set time periods. Because the frequency and the service types of transactions between a user and different transaction objects are usually different, the embodiment of the application binds the user and the transaction object which the user needs to perform the transaction currently, and only considers the transaction between the user and the same transaction object when performing security detection on the current transaction of the user, so that the security detection can be performed on the transaction which the user needs to perform currently based on a specific transaction object in a targeted manner, the accuracy of risk identification is improved, and the accuracy of system security control is further improved.
Detailed Description
In the embodiment of the application, the transaction object which is required to be transacted by the user currently is bound with the user, the transaction times of the two users in the previous first set time period and the transaction times of the two users in the latest second set time period are respectively determined, and the current transaction of the user is safely controlled according to the transaction times of the two users in the two set time periods. Because the frequency and the service types of transactions between a user and different transaction objects are usually different, the embodiment of the application binds the user and the transaction object which the user needs to perform the transaction currently, and only considers the transaction between the user and the same transaction object when performing security detection on the current transaction of the user, so that the security detection can be performed on the transaction which the user needs to perform currently based on a specific transaction object in a targeted manner, the accuracy of risk identification is improved, and the accuracy of system security control is further improved.
The embodiments of the present application will be described in further detail with reference to the drawings attached hereto.
As shown in fig. 1, a flowchart of a method for performing system security control according to an embodiment of the present application includes the following steps:
s101: receiving a transaction request message sent by a user; the transaction request message includes information of a transaction object transacted with the user.
The execution subject of the embodiment of the application is a server for performing system security control.
In this step, after receiving a transaction request message sent by a user, a server extracts user information, such as account information that the user logs in, and information of a transaction object that the user needs to perform a transaction, such as a name or an account of the transaction object, for identifying the transaction object.
S102: determining the transaction times between the user and the transaction object in a first set time period and the transaction times between the user and the transaction object in a second set time period according to the stored transaction log; the second set time period is the time within the second set time period from the current time, the time of the first set time period is earlier than the time of the second set time period, and the length of the first set time period is longer than the length of the second set time period.
In this step, the server extracts transaction information about the transaction between the user and the transaction object of the user from the stored transaction log, where the transaction information includes transaction time information, and determines the transaction times about the transaction between the user and the transaction object of the user within the first set time period and the second set time period, respectively, according to the extracted transaction information, for example, the first set time period is a time within the last half year excluding the current day (i.e., the day on which the transaction request message sent by the user is received in S101), and the second set time period is a time within the last 10 minutes.
S103: and performing safety control on the current transaction of the user according to the transaction times in the first set time period and the transaction times in the second set time period.
In this step, the transaction frequency in the first set time period is compared with the transaction frequency in a second set time period, and if the transaction frequency of the user and the transaction object in the second set time period obviously does not accord with the transaction rule of the user and the transaction object in the first set time period, it indicates that the transaction between the user and the transaction object is at risk. For example, if the number of transactions of the user with a brand-name bag seller in the last half year (not including the current day) is one, but the number of transactions with the seller in the last 10 minutes is up to 20, which is much greater than the number of transactions of the user with the seller in the last half year, the current transaction of the user with the seller can be controlled, for example, the transaction of the user can be directly rejected; alternatively, the user may be authenticated with the security information, for example, the user inputs an answer to a preset security question, the answer input by the user is compared with an answer input by the previous user registration, and if the answer input by the user is consistent with the answer input by the previous user registration, it is determined that the user passes the security information authentication, and the user is allowed to perform the transaction.
The present application is further described below with reference to a specific embodiment, and details of the specific implementation are repeated in the above embodiment and are not repeated.
As shown in fig. 2, a flowchart of a method for performing system security control according to a second embodiment of the present application includes:
s201: receiving a transaction request message sent by a user; the transaction request message includes information of a transaction object transacted with the user.
S202: determining the transaction times between the user and the transaction object in a first set time period and the transaction times between the user and the transaction object in a second set time period according to the stored transaction log; the second set time period is the time within the second set time period from the current time, the time of the first set time period is earlier than the time of the second set time period, and the length of the first set time period is longer than the length of the second set time period.
S203: and determining a transaction risk coefficient according to the transaction times in the first set time period and the transaction times in the second set time period.
In this step, a sum of the transaction frequency and a preset value in a first set time period may be determined, where the preset value is greater than 0; and determining the ratio of the transaction times to the sum value in a second set time period as the transaction risk coefficient. That is, the transaction risk coefficient k may be determined according to the following formula:
wherein the alpha is the preset value.
In the above formula, the reason why the preset value α is added after the transaction frequency in the first set time period of the denominator part is to prevent the transaction risk coefficient k from being infinite when the transaction frequency in the first set time period is 0, and the system error report occurs. In this formula, the time within the first set time period is earlier than the time within the second set time period, and the length of the first set time period is longer than the length of the second set time period, for example, the first set time period is the last half year (excluding the day on which the user sends the transaction request message in S201), and the second set time period is the last 10 minutes.
S204: and performing safety control on the current transaction of the user according to the transaction risk coefficient.
In this step, according to the transaction risk coefficient, the following two ways of performing security control on the current transaction of the user may be used:
firstly, safety control is carried out based on a comparison result of the transaction risk coefficient and a set risk coefficient threshold;
specifically, when the transaction risk coefficient is smaller than a set risk coefficient threshold, the user is allowed to conduct the transaction, otherwise, the user is refused to conduct the transaction or the user is subjected to security information verification.
In this embodiment, the transaction risk coefficient calculated in S203 is directly compared with a preset risk coefficient threshold, and when the transaction risk coefficient is greater than or equal to the set risk coefficient threshold, it indicates that a risk exists in a transaction (i.e., a transaction requested by the user sending the transaction request message in S201) that the user currently needs to perform, and the user may be directly rejected to perform the transaction or perform security information verification on the user.
Secondly, performing safety control based on a preset safety control model;
specifically, inputting a plurality of control parameter values including the transaction risk coefficient into a preset safety control model;
and when the transaction risk score output by the safety control model is smaller than a set risk score threshold value, allowing the user to perform the transaction, otherwise, refusing the user to perform the transaction or performing safety information verification on the user.
In this embodiment, the user is subjected to security control based on a preset security control model, and the control parameters related to the security control model may include, in addition to the transaction risk coefficient, other parameters, such as a trusted environment type parameter (such as a MAC address) of the user transaction, a transaction type parameter (such as a transaction amount), and the like. For example, a Media Access Control (MAC) address of a terminal device used by a user (the user may be uniquely identified by account information registered by the user) for performing the transaction may be compared with a MAC address of the terminal device used by the user for performing the transaction in the last half year (not including the current day), if the MAC address of the terminal device used by the user for performing the transaction is not included in the MAC address of the terminal device used by the user for performing the transaction in the last half year (not including the current day), the MAC address risk value (belonging to the trusted environment type parameter value) may be set to 1, otherwise, the MAC address risk value may be set to 0. For another example, if the transaction amount of the transaction between the user and the transaction object required for the transaction at this time exceeds ten times of the transaction amount of the transaction between the user and the transaction object in the last half year (not including the current day), the transaction amount risk value may be set to 1, otherwise, the transaction amount risk value may be set to 0.
In specific implementation, collecting all control parameter values related to the preset safety control model, and inputting the control parameter values including the transaction risk coefficient into the safety control model to obtain a transaction risk score; and then, according to the transaction risk score, judging the risk degree of the user for carrying out the transaction. In a specific implementation, the safety control model may be set according to actual conditions, and simply, the value output by the safety control model may be a value obtained by weighted addition of various control parameter values.
Based on the same inventive concept, the embodiment of the present application further provides a device for performing system security control corresponding to the method for performing system security control, and as the principle of the device for solving the problem is similar to the method for performing system security control according to the embodiment of the present application, the implementation of the device may refer to the implementation of the method, and repeated details are omitted.
As shown in fig. 3, a schematic structural diagram of a device for performing system safety control according to an embodiment of the present application includes:
a receiving module 31, configured to receive a transaction request message sent by a user; the transaction request message comprises information of a transaction object transacted with the user;
a determining module 32, configured to determine, according to the stored transaction log, a transaction number between the user and the transaction object in a first set time period and a transaction number between the user and the transaction object in a second set time period; the second set time period is the time within the second set time length from the current time, the time of the first set time period is earlier than the time of the second set time period, and the length of the first set time period is longer than the length of the second set time period;
and the control module 33 is configured to perform security control on the current transaction of the user according to the transaction times in the first set time period and the transaction times in the second set time period.
Optionally, the control module 33 is specifically configured to:
determining a transaction risk coefficient according to the transaction times in the first set time period and the transaction times in the second set time period; and performing safety control on the current transaction of the user according to the transaction risk coefficient.
Optionally, the control module 33 is specifically configured to: determining the sum of the transaction times and a preset value in a first set time period, wherein the preset value is greater than 0; and determining the ratio of the transaction times to the sum value in a second set time period as the transaction risk coefficient.
Optionally, the control module 33 is specifically configured to:
and when the transaction risk coefficient is smaller than a set risk coefficient threshold value, allowing the user to perform the transaction, otherwise, refusing the user to perform the transaction or performing safety information verification on the user.
Optionally, the control module 33 is specifically configured to:
inputting a plurality of control parameter values including the transaction risk coefficient into a preset safety control model; and when the transaction risk score output by the safety control model is smaller than a set risk score threshold value, allowing the user to perform the transaction, otherwise, refusing the user to perform the transaction or performing safety information verification on the user.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all alterations and modifications as fall within the scope of the application.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present application without departing from the spirit and scope of the application. Thus, if such modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is intended to include such modifications and variations as well.