CN114302399B - Control method and device for WIFI sharing hot spot and storage medium - Google Patents

Control method and device for WIFI sharing hot spot and storage medium Download PDF

Info

Publication number
CN114302399B
CN114302399B CN202111536696.6A CN202111536696A CN114302399B CN 114302399 B CN114302399 B CN 114302399B CN 202111536696 A CN202111536696 A CN 202111536696A CN 114302399 B CN114302399 B CN 114302399B
Authority
CN
China
Prior art keywords
mode
wireless network
network card
target state
hot spot
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
CN202111536696.6A
Other languages
Chinese (zh)
Other versions
CN114302399A (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.)
Qianxin Technology Group Co Ltd
Secworld Information Technology Beijing Co Ltd
Original Assignee
Qianxin Technology Group Co Ltd
Secworld Information Technology 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 Qianxin Technology Group Co Ltd, Secworld Information Technology Beijing Co Ltd filed Critical Qianxin Technology Group Co Ltd
Priority to CN202111536696.6A priority Critical patent/CN114302399B/en
Publication of CN114302399A publication Critical patent/CN114302399A/en
Application granted granted Critical
Publication of CN114302399B publication Critical patent/CN114302399B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The application discloses a control method and device of a WIFI sharing hotspot, a storage medium and computer equipment, wherein the method comprises the following steps: responding to a user state program starting instruction, calling a target state reading interface, and determining an operation mode of the wireless network card through the target state reading interface; and when the operation mode of the wireless network card is a sharing hot spot mode, calling a target state setting interface, and changing the operation mode of the wireless network card into a signal receiving mode through the target state setting interface so as to close the WIFI sharing hot spot corresponding to the wireless network card. According to the method and the device, the running mode of the wireless network card is determined by calling the target state reading interface, and the sharing hot spot of the wireless network card is closed by calling the target state setting interface, so that unauthorized terminal equipment can be effectively prevented from accessing the intranet through the WIFI sharing hot spot, and the safety of the intranet environment and internal data is greatly improved.

Description

Control method and device for WIFI sharing hot spot and storage medium
Technical Field
The application relates to the technical field of wireless transmission, in particular to a control method and device for a WIFI sharing hotspot, a storage medium and computer equipment.
Background
With the continuous development of the internet, a sharing hot spot function has been developed. For convenience of network connection, many terminal devices have a function of opening a sharing hot spot, for example, the sharing hot spot is opened for a computer terminal through a mobile phone terminal, so as to realize wireless network connection of a computer, and the like, so that the convenience of network connection is greatly improved due to the sharing hot spot function.
However, in daily work, many terminal devices connect to the intranet and open a sharing hotspot for other terminal devices, which creates a great risk for the intranet environment and security of internal data.
Disclosure of Invention
In view of this, the present application provides a control method and apparatus for a WIFI sharing hotspot, a storage medium, and a computer device, which can effectively avoid an unauthorized terminal device from accessing an intranet through the WIFI sharing hotspot, thereby greatly improving the security of the intranet environment and internal data.
According to one aspect of the present application, there is provided a control method of a WIFI sharing hotspot, including:
responding to a user state program starting instruction, calling a target state reading interface, and determining an operation mode of the wireless network card through the target state reading interface;
And when the operation mode of the wireless network card is a sharing hot spot mode, calling a target state setting interface, and changing the operation mode of the wireless network card into a signal receiving mode through the target state setting interface so as to close the WIFI sharing hot spot corresponding to the wireless network card.
Optionally, after the determining, by the target state reading interface, the operation mode of the wireless network card, the method further includes: when the running mode of the wireless network card is the signal receiving mode, starting a first timing device, and returning to the step of calling the target state reading interface when the time recorded by the first timing device is consistent with a first preset time interval; or,
after the operation mode of the wireless network card is changed into the signal receiving mode through the target state setting interface, the method further comprises: and starting a second timing device, and returning to the step of calling the target state reading interface when the time recorded by the second timing device is consistent with the first preset time interval.
Optionally, the method further comprises:
responding to a kernel mode program starting instruction, monitoring operation data of a preset device management function in real time, calling a preset interception function to intercept the operation data when the operation data is monitored, and checking the intercepted operation data through the preset interception function;
When the operation data is the operation data corresponding to the operation mode of the wireless network card modified to the sharing hot spot mode, terminating the transmission of the operation data;
and when the operation data is not the operation data corresponding to the mode of modifying the operation mode of the wireless network card into the sharing hot spot mode, releasing the operation data.
Optionally, after the responding to the user mode program start instruction, the method further comprises:
monitoring the kernel mode program starting instruction in real time, calling the target state reading interface after the kernel mode program starting instruction is monitored, and determining the running mode of the wireless network card through the target state reading interface;
returning to the step of calling a target state setting interface when the running mode of the wireless network card is the sharing hot spot mode;
and when the running mode of the wireless network card is the signal receiving mode, closing the first timing device or the second timing device.
Optionally, after the first timing device or the second timing device is turned off, the method further comprises:
continuously monitoring the running data of the kernel mode program, and restarting the first timing device or the second timing device when the idle time of the running data is not monitored to be longer than the preset idle time.
Optionally, after the operation mode of the wireless network card is the sharing hot spot mode, the method further includes:
determining an access equipment identifier of the WIFI sharing hotspot of the wireless network card, and acquiring a preset permission identifier list;
and executing the call target state setting interface when the preset permission identification list does not comprise the access equipment identification.
Optionally, after the operation mode of the wireless network card is changed to the signal receiving mode through the target state setting interface, the method further includes:
recording the changing times of the wireless network card running mode, and replacing the first preset time interval by using a second preset time interval when the changing times are larger than a preset time threshold, wherein the first preset time interval is larger than the second preset time interval.
According to another aspect of the present application, there is provided a control apparatus for a WIFI sharing hotspot, including:
the running mode determining module is used for responding to a user state program starting instruction, calling a target state reading interface and determining the running mode of the wireless network card through the target state reading interface;
and the operation mode changing module is used for calling a target state setting interface when the operation mode of the wireless network card is a sharing hot spot mode, and changing the operation mode of the wireless network card into a signal receiving mode through the target state setting interface so as to close the WIFI sharing hot spot corresponding to the wireless network card.
Optionally, the apparatus further comprises:
the timing module is used for starting a first timing device when the running mode of the wireless network card is the signal receiving mode after the running mode of the wireless network card is determined through the target state reading interface, and returning to the step of calling the target state reading interface when the time recorded by the first timing device is consistent with a first preset time interval; or after the operation mode of the wireless network card is changed into the signal receiving mode through the target state setting interface, starting a second timing device, and returning to the step of calling the target state reading interface when the time recorded by the second timing device is consistent with the first preset time interval.
Optionally, the apparatus further comprises:
the monitoring module is used for responding to a kernel mode program starting instruction, monitoring operation data of a preset device management function in real time, calling a preset interception function to intercept the operation data when the operation data is monitored, and checking the intercepted operation data through the preset interception function;
the termination module is used for terminating the transmission of the operation data when the operation data is the operation data corresponding to the operation mode of the wireless network card modified to the sharing hot spot mode;
And the release module is used for releasing the operation data when the operation data is not the operation data corresponding to the mode of modifying the operation mode of the wireless network card into the sharing hot spot mode.
Optionally, the apparatus further comprises:
the monitoring module is further configured to monitor the kernel mode program start instruction in real time after the response to the user mode program start instruction, and call the target state reading interface after the kernel mode program start instruction is monitored, and determine an operation mode of the wireless network card through the target state reading interface;
the operation mode determining module is further configured to return to the step of calling the target state setting interface when the operation mode of the wireless network card is the shared hot spot mode;
and the closing module is used for closing the first timing device or the second timing device when the running mode of the wireless network card is the signal receiving mode.
Optionally, the apparatus further comprises:
and the starting module is used for continuously monitoring the running data of the kernel mode program after the first timing device or the second timing device is closed, and restarting the first timing device or the second timing device when the idle time of the running data is not monitored to be longer than the preset idle time.
Optionally, the apparatus further comprises:
the list acquisition module is used for determining an access equipment identifier of the wireless network card WIFI sharing hotspot after the operation mode of the wireless network card is a sharing hotspot mode, and acquiring a preset permission identifier list;
the operation mode determining module is further configured to execute the call target state setting interface when the preset permission identifier list does not include the access device identifier.
Optionally, the apparatus further comprises:
the recording module is used for recording the changing times of the wireless network card operation mode after changing the wireless network card operation mode into the signal receiving mode through the target state setting interface, and replacing the first preset time interval by using a second preset time interval when the changing times are larger than a preset time threshold, wherein the first preset time interval is larger than the second preset time interval.
According to still another aspect of the present application, there is provided a storage medium having stored thereon a computer program, which when executed by a processor, implements the control method of the WIFI sharing hotspot described above.
According to still another aspect of the present application, there is provided a computer device, including a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor, where the processor implements the control method of the WIFI sharing hotspot when executing the program.
By means of the technical scheme, the control method and device, the storage medium and the computer equipment for the WIFI sharing hot spot can respond to the user state program starting instruction and call the target state reading interface when the user state program starting instruction is received. And then, determining the running mode of the current wireless network card through the called target state reading interface. When the operation mode of the wireless network card is determined to be the sharing hot spot mode through the target state reading interface, the target state setting interface can be further called, the WIFI sharing hot spot of the wireless network card is closed through the target state setting interface, and the operation mode of the wireless network card is changed from the sharing hot spot mode to the signal receiving mode. According to the method and the device, the running mode of the wireless network card is determined by calling the target state reading interface, and the sharing hot spot of the wireless network card is closed by calling the target state setting interface, so that unauthorized terminal equipment can be effectively prevented from accessing the intranet through the WIFI sharing hot spot, and the safety of the intranet environment and internal data is greatly improved.
The foregoing description is only an overview of the technical solutions of the present application, and may be implemented according to the content of the specification in order to make the technical means of the present application more clearly understood, and in order to make the above-mentioned and other objects, features and advantages of the present application more clearly understood, the following detailed description of the present application will be given.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiments of the application and together with the description serve to explain the application and do not constitute an undue limitation to the application. In the drawings:
fig. 1 is a flow chart illustrating a control method of a WIFI sharing hotspot according to an embodiment of the present application;
fig. 2 is a flow chart illustrating another control method of a WIFI sharing hotspot according to an embodiment of the present application;
fig. 3 is a flow chart illustrating another control method of a WIFI sharing hotspot according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a control device of a WIFI sharing hotspot according to an embodiment of the present application;
fig. 5 shows a schematic physical structure of a computer device according to an embodiment of the present application.
Detailed Description
The present application will be described in detail hereinafter with reference to the accompanying drawings in conjunction with embodiments. It should be noted that, in the case of no conflict, the embodiments and features in the embodiments may be combined with each other.
In this embodiment, a control method for a WIFI sharing hotspot is provided, as shown in fig. 1, where the method includes:
Step 101, responding to a user state program starting instruction, calling a target state reading interface, and determining an operation mode of the wireless network card through the target state reading interface;
at present, operating systems such as a Windows operating system, a Linux operating system and the like comprise a kernel mode and a user mode. Because of the need to limit the access capability between different programs, they are prevented from acquiring memory data of other programs or acquiring data of peripheral devices and sending the data to a network, and the CPU divides two authority levels, namely a user mode and a kernel mode. When the program executes the system call and is trapped into the kernel code for execution, the kernel mode program is called, and when the program executes the code of the user, the user mode program is called. The WIFI sharing hotspot control method provided by the embodiment of the application can be particularly applied to a Linux operating system. First, when a user mode program start instruction is received, the user mode program start instruction may be responded, and a target state read interface may be called, where the target state read interface may be a system API interface. And then, determining the running mode of the current wireless network card through the called target state reading interface. The target state reading interface may be a system API interface.
Step 102, when the operation mode of the wireless network card is a sharing hotspot mode, a target state setting interface is invoked, and the operation mode of the wireless network card is changed into a signal receiving mode through the target state setting interface so as to close a WIFI sharing hotspot corresponding to the wireless network card.
In this embodiment, the operation mode of the wireless network card may be a signal receiving mode or a shared hot spot mode, where the signal receiving mode refers to a normal signal receiving mode, i.e. a managed mode, and the shared hot spot mode refers to a hot spot transmitting signal mode, i.e. a master mode. When the running mode of the wireless network card is determined to be the sharing hot spot mode through the target state reading interface, the fact that the wireless network card is transmitting hot spot signals for other terminal equipment is indicated, so that unauthorized terminal equipment is easily illegally accessed into the intranet, and great threat is caused to the intranet environment and data security. Therefore, the target state setting interface can be further called, the WIFI sharing hot spot of the wireless network card is closed through the target state setting interface, and the running mode of the wireless network card is changed from the sharing hot spot mode to the signal receiving mode. Here, the terminal device for starting the WIFI sharing hotspot may be accessed to the intranet through a wired network, or may be accessed to the intranet through the wireless network card after the wireless network card is restored to the signal receiving mode, which is not required herein.
By applying the technical scheme of the embodiment, firstly, when a user state program starting instruction is received, the user state program starting instruction can be responded, and the target state reading interface is called. And then, determining the running mode of the current wireless network card through the called target state reading interface. When the operation mode of the wireless network card is determined to be the sharing hot spot mode through the target state reading interface, the target state setting interface can be further called, the WIFI sharing hot spot of the wireless network card is closed through the target state setting interface, and the operation mode of the wireless network card is changed from the sharing hot spot mode to the signal receiving mode. According to the method and the device, the running mode of the wireless network card is determined by calling the target state reading interface, and the sharing hot spot of the wireless network card is closed by calling the target state setting interface, so that unauthorized terminal equipment can be effectively prevented from accessing the intranet through the WIFI sharing hot spot, and the safety of the intranet environment and internal data is greatly improved.
Further, as a refinement and extension of the foregoing embodiment, in order to fully describe a specific implementation procedure of the embodiment, another control method of a WIFI sharing hotspot is provided, as shown in fig. 2, where the method includes:
Step 201, responding to a user state program starting instruction, calling a target state reading interface, and determining an operation mode of the wireless network card through the target state reading interface;
in the embodiment of the application, when the user mode program starting instruction is received, the user mode program starting instruction can be responded, and the target state reading interface is called, wherein the target state reading interface can be a system API interface. And then, determining the running mode of the current wireless network card through the called target state reading interface.
Step 202, when the operation mode of the wireless network card is a sharing hotspot mode, determining an access device identifier of the wireless network card WIFI sharing hotspot, and acquiring a preset permission identifier list;
in the embodiment of the application, when the running mode of the wireless network card is determined to be the sharing hotspot mode through the target state reading interface, the fact that the wireless network card is starting the WIFI sharing hotspot for other terminal equipment is indicated, so that unauthorized terminal equipment is easy to illegally access the intranet, and great threat is caused to the intranet environment and data security. Thus, the device identifier corresponding to the terminal device accessing the WIFI sharing hotspot can be determined, where the access device identifier corresponds to the accessed device one-to-one. Meanwhile, a preset permission identification list can be obtained, the preset permission identification list can comprise identifications corresponding to the terminal equipment with access permission, and the terminal equipment corresponding to the identifications contained in the preset permission identification list can be accessed into the WIFI sharing hot spot of the wireless network card.
Step 203, when the preset permission identifier list does not include the access device identifier, a target state setting interface is invoked, and the operation mode of the wireless network card is changed into a signal receiving mode through the target state setting interface, so as to close a WIFI sharing hotspot corresponding to the wireless network card;
in this embodiment, when the access device identifier corresponding to the accessed terminal device is not included in the preset permission identifier list, it is indicated that the terminal device does not have permission to access the WIFI sharing hotspot, and at this time, the target state setting interface may be invoked, and the WIFI sharing hotspot corresponding to the wireless network card is closed by using the target state setting interface, so that the operation mode of the wireless network card is changed into the signal receiving mode. According to the embodiment of the application, the terminal equipment with the access WIFi sharing hot spot permission can be accessed into the intranet by setting the preset permission identification list, so that the safety of the intranet environment and internal data can be ensured on one hand, and on the other hand, the terminal equipment needing the network can be connected with the intranet to ensure the normal networking of the safe terminal equipment.
In addition, when the access device identifier is greater than one and the preset permission identifier list contains a part of the access device identifiers, the target state setting interface is called, the WIFi sharing hot spot corresponding to the wireless network card is closed through the target state setting interface, the operation mode of the wireless network card is changed into a signal receiving mode, and the access device identifiers which are not contained in the preset permission identifier list are reported.
In this embodiment, when a part of terminal devices accessing to the wi-fi sharing hotspot has access rights and a part of terminal devices does not have access rights, the wi-fi sharing hotspot of the wireless network card can be closed, and access device identifiers which are not included in a preset rights identifier list are reported, so that suspicious terminal devices can be found in time, and internal data leakage is avoided.
Step 204, in response to a kernel mode program starting instruction, monitoring operation data of a preset device management function in real time, calling a preset interception function to intercept the operation data when the operation data is monitored, and checking the intercepted operation data through the preset interception function;
in this embodiment, kernel mode programs are included in addition to user mode programs. In general, a user mode program and a kernel mode program are run simultaneously, so as to avoid that in a special case, the kernel mode program runs but the user mode program does not run, so that the running mode of the wireless network card cannot be monitored, and the running mode of the wireless network card can be controlled by the following steps when the kernel mode program runs. First, in response to a kernel mode program start instruction, operation data of a preset device management function may be monitored in real time, where the preset device management function may be an ioctl function. In the Linux operating system, most of the operations are realized by calling the ioctl function. When operation data corresponding to a preset device management function is monitored, a preset interception function can be called, and corresponding operation data is intercepted through the preset interception function, wherein the preset interception function can be a hook function registered in a system operation kernel and the like. After interception, the intercepted operation data can be further checked through a preset interception function, and specifically, the operation data can be parameter data corresponding to a preset equipment management function and the like.
Step 205, when the operation data is the operation data corresponding to the operation mode of modifying the wireless network card into the sharing hot spot mode, terminating the transmission of the operation data;
in this embodiment, whether the operation data is the operation data corresponding to the operation mode of the wireless network card is determined by the preset interception function, and when the operation data is the operation data corresponding to the operation mode of the wireless network card, the transmission of the operation data is stopped, so that the operation mode of the wireless network card is prevented from being modified to the operation mode of the shared hot spot.
And 206, releasing the operation data when the operation data is not the operation data corresponding to the operation mode of modifying the wireless network card into the sharing hot spot mode.
In this embodiment, when it is determined through the preset interception function that the operation data is not the operation data corresponding to the shared hot spot mode, it is indicated that the operation data is irrelevant to the present interception, and the operation data may be released.
In the embodiment of the application, when the kernel mode program runs, the relevant operation data of the wireless network card sharing hot spot which is required to be opened can be terminated only through a preset interception function, and when the kernel mode program is started, the WIFI sharing hot spot of the wireless network card can be closed in a mode of calling the target state reading interface and the target state setting interface when the user mode program runs. The two function together to ensure the safety of the intranet environment and the internal data.
In this embodiment, after the "determining the operation mode of the wireless network card through the target state reading interface" in step 201, the method further includes: when the running mode of the wireless network card is the signal receiving mode, starting a first timing device, and returning to the step of calling the target state reading interface when the time recorded by the first timing device is consistent with a first preset time interval; alternatively, after the "change the operation mode of the wireless network card to the signal receiving mode through the target state setting interface" in step 203, the method further includes: and starting a second timing device, and returning to the step of calling the target state reading interface when the time recorded by the second timing device is consistent with the first preset time interval.
In this embodiment, when the operation mode of the wireless network card is determined to be the signal receiving mode through the target state reading interface, the first timing device may be started, after the first timing device is started, timing may be started through the first timing device, and when the time recorded by the first timing device reaches the first preset time interval, the target state reading interface may be called again, and the operation mode of the current wireless network card is determined through the target state reading interface. Then, when the operation mode of the wireless network card is determined to be the sharing hot spot mode, a target state setting interface can be called, the WIFi sharing hot spot of the wireless network card is closed by utilizing the target state setting interface, and the operation mode of the wireless network card is further modified to be a signal receiving mode; when the operation mode of the wireless network card is determined to be the signal receiving mode, the second timing device can be started, and the second timing device is used for timing, so that repeated judgment of the operation mode of the wireless network card is realized. In addition, after the operation mode of the wireless network card is changed into the signal receiving mode through the target state setting interface, the second timing device can be started, and likewise, the timing can be started through the second timing device, when the time recorded by the second timing device reaches the first preset time interval, the target state reading interface can be called again, and the operation mode of the current wireless network card is determined through the target state reading interface. Then, when the operation mode of the wireless network card is determined to be the sharing hot spot mode, a target state setting interface can be called, the WIFi sharing hot spot of the wireless network card is closed by utilizing the target state setting interface, and the operation mode of the wireless network card is further modified to be a signal receiving mode; and when the running mode of the wireless network card is still the signal receiving mode, restarting the second timing device to realize repeated judgment of the running mode of the wireless network card. According to the method and the device, the first preset time interval is set, and when the time recorded by the first timing device or the second timing device is consistent with the first preset time interval, the target state reading interface is called again, so that the operation mode of the wireless network card can be repeatedly checked, the wireless network card WIFi sharing hot spot is prevented from being started again after being closed, the wireless network card WIFi sharing hot spot is accessed to the unauthorized terminal equipment, and the internal data security is threatened.
In an embodiment of the present application, after the "responding to the user mode program start instruction" in step 201, the method further includes: monitoring the kernel mode program starting instruction in real time, calling the target state reading interface after the kernel mode program starting instruction is monitored, and determining the running mode of the wireless network card through the target state reading interface; returning to the step of calling a target state setting interface when the running mode of the wireless network card is the sharing hot spot mode; and when the running mode of the wireless network card is the signal receiving mode, closing the first timing device or the second timing device.
In this embodiment, when the user mode program is started, in response to the user mode program start instruction, the shared hot spot operation mode of the wireless network card may be recovered to the signal receiving mode by calling the target state reading interface and the target state setting interface, and the kernel mode program start instruction may be monitored in real time, and when the kernel mode program start instruction is not monitored, the operation mode of the wireless network card may be repeatedly checked at a first preset time interval. When the starting instruction of the kernel mode program is monitored, the kernel mode program can intercept the operation data for modifying the operation mode of the wireless network card into the sharing mode in real time when running, and the starting of the sharing hot spot is prevented. Therefore, the target state reading interface can be called at this time, and whether the operation mode of the wireless network card is the sharing hot spot mode or not is determined by utilizing the target state reading interface. When the wireless network card is started, a target state setting interface is called, a WIFI sharing hot spot of the wireless network card is closed through the target state setting interface, the operation mode of the wireless network card is changed from a sharing hot spot mode to a signal receiving mode, when the starting timing device is a first timing device, the first timing device is closed, or when the starting timing device is a second timing device, the second timing device is closed, the target state reading interface is not repeatedly called, and operation data for changing the operation mode of the wireless network card is intercepted through a preset interception function in a kernel mode program, so that the starting of the sharing hot spot mode of the wireless network card is prevented; and if not, indicating that the sharing hot spot of the current wireless network card is not started, at the moment, directly closing the started first timing device or second timing device, and not repeatedly calling the target state reading interface, and intercepting the operation data for modifying the operation mode of the wireless network card through a preset interception function in the kernel mode program to prevent the starting of the sharing hot spot mode of the wireless network card.
In an embodiment of the present application, after the "turning off the first timer device or the second timer device", the method further includes: continuously monitoring the running data of the kernel mode program, and restarting the first timing device or the second timing device when the idle time of the running data is not monitored to be longer than the preset idle time.
In this embodiment, after the kernel mode program start instruction is monitored and the first timing device or the second timing device started is turned off, the running data of the kernel mode program may be continuously monitored to determine whether the kernel mode program runs normally. When the running data of the kernel-mode program is not monitored beyond the preset idle time, the fact that the kernel-mode program is not run successfully due to some problems is indicated, the timing device can be restarted, and the running mode of the wireless network card is controlled in a mode that the user-mode program calls the target state reading interface and the target state setting interface at regular time. Here, the first timer may be restarted when the closed timer is the first timer, and the second timer may be restarted when the closed timer is the second timer.
In an embodiment of the present application, after the "changing the operation mode of the wireless network card to the signal receiving mode", the method further includes: recording the changing times of the wireless network card running mode, and replacing the first preset time interval by using a second preset time interval when the changing times are larger than a preset time threshold, wherein the first preset time interval is larger than the second preset time interval.
In this embodiment, after the operation mode of the wireless network card is changed each time, the number of times of changing the operation mode may be recorded, and when the number of times of changing the operation mode of the wireless network card is greater than a threshold value of the preset number of times, it is indicated that the wireless network card is frequently restored to the sharing hot spot mode from the signal receiving mode, and there is a high possibility that dangerous terminal equipment exists, which is very unfavorable for the security of the internal data, so that the first preset time interval may be replaced with the second preset time interval, where the second preset time interval is smaller than the first preset time interval, and the security of the intranet environment and the internal data is further ensured by shortening the inspection time of the operation mode of the wireless network card.
In order to better illustrate the control method of the wireless network card WIFI sharing hotspot during the user mode program running and the kernel mode program running, fig. 3 shows the control process in two cases respectively. For the control method of the wireless network card WIFI sharing hot spot when the user mode program runs, firstly, when the user mode program runs, a target state reading interface is called to read the state of the wireless network card, and when the state of the wireless network card is the opened hot spot state, a target state setting interface is called to close the hot spot of the wireless network card, and the wireless network card running mode is restored to a signal receiving mode; when the state of the wireless network card is not the hot spot state which is started, waiting for the next examination. When various network configuration programs call icotl functions, namely operation data of the ioctl functions are monitored, preset equipment management functions such as a kernel hook function and the like can be called, whether the operation data are operation data for modifying the operation mode of the wireless network card is further determined through the preset equipment management functions such as the kernel hook function and the like, when the operation data are intercepted, and when the operation data are not intercepted, release processing is carried out on the operation data.
Further, as a specific implementation of the method of fig. 1, an embodiment of the present application provides a control device for a WIFI sharing hotspot, as shown in fig. 4, where the device includes:
the running mode determining module is used for responding to a user state program starting instruction, calling a target state reading interface and determining the running mode of the wireless network card through the target state reading interface;
and the operation mode changing module is used for calling a target state setting interface when the operation mode of the wireless network card is a sharing hot spot mode, and changing the operation mode of the wireless network card into a signal receiving mode through the target state setting interface so as to close the WIFI sharing hot spot corresponding to the wireless network card.
Optionally, the apparatus further comprises:
the timing module is used for starting a first timing device when the running mode of the wireless network card is the signal receiving mode after the running mode of the wireless network card is determined through the target state reading interface, and returning to the step of calling the target state reading interface when the time recorded by the first timing device is consistent with a first preset time interval; or after the operation mode of the wireless network card is changed into the signal receiving mode through the target state setting interface, starting a second timing device, and returning to the step of calling the target state reading interface when the time recorded by the second timing device is consistent with the first preset time interval.
Optionally, the apparatus further comprises:
the monitoring module is used for responding to a kernel mode program starting instruction, monitoring operation data of a preset device management function in real time, calling a preset interception function to intercept the operation data when the operation data is monitored, and checking the intercepted operation data through the preset interception function;
the termination module is used for terminating the transmission of the operation data when the operation data is the operation data corresponding to the operation mode of the wireless network card modified to the sharing hot spot mode;
and the release module is used for releasing the operation data when the operation data is not the operation data corresponding to the mode of modifying the operation mode of the wireless network card into the sharing hot spot mode.
Optionally, the apparatus further comprises:
the monitoring module is further configured to monitor the kernel mode program start instruction in real time after the response to the user mode program start instruction, and call the target state reading interface after the kernel mode program start instruction is monitored, and determine an operation mode of the wireless network card through the target state reading interface;
the operation mode determining module is further configured to return to the step of calling the target state setting interface when the operation mode of the wireless network card is the shared hot spot mode;
And the closing module is used for closing the first timing device or the second timing device when the running mode of the wireless network card is the signal receiving mode.
Optionally, the apparatus further comprises:
and the starting module is used for continuously monitoring the running data of the kernel mode program after the first timing device or the second timing device is closed, and restarting the first timing device or the second timing device when the idle time of the running data is not monitored to be longer than the preset idle time.
Optionally, the apparatus further comprises:
the list acquisition module is used for determining an access equipment identifier of the wireless network card WIFI sharing hotspot after the operation mode of the wireless network card is a sharing hotspot mode, and acquiring a preset permission identifier list;
the operation mode determining module is further configured to execute the call target state setting interface when the preset permission identifier list does not include the access device identifier.
Optionally, the apparatus further comprises:
the recording module is used for recording the changing times of the wireless network card operation mode after changing the wireless network card operation mode into the signal receiving mode through the target state setting interface, and replacing the first preset time interval by using a second preset time interval when the changing times are larger than a preset time threshold, wherein the first preset time interval is larger than the second preset time interval.
It should be noted that, other corresponding descriptions of each functional unit related to the control device for WIFI sharing hot spot provided in the embodiment of the present application may refer to corresponding descriptions in the methods of fig. 1 to fig. 2, and are not repeated herein.
Based on the above methods shown in fig. 1 to fig. 2, correspondingly, the embodiment of the application further provides a storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the above method for controlling the WIFI sharing hot spot shown in fig. 1 to fig. 2.
Based on such understanding, the technical solution of the present application may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (may be a CD-ROM, a U-disk, a mobile hard disk, etc.), and includes several instructions for causing a computer device (may be a personal computer, a server, or a network device, etc.) to perform the methods described in various implementation scenarios of the present application.
Based on the method shown in fig. 1 to fig. 2 and the virtual device embodiment shown in fig. 4, in order to achieve the above object, an embodiment of the present application further provides a physical structure diagram of a computer device, as shown in fig. 5, where the computer device includes: the control method for the WIFI sharing hot spot shown in fig. 1 is realized when the processor 31 executes the program.
Optionally, the computer device may also include a user interface, a network interface, a camera, radio Frequency (RF) circuitry, sensors, audio circuitry, WI-FI modules, and the like. The user interface may include a Display screen (Display), an input unit such as a Keyboard (Keyboard), etc., and the optional user interface may also include a USB interface, a card reader interface, etc. The network interface may optionally include a standard wired interface, a wireless interface (e.g., bluetooth interface, WI-FI interface), etc.
It will be appreciated by those skilled in the art that the architecture of a computer device provided in the present embodiment is not limited to the computer device, and may include more or fewer components, or may combine certain components, or may be arranged in different components.
The storage medium may also include an operating system, a network communication module. An operating system is a program that manages and saves computer device hardware and software resources, supporting the execution of information handling programs and other software and/or programs. The network communication module is used for realizing communication among all components in the storage medium and communication with other hardware and software in the entity equipment.
From the above description of the embodiments, it will be apparent to those skilled in the art that the present application may be implemented by means of software plus necessary general hardware platforms, or may be implemented by hardware. First, when a user mode program start instruction is received, the user mode program start instruction may be responded, and a call may be made to the target state reading interface. And then, determining the running mode of the current wireless network card through the called target state reading interface. When the operation mode of the wireless network card is determined to be the sharing hot spot mode through the target state reading interface, the target state setting interface can be further called, the WIFI sharing hot spot of the wireless network card is closed through the target state setting interface, and the operation mode of the wireless network card is changed from the sharing hot spot mode to the signal receiving mode. According to the method and the device, the running mode of the wireless network card is determined by calling the target state reading interface, and the sharing hot spot of the wireless network card is closed by calling the target state setting interface, so that unauthorized terminal equipment can be effectively prevented from accessing the intranet through the WIFI sharing hot spot, and the safety of the intranet environment and internal data is greatly improved.
Those skilled in the art will appreciate that the drawings are merely schematic illustrations of one preferred implementation scenario, and that the modules or flows in the drawings are not necessarily required to practice the present application. Those skilled in the art will appreciate that modules in an apparatus in an implementation scenario may be distributed in an apparatus in an implementation scenario according to an implementation scenario description, or that corresponding changes may be located in one or more apparatuses different from the implementation scenario. The modules of the implementation scenario may be combined into one module, or may be further split into a plurality of sub-modules.
The foregoing application serial numbers are merely for description, and do not represent advantages or disadvantages of the implementation scenario. The foregoing disclosure is merely a few specific implementations of the present application, but the present application is not limited thereto and any variations that can be considered by a person skilled in the art shall fall within the protection scope of the present application.

Claims (10)

1. The control method of the WIFI sharing hot spot is characterized by comprising the following steps:
responding to a user state program starting instruction, calling a target state reading interface, and determining an operation mode of the wireless network card through the target state reading interface;
when the operation mode of the wireless network card is a sharing hot spot mode, a target state setting interface is called, and the operation mode of the wireless network card is changed into a signal receiving mode through the target state setting interface so as to close a WIFI sharing hot spot corresponding to the wireless network card;
After the responding to the user mode program starting instruction, the method further comprises the following steps:
monitoring a kernel mode program starting instruction in real time; when the kernel mode program starting instruction is not monitored, repeatedly checking the running mode of the wireless network card according to a first preset time interval; when the kernel mode program starting instruction is monitored, operation data for modifying the wireless network card operation mode into a sharing hot spot mode is intercepted in real time, and the target state setting interface is stopped from being invoked.
2. The method of claim 1, wherein the step of determining the position of the substrate comprises,
after the operation mode of the wireless network card is determined through the target state reading interface, the method further comprises: when the running mode of the wireless network card is the signal receiving mode, starting a first timing device, and returning to the step of calling the target state reading interface when the time recorded by the first timing device is consistent with a first preset time interval; or,
after the operation mode of the wireless network card is changed into the signal receiving mode through the target state setting interface, the method further comprises:
and starting a second timing device, and returning to the step of calling the target state reading interface when the time recorded by the second timing device is consistent with the first preset time interval.
3. The method according to claim 2, wherein the method further comprises:
responding to a kernel mode program starting instruction, monitoring operation data of a preset device management function in real time, calling a preset interception function to intercept the operation data when the operation data is monitored, and checking the intercepted operation data through the preset interception function;
when the operation data is the operation data corresponding to the operation mode of the wireless network card modified to the sharing hot spot mode, terminating the transmission of the operation data;
and when the operation data is not the operation data corresponding to the mode of modifying the operation mode of the wireless network card into the sharing hot spot mode, releasing the operation data.
4. A method according to claim 3, wherein after said responding to a user mode program start instruction, the method further comprises:
monitoring the kernel mode program starting instruction in real time, calling the target state reading interface after the kernel mode program starting instruction is monitored, and determining the running mode of the wireless network card through the target state reading interface;
returning to the step of calling a target state setting interface when the running mode of the wireless network card is the sharing hot spot mode;
And when the running mode of the wireless network card is the signal receiving mode, closing the first timing device or the second timing device.
5. The method of claim 4, wherein after the turning off the first timing device or the second timing device, the method further comprises:
continuously monitoring the running data of the kernel mode program, and restarting the first timing device or the second timing device when the idle time of the running data is not monitored to be longer than the preset idle time.
6. The method of claim 1, wherein after the operating mode of the wireless network card is a shared hot spot mode, the method further comprises:
determining an access equipment identifier of the WIFI sharing hotspot of the wireless network card, and acquiring a preset permission identifier list;
and executing the call target state setting interface when the preset permission identification list does not comprise the access equipment identification.
7. The method of claim 1, wherein after the changing the operation mode of the wireless network card to the signal receiving mode through the target state setting interface, the method further comprises:
Recording the changing times of the wireless network card running mode, and replacing the first preset time interval by using a second preset time interval when the changing times are larger than a preset time threshold, wherein the first preset time interval is larger than the second preset time interval.
8. A control device for a WIFI-sharing hotspot, comprising:
the running mode determining module is used for responding to a user state program starting instruction, calling a target state reading interface and determining the running mode of the wireless network card through the target state reading interface;
the operation mode changing module is used for calling a target state setting interface when the operation mode of the wireless network card is a sharing hot spot mode, and changing the operation mode of the wireless network card into a signal receiving mode through the target state setting interface so as to close a WIFI sharing hot spot corresponding to the wireless network card;
the monitoring module is used for monitoring the kernel mode program starting instruction in real time after responding to the user mode program starting instruction; when the kernel mode program starting instruction is not monitored, repeatedly checking the running mode of the wireless network card according to a first preset time interval; when the kernel mode program starting instruction is monitored, operation data for modifying the wireless network card operation mode into a sharing hot spot mode is intercepted in real time, and the target state setting interface is stopped from being invoked.
9. A storage medium having stored thereon a computer program, which when executed by a processor, implements the method of any of claims 1 to 7.
10. A computer device comprising a storage medium, a processor and a computer program stored on the storage medium and executable on the processor, characterized in that the processor implements the method of any one of claims 1 to 7 when executing the computer program.
CN202111536696.6A 2021-12-15 2021-12-15 Control method and device for WIFI sharing hot spot and storage medium Active CN114302399B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111536696.6A CN114302399B (en) 2021-12-15 2021-12-15 Control method and device for WIFI sharing hot spot and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111536696.6A CN114302399B (en) 2021-12-15 2021-12-15 Control method and device for WIFI sharing hot spot and storage medium

Publications (2)

Publication Number Publication Date
CN114302399A CN114302399A (en) 2022-04-08
CN114302399B true CN114302399B (en) 2023-12-29

Family

ID=80967579

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111536696.6A Active CN114302399B (en) 2021-12-15 2021-12-15 Control method and device for WIFI sharing hot spot and storage medium

Country Status (1)

Country Link
CN (1) CN114302399B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103188647A (en) * 2011-12-29 2013-07-03 北京网秦天下科技有限公司 Method and system for statistically analyzing and warning Internet surfing flow of mobile terminal
CN104427541A (en) * 2013-08-30 2015-03-18 许辉跃 WiFi hot spot registration and information service system and method
CN106454810A (en) * 2016-09-14 2017-02-22 广东欧珀移动通信有限公司 Hotspot establishing method and terminal equipment
CN111107614A (en) * 2018-10-26 2020-05-05 中兴通讯股份有限公司 Terminal device control method and device and terminal device readable storage medium
CN111901852A (en) * 2020-06-23 2020-11-06 于志国 Mobile device hotspot connection management system and corresponding terminal
CN112055390A (en) * 2020-07-30 2020-12-08 深圳市修远文化创意有限公司 Signal switching method and related device
CN112291787A (en) * 2019-07-24 2021-01-29 杭州萤石软件有限公司 Network connection method, device and system
CN112333683A (en) * 2020-11-27 2021-02-05 北京小米移动软件有限公司 Hotspot sharing method and device, mobile terminal and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018125682A1 (en) * 2016-12-27 2018-07-05 Bandwidthx Inc. Auto-discovery of amenities
US20180332525A1 (en) * 2017-05-09 2018-11-15 Coronet Cyber Security Ltd. Secure hotspot setup

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103188647A (en) * 2011-12-29 2013-07-03 北京网秦天下科技有限公司 Method and system for statistically analyzing and warning Internet surfing flow of mobile terminal
CN104427541A (en) * 2013-08-30 2015-03-18 许辉跃 WiFi hot spot registration and information service system and method
CN106454810A (en) * 2016-09-14 2017-02-22 广东欧珀移动通信有限公司 Hotspot establishing method and terminal equipment
CN111107614A (en) * 2018-10-26 2020-05-05 中兴通讯股份有限公司 Terminal device control method and device and terminal device readable storage medium
CN112291787A (en) * 2019-07-24 2021-01-29 杭州萤石软件有限公司 Network connection method, device and system
CN111901852A (en) * 2020-06-23 2020-11-06 于志国 Mobile device hotspot connection management system and corresponding terminal
CN112055390A (en) * 2020-07-30 2020-12-08 深圳市修远文化创意有限公司 Signal switching method and related device
CN112333683A (en) * 2020-11-27 2021-02-05 北京小米移动软件有限公司 Hotspot sharing method and device, mobile terminal and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
WiFi无线网络的安全与防范措施探讨;谭悦平;;信息与电脑(理论版)(第09期);全文 *

Also Published As

Publication number Publication date
CN114302399A (en) 2022-04-08

Similar Documents

Publication Publication Date Title
US10169585B1 (en) System and methods for advanced malware detection through placement of transition events
US11368432B2 (en) Network containment of compromised machines
EP3761208B1 (en) Trust zone-based operating system and method
US10341365B1 (en) Methods and system for hiding transition events for malware detection
US9100440B1 (en) Systems and methods for applying data loss prevention policies to closed-storage portable devices
EP3335146B1 (en) Systems and methods for detecting unknown vulnerabilities in computing processes
US9781143B1 (en) Systems and methods for detecting near field communication risks
KR20130135952A (en) Processing method and device in application running
US20180181752A1 (en) Automated classification of exploits based on runtime environmental features
US10769275B2 (en) Systems and methods for monitoring bait to protect users from security threats
EP3089068A1 (en) Application program management method, device, terminal, and computer storage medium
CN109815700B (en) Application program processing method and device, storage medium and computer equipment
EP3513353B1 (en) Systems and methods for detecting malicious processes on computing devices
US9942268B1 (en) Systems and methods for thwarting unauthorized attempts to disable security managers within runtime environments
US9552481B1 (en) Systems and methods for monitoring programs
Ramachandran et al. Android anti-virus analysis
CN111651763B (en) Process monitoring method and device, electronic equipment and storage medium
CN114302399B (en) Control method and device for WIFI sharing hot spot and storage medium
US11113389B1 (en) Systems and methods for providing persistent visual warnings for application launchers
CN109784041B (en) Event processing method and device, storage medium and electronic device
CN106022105B (en) A kind of command processing method and device
CN111651764B (en) Process monitoring method and device, electronic equipment and storage medium
CN113836529A (en) Process detection method, device, storage medium and computer equipment
CN111259392B (en) Kernel module-based malicious software interception method and device
CN109800580B (en) Permission control method and device of system process, storage medium and computer equipment

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
CB02 Change of applicant information

Address after: 100032 NO.332, 3rd floor, Building 102, 28 xinjiekouwai street, Xicheng District, Beijing

Applicant after: Qianxin Technology Group Co.,Ltd.

Applicant after: Qianxin Wangshen information technology (Beijing) Co.,Ltd.

Address before: 100032 NO.332, 3rd floor, Building 102, 28 xinjiekouwai street, Xicheng District, Beijing

Applicant before: Qianxin Technology Group Co.,Ltd.

Applicant before: LEGENDSEC INFORMATION TECHNOLOGY (BEIJING) Inc.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant