The content of the invention
Based on the above situation, the present invention proposes recognition methods and the identification device of a kind of mobile phone focus, to judge one
Whether focus is focus that mobile phone virtual goes out, therefore, the scheme used is as follows.
A kind of recognition methods of mobile phone focus, including step:
The focus under current environment is scanned, therefrom selects focus to be identified;
Focus to be identified is connected, and obtains IP address;
Mobile phone focus IP address range is searched, it is determined that acquired IP address whether in the range of, if in the range of, is sentenced
Fixed focus to be identified is mobile phone focus.
A kind of identification device of mobile phone focus, including:
Focus chooses module, for scanning the focus under current environment, therefrom selects focus to be identified;
IP address acquisition module, for connecting focus to be identified, and obtain IP address;
IP address judge module, for searching mobile phone focus IP address range, it is determined that whether acquired IP address is in model
In enclosing, if in the range of, judge focus to be identified for mobile phone focus.
The IP address that the focus of mobile phone virtual is distributed is in fixed range, the recognition methods and knowledge of mobile phone focus of the present invention
Other device, according to this feature, judge whether current hotspot is mobile phone focus, and method is simple and easy, fast and effective, facilitates use
Make the selection whether connected in family.
Embodiment
In order to make the purpose , technical scheme and advantage of the present invention be clearer, it is right below in conjunction with drawings and Examples
The present invention is described in further detail.It should be appreciated that embodiment described herein is only explaining this hair
It is bright, do not limit protection scope of the present invention.
The recognition methods of the mobile phone focus of the present invention, as shown in figure 1, comprising the following steps.
Step s101, the focus under current environment is scanned, therefrom selects focus to be identified.
For example, in certain position, open smart mobile phone and search 10 WIFI hot spots.Now, user can only see focus name
Claim and signal intensity, with the presence or absence of the mobile phone focus for being not suitable for connection in the focus searched, user can not intuitive judgment, use
This method, then a focus can be manually selected by user and is tested as focus to be identified, or it is automatic one by one by mobile phone
Test.
Step s102, focus to be identified is connected, and obtains IP address.
Focus to be identified is attached as ordinary hot point, focus to be identified will distribute IP address for the equipment of connection.
The IP address distributed not is arbitrarily to distribute, but in fixed address field, such as the smart mobile phone of Android operation system
The IP address acquiescence distributed is limited in the range of following 7 sector address:
192.168.42.2-192.168.42.254
192.168.43.2-192.168.43.254
192.168.44.2-192.168.44.254
192.168.45.2-192.168.45.254
192.168.46.2-192.168.46.254
192.168.47.2-192.168.47.254
192.168.48.2-192.168.48.254
And the IP address acquiescence for using the smart mobile phone of IOS to be distributed is limited in following scope:
172.20.10.2-172.20.10.254
Above is the characteristics of smart mobile phone of common two kinds of operating systems distributes IP address, this distribution feature belongs to neck
Common knowledge in domain, any technical staff can be known.This method is exactly to utilize this feature, prestores mobile phone focus
The IP address range of distribution, and carry out following step.
Step s103, mobile phone focus IP address range is searched, it is determined that acquired IP address is whether in the range of, if in model
In enclosing, then judge focus to be identified for mobile phone focus.
By the IP address got compared with the IP address in the IP address range prestored, if in the presence of consistent IP
Location, the IP address for showing currently to obtain are distributed by smart mobile phone, and focus to be identified is mobile phone focus.Carried so as to provide
Show, decide whether to abandon connecting by user.If without consistent IP address, it is not mobile phone focus to show focus to be identified, can be with
Continue to connect.
In addition to the IP address of distribution has These characteristics, the cipher mode of mobile phone focus there is also it is certain the characteristics of:I.e.
Cipher mode be confined to it is specific several, it is various rather than common WIFI hot spot cipher mode.Wherein, Android operations system
The cipher mode of the focus of system mobile phone virtual is limited to OPEN, WPA PSK and tri- kinds of WPA2PSK, IOS mobile phone virtual
The cipher mode of focus is only limitted to WPA2 PSK.
Analyzed based on more than, basis of characterization that can be using cipher mode as mobile phone focus, but due to common WIFI hot spot
Cipher mode cover the above-mentioned cipher mode of mobile phone focus, thus cipher mode is adapted only to as assistant criteria.As one
Individual preferred embodiment, IP address is combined with cipher mode, judged according to the two features, can be more accurately
Identify mobile phone focus.
It is previously mentioned, the IP address of the smart mobile phone of Android operation system and the smart mobile phone distribution of IOS
In different address fields, according to this feature, it is empty by the mobile phone of which kind of operating system that can determine whether mobile phone focus
Intend.
Flow chart shown in Fig. 2 is a preferred embodiment, and the embodiment falls according to acquired IP address
Still fall in android system mobile phone focus IP address range in IOS system mobile phone focus IP address ranges, and it is acquired
Cipher mode belong to android system mobile phone focus cipher mode and still fall within IOS system mobile phone focus cipher modes, judge
Focus to be identified is android system mobile phone focus or IOS system mobile phone focuses.
When judge focus to be identified for mobile phone focus after, if user selects to keep connecting the mobile phone focus, this method is also
The flow from mobile phone focus consumption, concurrent outflow prompting can be detected.For example, certain user possesses a smart mobile phone and one
Portion's Intelligent flat, smart mobile phone can be networked by mobile network, can also be networked by wireless network, Intelligent flat then can only
Networked by wireless network.In no attachable environment of valid wireless signal, user wants to surf the Net by Intelligent flat, because
This creates a focus using its mobile phone, after Intelligent flat is connected to the focus, you can free interconnection, but what is consumed is mobile phone
Data traffic.Now, this method shows the window of a traffic statistics on the Intelligent flat of user, then user can be at any time
Solution has used how much flows of mobile phone, and being unlikely to occur flow transfinites the situation that user but knows nothing.
In addition, cell phone manufacturer typically both provides the automatic updating system version when connecting wifi hotspot or updates software
Function, if current wifi hotspot is the focus of mobile phone virtual, the big data bag of upgrading and renewal will consume the M of mobile phone more than ten even
Tens M flow, the user to flow-sensitive will be a no small losses.Thus, this method is also identifying that current hotspot is
After the focus gone out by mobile phone virtual, the upgrading and renewal of software are automatically prevented from.
Above is the embodiment of the recognition methods of mobile phone focus of the present invention, is described below corresponding with above-mentioned recognition methods
Identification device.
The identification device of mobile phone focus of the present invention, as shown in figure 3, including:
Focus chooses module, for scanning the focus under current environment, therefrom selects focus to be identified;
IP address acquisition module, for connecting focus to be identified, and obtain IP address;
IP address judge module, for searching mobile phone focus IP address range, it is determined that whether acquired IP address is in model
In enclosing, if in the range of, judge focus to be identified for mobile phone focus.
Focus is chosen module, IP address acquisition module and IP address judge module and is sequentially connected, and forms this identification device
One embodiment.
Further, as a preferred embodiment, the IP address acquisition module, it is additionally operable to obtaining IP address
Meanwhile obtain the cipher mode of focus to be identified;The IP address judge module, it is additionally operable to search mobile phone focus cipher mode kind
Class, it is determined that whether acquired cipher mode is arranging, if arranging, further judge focus to be identified for mobile phone focus.
Further, android system hand is included as a preferred embodiment, the mobile phone focus IP address range
Machine focus IP address range and IOS system mobile phone focus IP address ranges;The mobile phone focus cipher mode species includes
Android system mobile phone focus cipher mode and IOS system mobile phone focus cipher modes;The IP address judge module, is also used
Still fall in android system mobile phone focus IP address range in IOS system mobile phones heat in being fallen according to acquired IP address
In point IP address range, and acquired cipher mode belongs to android system mobile phone focus cipher mode and still falls within IOS
System mobile phone focus cipher mode, judge focus to be identified for android system mobile phone focus or IOS system mobile phone focuses.
Further, traffic monitoring module can also be included as a preferred embodiment, this identification device, for
The IP address judge module judges that focus to be identified is mobile phone focus, and keeps after connecting the mobile phone focus, detects from above-mentioned
The flow of mobile phone focus consumption, concurrent outflow prompting.
Further, as a preferred embodiment, this identification device can also include upgrading and block module, for
After the IP address judge module judges focus to be identified for mobile phone focus, stop the upgrading and renewal of software.
Due to the module of this identification device with the step of above-mentioned recognition methods be it is corresponding, thus, technical characteristic is no longer heavy
It is multiple to explain.
To sum up, the recognition methods of mobile phone focus of the present invention and identification device, by the correlated characteristic of mobile phone focus, by mobile phone
Focus identifies from common wifi hotspot, so that user pointedly makes a choice.
Embodiment described above only expresses the several embodiments of the present invention, and its description is more specific and detailed, but simultaneously
Therefore the limitation to the scope of the claims of the present invention can not be interpreted as.It should be pointed out that for one of ordinary skill in the art
For, without departing from the inventive concept of the premise, various modifications and improvements can be made, these belong to the guarantor of the present invention
Protect scope.Therefore, the protection domain of patent of the present invention should be determined by the appended claims.