CN110351767B - Wi-Fi connection management method and device, electronic terminal and storage medium - Google Patents

Wi-Fi connection management method and device, electronic terminal and storage medium Download PDF

Info

Publication number
CN110351767B
CN110351767B CN201910759322.7A CN201910759322A CN110351767B CN 110351767 B CN110351767 B CN 110351767B CN 201910759322 A CN201910759322 A CN 201910759322A CN 110351767 B CN110351767 B CN 110351767B
Authority
CN
China
Prior art keywords
connection
field
initiating terminal
configuration information
application
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910759322.7A
Other languages
Chinese (zh)
Other versions
CN110351767A (en
Inventor
龚健飞
陈炎福
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Cloud Computing Beijing Co Ltd
Original Assignee
Tencent Cloud Computing Beijing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Cloud Computing Beijing Co Ltd filed Critical Tencent Cloud Computing Beijing Co Ltd
Priority to CN201910759322.7A priority Critical patent/CN110351767B/en
Publication of CN110351767A publication Critical patent/CN110351767A/en
Application granted granted Critical
Publication of CN110351767B publication Critical patent/CN110351767B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/08Testing, supervising or monitoring using real traffic
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Environmental & Geological Engineering (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The application provides a Wi-Fi connection management method, a device, an electronic terminal and a storage medium, which are applied to the electronic terminal with a Wi-Fi module, wherein after the Wi-Fi module processes a Wi-Fi network connection request, a Wi-Fi connection event is generated. By executing the scheme of the application for multiple times, the Wi-Fi connection success condition of each application program running on the operating system of the electronic terminal can be accurately determined.

Description

Wi-Fi connection management method and device, electronic terminal and storage medium
Technical Field
The present invention relates to the field of wireless communications technologies, and in particular, to a Wi-Fi connection management method, device, electronic terminal, and storage medium.
Background
Wi-Fi management APP (Application) refers to an APP that can provide Wi-Fi hotspot (including free Wi-Fi hotspots as well as crowdsourcing Wi-Fi hotspots) connectivity functions, such as Wi-Fi master keys, tencel Wi-Fi households, and the like. The Wi-Fi connection success rate index of the Wi-Fi management APP is one of core indexes which directly reflects the use value and user experience. Therefore, it is necessary to determine the connection success rate of Wi-Fi management APP. The connection success rate of a Wi-Fi management APP refers to the ratio of the number of times the Wi-Fi management APP successfully connects to a Wi-Fi hotspot to the number of times the Wi-Fi management APP initiates a Wi-Fi connection.
At present, after the electronic terminal monitors a Wi-Fi connection event, wi-Fi connection information corresponding to the Wi-Fi connection event is determined, and a background server determines Wi-Fi connection success rates of all Wi-Fi management APPs according to the Wi-Fi connection information determined by the electronic terminal. One Wi-Fi connection information includes APP information that initiates the Wi-Fi connection and a connection result.
However, after monitoring the Wi-Fi connection event, the electronic terminal determines that the APP that initiates the Wi-Fi connection is the APP corresponding to the interface currently displayed by the electronic terminal, that is, when the electronic terminal monitors the Wi-Fi connection event while displaying the interface of the first APP, that is, considers that the corresponding Wi-Fi connection is initiated by the first APP, but in fact, the Wi-Fi connection may be initiated by the second APP in the background. In this way, the connection success rate of the background server to the first APP and the connection success rate of the second APP can be determined to be wrong.
Disclosure of Invention
In view of the above, the application provides a Wi-Fi connection management method, a Wi-Fi connection management device, an electronic terminal and a storage medium, so as to accurately determine the success rate of Wi-Fi connection.
In order to achieve the above objective, in one aspect, the present application provides a Wi-Fi connection management method applied to an electronic terminal having a Wi-Fi module, including:
acquiring a Wi-Fi connection event broadcasted from an operating system of an electronic terminal outwards, wherein the Wi-Fi connection event is used for indicating that a Wi-Fi network connection request is processed and completed by the Wi-Fi module;
acquiring configuration information for recording the Wi-Fi connection event;
analyzing and processing the configuration information so as to determine the name of an application package of an initiating terminal initiating the Wi-Fi network connection request;
generating a Wi-Fi connection record of the initiating terminal, wherein the Wi-Fi connection record of the initiating terminal comprises an application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal;
the Wi-Fi connection record of the initiating terminal is sent to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal.
In still another aspect, the present application further provides a Wi-Fi connection management device, applied to an electronic terminal having a Wi-Fi module, where the device includes:
the Wi-Fi connection event acquisition unit is used for acquiring Wi-Fi connection events broadcasted outside by an operating system of the electronic terminal, wherein the Wi-Fi connection events are used for indicating that the Wi-Fi module has processed and completed a Wi-Fi network connection request;
the configuration information acquisition unit is used for acquiring and recording the configuration information of the Wi-Fi connection event;
the application packet name determining unit is used for analyzing and processing the configuration information so as to determine the application packet name of the initiating terminal initiating the Wi-Fi network connection request;
a Wi-Fi connection record generating unit, configured to generate a Wi-Fi connection record of the initiator, where the Wi-Fi connection record of the initiator includes an application package name of the initiator and a Wi-Fi connection result of the initiator;
the output unit is used for sending the Wi-Fi connection record of the initiating terminal to a server so that the server processes the connection record of the initiating terminal and outputs the Wi-Fi connection success condition of the initiating terminal; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal.
In still another aspect, the present application further provides an electronic terminal, including:
a processor and a memory;
wherein the processor is configured to execute a program stored in the memory;
the memory is used for storing a program, and the program is used for at least:
acquiring a Wi-Fi connection event broadcasted from an operating system of an electronic terminal outwards, wherein the Wi-Fi connection event is used for indicating that a Wi-Fi network connection request is processed and completed by the Wi-Fi module;
acquiring configuration information for recording the Wi-Fi connection event;
analyzing and processing the configuration information so as to determine the name of an application package of an initiating terminal initiating the Wi-Fi network connection request;
generating a Wi-Fi connection record of the initiating terminal, wherein the Wi-Fi connection record of the initiating terminal comprises an application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal;
the Wi-Fi connection record of the initiating terminal is sent to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal.
In yet another aspect, the present application further provides a storage medium having stored therein computer-executable instructions that, when loaded and executed by a processor, implement the Wi-Fi connection management method as described above.
Compared with the prior art, the Wi-Fi connection management method, the device, the electronic terminal and the storage medium are applied to the electronic terminal with the Wi-Fi module, after the Wi-Fi connection management client monitors a Wi-Fi connection event for indicating that the Wi-Fi module has processed and completed a Wi-Fi network connection request, configuration information for recording the Wi-Fi connection event is acquired firstly, then the configuration information is analyzed and processed, so that an application package name of an initiating terminal for initiating the Wi-Fi network connection request is determined, then a Wi-Fi connection record comprising the application package name of the initiating terminal and Wi-Fi connection results of the initiating terminal is generated, and finally the Wi-Fi connection record of the initiating terminal is sent to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal. In the scheme, after a Wi-Fi network connection request is processed by the Wi-Fi module, a Wi-Fi connection event is generated, after the Wi-Fi connection event is monitored, the Wi-Fi connection management client determines an initiating terminal for initiating the Wi-Fi connection not according to the interface information currently displayed by the electronic terminal, but according to the configuration information for recording the Wi-Fi connection event, and because the configuration information records the real processing process of the Wi-Fi module on the Wi-Fi network connection request, the initiating terminal for initiating the Wi-Fi connection can be accurately determined according to the configuration information, and further the successful Wi-Fi connection condition of the initiating terminal can be accurately determined. By executing the scheme of the application for multiple times, the Wi-Fi connection success condition of each application program running on the operating system of the electronic terminal can be accurately determined.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only embodiments of the present invention, and that other drawings can be obtained according to the provided drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic diagram of a composition architecture of a Wi-Fi connection management system according to an embodiment of the present invention;
fig. 2 is a flowchart of a Wi-Fi connection management method according to an embodiment of the present invention;
fig. 3 is a flowchart of a specific implementation method for analyzing and processing the configuration information to determine an application packet name of an initiator that initiates a Wi-Fi network connection request according to an embodiment of the present invention;
fig. 4 is a flowchart of a specific implementation method for processing a connection record of an initiator and outputting a Wi-Fi connection success condition of the initiator according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of an example of outputting a first result and a second result according to an embodiment of the present invention;
fig. 6 is a block diagram of a Wi-Fi connection management device according to an embodiment of the present invention;
Fig. 7 is a schematic diagram of a composition structure of an electronic terminal according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
For ease of understanding, the constituent architecture of the system to which the scheme of the present application is applied will be described first. For example, referring to fig. 1, a schematic diagram of the composition architecture of a Wi-Fi connection management system of the present application is shown.
As can be seen from fig. 1, the Wi-Fi connection management system includes an electronic terminal 10 and a server 11, where the electronic terminal 10 may be a smart phone, a tablet computer, etc. with a Wi-Fi module: the server 11 may be a single server, a server cluster, or a distributed cluster composed of a plurality of servers.
The electronic terminal can install various types of APP (Application) through an operating system (for example, android system) thereof so as to realize different functions. For example, to better access Wi-Fi networks, electronic terminals typically have Wi-Fi management APPs installed. The WiFi management APP can initiate connection of the electronic terminal and each APP with the Wi-Fi network by calling the Wi-Fi module. When the Wi-Fi management APP calls the Wi-Fi module to initiate a Wi-Fi network connection request, an operating system of the electronic terminal can automatically generate a Wi-Fi network connection event corresponding to the Wi-Fi network connection request and broadcast the Wi-Fi network connection event.
A Wi-Fi connection management client (hereinafter referred to as a client) is installed on the electronic terminal, the client can be implemented on an operating system of the electronic terminal or any APP installed on the electronic terminal, after the client is started, a Wi-Fi connection event broadcasted by the operating system of the electronic terminal is monitored, a Wi-Fi connection event used for indicating that the Wi-Fi module has processed a Wi-Fi network connection request is obtained, and configuration information for recording the Wi-Fi connection event is obtained; analyzing and processing the configuration information, so as to determine the application package name of the Wi-Fi management APP for initiating the Wi-Fi network connection request; generating a Wi-Fi connection record of the Wi-Fi management APP, wherein the Wi-Fi connection record of the Wi-Fi management APP comprises an application package name of the Wi-Fi management APP and a Wi-Fi connection result of the Wi-Fi management APP; the Wi-Fi connection record of the Wi-Fi management APP is sent to a server, so that the server processes the connection record of the Wi-Fi management APP and outputs the Wi-Fi connection success condition of the Wi-Fi management APP; or processing the connection record of the Wi-Fi management APP to output the successful Wi-Fi connection condition of the Wi-Fi management APP.
After receiving the Wi-Fi connection records of the Wi-Fi management APPs, the server processes the Wi-Fi connection records of the Wi-Fi management APPs so as to determine the successful Wi-Fi connection condition of the Wi-Fi management APPs. The server can also output the Wi-Fi connection success condition of each Wi-Fi management APP to the operator terminal, so that operators optimize each Wi-Fi management APP according to the Wi-Fi connection success condition of each Wi-Fi management APP.
Based on the Wi-Fi connection management system shown in fig. 1, the Wi-Fi connection management method provided by the embodiment of the present invention is described below in terms of a client.
Fig. 2 is a flowchart of a Wi-Fi connection management method according to an embodiment of the present invention, where the method may be applied to an electronic terminal having a Wi-Fi module, and referring to fig. 2, the method may include:
s201: and acquiring a Wi-Fi connection event broadcasted outside by an operating system of the electronic terminal, wherein the Wi-Fi connection event is used for indicating that the Wi-Fi module has processed and completed a Wi-Fi network connection request.
In the process that the Wi-Fi module processes a Wi-Fi network connection request, an operating system of the electronic terminal generates three types of Wi-Fi connection events and broadcasts the events, wherein the events include a connection-in event, a connection-out event and a connection-out event, the connection-in event is used for indicating that the Wi-Fi module is processing the Wi-Fi network connection request, the connection-out event is used for indicating that connection between an initiating terminal and a Wi-Fi network is successfully established, and the connection-out event is used for indicating that connection between the initiating terminal and the Wi-Fi network is not successfully established.
In the process of Wi-Fi network connection request processing by the Wi-Fi module, an operating system of the electronic terminal can continuously broadcast Wi-Fi connection events of the same type for multiple times, and accordingly, a client can continuously monitor the Wi-Fi connection events of the same type for multiple times.
After the client monitors all Wi-Fi connection events in a preset time period, determining Wi-Fi connection events used for indicating that the Wi-Fi module has processed and completed a Wi-Fi network connection request, wherein the Wi-Fi connection events used for indicating that the Wi-Fi module has processed and completed a Wi-Fi network connection request comprise a first connection success event after N connection events and a first connection failure event after N connection events, and N is an integer greater than or equal to 1.
For example, assume that a is a connection event that is monitored by a client, B is a connection success event that is monitored by the client, C is a connection failure event that is monitored by the client, and all Wi-Fi connection events that are monitored by the client in a preset time period are as follows:
AAABBAAAAACAAABCAAACABAAAAABB;
the underlined portion is a Wi-Fi connection event for indicating that the Wi-Fi module has processed a Wi-Fi network connection request.
S202: and acquiring configuration information for recording the Wi-Fi connection event.
The Wi-Fi module of the electronic terminal is responsible for processing Wi-Fi network connection requests sent by an operating system or an application program running on the operating system, and records real processing procedures of the Wi-Fi module on each Wi-Fi network connection request respectively through a plurality of configuration information. After the client acquires the Wi-Fi connection event, the Wi-Fi connection event can be analyzed and processed to determine a Wi-Fi network connection request processed by the Wi-Fi module, and configuration information for recording the Wi-Fi connection event is acquired from the Wi-Fi module of the electronic terminal according to the Wi-Fi network connection request.
As an implementation manner, an identification of a target Wi-Fi to which the Wi-Fi network connection request indicates a connection may be acquired; sending a configuration information acquisition request to the Wi-Fi module, wherein the configuration information acquisition request comprises the identification of the target Wi-Fi; and receiving configuration information corresponding to the target Wi-Fi identifier, which is sent by the Wi-Fi module, wherein the configuration information corresponding to the target Wi-Fi identifier is the configuration information for recording the Wi-Fi connection event.
S203: and analyzing and processing the configuration information so as to determine the name of the application packet of the initiating terminal initiating the Wi-Fi network connection request.
In this embodiment, the analysis processing of the configuration information specifically refers to acquiring a preset field included in the configuration information, and then determining an application packet name of an initiator that initiates a Wi-Fi network connection request according to the preset field. The initiating terminal for initiating the Wi-Fi network connection request may be an operating system of the electronic terminal, or may be an application program running on the operating system of the electronic terminal, when the initiating terminal is the operating system of the electronic terminal, the application packet name of the initiating terminal is a preset application packet name, and when the initiating terminal is the application program running on the operating system of the electronic terminal, the application packet name of the initiating terminal is an application packet name indicated by a target field, and the target field is one field of preset fields. The specific implementation will be described in detail by the following examples.
S204: and generating a Wi-Fi connection record of the initiating terminal, wherein the Wi-Fi connection record of the initiating terminal comprises an application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal.
In this embodiment, the application package name is the name of pkg (installation package configuration file), and the connection result includes two types, one is connection success, and the other is connection failure. The Wi-Fi connection record of the initiating terminal comprises an application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal, and the Wi-Fi connection record is used for indicating that the initiating terminal with the application package name initiates a Wi-Fi network connection request once. The connection result is connection success/failure.
S205: the Wi-Fi connection record of the initiating terminal is sent to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal.
In this embodiment, after generating the Wi-Fi connection record of the initiator, the client may send the Wi-Fi connection record of the initiator to the server, so that the server processes the connection record of the initiator and outputs the successful Wi-Fi connection condition of the initiator. The connection record of the initiating terminal can also be directly processed to output the successful Wi-Fi connection condition of the initiating terminal.
It should be noted that, in the preset time period, the client may generate Wi-Fi connection records of multiple initiator ends, the client or the server may process the Wi-Fi connection records of multiple initiator ends, and output the Wi-Fi connection success condition of multiple initiator ends, where the Wi-Fi connection success condition of each initiator end may be specifically the Wi-Fi connection success rate of the initiator end.
The embodiment discloses a Wi-Fi connection management method, which is applied to an electronic terminal with a Wi-Fi module, wherein after a Wi-Fi connection event for indicating that the Wi-Fi module has processed a Wi-Fi network connection request is monitored, a Wi-Fi connection management client firstly acquires configuration information for recording the Wi-Fi connection event, then analyzes and processes the configuration information, so as to determine an application package name of an initiating terminal for initiating the Wi-Fi network connection request, then generates a Wi-Fi connection record comprising the application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal, and finally sends the Wi-Fi connection record of the initiating terminal to a server, so that the server processes the connection record of the initiating terminal and outputs the Wi-Fi connection success condition of the initiating terminal; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal. In the scheme, after a Wi-Fi network connection request is processed by the Wi-Fi module, a Wi-Fi connection event is generated, after the Wi-Fi connection event is monitored, the Wi-Fi connection management client determines an initiating terminal for initiating the Wi-Fi connection not according to the interface information currently displayed by the electronic terminal, but according to the configuration information for recording the Wi-Fi connection event, and because the configuration information records the real processing process of the Wi-Fi module on the Wi-Fi network connection request, the initiating terminal for initiating the Wi-Fi connection can be accurately determined according to the configuration information, and further the successful Wi-Fi connection condition of the initiating terminal can be accurately determined. By executing the scheme of the application for multiple times, the Wi-Fi connection success condition of each application program running on the operating system of the electronic terminal can be accurately determined.
On the basis of the Wi-Fi connection management method shown in fig. 2, the embodiment of the present invention provides a flowchart of a specific implementation method for analyzing and processing the configuration information to determine an application package name of an initiator that initiates a Wi-Fi network connection request, where the method may be applied to an electronic terminal having a Wi-Fi module, and referring to fig. 3, the method may include:
s301: and acquiring a preset field contained in the configuration information through a reflection technology.
The preset field is a field used for indicating UID (User Identification ) of the application program in the configuration information, and specifically comprises a first field, a second field and a third field; the field value of the first field is used for indicating the UID of the application program creating the configuration information, the field value of the second field is used for indicating the UID of the application program updating the configuration information last, and the field value of the third field is used for indicating the UID of the application program updating the configuration information last. In practical situations, all three fields do not necessarily have field values, but as long as they have field values, the field values are UID of a certain application program.
For example, configuration information recorded in a Wi-Fi module of an electronic terminal with an Android operating system includes: the field value of the createurid field is the UID, lastUpdateUid field value of the APP for creating the configuration information, namely the UID, lastConnectUid field value of the APP for updating the configuration information finally is the UID of the APP for connecting Wi-Fi through the configuration information if the three fields have field values.
It should be noted that, the preset field belongs to a hidden field in the configuration information, and in this embodiment, the preset field included in the configuration information may be obtained by a reflection technique. Reflection technology is one of Java language programming skills, by which non-published APIs or properties can be obtained during Java programming.
S302: and judging whether the preset field has a corresponding application packet name, if the preset field has the corresponding application packet name, executing S303, and if the preset field does not have the corresponding application packet name, executing S304.
When the application program is installed on the electronic terminal, the operating system of the electronic terminal allocates the application program to the electronic terminal, and the UID of the application program has a corresponding relationship with the application package name of the application program. That is, if a certain field has a field value, the field has a corresponding application packet name, and if a certain field does not have a field value, the field does not have a corresponding application packet name. Therefore, judging whether the first field has a corresponding application packet name can specifically judge whether the first field has a field value, if so, determining that the first field has a corresponding application packet name, and if not, determining that the first field does not have a corresponding application packet name. The judgment modes of other fields are similar. That is, in the present embodiment, the field having the field value is the field having the corresponding application packet name.
In this embodiment, it may be determined whether the first field has a field value; judging whether the second field has a field value or not; judging whether the third field has a field value or not; when the first field has a field value, and/or the second field has a field value, and/or the third field has a field value, determining that the preset field has a corresponding application packet name; when the first field does not have a field value, the second field does not have a field value, and the third field does not have a field value, it is determined that the preset field does not have a corresponding application packet name.
It should be noted that, when it is determined that the preset field has a corresponding application packet name, it may be determined that the initiator is an application program running on an operating system of the electronic terminal. When the preset field is determined not to have the corresponding application package name, the initiating terminal can be determined to be an operating system of the electronic terminal.
S303: and determining the name of the application packet of the initiating terminal initiating the Wi-Fi network connection request as the name of the application packet corresponding to the target field in the preset field.
In this embodiment, it may be determined that a field with the highest priority among the fields with field values is a target field, and an application packet name corresponding to the field value of the target field is obtained as an application packet name of the initiator.
In this embodiment, the first field, the second field, and the third field are ordered according to the priority from high to low: the third field, the second field and the first field, when the third field has a field value, determining that the application packet name of the initiating terminal initiating the Wi-Fi network connection request is the application packet name corresponding to the field value of the third field; when the third field does not have a field value and the second field has a field value, determining that the application packet name of the initiating terminal initiating the Wi-Fi network connection request is the application packet name corresponding to the field value of the second field; when the third field does not have a field value, the second field does not have a field value, and the first field has a field value, determining that the application packet name of the initiating end initiating the Wi-Fi network connection request is the application packet name corresponding to the field value of the first field.
In this embodiment, the application packet name corresponding to the field value of the target field is obtained, that is, the field value of the target field is converted into the corresponding application packet name according to the corresponding relationship between the preset application UID and the application packet name.
S304: and determining the name of an application package of an initiating terminal initiating the Wi-Fi network connection request as a preset application package name.
When the initiating terminal is an operating system of the electronic terminal, the preset field in the configuration information does not have a field value, and at the moment, the name of the application package of the initiating terminal initiating the Wi-Fi network connection request can be determined to be the preset application package name.
Examples are: for an Android electronic terminal of an operating system, firstly converting the Android electronic terminal into an application package name pkg through a lastConnecteUid field, if the conversion is unsuccessful, using a lastUpdateUid field, and secondly, converting the priority to be: lastconnectiduid field > lastUpdateUid field > createuid field. If both the conversions are unsuccessful, it is considered an operating system initiated connection of the electronic terminal, at which point the application package name pkg uses the default value "com.
On the basis of the Wi-Fi connection management method shown in fig. 2, the embodiment of the present invention provides a flowchart of a specific implementation method for processing a connection record of the initiator and outputting a Wi-Fi connection success condition of the initiator, where the method can be applied to an electronic terminal having a Wi-Fi module, and referring to fig. 4, the method may include:
s401: and processing the connection record of the initiating terminal to determine the successful Wi-Fi connection condition of the initiating terminal, and generating a first result, wherein the first result comprises the application package name of the initiating terminal and the successful Wi-Fi connection condition of the initiating terminal.
In this embodiment, the processing of Wi-Fi connection records of multiple initiator ends by the server or the client specifically refers to determining Wi-Fi connection success rates of multiple initiator ends by means of aggregation query, and generating a first result, where the first result specifically includes application package names of each initiator end and Wi-Fi connection success rates corresponding to each application package name.
For example, the Wi-Fi connection success rate of the target initiator with the application package name of pkg is:
count (pkg), success)/count (pkg)
Wherein count (pkg) =count (pkg, success) +count (pkg, failure)
S402: and determining the application name corresponding to the application package name of the initiating terminal according to the preset corresponding relation between the application package name and the application name.
In this embodiment, the corresponding relationship between the application package name and the application name may be preset in the server or the client, and as an implementation manner, the operator may bind the application package name and the corresponding application name and then configure the binding to the database server.
For example, the correspondence between the preset application package name and the application name is as follows:
com.tent.wifimanager → Tencerting WiFi housekeeping
com.snda.wifilocing→WiFi master key
com.qihoo360.mobilesafe → 360 mobile phone guard
com.android.setting→android system
The left side of the arrow is an application package name, and the right side of the arrow is an application name corresponding to the application package name.
After the server or the client generates the first result, a corresponding relation between the preset application package name and the application name can be obtained from the database server, and the application name corresponding to the application package name of the initiating terminal is determined according to the corresponding relation between the preset application package name and the application name.
S403: and generating a second result, wherein the second result comprises the application name of the initiating terminal and the Wi-Fi connection success condition of the initiating terminal.
After the server or the client determines the application name corresponding to the application package name of the initiator, a second result can be generated, wherein the second result specifically comprises the application name of each initiator and the Wi-Fi connection success rate corresponding to the application name.
S404: outputting the first result and the second result.
After the server or the client generates the first result and the second result, the first result and the second result can be output to the operator terminal, and the operator obtains the Wi-Fi connection success condition of each initiator according to the first result and the second result. Referring to fig. 5, fig. 5 is a schematic diagram of an output example of a first result and a second result provided in an embodiment of the present application, where Wi-Fi connection success conditions of each initiator are recorded in the output.
Preferably, the server or the client can also screen out the target application package name without the application name by comparing the first result and the second result, generate prompt information and send the prompt information to the operator terminal, and the operator binds the corresponding application name for the target application package name without the application package name.
The Wi-Fi connection management device provided by the embodiment of the present invention is described below, and the Wi-Fi connection management device described below can be referred to correspondingly to the Wi-Fi connection management method.
Fig. 6 is a block diagram of a Wi-Fi connection management device according to an embodiment of the present invention, where the Wi-Fi connection management device may specifically be a Wi-Fi connection management client, and referring to fig. 6, the device may include:
a Wi-Fi connection event obtaining unit 61, configured to obtain a Wi-Fi connection event broadcasted from an operating system of the electronic terminal, where the Wi-Fi connection event is used to indicate that the Wi-Fi module has processed and completed a Wi-Fi network connection request;
a configuration information obtaining unit 62, configured to obtain configuration information for recording the Wi-Fi connection event;
an application packet name determining unit 63, configured to analyze and process the configuration information, so as to determine an application packet name of an originating terminal that initiates the Wi-Fi network connection request;
A Wi-Fi connection record generating unit 64, configured to generate a Wi-Fi connection record of the initiator, where the Wi-Fi connection record of the initiator includes an application package name of the initiator and a Wi-Fi connection result of the initiator;
an output unit 65, configured to send the Wi-Fi connection record of the initiator to a server, so that the server processes the connection record of the initiator and outputs a Wi-Fi connection success condition of the initiator; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal.
In some optional implementations of this embodiment, the configuration information obtaining unit specifically includes:
the identification acquisition subunit of the target Wi-Fi is used for acquiring the identification of the target Wi-Fi, which is connected by the Wi-Fi network connection request indication;
a request sending subunit, configured to send a configuration information obtaining request to the Wi-Fi module, where the configuration information obtaining request includes an identifier of the target Wi-Fi;
the configuration information receiving subunit is configured to receive configuration information corresponding to the target Wi-Fi identifier sent by the Wi-Fi module, where the configuration information corresponding to the target Wi-Fi identifier is configuration information for recording the Wi-Fi connection event.
In some optional implementations of the present embodiment, the application package name determining unit includes:
a preset field obtaining subunit, configured to obtain a preset field included in the configuration information through a reflection technology;
the judging subunit is used for judging whether the preset field has a corresponding application packet name or not;
the first determining unit is used for determining that the application packet name of the initiating terminal initiating the Wi-Fi network connection request is the application packet name corresponding to the target field in the preset field if the preset field has the corresponding application packet name;
and the second determining unit is used for determining that the application packet name of the initiating terminal initiating the Wi-Fi network connection request is the preset application packet name if the preset field does not have the corresponding application packet name.
In some optional implementations of this embodiment, the preset field obtaining subunit is specifically configured to:
acquiring a first field, a second field and a third field contained in the configuration information through a reflection technology; the field value of the first field is used for indicating the UID of the application program creating the configuration information, the field value of the second field is used for indicating the UID of the application program updating the configuration information last, and the field value of the third field is used for indicating the UID of the application program updating the configuration information last.
In some optional implementations of this embodiment, the determining subunit is specifically configured to:
judging whether the first field has a field value or not;
judging whether the second field has a field value or not;
judging whether the third field has a field value or not;
when the first field has a field value, and/or the second field has a field value, and/or the third field has a field value, determining that the preset field has a corresponding application packet name;
when the first field does not have a field value, the second field does not have a field value, and the third field does not have a field value, it is determined that the preset field does not have a corresponding application packet name.
In some optional implementations of the present embodiment, the first determining subunit is specifically configured to:
determining the field with highest priority among the fields with field values as a target field;
and taking the application packet name corresponding to the field value of the target field as the application packet name of the initiating terminal.
In some optional implementations of this embodiment, the output unit specifically includes:
the first result generation subunit is used for processing the connection record of the initiating terminal to determine the successful Wi-Fi connection condition of the initiating terminal, and generating a first result, wherein the first result comprises the application package name of the initiating terminal and the successful Wi-Fi connection condition of the initiating terminal;
An application name determining subunit, configured to determine an application name corresponding to the application package name of the initiator according to a preset correspondence between the application package name and the application name;
a second result generating subunit, configured to generate a second result, where the second result includes an application name of the initiator and a Wi-Fi connection success condition of the initiator;
and the output subunit is used for outputting the first result and the second result.
It should be noted that, the specific functional implementation of each unit is described in detail in the foregoing embodiments, and this embodiment is not repeated.
On the other hand, the present application further provides an electronic terminal, referring to fig. 7, which shows a schematic structural diagram of the electronic terminal of the present application, an electronic terminal 700 of the present embodiment may include: a processor 701 and a memory 702.
Optionally, the electronic terminal may further comprise a communication interface 703, an input unit 704 and a display 705 and a communication bus 706.
The processor 701, the memory 702, the communication interface 703, the input unit 704, the display 705, all perform communication with each other via the communication bus 706.
In an embodiment of the present application, the processor 701 may be a central processing unit (Central Processing Unit, CPU), an asic, a dsp, an off-the-shelf programmable gate array, or other programmable logic device.
The processor may call programs stored in the memory 702. Specifically, the processor may perform operations performed by the electronic terminal in an embodiment of the Wi-Fi connection management method.
The memory 702 is used to store one or more programs, and the programs may include program code that includes computer operation instructions, and in embodiments of the present application, at least the programs for implementing the following functions are stored in the memory:
acquiring a Wi-Fi connection event broadcasted outside by an operating system of the electronic terminal, wherein the Wi-Fi connection event is used for indicating that the Wi-Fi module has processed a Wi-Fi network connection request;
acquiring configuration information for recording the Wi-Fi connection event;
analyzing and processing the configuration information so as to determine the name of an application packet of an initiating terminal initiating the Wi-Fi network connection request;
generating a Wi-Fi connection record of the initiating terminal, wherein the Wi-Fi connection record of the initiating terminal comprises an application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal;
the Wi-Fi connection record of the initiating terminal is sent to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal; or processing the connection record of the initiating terminal to output the successful Wi-Fi connection condition of the initiating terminal.
In one possible implementation, the memory 702 may include a storage program area and a storage data area, where the storage program area may store an operating system, and at least one application program required for a function (such as an image playing function, etc.), and so on; the storage data area may store data created during use of the computer, such as user data, user access data, and audio, video, image data, and the like.
In addition, the memory 702 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device or other volatile solid-state storage device.
The communication interface 703 may be an interface of a communication module, such as an interface of a GSM module.
The application may also include a display 704 and an input unit 705, etc.
Of course, the structure of the electronic terminal shown in fig. 7 is not limited to the electronic terminal in the embodiment of the present application, and the electronic terminal may include more or less components than those shown in fig. 7 or may combine some components in practical applications.
On the other hand, the embodiment of the application also provides a storage medium, wherein computer executable instructions are stored in the storage medium, and when the computer executable instructions are loaded and executed by a processor, the Wi-Fi connection management method in any one of the embodiments is realized.
It should be noted that, in the present specification, each embodiment is described in a progressive manner, and each embodiment is mainly described as different from other embodiments, and identical and similar parts between the embodiments are all enough to be referred to each other. For the apparatus class embodiments, the description is relatively simple as it is substantially similar to the method embodiments, and reference is made to the description of the method embodiments for relevant points.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or electronic terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or electronic terminal. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or electronic terminal comprising the element.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
The foregoing is merely a preferred embodiment of the present invention and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present invention, which are intended to be comprehended within the scope of the present invention.

Claims (10)

1. The Wi-Fi connection management method is applied to an electronic terminal with a Wi-Fi module and is characterized by comprising the following steps:
acquiring a Wi-Fi connection event broadcasted from an operating system of an electronic terminal outwards, wherein the Wi-Fi connection event is used for indicating that a Wi-Fi network connection request is processed and completed by the Wi-Fi module;
acquiring configuration information for recording the Wi-Fi connection event;
Analyzing and processing the configuration information so as to determine the name of an application package of an initiating terminal initiating the Wi-Fi network connection request;
generating a Wi-Fi connection record of the initiating terminal, wherein the Wi-Fi connection record of the initiating terminal comprises an application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal;
processing the connection record of the initiating terminal through the electronic terminal to output the successful Wi-Fi connection condition of the initiating terminal; or sending the Wi-Fi connection record of the initiating terminal to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal.
2. The method of claim 1, wherein the obtaining configuration information recording the Wi-Fi connection event comprises:
acquiring an identification of a target Wi-Fi of which the Wi-Fi network connection request indicates connection;
sending a configuration information acquisition request to the Wi-Fi module, wherein the configuration information acquisition request comprises the identification of the target Wi-Fi;
and receiving configuration information corresponding to the target Wi-Fi identifier, which is sent by the Wi-Fi module, wherein the configuration information corresponding to the target Wi-Fi identifier is the configuration information for recording the Wi-Fi connection event.
3. The method of claim 2, wherein the analyzing the configuration information to determine the application package name of the initiator that originated the Wi-Fi network connection request comprises:
acquiring preset fields contained in the configuration information through a reflection technology;
judging whether the preset field has a corresponding application packet name or not;
if the preset field has a corresponding application packet name, determining that the application packet name of the initiating terminal initiating the Wi-Fi network connection request is the application packet name corresponding to the target field in the preset field;
and if the preset field does not have the corresponding application packet name, determining that the application packet name of the initiating terminal initiating the Wi-Fi network connection request is the preset application packet name.
4. A method according to claim 3, wherein said obtaining, by reflection, a preset field included in said configuration information comprises:
acquiring a first field, a second field and a third field contained in the configuration information through a reflection technology; the field value of the first field is used for indicating the UID of the application program creating the configuration information, the field value of the second field is used for indicating the UID of the application program updating the configuration information last, and the field value of the third field is used for indicating the UID of the application program updating the configuration information last.
5. The method of claim 4, wherein the determining whether the preset field has a corresponding application package name comprises:
judging whether the first field has a field value or not;
judging whether the second field has a field value or not;
judging whether the third field has a field value or not;
when the first field has a field value, and/or the second field has a field value, and/or the third field has a field value, determining that the preset field has a corresponding application packet name;
and when the first field does not have a field value, the second field does not have a field value, and the third field does not have a field value, determining that the preset field does not have a corresponding application packet name.
6. The method of claim 5, wherein the determining that the application packet name of the initiator that initiates the Wi-Fi network connection request is the application packet name corresponding to the target field in the preset field comprises:
determining the field with highest priority among the fields with field values as a target field;
and taking the application packet name corresponding to the field value of the target field as the application packet name of the initiating terminal.
7. The method according to claim 1, wherein the processing the connection record of the initiator and outputting the successful Wi-Fi connection of the initiator includes:
processing the connection record of the initiating terminal to determine the successful Wi-Fi connection condition of the initiating terminal, and generating a first result, wherein the first result comprises an application package name of the initiating terminal and the successful Wi-Fi connection condition of the initiating terminal;
determining an application name corresponding to the application package name of the initiating terminal according to a preset corresponding relation between the application package name and the application name;
generating a second result, wherein the second result comprises an application name of the initiating terminal and a Wi-Fi connection success condition of the initiating terminal;
and outputting the first result and the second result.
8. A Wi-Fi connection management apparatus applied to an electronic terminal having a Wi-Fi module, comprising:
the Wi-Fi connection event acquisition unit is used for acquiring Wi-Fi connection events broadcasted outside by an operating system of the electronic terminal, wherein the Wi-Fi connection events are used for indicating that the Wi-Fi module has processed and completed a Wi-Fi network connection request;
the configuration information acquisition unit is used for acquiring and recording the configuration information of the Wi-Fi connection event;
The application packet name determining unit is used for analyzing and processing the configuration information so as to determine the application packet name of the initiating terminal initiating the Wi-Fi network connection request;
a Wi-Fi connection record generating unit, configured to generate a Wi-Fi connection record of the initiator, where the Wi-Fi connection record of the initiator includes an application package name of the initiator and a Wi-Fi connection result of the initiator;
the output unit is used for processing the connection record of the initiating terminal through the electronic terminal so as to output the Wi-Fi connection success condition of the initiating terminal; or sending the Wi-Fi connection record of the initiating terminal to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal.
9. An electronic terminal, comprising:
a processor and a memory;
wherein the processor is configured to execute a program stored in the memory;
the memory is used for storing a program, and the program is used for at least:
acquiring a Wi-Fi connection event broadcasted from an operating system of an electronic terminal outwards, wherein the Wi-Fi connection event is used for indicating that a Wi-Fi network connection request is processed and completed by the Wi-Fi module;
Acquiring configuration information for recording the Wi-Fi connection event;
analyzing and processing the configuration information so as to determine the name of an application package of an initiating terminal initiating the Wi-Fi network connection request;
generating a Wi-Fi connection record of the initiating terminal, wherein the Wi-Fi connection record of the initiating terminal comprises an application package name of the initiating terminal and a Wi-Fi connection result of the initiating terminal;
processing the connection record of the initiating terminal through the electronic terminal to output the successful Wi-Fi connection condition of the initiating terminal; or sending the Wi-Fi connection record of the initiating terminal to a server, so that the server processes the connection record of the initiating terminal and outputs the successful Wi-Fi connection condition of the initiating terminal.
10. A storage medium having stored therein computer executable instructions which when loaded and executed by a processor implement the Wi-Fi connection management method of any of the preceding claims 1 to 7.
CN201910759322.7A 2019-08-16 2019-08-16 Wi-Fi connection management method and device, electronic terminal and storage medium Active CN110351767B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910759322.7A CN110351767B (en) 2019-08-16 2019-08-16 Wi-Fi connection management method and device, electronic terminal and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910759322.7A CN110351767B (en) 2019-08-16 2019-08-16 Wi-Fi connection management method and device, electronic terminal and storage medium

Publications (2)

Publication Number Publication Date
CN110351767A CN110351767A (en) 2019-10-18
CN110351767B true CN110351767B (en) 2023-11-03

Family

ID=68185310

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910759322.7A Active CN110351767B (en) 2019-08-16 2019-08-16 Wi-Fi connection management method and device, electronic terminal and storage medium

Country Status (1)

Country Link
CN (1) CN110351767B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107229619A (en) * 2016-03-23 2017-10-03 阿里巴巴集团控股有限公司 Internet service link calls statistics, methods of exhibiting and the device of situation
CN108307414A (en) * 2017-12-12 2018-07-20 广东小天才科技有限公司 Wi-Fi connection abnormality eliminating method, device, terminal and the storage medium of application program
CN108471623A (en) * 2018-06-12 2018-08-31 Oppo广东移动通信有限公司 WiFi connections method of adjustment, device, mobile terminal and storage medium

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101341710B (en) * 2005-12-16 2013-06-05 诺基亚公司 Supporting for integrated WLAN hot customer terminal
CN102752792B (en) * 2011-12-26 2015-08-19 华为技术有限公司 Method, the equipment and system of monitoring mobile terminal Internet access quality of service
CN104684048B (en) * 2015-03-04 2019-06-04 小米科技有限责任公司 WIFI list shows method and apparatus

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107229619A (en) * 2016-03-23 2017-10-03 阿里巴巴集团控股有限公司 Internet service link calls statistics, methods of exhibiting and the device of situation
CN108307414A (en) * 2017-12-12 2018-07-20 广东小天才科技有限公司 Wi-Fi connection abnormality eliminating method, device, terminal and the storage medium of application program
CN108471623A (en) * 2018-06-12 2018-08-31 Oppo广东移动通信有限公司 WiFi connections method of adjustment, device, mobile terminal and storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Longbiao Chen,Leye Wang,etc..EnUp: Energy-Efficient Data Uploading for Mobile Crowd Sensing Applications.2016 Intl IEEE Conferences on Ubiquitous Intelligence.2016,1074-1078. *
一个面向实时传输的应用层组播协议的设计;陈旭孟;张卫;;计算机应用与软件(09);全文 *

Also Published As

Publication number Publication date
CN110351767A (en) 2019-10-18

Similar Documents

Publication Publication Date Title
US10423958B2 (en) Method, apparatus and system for voice verification
CN105120299B (en) Video pushing method and device
CN108509523B (en) Method and device for structured processing of block chain data and readable storage medium
CN112152853A (en) Equipment network distribution method and device, computer-readable storage medium and electronic device
WO2017101297A1 (en) Method and device for video messaging, terminal, and server
CN104756080A (en) Augmenting capabilities of a host device
CN111258723B (en) Transaction processing method, device, system, medium and equipment of distributed system
WO2016127612A1 (en) Monitoring processing method and device
CN105323128B (en) method, device and system for accessing front-end equipment to server
WO2011150885A2 (en) Method and device for managing voice message
CN114039961A (en) Message pushing method, device, server and storage medium based on WebSocket
CN110351767B (en) Wi-Fi connection management method and device, electronic terminal and storage medium
CN107425994B (en) Method, terminal and server for realizing remote parameter management
WO2020044092A9 (en) Data transmission method and apparatus thereof
CN110825797B (en) Data exchange method and device
CN112954669A (en) Method, device, network element and storage medium for controlling service of shared terminal
US20200304627A1 (en) Incoming Voice Calling Method and Terminal
CN113660359A (en) Management method and device for domain name resolution record, storage medium and electronic equipment
CN117240925B (en) Flow recording method and device, storage medium and computer equipment
CN110891247B (en) Method, system, equipment and medium for client stateless access cluster
CN106331270B (en) Method and device for managing numbers of contact persons
CN110619195B (en) Authority application processing method, device, equipment and storage medium
CN116634384B (en) Terminal equipment searching method, system and storage medium thereof
CN113992732B (en) Terminal management control method, device, server and storage medium
CN112291209B (en) Method and device for acquiring front-end equipment catalog

Legal Events

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