Method and device for automatically kicking out login equipment
By automatically calculating the device intimacy and determining the device ID to be deleted, the automatic kicking of the logged-in device is realized, solving the complexity problem of users manually selecting devices and improving the user experience.
Patent Information
- Application Number
- CN202510242705.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-03
- Publication Date
- 2025-06-03
AI Technical Summary
In the prior art, users need to manually select the login device to be kicked out, resulting in complex and time-consuming user operations and affecting user experience.
By obtaining the target account ID, determining the account login list, calculating the intimacy of each device, and automatically determining the device ID to be deleted, realizing the automatic kicking of the device.
No need for users to manually select devices, saving time and energy, reducing user operation complexity, and improving user experience.
Smart Images

Figure CN120091056A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular, to a method and device for automatically kicking out logged-in devices. Background Art
[0002] With the development of the Internet, various APPs have gradually integrated into people's lives and become an important platform for people's daily entertainment. In the process of using these APPs, the phenomena of account sharing and multi-device login are very common. To maintain the stability and security of the system, APPs usually limit the number of logged-in devices. When the limit is exceeded, the system often requires users to manually select the logged-in device to be kicked out to ensure that the number of logged-in devices remains within the specified value.
[0003] To ensure that the number of logged-in devices remains within the specified value, users often need to select the logged-in device to be kicked out, and then kick out the logged-in device.
[0004] However, the above method requires users to screen and select among numerous device options, consuming users' time and energy and greatly increasing the complexity of user operations, thus resulting in a poor user experience. Summary of the Invention
[0005] This application provides a method and device for automatically kicking out logged-in devices. This method does not require users to screen and select among numerous device options, saving users' time and energy, reducing the complexity of user operations, and improving the user experience.
[0006] In a first aspect, this application provides a method for automatically kicking out logged-in devices, and the method includes:
[0007] When a user logs in to a target account using a current device, obtain the target account ID to be used;
[0008] According to the target account ID, determine the account login list corresponding to the target account ID, where the account login list includes the device IDs of the devices that have logged in to the target account;
[0009] When the account login list meets a preset condition, determine the intimacy corresponding to each device ID in the account login list;
[0010] According to the intimacy corresponding to each device ID, determine the target device ID to be deleted;
[0011] In the account login list, delete the target device ID to kick out the login of the target device.
[0012] Optionally, the determining the target device ID to be deleted according to the intimacy corresponding to each device ID includes:
[0013] Determine the target intimacy corresponding to the current device;
[0014] Among the intimacies corresponding to each device ID, detect whether there is a reference intimacy less than the target intimacy;
[0015] When there is a reference intimacy less than the target intimacy, use the first strategy to select the target device ID to be deleted from the device IDs corresponding to the reference intimacy;
[0016] When there is no reference intimacy less than the target intimacy, use the second strategy to select the target device ID to be deleted from all device IDs.
[0017] Optionally, the determining the target intimacy corresponding to the current device includes:
[0018] Obtain the target association relationship of the account ID, device ID, and intimacy;
[0019] According to the device ID of the current device and the target account ID, detect whether there is a corresponding intimacy in the target association relationship;
[0020] When there is a corresponding intimacy, determine the intimacy as the target intimacy corresponding to the current device;
[0021] When there is no corresponding intimacy, obtain the current device association data of the current device, and determine the target intimacy corresponding to the current device according to the current device association data.
[0022] Optionally, the current device association data includes the current device name, the current login location, and the current behavior data. The determining the target intimacy corresponding to the current device according to the current device association data includes:
[0023] Obtain the target device name, target login location, and target behavior data of the main device, where the main device is the device bound to the target account;
[0024] Determine the first similarity corresponding to the device name according to the current device name and the target device name;
[0025] Determine the second similarity corresponding to the login location according to the current login location and the target login location;
[0026] Determine the third similarity corresponding to the behavior data according to the current behavior data and the target behavior data;
[0027] Determine the target intimacy corresponding to the current device according to the first similarity, the second similarity, and the third similarity.
[0028] Optionally, the method further includes:
[0029] Receiving an intimacy setting message from the user, where the intimacy setting message includes the target account ID, the associated device ID, and the corresponding intimacy;
[0030] Setting the target association relationship according to the association relationship between the target account ID, the associated device ID, and the intimacy.
[0031] Optionally, the method further includes:
[0032] Obtaining the intimacy and the SMS verification frequency corresponding to each device ID according to the account login list;
[0033] For each device ID, determining an SMS verification threshold according to the intimacy corresponding to the device ID, and when the corresponding SMS verification frequency is greater than the SMS verification threshold, adjusting the intimacy corresponding to the device ID.
[0034] Optionally, adjusting the intimacy corresponding to the device ID includes:
[0035] Sending an intimacy adjustment notification to the current device to enable the user to adjust the intimacy of the device;
[0036] Or, recalculating the intimacy corresponding to the device ID according to the intimacy calculation method to obtain the adjusted intimacy, and adjusting the intimacy of the device ID according to the adjusted intimacy.
[0037] In a second aspect, the present application provides a device for automatically kicking out a logged-in device, and the device includes:
[0038] An obtaining unit, configured to obtain a target account ID to be used when the user logs in to a target account using a current device;
[0039] A first determination unit, configured to determine an account login list corresponding to the target account ID according to the target account ID, where the account login list includes device IDs that have logged in to the target account;
[0040] A second determination unit, configured to determine the intimacy corresponding to each device ID in the account login list when the account login list meets a preset condition;
[0041] A third determination unit, configured to determine a target device ID to be deleted according to the intimacy corresponding to each device ID;
[0042] A deletion unit, configured to delete the target device ID in the account login list to kick out the login of the target device.
[0043] Optionally, a third determination unit is configured to:
[0044] Determine the target intimacy corresponding to the current device;
[0045] In the intimacies corresponding to each device ID, detect whether there is a reference intimacy less than the target intimacy;
[0046] When there is a reference intimacy less than the target intimacy, use the first strategy to select a target device ID to be deleted from the device IDs corresponding to the reference intimacy;
[0047] When there is no reference intimacy less than the target intimacy, use the second strategy to select a target device ID to be deleted from all device IDs.
[0048] Optionally, a third determination unit is configured to:
[0049] Obtain the target association relationship among the account ID, device ID, and intimacy;
[0050] According to the device ID of the current device and the target account ID, detect whether there is a corresponding intimacy in the target association relationship;
[0051] When there is a corresponding intimacy, determine the intimacy as the target intimacy corresponding to the current device;
[0052] When there is no corresponding intimacy, obtain the current device association data of the current device, and determine the target intimacy corresponding to the current device according to the current device association data.
[0053] Optionally, the current device association data includes the current device name, current login location, and current behavior data. The third determination unit is configured to:
[0054] Obtain the target device name, target login location, and target behavior data of the main device, where the main device is the device bound to the target account;
[0055] Determine the first similarity corresponding to the device name according to the current device name and the target device name;
[0056] Determine the second similarity corresponding to the login location according to the current login location and the target login location;
[0057] Determine the third similarity corresponding to the behavior data according to the current behavior data and the target behavior data;
[0058] Determine the target intimacy corresponding to the current device according to the first similarity, the second similarity, and the third similarity.
[0059] Optionally, the device further includes a setting unit, and the setting unit is configured to:
[0060] Receive a user's intimacy setting message, where the intimacy setting message includes the target account ID, the related device ID, and the corresponding intimacy;
[0061] Set the target association relationship according to the association relationship between the target account ID, the related device ID, and the intimacy.
[0062] Optionally, the device further includes an adjustment unit, and the adjustment unit is configured to:
[0063] Obtain the intimacy and the SMS verification frequency corresponding to each device ID according to the account login list;
[0064] For each device ID, determine an SMS verification threshold according to the intimacy corresponding to the device ID. When the corresponding SMS verification frequency is greater than the SMS verification threshold, adjust the intimacy corresponding to the device ID.
[0065] Optionally, the adjustment unit is configured to:
[0066] Send an intimacy adjustment notification to the current device so that the user can adjust the intimacy of the device;
[0067] Or, recalculate the intimacy corresponding to the device ID according to the intimacy calculation method to obtain the adjusted intimacy, and adjust the intimacy of the device ID according to the adjusted intimacy.
[0068] In a third aspect, the present application provides a device for automatically kicking out a logged-in device, including: at least one communication interface; at least one bus connected to the at least one communication interface; at least one processor connected to the at least one bus; at least one memory connected to the at least one bus, where the processor is configured to:
[0069] When a user logs in to a target account using the current device, obtain the target account ID to be used;
[0070] Determine an account login list corresponding to the target account ID according to the target account ID, where the account login list includes device IDs that have logged in to the target account;
[0071] When the account login list meets a preset condition, determine the intimacy corresponding to each device ID in the account login list;
[0072] Determine the target device ID to be deleted according to the intimacy corresponding to each device ID;
[0073] In the account login list, delete the target device ID to kick out the login of the target device.
[0074] In a fourth aspect, the present application provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the above-mentioned automatic login device kicking method is implemented.
[0075] The above technical solutions provided by the embodiments of the present application have the following advantages compared with the prior art: In the embodiments of the present application, when a user logs in to a target account using a current device, obtain the target account ID to be used; according to the target account ID, determine the account login list corresponding to the target account ID, and the account login list includes device IDs that have logged in to the target account; when the account login list meets a preset condition, determine the intimacy corresponding to each device ID in the account login list; determine the target device ID to be deleted according to the intimacy corresponding to each device ID; in the account login list, delete the target device ID to kick out the login of the target device. It can be seen that the present application can automatically determine the device to be deleted and delete the device to automatically kick out the login of the target device. In this way, there is no need for the user to screen and select among many device options, saving the user's time and energy, reducing the complexity of the user's operation, and improving the user experience. Description of the Drawings
[0076] The drawings here are incorporated into the description and form a part of this description, showing embodiments consistent with the present invention and used together with the description to explain the principles of the present invention.
[0077] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, for those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0078] One or more embodiments are illustrated by way of example with pictures in the corresponding drawings. These exemplary illustrations do not limit the embodiments. Elements with the same reference numerals in the drawings are represented as similar elements, unless otherwise stated, and the drawings in the figures do not constitute a scale limitation.
[0079] Figure 1 It is a schematic diagram of the scenario of an automatic login device kicking method provided by the embodiments of the present application;
[0080] Figure 2Schematic flowchart of a method for automatically kicking out a logged-in device provided by an embodiment of the present application;
[0081] Figure 3 Schematic flowchart of a method for determining a target intimacy degree provided by an embodiment of the present application;
[0082] Figure 4 Schematic flowchart of another method for determining a target intimacy degree provided by an embodiment of the present application;
[0083] Figure 5 Schematic flowchart of still another method for determining a target intimacy degree provided by an embodiment of the present application;
[0084] Figure 6 Schematic flowchart of a method for setting an intimacy degree provided by an embodiment of the present application;
[0085] Figure 7 Schematic flowchart of a method for automatically adjusting an intimacy degree provided by an embodiment of the present application;
[0086] Figure 8 Schematic flowchart of a method for setting an intimacy degree provided by an embodiment of the present application;
[0087] Figure 9 Schematic diagram of a device management page provided by an embodiment of the present application;
[0088] Figure 10 Schematic flowchart of a device for automatically kicking out a logged-in device provided by an embodiment of the present application;
[0089] Figure 11 Schematic diagram of a device for automatically kicking out a logged-in device provided by an embodiment of the present application. Detailed implementation manners
[0090] To make the objectives, technical solutions, and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Apparently, the described embodiments are some, but not all, of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present application without creative efforts shall fall within the protection scope of the present application.
[0091] The following disclosure provides many different embodiments or examples for implementing different structures of the present invention. To simplify the disclosure of the present invention, components and settings of specific examples are described below. Of course, they are only examples and are not intended to limit the present invention. In addition, the present invention may repeat reference numerals and / or letters in different examples. This repetition is for the purpose of simplicity and clarity and does not itself indicate the relationship between the various embodiments and / or settings discussed.
[0092] To facilitate the understanding of this application, the implementation scenario of this application is briefly introduced first:
[0093] As Figure 1 shown, in the actual scenario, the user can use a certain device to log in to the target account. For the convenience of subsequent elaboration, this device is referred to as the current device. The user can log in to the target account using the current device through three login methods: password input, scanning code, and SMS verification. The following takes the login method of password input as an example for illustration: After the user opens the login page, enters the target account and password on the page, and then clicks the confirm login button, at this time the current device receives the login instruction. Then, the current device will generate a login request based on the target account ID, password, device ID, and other information, and send it to the server. After receiving the login request, the server will first verify the target account ID and password. After the verification passes, the server will determine the account login list of the target account ID, and then detect whether the device ID of the current device exists in this account login list. If the device ID of the current device is in the account login list, the server will allow the current device to log in to the target account; if the device ID of the current device is not in the account login list and the number of device IDs in the account login list is greater than the preset threshold, the server will determine the device to be deleted in this account login list, delete it and make it exit the login state, then add the device ID of the current device to this account login list, and allow the current device to log in to the target account.
[0094] Among them, the types of the current device are rich and diverse, covering smartphones commonly used in daily life and work, tablets suitable for mobile scenario entertainment and office; and notebooks that provide users with an efficient office and entertainment experience, etc. The current device can also be other devices, which are not limited here.
[0095] Based on the above usage scenario, the embodiment of this application provides a method for automatically kicking out a logged-in device. This method does not require the user to screen and select among many device options, saving the user's time and energy, reducing the complexity of the user's operation, and improving the user experience. As Figure 1 shown, the specific steps include:
[0096] Step 201, when the user uses the current device to log in to the target account, obtain the target account ID to be used.
[0097] Among them, the target account is the currently used account, and the target account ID is used to uniquely represent the target account.
[0098] In this step, when using the password login method, the login request will carry the target account ID, and the server can directly extract the target account ID from the login request. When using the SMS login method, the login request contains the SMS verification code. With this SMS verification code, the server can find the corresponding target account ID, so as to obtain the target account ID to be used. If it is the QR code login method, the login request carries the QR code, and the server parses the QR code to find the corresponding target account ID, and finally obtains the target account ID to be used.
[0099] Step 202: Determine the account login list corresponding to the target account ID according to the target account ID.
[0100] Among them, each account corresponds to an account login list. The account login list refers to a list that records the login information of a certain account on different devices or platforms. The account login list includes login device information, login time, login location, login method, etc. Among them, the login device information includes device model, device name, device ID, etc. information. In this application, the account login list at least includes the device IDs of the devices that have logged in to the target account.
[0101] In this step, the server stores the corresponding relationship between the account ID and the account login list, so that the account login list corresponding to the target account ID can be determined according to the target account ID.
[0102] Step 203: When the account login list meets the preset conditions, determine the intimacy corresponding to each device ID in the account login list.
[0103] Among them, the preset conditions are that the device ID of the current device is not in the account login list, and the number of device IDs in the account login list is greater than the preset threshold. The device ID of the current device is used to uniquely represent the current device, which can be the device name of the current device or other data that uniquely indicates the current device. The preset threshold is set by technicians according to needs. For example, the preset threshold is set to 5. The intimacy is used to describe the degree of closeness between the device and the account, mainly reflected in the usage frequency, usage duration, operation behavior, operation habits, etc. of the user after a certain device logs in to a specific account. The higher the intimacy between the device and the account, the closer the association between the two, and the lower the probability that the device is kicked out of the account login list. On the contrary, the lower the intimacy between a certain device and the account, the looser the association between the two, and the higher the probability that the device is kicked out of the account login list. The intimacy corresponding to each device ID can be set by the user according to actual needs or determined by the server according to a preset algorithm, which is not limited here.
[0104] In this step, when each device logs in with a certain account, the user can set the intimacy of the device or use a preset method to calculate the intimacy of the device. Then, according to the determined intimacy, create the target association relationship of the account ID, device ID, and intimacy, and then store the target association relationship in the server. Then, when the account login list meets the preset conditions, according to the device IDs in the account login list and the target association relationship, determine the intimacy corresponding to each device ID.
[0105] In the above process, the specific steps of calculating the intimacy of the device using the preset method are as follows: obtain the device association data corresponding to the device and the master device respectively, calculate the similarity between the two device association data, and then determine the intimacy of the device according to the similarity. Among them, the device association data can be the location data, behavior data, device data, etc. of the device.
[0106] In the above process, it is possible to first detect whether the device ID of the current device is in the account login list, and then detect whether the number of device IDs in the account login list is greater than the preset threshold, or first detect whether the number of device IDs in the account login list is greater than the preset threshold, and then detect whether the device ID of the current device is in the account login list, which is not limited here.
[0107] Step 204, determine the target device ID to be deleted according to the intimacy corresponding to each device ID.
[0108] In this step, the device ID corresponding to the lowest intimacy can be determined as the target device ID to be deleted. The current device ID can also be obtained, and based on the current device ID, the target intimacy between the current device and the target account can be determined, that is, the target intimacy corresponding to the current device. Then, based on this target intimacy and the intimacy corresponding to each device ID, the target device ID to be deleted is determined. Other methods can also be used to determine the target device ID, which is not limited here.
[0109] Step 205, in the account login list, delete the target device ID to kick out the login of the target device.
[0110] In this step, in the account login list, delete the target device ID to kick out the login of the target device.
[0111] After that, the device ID of the current device also needs to be added to the account login list to update the account login list.
[0112] In the embodiment of the present application, when the user logs in to the target account using the current device, the target account ID to be used is obtained; according to the target account ID, the account login list corresponding to the target account ID is determined, and the account login list includes the device IDs of the devices that have logged in to the target account; when the account login list meets the preset conditions, the intimacy corresponding to each device ID in the account login list is determined; according to the intimacy corresponding to each device ID, the target device ID to be deleted is determined; in the account login list, the target device ID is deleted to kick out the login of the target device. It can be seen that the present application can automatically determine the device to be deleted and delete the device to automatically kick out the login of the target device. In this way, there is no need for the user to screen and select among many device options, saving the user's time and energy, reducing the complexity of the user's operation, and improving the user experience.
[0113] In the embodiment of the present application, first, the target intimacy corresponding to the current device is determined, and then among the intimacies corresponding to each device ID, it is detected whether there is a reference intimacy less than the target intimacy. If it exists, the first strategy is adopted to select the target device ID to be deleted from the device IDs corresponding to the reference intimacy; if it does not exist, the second strategy is adopted to select the target device ID to be deleted from all the device IDs. In this way, according to different intimacy situations, the corresponding strategies can be flexibly used to process the device ID and intimacy relationship, effectively meeting the diverse device management and intimacy setting requirements, and improving the accuracy and adaptability of device management. Therefore, the embodiment of the present application provides a method for determining the target intimacy, and the method is as Figure 3 shown, and the specific steps include:
[0114] Step 301, determine the target intimacy corresponding to the current device.
[0115] In this step, the server can obtain the device ID of the current device. After that, based on the target account and this device ID, in the target association, the target intimacy corresponding to the current device can be determined. It is also possible to calculate the target intimacy corresponding to the current device according to the intimacy calculation method. Of course, other methods can also be used to determine the target intimacy, which is not limited here.
[0116] Step 302: Detect whether there is a reference intimacy less than the target intimacy among the intimacies corresponding to each device ID.
[0117] In this step, the target intimacy is compared with the intimacies corresponding to each device ID, and the intimacy less than the target intimacy is called the reference intimacy. After completing the intimacy comparison process, it is detected whether there is a reference intimacy.
[0118] Step 303: When there is a reference intimacy less than the target intimacy, use the first strategy to select the target device ID to be deleted among the device IDs corresponding to the reference intimacy.
[0119] Among them, the first strategy is to determine the device ID corresponding to the minimum reference intimacy as the target device ID to be deleted. Or, the first strategy is to randomly select a device ID among the device IDs corresponding to the reference intimacy and determine it as the target device ID. Of course, the first strategy can also be other strategies, which is not limited here.
[0120] Step 304: When there is no reference intimacy less than the target intimacy, use the second strategy to select the target device ID to be deleted among all device IDs.
[0121] Among them, the second strategy is to determine the device ID corresponding to the minimum intimacy as the target device ID to be deleted. Or, the second strategy is to randomly select a device ID among all device IDs and determine it as the target device ID. Of course, the second strategy can also be other strategies, which is not limited here.
[0122] In an actual application scenario, if the current device has a login record recently, then the associated relationship related to it is probably not deleted yet. Based on this, when it is necessary to determine the target intimacy corresponding to the current device ID, the target intimacy corresponding to the current device ID can be quickly and accurately obtained according to the target association relationship of the account ID, device ID, and intimacy. However, if the associated relationship related to it has been deleted, or the current device is logging in to this account for the first time and is a newly logged-in device, then the target intimacy cannot be directly obtained from the target association relationship. At this time, relevant calculations are required to determine the target intimacy corresponding to the current device. Therefore, the present application provides a method for determining the target intimacy, and this method is asFigure 4 As shown below, the specific steps include:
[0123] Step 401, obtain the target association relationship among the account ID, device ID, and intimacy.
[0124] In this step, the server obtains the pre-stored target association relationship among the account ID, device ID, and intimacy, and based on this target association relationship, detects whether there is a target intimacy corresponding to the current device ID.
[0125] Step 402, according to the device ID of the current device and the target account ID, detect whether there is a corresponding intimacy in the target association relationship.
[0126] In this step, compare the device ID of the current device and the target account ID with the device ID and account ID in the target association relationship to detect whether the corresponding intimacy is found.
[0127] Step 403, in the case where there is a corresponding intimacy, determine this intimacy as the target intimacy corresponding to the current device.
[0128] In this step, in the case where there is a corresponding intimacy, it means that this intimacy is the target intimacy corresponding to the current device, and then this intimacy can be determined as the target intimacy.
[0129] Step 404, in the case where there is no corresponding intimacy, obtain the current device association data of the current device, and determine the target intimacy corresponding to the current device according to the current device association data.
[0130] In this step, in the case where there is no corresponding intimacy, it is necessary to calculate to determine the target intimacy of the current device. The calculation steps are as follows: First, obtain the device ID of the current device. Based on this device ID, search for the corresponding current device association data in the database. Among them, the current device association data includes the behavior data and device data of the user using the current device. At the same time, according to the target account ID, find out the device ID of the main device bound to this target account ID. After determining the device ID of the main device, obtain the device association data of the main device. Then, calculate the similarity between these two sets of device association data, and determine the target intimacy of the current device according to the calculated similarity.
[0131] Among them, the primary device is usually the device that the user uses most frequently and has a relatively high degree of trust. Specifically, the primary device is the device bound to the target account. In an actual application scenario, when the user successfully logs in to the target account using a certain device, the client will provide an option for the user to set independently, and the user can decide whether to bind the target account to the currently logged-in device. Once the user selects to bind, then this device will be recognized as the primary device. Of course, the server can also comprehensively consider multi-dimensional information corresponding to each device ID, such as the login frequency of the device, that is, the number of times the device logs in to the account within a certain period; the login duration, that is, the duration of continuous online after each login; and the login method, to determine whether it is the commonly used password login or the login by means of SMS verification code, scanning code, etc. By deeply analyzing and evaluating this multi-dimensional information, the device ID that best meets the characteristics of the primary device is selected from the list of logged-in accounts.
[0132] In the embodiment of the present application, the current device association data can be the current user behavior data, the current device name, and the current login location after logging in to the target account using the current device. In this way, after obtaining the device association data, the similarity between the current device and the primary device can be analyzed from these data, and then the target intimacy corresponding to the current device can be determined. Therefore, the embodiment of the present application provides a method for determining the target intimacy, and this method is as Figure 5 shown, and the specific steps include:
[0133] Step 501, obtain the target device name, the target login location, and the target behavior data of the primary device.
[0134] Among them, the target behavior data contains all necessary information related to the behavior, such as the time, location, operation type, operation object, etc. when the behavior occurs.
[0135] In this step, the server collects the target device name, the target login location, and the target behavior data of the primary device from various data sources to obtain the target device name, the target login location, and the target behavior data of the primary device.
[0136] Step 502, determine the first similarity corresponding to the device name according to the current device name and the target device name.
[0137] In this step, first perform text preprocessing on these two device names. Then perform word segmentation processing on the preprocessed device names to obtain the word segmentation results corresponding to the current device name and the target device name respectively. Finally, use a similarity calculation algorithm to calculate the similarity between the two word segmentation results, and normalize this similarity to obtain the first similarity corresponding to the device name.
[0138] Among them, the similarity calculation algorithm can be the edit distance algorithm or other similarity calculation algorithms, which is not limited here.
[0139] Step 503: Determine the second similarity corresponding to the login location according to the current login location and the target login location.
[0140] Among them, the accurate location information of the current login location is obtained through the GPS positioning, IP address positioning or other positioning technologies of the user device. This information may include data such as longitude and latitude, specific address, geographical area or administrative region to which it belongs, etc.
[0141] In this step, obtain the longitude and latitude, specific address, and the area to which the current login location and the target login location belong. Calculate the distance between two longitudes and latitudes using the geographical distance formula, and determine the similarity corresponding to the longitude and latitude accordingly. Use the string similarity algorithm to calculate the similarity of the two specific addresses. According to the two areas to which they belong, judge whether the current and target login locations belong to the same regional unit. If so, set the similarity corresponding to the area to the first similarity value; if not, set it to the second similarity value. Finally, add the similarities corresponding to the longitude and latitude, specific address, and area to obtain the second similarity corresponding to the login location.
[0142] Step 504: Determine the third similarity corresponding to the behavior data according to the current behavior data and the target behavior data.
[0143] In this step, clean the behavior data to remove duplicate data, error data, and missing values. According to the characteristics of the behavior data and the analysis purpose, extract representative features, such as behavior frequency, behavior duration, time interval between behaviors, behavior path, type of object operated on, etc. Use the feature selection algorithm to screen out the features that contribute more to the similarity calculation, remove redundant and irrelevant features, so as to reduce the data dimension, improve the calculation efficiency and accuracy. Standardize the extracted feature data so that the data of different features have the same scale and distribution range. Finally, use the similarity calculation algorithm to calculate the standardized feature data to obtain the third similarity corresponding to the behavior data.
[0144] Step 505: Determine the target intimacy corresponding to the target device according to the first similarity, the second similarity, and the third similarity.
[0145] In this step, the first similarity, the second similarity, and the third similarity can be directly added together to obtain the target intimacy. However, considering that the influence degrees of user behavior data, device name, and login location on intimacy are different, in order to calculate more accurately, a weighted calculation method can also be adopted. The specific steps are as follows: First, set the corresponding weight coefficients for user behavior data, device name, and login location respectively. The setting of the weight coefficients is determined according to their respective importance in influencing intimacy. The higher the importance, the larger the weight coefficient. Then, multiply the first similarity by the weight coefficient corresponding to user behavior data to obtain the first value; multiply the second similarity by the weight coefficient corresponding to the device name to get the second value; multiply the third similarity by the weight coefficient corresponding to the login location to calculate the third value. Finally, add these three values together to obtain the target intimacy corresponding to the current device.
[0146] In the embodiment of the present application, a page for setting intimacy can be displayed on the current device. On this page, the user can freely set the intimacy value for the device logged in to the target account. After completing the intimacy setting operation, the current device will automatically send an intimacy setting message containing detailed setting information to the server, so that after receiving this message, the server will accurately set the intimacy according to the content therein. Therefore, the embodiment of the present application provides a method for setting intimacy, and this method is as Figure 6 shown, and the specific steps include:
[0147] Step 601, receive the user's intimacy setting message.
[0148] Among them, the intimacy setting message includes at least the target account ID, the relevant device ID, and the intimacy corresponding to the relevant device ID. The relevant device ID can be the device ID in the account login list or the device ID of the current device, and it is not limited here.
[0149] In this step, when the user wants to set the intimacy, the user can open the intimacy setting page on the current device, and then set the intimacy of the relevant device ID on this intimacy setting page. The intimacy setting page includes a device ID selection option, a corresponding intimacy setting option, and a setting completion button. Among them, the device ID selection option is used for the user to select the device ID for which the intimacy is to be set, and the intimacy setting option is used for the user to set the intimacy of the device ID. When the user clicks the setting completion button, the current device can obtain the target account ID, the device ID in the device ID selection option, and the intimacy in the intimacy setting option, generate an intimacy setting message based on this, and send it to the server, so that the server receives the intimacy setting message sent by the current device.
[0150] Step 602: Set the target association relationship according to the association relationship among the target account ID, the relevant device ID, and the intimacy.
[0151] In this step, the server retrieves in the target association relationship according to the target account ID and the relevant device ID. If the server successfully retrieves the corresponding intimacy, it indicates that the intimacy corresponding to the relevant device ID already exists in the target association relationship. At this time, the server performs an update operation on the target association relationship according to the association relationship among the target account ID, the relevant device ID, and the newly set intimacy. On the contrary, if the server fails to retrieve the intimacy that matches the target account ID and the relevant device ID in the target association relationship, it means that the intimacy corresponding to the relevant device ID has not been recorded. In this case, the server needs to add the association relationship among the target account ID, the relevant device ID, and the newly set intimacy to the target association relationship.
[0152] In the embodiment of the present application, for the account login list corresponding to the target account, each device ID in the account login list has a corresponding intimacy. When the intimacy corresponding to a certain device ID is greater than the preset threshold, it is considered that the device is a device trusted by the user, and the user can be allowed to directly log in to the device. When the intimacy corresponding to a certain device ID is not greater than the preset threshold, the user may use the method of scanning the code to log in or the method of SMS verification to log in to verify whether the device can log in to a specific account. For these devices, when using a specific account to log in to a certain device, if the device receives too many login verification SMSs, it means that the user often uses the specific account to log in to the device, and the device can be set as a device trusted by the user to avoid generating too many verification login SMSs, thereby increasing the burden on the server side. Therefore, the embodiment of the present application provides a method for automatically adjusting intimacy, and the method is as Figure 7 shown, and the specific steps include:
[0153] Step 701: Obtain the intimacy and SMS verification frequency corresponding to each device ID according to the account login list.
[0154] Among them, the SMS verification frequency refers to the frequency at which the server sends login verification SMSs to the device logging in to a specific account. When the sending time of a certain login verification SMS is relatively long ago, its reference value is relatively limited. Therefore, in order to accurately reflect the frequency at which the user uses a certain device to log in to a certain account, it is necessary to obtain the recent SMS verification frequency. For example, obtain the SMS verification frequency within one month.
[0155] In this step, the intimacy corresponding to each device ID in the account login list is pre-stored. At the same time, the association relationship among the account ID, the device ID, and the SMS verification frequency is also stored. In this way, the intimacy and SMS verification frequency corresponding to each device ID can be obtained according to the target account ID.
[0156] Step 702: For each device ID, determine the SMS verification threshold according to the intimacy corresponding to the device ID. When the corresponding SMS verification frequency is greater than the SMS verification threshold, adjust the intimacy corresponding to the device ID.
[0157] Among them, different intimacies correspond to different SMS verification thresholds. The higher the intimacy, the lower the corresponding SMS verification threshold; the lower the intimacy, the higher the corresponding SMS verification threshold. Since methods such as automatic login, QR code login, and password login are all relatively convenient, the higher the intimacy, the higher the probability of using QR code or password login, and the lower the probability of using SMS verification, which also makes the corresponding SMS verification threshold lower. The intimacy adjustment notice is used to notify the user that they can adjust the intimacy of a specific device.
[0158] In this step, since different intimacies correspond to different SMS verification thresholds, the association relationship between intimacy and SMS verification threshold can be stored, so that the SMS verification threshold can be determined according to the intimacy corresponding to the device ID. For each device ID in the account login list, when the SMS verification frequency corresponding to the device ID is greater than its corresponding SMS verification threshold, it means that the intimacy corresponding to the device ID can be adjusted to reduce the number of login verification SMS sent. Therefore, an intimacy adjustment notice can be sent to the corresponding device to enable the user to adjust the intimacy of the device.
[0159] Of course, when the SMS verification frequency corresponding to a certain device ID is greater than its corresponding SMS verification threshold, the intimacy of the device ID can be automatically increased to reduce the number of login verification SMS sent. For example, assume that the intimacy between a certain device ID and a specific account ID is 2. When the SMS verification frequency corresponding to the device ID is greater than its corresponding SMS verification threshold, the intimacy between the device ID and the specific account ID can be adjusted to 3.
[0160] Furthermore, the specific steps for adjusting the intimacy corresponding to the device ID are as follows: Send an intimacy adjustment notice to the current device to enable the user to adjust the intimacy of the device ID.
[0161] In this step, the server can send an intimacy adjustment notice to the current device, and the intimacy adjustment notice includes the device ID to be adjusted. Then, after the current device receives the intimacy adjustment notice, it displays an intimacy adjustment interface based on the device ID in the intimacy adjustment notice to enable the user to adjust the intimacy of the device ID. When the user adjusts the intimacy of the device ID, the current device can send the adjusted intimacy to the server so that the server can adjust the intimacy of the device ID.
[0162] Alternatively, according to the intimacy calculation method, recalculate the intimacy corresponding to the device ID to obtain the adjusted intimacy, and adjust the intimacy of the device ID according to the adjusted intimacy.
[0163] Among them, the intimacy calculation method can be Figure 5 The corresponding intimacy calculation method, or other calculation methods can also be used, which is not limited here.
[0164] Based on the above embodiments, the account login list of the target account includes not only the login device IDs used by the user himself, but also the login device IDs used by the user's friends. In view of this situation, in order to further reduce the SMS overhead, when setting the device intimacy, it is also possible to detect whether there is a device used by the user himself but not the main device. When there is such a device, the intimacy of this device can be preferentially set to the lowest intimacy to preferentially kick out this device. This is because this device is logged in by the user himself, and when logging in, usually the main device is used for scanning code login or account password login, which is fast and convenient and does not generate SMS verification fees, avoiding the SMS overhead when this device logs in again.
[0165] Furthermore, it is possible to determine whether a device is a device used by the user himself by detecting the distance between a certain device and the main device. For example, when the distance between a certain device and the main device is less than the preset distance, it is determined that this device is a device used by the user himself; when the distance between a certain device and the main device is not less than the preset distance, it is determined that this device is not a device used by the user himself.
[0166] In addition, the account login list of the target account also includes the login method corresponding to each device ID. In order to reduce the SMS overhead of the platform, retain the device ID corresponding to the SMS verification method, and preferentially kick out the device ID corresponding to the non-SMS verification method. When there are multiple device IDs to be kicked out, according to Figure 2 the above method, among these device IDs, determine the device ID to be kicked out.
[0167] Or, when Figure 2 the above method determines multiple target device IDs, determine the final target device ID to be kicked out according to the login method corresponding to each target device ID.
[0168] Based on the above embodiments, the embodiments of the present application also provide an intimacy setting method, and this method is as Figure 8As shown in the figure, the specific steps include: After logging in to the target account using a new device, since there is no corresponding intimacy for this device, first determine whether the user independently sets the device intimacy. If so, the user can independently set it on the device management page of the terminal and store the set data; if not, the device association data of this device can be obtained, and based on this device association data, calculate the device intimacy for automatic setting.
[0169] Among them, the above-mentioned device management page is as Figure 9 shown, including the IDs of all logged-in devices and the corresponding intimacies, and also including some other data, such as data like login time, login location, etc.
[0170] Then, for each logged-in device, determine whether the SMS verification frequency of this logged-in device is greater than the threshold. If it is greater than the threshold, determine again whether the user independently sets it. If the user independently sets it, a pop-up window will suggest adjusting the device intimacy; if the user does not independently set it, recalculate the device intimacy. If the SMS verification code frequency is not greater than the threshold, this device can be used normally.
[0171] As Figure 10 shown, an embodiment of the present application provides a device for automatically kicking out a logged-in device. This device corresponds to the method embodiment and specifically includes:
[0172] An acquisition unit 1001, configured to obtain the ID of the target account to be used when the user logs in to the target account using the current device;
[0173] A first determination unit 1002, configured to determine an account login list corresponding to the target account ID according to the target account ID, where the account login list includes the device IDs of the devices that have logged in to the target account;
[0174] A second determination unit 1003, configured to determine the intimacy corresponding to each device ID in the account login list when the account login list meets a preset condition;
[0175] A third determination unit 1004, configured to determine the target device ID to be deleted according to the intimacy corresponding to each device ID;
[0176] A deletion unit 1005, configured to delete the target device ID in the account login list to kick out the login of the target device.
[0177] Optionally, the third determination unit 1004 is configured to:
[0178] Determine the target intimacy corresponding to the current device;
[0179] Detect whether there is a reference intimacy less than the target intimacy among the intimacies corresponding to each device ID;
[0180] When there is a reference intimacy less than the target intimacy, use the first strategy to select the target device ID to be deleted from the device IDs corresponding to the reference intimacy.
[0181] When there is no reference intimacy less than the target intimacy, use the second strategy to select the target device ID to be deleted from all device IDs.
[0182] Optionally, the third determination unit 1004 is configured to:
[0183] Obtain the target association relationship among the account ID, device ID, and intimacy.
[0184] According to the device ID of the current device and the target account ID, detect whether there is a corresponding intimacy in the target association relationship.
[0185] When there is a corresponding intimacy, determine the intimacy as the target intimacy corresponding to the current device.
[0186] When there is no corresponding intimacy, obtain the current device association data of the current device, and determine the target intimacy corresponding to the current device according to the current device association data.
[0187] Optionally, the current device association data includes the current device name, current login location, and current behavior data. The third determination unit 1004 is configured to:
[0188] Obtain the target device name, target login location, and target behavior data of the main device, where the main device is the device bound to the target account.
[0189] Determine the first similarity corresponding to the device name according to the current device name and the target device name.
[0190] Determine the second similarity corresponding to the login location according to the current login location and the target login location.
[0191] Determine the third similarity corresponding to the behavior data according to the current behavior data and the target behavior data.
[0192] Determine the target intimacy corresponding to the current device according to the first similarity, the second similarity, and the third similarity.
[0193] Optionally, the device further includes a setting unit 1006. The setting unit 1006 is configured to:
[0194] Receive the intimacy setting message from the user. The intimacy setting message includes the target account ID, the related device ID, and the corresponding intimacy.
[0195] Set the target association relationship according to the association relationship between the target account ID, the relevant device ID, and the intimacy.
[0196] Optionally, the device further includes an adjustment unit 1007, and the adjustment unit 1007 is used for:
[0197] Obtain the intimacy and SMS verification frequency corresponding to each device ID according to the account login list;
[0198] For each device ID, determine the SMS verification threshold according to the intimacy corresponding to the device ID. When the corresponding SMS verification frequency is greater than the SMS verification threshold, adjust the intimacy corresponding to the device ID.
[0199] Optionally, the adjustment unit 1007 is used for:
[0200] Send an intimacy adjustment notice to the current device to enable the user to adjust the intimacy of the device;
[0201] Or, according to the intimacy calculation method, recalculate the intimacy corresponding to the device ID to obtain the adjusted intimacy, and adjust the intimacy of the device ID according to the adjusted intimacy.
[0202] As Figure 11 As shown, an embodiment of the present application provides a method for automatically kicking out a device for a logged-in device, including a processor 1101, a communication interface 1102, a memory 1103, and a communication bus 1104. Among them, the processor 1101, the communication interface 1102, and the memory 1103 communicate with each other through the communication bus 1104.
[0203] The memory 1103 is used to store a computer program;
[0204] In an embodiment of the present application, when the processor 1101 is used to execute the program stored in the memory 1103, it implements the method for automatically kicking out a logged-in device provided in any of the foregoing method embodiments, including:
[0205] When a user logs in to a target account using the current device, obtain the target account ID to be used;
[0206] According to the target account ID, determine the account login list corresponding to the target account ID, and the account login list includes the device IDs that have logged in to the target account;
[0207] When the account login list meets a preset condition, determine the intimacy corresponding to each device ID in the account login list;
[0208] Determine the target device ID to be deleted according to the intimacy corresponding to each device ID;
[0209] In the account login list, delete the target device ID to kick out the login of the target device.
[0210] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the automatic kick-out method for logged-in devices provided in any of the foregoing method embodiments are implemented.
[0211] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0212] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the essence of the above technical solution or the part that contributes to the related technology can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., including several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0213] It should be understood that the terms used in this specification are only for the purpose of describing specific example embodiments and are not intended to be limiting. Unless the context clearly indicates otherwise, the singular forms "a", "an", and "the" as used herein may also include the plural forms. The terms "comprising", "including", "containing", and "having" are inclusive and thus specify the presence of the stated features, steps, operations, elements, and / or components, but do not preclude the presence or addition of one or more other features, steps, operations, elements, components, and / or their combinations. The method steps, processes, and operations described herein are not to be construed as necessarily requiring them to be executed in the specific order described or illustrated, unless the execution order is clearly indicated. It should also be understood that additional or alternative steps may be used.
[0214] The above are only specific embodiments of the present invention, enabling those skilled in the art to understand or implement the present invention. Various modifications to these embodiments will be obvious to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to these embodiments shown herein, but rather will be accorded the widest scope consistent with the principles and novel features claimed herein.
Claims
1. A method for automatically kicking out a login device, characterized in that: The method comprises: When the user logs in to the target account using the current device, the target account ID to be used is obtained; According to the target account ID, determine an account login list corresponding to the target account ID, the account login list including the device ID of the logged-in target account; When the account login list meets a preset condition, determining the intimacy corresponding to each device ID in the account login list; Determine the target device ID to be deleted based on the intimacy corresponding to each device ID; In the account login list, the target device ID is deleted to kick out the login of the target device.
2. The method according to claim 1, characterized in that: The step of determining the target device ID to be deleted according to the intimacy corresponding to each device ID includes: Determining a target intimacy corresponding to the current device; In the intimacy corresponding to each device ID, detecting whether there is a reference intimacy that is less than the target intimacy; When there is a reference intimacy that is less than the target intimacy, using a first strategy, selecting a target device ID to be deleted from the device IDs corresponding to the reference intimacy; When there is no reference intimacy less than the target intimacy, the second strategy is used to select a target device ID to be deleted from all device IDs.
3. The method according to claim 2, characterized in that: The determining the target intimacy corresponding to the current device includes: Get the target association relationship between account ID, device ID and intimacy; According to the device ID of the current device and the target account ID, detecting whether there is a corresponding intimacy in the target association relationship; If there is a corresponding intimacy, determining the intimacy as a target intimacy corresponding to the current device; In the case where there is no corresponding intimacy, current device association data of the current device is obtained, and the target intimacy corresponding to the current device is determined according to the current device association data.
4. The method according to claim 3, characterized in that: The current device association data includes the current device name, the current login location and the current behavior data. The determining the target intimacy corresponding to the current device according to the current device association data includes: Obtaining a target device name, a target login location, and target behavior data of a master device, wherein the master device is a device bound to the target account; Determining a first similarity corresponding to a device name according to the current device name and the target device name; Determining a second similarity corresponding to the login location according to the current login location and the target login location; Determining a third similarity corresponding to the behavior data according to the current behavior data and the target behavior data; A target intimacy corresponding to the current device is determined according to the first similarity, the second similarity, and the third similarity.
5. The method according to claim 1, characterized in that: The method further comprises: Receive an intimacy setting message from a user, wherein the intimacy setting message includes the target account ID, a related device ID, and a corresponding intimacy; The target association relationship is set according to the association relationship among the target account ID, the related device ID and the intimacy.
6. The method according to claim 1, characterized in that: The method further comprises: According to the account login list, obtain the intimacy and SMS verification frequency corresponding to each device ID; For each device ID, a text message verification threshold is determined according to the intimacy corresponding to the device ID, and when the corresponding text message verification frequency is greater than the text message verification threshold, the intimacy corresponding to the device ID is adjusted.
7. The method according to claim 1, characterized in that: The adjusting the intimacy corresponding to the device ID includes: Sending an intimacy adjustment notification to the current device so that the user can adjust the intimacy of the device; Or, according to the intimacy calculation method, the intimacy corresponding to the device ID is recalculated to obtain an adjusted intimacy, and the intimacy of the device ID is adjusted according to the adjusted intimacy.
8. A device for automatically kicking out a login device, characterized in that: The device comprises: An acquisition unit, used to acquire the target account ID to be used when the user logs in to the target account using the current device; A first determining unit, configured to determine, according to the target account ID, an account login list corresponding to the target account ID, wherein the account login list includes a device ID that has logged into the target account; A second determining unit, configured to determine the intimacy corresponding to each device ID in the account login list when the account login list meets a preset condition; A third determining unit, configured to determine a target device ID to be deleted according to the intimacy corresponding to each device ID; The deleting unit is used to delete the target device ID from the account login list to kick out the target device from logging in.
9. A login device automatically kicks out a device, characterized in that: include: at least one communication interface; at least one bus connected to the at least one communication interface; at least one processor connected to the at least one bus; at least one memory connected to the at least one bus, wherein the processor is configured to: When the user logs in to the target account using the current device, the target account ID to be used is obtained; According to the target account ID, determine an account login list corresponding to the target account ID, the account login list including the device ID of the logged-in target account; When the account login list meets a preset condition, determining the intimacy corresponding to each device ID in the account login list; Determine the target device ID to be deleted based on the intimacy corresponding to each device ID; In the account login list, the target device ID is deleted to kick out the login of the target device.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for automatically kicking out a login device as described in any one of claims 1 to 7 is implemented.