CN104144231A - Method and device for processing DNS query request - Google Patents

Method and device for processing DNS query request Download PDF

Info

Publication number
CN104144231A
CN104144231A CN201410416273.4A CN201410416273A CN104144231A CN 104144231 A CN104144231 A CN 104144231A CN 201410416273 A CN201410416273 A CN 201410416273A CN 104144231 A CN104144231 A CN 104144231A
Authority
CN
China
Prior art keywords
domain name
dns resolution
dns
target
resolution result
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.)
Granted
Application number
CN201410416273.4A
Other languages
Chinese (zh)
Other versions
CN104144231B (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.)
Zhuhai Baoqu Technology Co Ltd
Original Assignee
Beijing Kingsoft Internet Security Software 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 Beijing Kingsoft Internet Security Software Co Ltd filed Critical Beijing Kingsoft Internet Security Software Co Ltd
Priority to CN201410416273.4A priority Critical patent/CN104144231B/en
Publication of CN104144231A publication Critical patent/CN104144231A/en
Application granted granted Critical
Publication of CN104144231B publication Critical patent/CN104144231B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Telephonic Communication Services (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The embodiment of the invention discloses a method and a device for processing a DNS query request, wherein the method comprises the following steps: acquiring a DNS query request which is forwarded by a forwarding driver associated with a network card driver and carries a target domain name to be resolved; after monitoring a data packet which is processed by a network card driver and sent by a handheld terminal with a target port being a preset port, a forwarding driver performs data stripping processing from a session layer to an application layer to obtain a DNS query request; judging whether the target domain name exists in a historical mapping record of the domain name and the DNS analysis result, if so, feeding back the target DNS analysis result corresponding to the determined target domain name to the handheld terminal; and if not, requesting a target DNS analysis result of the target domain name based on the first class DNS server in the local network configuration information, feeding back to the handheld terminal when a valid DNS analysis result is requested, and storing a mapping record of the target domain name and the target DNS analysis result. By the scheme, the efficiency of processing the DNS query request is improved.

Description

Process method and the device of DNS inquiry request
Technical field
The present invention relates to data processing field, particularly a kind of method and device of processing DNS inquiry request.
Background technology
Along with science and technology development at full speed, various terminals are constantly enriched and have been facilitated popular life.Owing to utilizing terminal processes information to there is the advantages such as convenient and swift, saving resource, make terminal become an indispensable part in user's life or work.In practical application, the terminals such as smart mobile phone, notebook computer, panel computer and desktop computer have been widely used in daily life.And, in terminal, various client softwares can be installed, for example: MSN, net purchase software, application market software, WIFI shareware etc.
Wherein, by for example, WIFI shareware being installed being provided with in the terminal of wireless network card (: desktop computer, notebook computer etc.), can be using this terminal as hot terminal, to play the effect of wireless router, thereby make handheld terminal (for example: smart mobile phone, panel computer etc.) can utilize this wireless router to surf the Net.
In prior art, handheld terminal can obtain the dns resolution result of the domain name of accessing by the hot terminal that wifi shareware is installed, and then the operation that conducts interviews of dns resolution result based on obtained.Concrete, the packet that comprises DNS inquiry request that handheld terminal sends is after the network-driven of hot terminal, the processing layer by layer of session layer, presentation layer and application layer will be passed through successively, final WIFI shareware can obtain this DNS inquiry request, and then DNS inquiry request is carried out to follow-up processing.This mechanism of processing is layer by layer comparatively consuming time undoubtedly, and the efficiency that causes processing DNS inquiry request is lower, finally makes user's experience lower.
And, in prior art, when WIFI shareware is processed DNS inquiry request, all need at least one the dns server request corresponding dns resolution result given to local network configuration information at every turn, owing to being subject to the restriction of network environment, this also can reduce the efficiency of processing DNS inquiry request undoubtedly.
Summary of the invention
Based on the problems referred to above, the embodiment of the invention discloses a kind of method and device of the DNS of processing inquiry request, to improve the efficiency of processing DNS inquiry request.Technical scheme is as follows:
First aspect, the embodiment of the present invention provides a kind of method of the DNS of processing inquiry request, comprising:
The forwarding that acquisition is associated with network interface card driving drives the DNS inquiry request that carries target domain name to be resolved forwarding; Wherein, described forwarding drive listen to driven by described network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, described packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved;
Judge whether described target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if, determine according to described historical map record the target dns resolution result that described target domain name is corresponding, and feed back the corresponding target dns resolution of described target domain name result to described handheld terminal; If not,
To the target dns resolution result of target domain name described in given at least one first kind dns server request of local network configuration information;
Receive the first request results of described at least one first kind dns server feedback;
In the time there is the first request results of the dns resolution result that does not belong to invalid in described the first request results receiving, described the first request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
Optionally, the method for a kind of DNS of processing inquiry request that the embodiment of the present invention provides, also comprises:
In the time that the first received request results all belongs to invalid dns resolution result, at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net;
Receive the second request results of described at least one Equations of The Second Kind dns server feedback;
If there is the second request results of the dns resolution result that does not belong to invalid in the second received request results, described the second request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
Optionally, the method for a kind of DNS of processing inquiry request that the embodiment of the present invention provides, also comprises:
When judge described target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or simultaneously
To target dns resolution result corresponding to target domain name described in described at least one first kind dns server request;
Receive the 3rd request results of described at least one first kind dns server feedback;
If existed in the 3rd received request results, not belong to the 3rd request results of invalid dns resolution result and described the 3rd request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 3rd request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
Optionally, the method for a kind of DNS of processing inquiry request that the embodiment of the present invention provides, also comprises:
When judge described target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or simultaneously
To the target dns resolution result of target domain name described in described at least one first kind dns server request;
Receive the 4th request results of described at least one first kind dns server feedback;
If existed in the 4th received request results, not belong to the 4th request results of invalid dns resolution result and described the 4th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 4th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal,
If the 4th received request results all belongs to invalid dns resolution result, to the target dns resolution result of described at least one Equations of The Second Kind dns server request target domain name;
Receive the 5th request results of described at least one Equations of The Second Kind dns server feedback;
If existed in the 5th received request results, not belong to the 5th request results of invalid dns resolution result and described the 5th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 5th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
Optionally, described invalid dns resolution result, comprising:
Showing to inquire about failed result or content is empty result.
Optionally, described default port-for-port 53.
Second aspect, the embodiment of the present invention also provides a kind of device of the DNS of processing inquiry request, comprising:
DNS inquiry request obtains module, and the forwarding that is associated with network interface card driving for obtaining drives the DNS inquiry request that carries target domain name to be resolved forwarding; Wherein, described forwarding drive listen to driven by described network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, described packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved;
Judge module, for judging whether described target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if so, triggers the first analysis result processing module; If not, trigger local request module;
Described the first analysis result processing module, for determine the target dns resolution result that described target domain name is corresponding according to described historical map record, and feeds back the corresponding target dns resolution of described target domain name result to described handheld terminal;
Described local request module, for the target dns resolution result to target domain name described in given at least one first kind dns server request of local network configuration information;
The first request results receiver module, for receiving the first request results of described at least one first kind dns server feedback;
The second analysis result processing module, for when described in the first request results existence of receiving while not belonging to the first request results of invalid dns resolution result, described the first request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
Optionally, the device of a kind of DNS of processing inquiry request that the embodiment of the present invention provides, also comprises:
Outer net request module, when all belonging to invalid dns resolution result, at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net when the first received request results;
The second request results receiver module, for receiving the second request results of described at least one Equations of The Second Kind dns server feedback;
The 3rd analysis result processing module, if there is the second request results of the dns resolution result that does not belong to invalid for the second received request results, the second request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
Optionally, the device of a kind of DNS of processing inquiry request that the embodiment of the present invention provides, also comprises:
The first request module again, for when judge described target domain name be present in buffer memory in advance the historical map record about domain name and dns resolution result and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or the while, to target dns resolution result corresponding to target domain name described in described at least one first kind dns server request;
The 3rd request results receiver module, for receiving the 3rd request results of described at least one first kind dns server feedback;
The 4th analysis result processing module, if exist the 3rd request results of the dns resolution result that does not belong to invalid and described the 3rd request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 3rd request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 3rd request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
Optionally, the device of a kind of DNS of processing inquiry request that the embodiment of the present invention provides, also comprises:
The second request module again, for when judge described target domain name be present in buffer memory in advance the historical map record about domain name and dns resolution result and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or the while, to the target dns resolution result of target domain name described in described at least one first kind dns server request;
The 4th request results receiver module, for receiving the 4th request results of described at least one first kind dns server feedback;
The 5th analysis result processing module, if exist the 4th request results of the dns resolution result that does not belong to invalid and described the 4th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 4th request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 4th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal,
The 3rd request module again, if all belong to invalid dns resolution result for the 4th received request results, to the target dns resolution result of described at least one Equations of The Second Kind dns server request target domain name;
The 5th request results receiver module, for receiving the 5th request results of described at least one Equations of The Second Kind dns server feedback;
The 6th analysis result processing module, if exist the 5th request results of the dns resolution result that does not belong to invalid and described the 5th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 5th request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 5th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
Optionally, described invalid dns resolution result, comprising:
Showing to inquire about failed result or content is empty result.
Optionally, described default port-for-port 53.
Compared with prior art, the forwarding being associated with in network interface card driving drives the packet that comprises DNS inquiry request that interception is finished dealing with by network-driven, that handheld terminal sends, and this packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved, further, forward driving this DNS inquiry request that carries target domain name to be resolved is transmitted to wifi shareware; And, while processing DNS inquiry request, first search dns resolution result based on the historical map record of buffer memory in advance, searching not then to corresponding first kind dns server request dns resolution result.Visible, this programme has effectively been avoided the processing layer by layer of the packet process session layer, presentation layer and the application layer that comprise DNS inquiry request, meanwhile, has effectively utilized caching mechanism, therefore, can effectively improve the efficiency of processing DNS inquiry request.
Brief description of the drawings
In order to be illustrated more clearly in the embodiment of the present invention or technical scheme of the prior art, to the accompanying drawing of required use in embodiment or description of the Prior Art be briefly described below, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, do not paying under the prerequisite of creative work, can also obtain according to these accompanying drawings other accompanying drawing.
The first flow chart of the method for a kind of DNS of processing inquiry request that Fig. 1 provides for the embodiment of the present invention;
The second flow chart of the method for a kind of DNS of processing inquiry request that Fig. 2 provides for the embodiment of the present invention;
The third flow chart of the method for a kind of DNS of processing inquiry request that Fig. 3 provides for the embodiment of the present invention;
The structural representation of the device of a kind of DNS of processing inquiry request that Fig. 4 provides for the embodiment of the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the present invention's part embodiment, instead of whole embodiment.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtaining under creative work prerequisite, belong to the scope of protection of the invention.
For the sake of clarity, the related content of paper DNS:
DNS (Domain Name System, domain name system) distributed data base for mutually shining upon as domain name and IP address on internet, it can make user access more easily the Internet, remembers and do not spend the IP address that can directly be read by machine.Wherein, the process that obtains IP address corresponding to this domain name by domain name is called domain name mapping.DNS inquiry request described in the embodiment of the present invention is for asking the corresponding IP of domain name address, and dns resolution result corresponding to domain name is IP address corresponding to domain name.
In order to improve the efficiency of processing DNS inquiry request, the embodiment of the present invention has improved a kind of method and device of the DNS of processing inquiry request.
The method of a kind of DNS of the processing the inquiry request first embodiment of the present invention being provided is below introduced.
It should be noted that, the method of a kind of DNS of processing inquiry request that the embodiment of the present invention provides is applied to hot terminal, wherein, so-called hot terminal is the terminal that has wireless network card and wifi shareware is installed, this hot terminal can be served as wireless router by operation wifi shareware, makes various handheld terminals realize networking.
And the functional software of realizing the method for a kind of DNS of processing inquiry request that the embodiment of the present invention provides can be specific wifi shareware.
As shown in Figure 1, a kind of method of processing DNS inquiry request, can comprise:
S101, the forwarding that acquisition is associated with network interface card driving drives the DNS inquiry request that carries target domain name to be resolved forwarding;
Wherein, this forwarding drive listen to driven by this network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, can carry out the data lift-off processing to application layer about session layer to this packet, thereby obtain carrying the DNS inquiry request of target domain name to be resolved.Wherein, this default port can be served corresponding port 53 for DNS.
Be understandable that, while sending DNS inquiry request due to handheld terminal, can pass through the encapsulation process layer by layer of application layer, presentation layer, session layer, transport layer etc.; And wifi shareware can be identified the data in application layer, drive the packet that comprises DNS inquiry request of tackling to be identified by wifi shareware in order to make to forward, forward and drive and can carry out the data lift-off processing to application layer about session layer to intercepted packet, obtain carrying the DNS inquiry request of target domain name to be resolved, and then be transmitted to the processing of wifi shareware.
It is emphasized that as network interface card drives the associated mode driving that forwards and can adopt prior art, and this packet is carried out also can adopting existing techniques in realizing about session layer to the data lift-off processing of application layer, do not repeat at this.
S102, judges that whether this target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if so, carries out S103; If not, carry out S104;
Wherein, carry in acquisition after the DNS inquiry request of target domain name to be resolved, can judge whether this target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, and carry out different operations according to different judged results.Concrete, when judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, show that this inquiry of DNS about target domain name not inquires about first, now, can carry out S103; And when judge this target domain name be not present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, can carry out S104, with to target dns resolution result corresponding to corresponding this target domain name of dns server request.
It should be noted that, in advance buffer memory about being the domain name that inquires before hot terminal and the map record of the corresponding dns resolution result of this domain name in the historical map record of domain name and dns resolution result.
S103, determines according to this history map record the target dns resolution result that this target domain name is corresponding, and feeds back the corresponding target dns resolution of this target domain name result to this handheld terminal;
When judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, show not inquiry first of this inquiry of DNS about target domain name, now, can be from the historical map record about domain name and dns resolution result of buffer memory in advance, determine the target dns resolution result that this target domain name is corresponding, and feed back the corresponding target dns resolution of this target domain name result to this handheld terminal.
S104, to the target dns resolution result of at least one given this target domain name of first kind dns server request of local network configuration information;
S105, receives the first request results that at least one first kind dns server feeds back;
When judge this target domain name be not present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, can be to the target dns resolution result of at least one given this target domain name of first kind dns server request of local network configuration information, and receive the first request results of at least one first dns server feedback.Be understandable that, when first kind dns server is when more than two, can be according to default request order successively to different first kind dns server requests, certainly, and also can be simultaneously to different first kind dns server requests, this is all rational.
Wherein, user can configure at least one first kind dns server in local network configuration information, and the given first kind dns server of local network configuration information can be the dns server of local area network (LAN) inside, also can be the public dns server of outer net, this be all rational.
S106, in the time there is the first request results of the dns resolution result that does not belong to invalid in the first request results receiving, the first request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to target domain name, and by target dns resolution result feedback to handheld terminal, will carry out caching process as historical map record about the map record of target domain name and target dns resolution result.
Obtaining after the first request results of at least one first kind dns server feedback, can judge in the first received request results, whether there is the dns resolution result that does not belong to invalid, and carry out different operations according to different judged results.Concrete, in the time judging the first received request results and all belong to invalid dns resolution result, resolve unsuccessfully, can feed back the result that cannot resolve or not make feedback processing to this handheld terminal, this is all rational; And in the time judging the first request results that has the dns resolution result that does not belong to invalid in the first received request results, the first request results that does not belong to invalid dns resolution result can be defined as to target dns resolution result corresponding to this target domain name, and give this handheld terminal by this target dns resolution result feedback, can be based on the existing access to netwoks of obtained target dns resolution fructufy so that obtain handheld terminal; And in order to improve the follow-up efficiency that this target domain name is carried out to DNS inquiry, can will carry out caching process as historical map record about the map record of this target domain name and target dns resolution result.
Concrete, described invalid dns resolution result, can comprise: showing to inquire about failed result or content is empty result.
Be understandable that, for a domain name, its corresponding dns resolution result is IP address, for example: for domain name www.baidu.com, its corresponding dns resolution result is 58.217.200.13, the IP address that this dns resolution result is Baidu's server.
Compared with prior art, the forwarding being associated with in network interface card driving drives the packet that comprises DNS inquiry request that interception is finished dealing with by network-driven, that handheld terminal sends, and this packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved, further, forward driving this DNS inquiry request that carries target domain name to be resolved is transmitted to wifi shareware; And, while processing DNS inquiry request, first search dns resolution result based on the historical map record of buffer memory in advance, searching not then to corresponding first kind dns server request dns resolution result.Visible, this programme has effectively been avoided the processing layer by layer of the packet process session layer, presentation layer and the application layer that comprise DNS inquiry request, meanwhile, has effectively utilized caching mechanism, therefore, can effectively improve the efficiency of processing DNS inquiry request.
In order further to improve the power that resolves to of domain name that handheld terminal is accessed, the embodiment of the present invention also provides a kind of method of the DNS of processing inquiry request.
It should be noted that, the method of a kind of DNS of processing inquiry request that the embodiment of the present invention provides is applied to hot terminal, wherein, so-called hot terminal is the terminal that has wireless network card and wifi shareware is installed, this hot terminal can be served as wireless router by operation wifi shareware, makes various handheld terminals realize networking.
And the functional software of realizing the method for a kind of DNS of processing inquiry request that the embodiment of the present invention provides can be specific wifi shareware.
As shown in Figure 2, a kind of method of processing DNS inquiry request, can comprise:
S201, the forwarding that acquisition is associated with network interface card driving drives the DNS inquiry request that carries target domain name to be resolved forwarding;
Wherein, this forwarding drive listen to driven by this network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, can carry out the data lift-off processing to application layer about session layer to this packet, thereby obtain carrying the DNS inquiry request of target domain name to be resolved.Wherein, this default port can be served corresponding port 53 for DNS.
S202, judges that whether this target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if so, carries out S203; If not, carry out S204;
S203, determines according to this history map record the target dns resolution result that this target domain name is corresponding, and feeds back the corresponding target dns resolution of this target domain name result to this handheld terminal;
S204, to the target dns resolution result of at least one given this target domain name of first kind dns server request of local network configuration information;
S205, receives the first request results that at least one first kind dns server feeds back;
In the present embodiment, S201-S205 is similar to the S101-S105 of above-described embodiment, does not repeat at this.
S206, judges whether the first received request results all belongs to invalid dns resolution result, if so, carries out S207; If not, carry out S210;
Obtaining after the first request results of at least one first kind dns server feedback, can judge whether the first received request results all belongs to invalid dns resolution result, and carry out different operations according to different judged results.Concrete, in the time judging the first received request results and all belong to invalid dns resolution result, can carry out S207; And in the time judging the first request results that has the dns resolution result that does not belong to invalid in the first received request results, can carry out S210.
Concrete, described invalid dns resolution result, can comprise: showing to inquire about failed result or content is empty result.
Be understandable that, for a domain name, its corresponding dns resolution result is IP address, for example: for domain name www.baidu.com, its corresponding dns resolution result is 58.217.200.13, the IP address that this dns resolution result is Baidu's server.
S207, at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net;
S208, receives the second request results that at least one Equations of The Second Kind dns server feeds back;
Wherein, in the time judging the first received request results and all belong to invalid dns resolution result, resolve unsuccessfully, can be at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net, and receive the second request results of at least one Equations of The Second Kind dns server feedback.
It should be noted that, this Equations of The Second Kind dns server is the public dns server of the built-in outer net of wifi shareware, this Equations of The Second Kind dns server can be the powerful dns server of domain name mapping, larger about the database of domain name and dns resolution result (IP address) map record.It should be noted that, can be according to default request order successively to different Equations of The Second Kind dns server request dns resolution results, certainly, and also can be simultaneously to different Equations of The Second Kind dns server request dns resolution results, this is all rational.S209, if there is the second request results of the dns resolution result that does not belong to invalid in the second received request results, the second request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to target domain name, and by target dns resolution result feedback to handheld terminal, and will carry out caching process as historical map record about the map record of target domain name and target dns resolution result;
Wherein, in the time judging the second request results that has the dns resolution result that does not belong to invalid in the second received request results, the second request results that this can not belonged to invalid dns resolution result is defined as target dns resolution result corresponding to this target domain name, and give this handheld terminal by this target dns resolution result feedback, can be based on the existing access to netwoks of obtained target dns resolution fructufy so that obtain handheld terminal; And, in order to improve the follow-up efficiency that this target domain name is carried out to DNS inquiry, can will carry out caching process as historical map record about the map record of this target domain name and target dns resolution result.
Be understandable that, if the second received request results all belongs to invalid dns resolution result, now, can feed back the result that cannot resolve or not make feedback processing to this handheld terminal, this be all rational.
S210, is defined as target dns resolution result corresponding to this target domain name by the first request results that does not belong to invalid dns resolution result, and gives this handheld terminal by this target dns resolution result feedback;
S211, will carry out caching process as historical map record about the map record of this target domain name and target dns resolution result.
Wherein, in the time judging the first request results that has the dns resolution result that does not belong to invalid in the first received request results, the first request results that this can not belonged to invalid dns resolution result is defined as target dns resolution result corresponding to this target domain name, and give this handheld terminal by this target dns resolution result feedback, can be based on the existing access to netwoks of obtained target dns resolution fructufy so that obtain handheld terminal; And in order to improve the follow-up efficiency that this target domain name is carried out to DNS inquiry, can will carry out caching process as historical map record about the map record of this target domain name and target dns resolution result.
Compared with prior art, the forwarding being associated with in network interface card driving drives the packet that comprises DNS inquiry request that interception is finished dealing with by network-driven, that handheld terminal sends, and this packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved, further, forward driving this DNS inquiry request that carries target domain name to be resolved is transmitted to wifi shareware; And, while processing DNS inquiry request, first search dns resolution result based on the historical map record of buffer memory in advance, searching not then to corresponding first kind dns server request dns resolution result.Visible, this programme has effectively been avoided the processing layer by layer of the packet process session layer, presentation layer and the application layer that comprise DNS inquiry request, meanwhile, has effectively utilized caching mechanism, therefore, can effectively improve the efficiency of processing DNS inquiry request.And, in the time that the given first kind dns server of local network configuration information cannot parse target domain name, can continue to continue to the public Equations of The Second Kind dns server of the outer net setting in advance the target dns resolution result of this target domain name of request, improve the power that resolves to of domain name with this.
It will be understood by those skilled in the art that, dns resolution result corresponding to the domain name of buffer memory has life cycle conventionally in advance, after life cycle finishes, it is invalid that dns resolution result will become, now, if receive dns resolution result and become the DNS inquiry request of invalid corresponding domain name, by again to dns resolution result corresponding to corresponding this domain name of dns server request.But, due to the variation of network environment, dns resolution the possibility of result corresponding to the domain name of buffer memory also can change in life cycle in advance, therefore, in order further to improve the reliability of analysis result, the embodiment of the present invention also provides a kind of method of the DNS of processing inquiry request.
It should be noted that, the method of a kind of DNS of processing inquiry request that the embodiment of the present invention provides is applied to hot terminal, wherein, so-called hot terminal is the terminal that has unlimited network interface card and wifi shareware is installed, this hot terminal can be served as wireless router by operation wifi shareware, makes various handheld terminals realize networking.
And the functional software of realizing the method for a kind of DNS of processing inquiry request that the embodiment of the present invention provides can be specific wifi shareware.
As shown in Figure 3, a kind of method of processing DNS inquiry request, can comprise:
S301, the forwarding that acquisition is associated with network interface card driving drives the DNS inquiry request that carries target domain name to be resolved forwarding;
Wherein, this forwarding drive listen to driven by this network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, can carry out the data lift-off processing to application layer about session layer to this packet, thereby obtain carrying the DNS inquiry request of target domain name to be resolved.Wherein, this default port can be served corresponding port 53 for DNS.
In the present embodiment, S301 is similar to S101, does not repeat at this.
S302, judges that whether this target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if so, carries out S303; If not, carry out S307;
Wherein, carry in acquisition after the DNS inquiry request of target domain name to be resolved, can judge whether this target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, and carry out different operations according to different judged results.Concrete, when judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, show that this inquiry of DNS about target domain name not inquires about first, now, can carry out S303; And when judge this target domain name be not present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, can carry out S307, with to target dns resolution result corresponding to corresponding this target domain name of dns server request.
It should be noted that, in advance buffer memory about being the domain name that inquires before hot terminal and the map record of the corresponding dns resolution result of this domain name in the historical map record of domain name and dns resolution result.
S303, determines according to this history map record the target dns resolution result that this target domain name is corresponding, and feeds back the corresponding target dns resolution of this target domain name result to this handheld terminal;
When judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, show not inquiry first of this inquiry of DNS about target domain name, now, can be from the historical map record about domain name and dns resolution result of buffer memory in advance, determine the target dns resolution result that this target domain name is corresponding, and feed back the corresponding target dns resolution of this target domain name result to this handheld terminal.
S304, to target dns resolution result corresponding at least one first kind dns server request target domain name;
S305, receives the 3rd request results that at least one first kind dns server feeds back;
In order to ensure the reliability of domain name mapping result, when judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or simultaneously, can also be to target dns resolution result corresponding to this at least one this target domain name of first kind dns server request, and receive the 3rd request results of this at least one first kind dns server feedback.
It is emphasized that in the present embodiment, S304 can carry out after S303, certainly, when judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, S303 and S304 can carry out simultaneously, this is also rational.
S306, if exist the 3rd request results that do not belong to the 3rd request results of invalid dns resolution result and the do not belong to invalid dns resolution result current target dns resolution result corresponding from the target domain name of institute buffer memory different in the 3rd received request results, corresponding target domain name target dns resolution result is updated to the 3rd request results of the dns resolution result that does not belong to invalid;
Obtaining after the 3rd request results, if exist the 3rd request results that do not belong to the 3rd request results of invalid dns resolution result and the do not belong to invalid dns resolution result current target dns resolution result corresponding from the target domain name of institute buffer memory different in the 3rd received request results, show that dns resolution result corresponding to this target domain name of institute's buffer memory is invalid, now, this corresponding target dns resolution of target domain name result can be updated to the 3rd request results of the dns resolution result that does not belong to invalid, to ensure: again receive handheld terminal and send after the DNS inquiry request about target domain name, to the target dns resolution result after the corresponding renewal of handheld terminal feedback target domain name.
S307, to the target dns resolution result of at least one given this target domain name of first kind dns server request of local network configuration information;
S308, receives the first request results that at least one first kind dns server feeds back;
S309, in the time there is the first request results of the dns resolution result that does not belong to invalid in the first request results receiving, the first request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to target domain name, and by target dns resolution result feedback to handheld terminal, will carry out caching process as historical map record about the map record of target domain name and target dns resolution result.
In the present embodiment, S307-S309 is similar to the S104-S106 of above-described embodiment, does not repeat since then.
Compared with prior art, the forwarding being associated with in network interface card driving drives the packet that comprises DNS inquiry request that interception is finished dealing with by network-driven, that handheld terminal sends, and this packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved, further, forward driving this DNS inquiry request that carries target domain name to be resolved is transmitted to wifi shareware; And, while processing DNS inquiry request, first search dns resolution result based on the historical map record of buffer memory in advance, searching not then to corresponding first kind dns server request dns resolution result.Visible, this programme has effectively been avoided the processing layer by layer of the packet process session layer, presentation layer and the application layer that comprise DNS inquiry request, meanwhile, has effectively utilized caching mechanism, therefore, can effectively improve the efficiency of processing DNS inquiry request.And, when judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in time, the not only target dns resolution result of feedback, but also again ask about the dns resolution result of target domain name to ensure the reliability of dns resolution result.
Further, on the basis of the given scheme of the second embodiment (S201-S211), in order to improve the reliability of dns resolution result, the method for a kind of DNS of processing inquiry request that the embodiment of the present invention provides can also comprise:
When judge this target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or simultaneously,
To the target dns resolution result of at least one first kind dns server request target domain name;
Receive the 4th request results of at least one first kind dns server feedback;
If exist the 4th request results that do not belong to the 4th request results of invalid dns resolution result and the do not belong to invalid dns resolution result current target dns resolution result corresponding from the target domain name of institute buffer memory different in the 4th received request results, corresponding target domain name target dns resolution result is updated to the 4th request results of the dns resolution result that does not belong to invalid, to ensure: again receive handheld terminal and send after the DNS inquiry request about described target domain name, to the target dns resolution result after the corresponding renewal of handheld terminal feedback target domain name,
If the 4th received request results all belongs to invalid dns resolution result, to the target dns resolution result of at least one Equations of The Second Kind dns server request target domain name;
Receive the 5th request results of at least one Equations of The Second Kind dns server feedback;
If exist the 5th request results that do not belong to the 5th request results of invalid dns resolution result and the do not belong to invalid dns resolution result current target dns resolution result corresponding from the target domain name of institute buffer memory different in the 5th received request results, corresponding target domain name target dns resolution result is updated to the 5th request results of the dns resolution result that does not belong to invalid, to ensure: again receive handheld terminal and send after the DNS inquiry request about target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to handheld terminal.
Further, on the basis of the given scheme of the third embodiment (S301-S309), resolve to power in order to improve, the another kind that the embodiment of the present invention provides is processed in the method for DNS inquiry request, in the time judging this first request results and all belong to invalid dns resolution result, not feed back the result that cannot resolve or do not make feedback processing to this handheld terminal, but carrying out following steps:
To at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net; Receive the 6th request results of at least one Equations of The Second Kind dns server feedback; If there is the 6th request results of the dns resolution result that does not belong to invalid in the 6th received request results, the 6th request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to target domain name, and by target dns resolution result feedback to handheld terminal, and will carry out caching process as historical map record about the map record of target domain name and target dns resolution result.
Corresponding to said method embodiment, the embodiment of the present invention also provides a kind of device of the DNS of processing inquiry request, as shown in Figure 4, can comprise:
DNS inquiry request obtains module 410, and the forwarding that is associated with network interface card driving for obtaining drives the DNS inquiry request that carries target domain name to be resolved forwarding; Wherein, described forwarding drive listen to driven by described network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, described packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved;
Judge module 420, for judging whether described target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if so, triggers the first analysis result processing module 430; If not, trigger local request module 440;
Described the first analysis result processing module 430, for determine the target dns resolution result that described target domain name is corresponding according to described historical map record, and feeds back the corresponding target dns resolution of described target domain name result to described handheld terminal;
Described local request module 440, for the target dns resolution result to target domain name described in given at least one first kind dns server request of local network configuration information;
The first request results receiver module 450, for receiving the first request results of described at least one first kind dns server feedback;
The second analysis result processing module 460, for when described in the first request results existence of receiving while not belonging to the first request results of invalid dns resolution result, described the first request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
Compared with prior art, the forwarding being associated with in network interface card driving drives the packet that comprises DNS inquiry request that interception is finished dealing with by network-driven, that handheld terminal sends, and this packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved, further, forward driving this DNS inquiry request that carries target domain name to be resolved is transmitted to wifi shareware; And, while processing DNS inquiry request, first search dns resolution result based on the historical map record of buffer memory in advance, searching not then to corresponding first kind dns server request dns resolution result.Visible, this programme has effectively been avoided the processing layer by layer of the packet process session layer, presentation layer and the application layer that comprise DNS inquiry request, meanwhile, has effectively utilized caching mechanism, therefore, can effectively improve the efficiency of processing DNS inquiry request.
Further, based on comprising that DNS inquiry request obtains the device of the processing DNS inquiry request of module 410, judge module 420, the first analysis result processing module 430, local request module 440 and the second analysis result processing module 460, the device that the another kind that the embodiment of the present invention provides is processed DNS inquiry request can also comprise:
Outer net request module, when all belonging to invalid dns resolution result, at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net when the first received request results;
The second request results receiver module, for receiving the second request results of described at least one Equations of The Second Kind dns server feedback;
The 3rd analysis result processing module, if there is the second request results of the dns resolution result that does not belong to invalid for the second received request results, the second request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
Further, based on comprising that DNS inquiry request obtains the device of the processing DNS inquiry request of module 410, judge module 420, the first analysis result processing module 430, local request module 440 and the second analysis result processing module 460, the device that the another kind that the embodiment of the present invention provides is processed DNS inquiry request can also comprise:
The first request module again, for when judge described target domain name be present in buffer memory in advance the historical map record about domain name and dns resolution result and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or the while, to target dns resolution result corresponding to target domain name described in described at least one first kind dns server request;
The 3rd request results receiver module, for receiving the 3rd request results of described at least one first kind dns server feedback;
The 4th analysis result processing module, if exist the 3rd request results of the dns resolution result that does not belong to invalid and described the 3rd request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 3rd request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 3rd request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
Further, based on comprising that DNS inquiry request obtains the device of the processing DNS inquiry request of module 410, judge module 420, the first analysis result processing module 430, local request module 440, the second analysis result processing module 460, outer net request module, the second request results receiver module and the 3rd analysis result processing module, the device that the another kind that the embodiment of the present invention provides is processed DNS inquiry request can also comprise:
The second request module again, for when judge described target domain name be present in buffer memory in advance the historical map record about domain name and dns resolution result and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or the while, to the target dns resolution result of target domain name described in described at least one first kind dns server request;
The 4th request results receiver module, for receiving the 4th request results of described at least one first kind dns server feedback;
The 5th analysis result processing module, if exist the 4th request results of the dns resolution result that does not belong to invalid and described the 4th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 4th request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 4th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal,
The 3rd request module again, if all belong to invalid dns resolution result for the 4th received request results, to the target dns resolution result of described at least one Equations of The Second Kind dns server request target domain name;
The 5th request results receiver module, for receiving the 5th request results of described at least one Equations of The Second Kind dns server feedback;
The 6th analysis result processing module, if exist the 5th request results of the dns resolution result that does not belong to invalid and described the 5th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 5th request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 5th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
Concrete, described invalid dns resolution result, comprising:
Showing to inquire about failed result or content is empty result.
Concrete, described default port-for-port 53.
For system or device embodiment, because it is substantially similar in appearance to embodiment of the method, so description is fairly simple, relevant part is referring to the part explanation of embodiment of the method.
It should be noted that, in this article, relational terms such as the first and second grades is only used for an entity or operation to separate with another entity or operating space, and not necessarily requires or imply and between these entities or operation, have the relation of any this reality or sequentially.And, term " comprises ", " comprising " or its any other variant are intended to contain comprising of nonexcludability, thereby the process, method, article or the equipment that make to comprise a series of key elements not only comprise those key elements, but also comprise other key elements of clearly not listing, or be also included as the intrinsic key element of this process, method, article or equipment.The in the situation that of more restrictions not, the key element being limited by statement " comprising ... ", and be not precluded within process, method, article or the equipment that comprises described key element and also have other identical element.
One of ordinary skill in the art will appreciate that all or part of step realizing in said method execution mode is can carry out the hardware that instruction is relevant by program to complete, described program can be stored in computer read/write memory medium, here the alleged storage medium obtaining, as: ROM/RAM, magnetic disc, CD etc.
The foregoing is only preferred embodiment of the present invention, be not intended to limit protection scope of the present invention.All any amendments of doing within the spirit and principles in the present invention, be equal to replacement, improvement etc., be all included in protection scope of the present invention.

Claims (12)

1. a method of processing DNS inquiry request, is characterized in that, comprising:
The forwarding that acquisition is associated with network interface card driving drives the DNS inquiry request that carries target domain name to be resolved forwarding; Wherein, described forwarding drive listen to driven by described network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, described packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved;
Judge whether described target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if, determine according to described historical map record the target dns resolution result that described target domain name is corresponding, and feed back the corresponding target dns resolution of described target domain name result to described handheld terminal; If not,
To the target dns resolution result of target domain name described in given at least one first kind dns server request of local network configuration information;
Receive the first request results of described at least one first kind dns server feedback;
In the time there is the first request results of the dns resolution result that does not belong to invalid in described the first request results receiving, described the first request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
2. method according to claim 1, is characterized in that, also comprises:
In the time that the first received request results all belongs to invalid dns resolution result, at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net;
Receive the second request results of described at least one Equations of The Second Kind dns server feedback;
If there is the second request results of the dns resolution result that does not belong to invalid in the second received request results, described the second request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
3. method according to claim 1, is characterized in that, also comprises:
When judge described target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or simultaneously
To target dns resolution result corresponding to target domain name described in described at least one first kind dns server request;
Receive the 3rd request results of described at least one first kind dns server feedback;
If existed in the 3rd received request results, not belong to the 3rd request results of invalid dns resolution result and described the 3rd request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 3rd request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
4. method according to claim 2, is characterized in that, also comprises:
When judge described target domain name be present in buffer memory in advance about the historical map record of domain name and dns resolution result in and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or simultaneously
To the target dns resolution result of target domain name described in described at least one first kind dns server request;
Receive the 4th request results of described at least one first kind dns server feedback;
If existed in the 4th received request results, not belong to the 4th request results of invalid dns resolution result and described the 4th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 4th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal,
If the 4th received request results all belongs to invalid dns resolution result, to the target dns resolution result of described at least one Equations of The Second Kind dns server request target domain name;
Receive the 5th request results of described at least one Equations of The Second Kind dns server feedback;
If existed in the 5th received request results, not belong to the 5th request results of invalid dns resolution result and described the 5th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 5th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
5. according to the method described in claim 1-4 any one, it is characterized in that, described invalid dns resolution result, comprising:
Showing to inquire about failed result or content is empty result.
6. according to the method described in claim 1-4 any one, it is characterized in that described default port-for-port 53.
7. a device of processing DNS inquiry request, is characterized in that, comprising:
DNS inquiry request obtains module, and the forwarding that is associated with network interface card driving for obtaining drives the DNS inquiry request that carries target domain name to be resolved forwarding; Wherein, described forwarding drive listen to driven by described network interface card finish dealing with and after destination interface is the packet being sent by handheld terminal of default port, described packet is carried out to the data lift-off processing to application layer about session layer, thereby obtain carrying the DNS inquiry request of target domain name to be resolved;
Judge module, for judging whether described target domain name is present in the historical map record about domain name and dns resolution result of buffer memory in advance, if so, triggers the first analysis result processing module; If not, trigger local request module;
Described the first analysis result processing module, for determine the target dns resolution result that described target domain name is corresponding according to described historical map record, and feeds back the corresponding target dns resolution of described target domain name result to described handheld terminal;
Described local request module, for the target dns resolution result to target domain name described in given at least one first kind dns server request of local network configuration information;
The first request results receiver module, for receiving the first request results of described at least one first kind dns server feedback;
The second analysis result processing module, for when described in the first request results existence of receiving while not belonging to the first request results of invalid dns resolution result, described the first request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
8. device according to claim 7, is characterized in that, also comprises:
Outer net request module, when all belonging to invalid dns resolution result, at least one default target dns resolution result as the public Equations of The Second Kind dns server request target domain name of outer net when the first received request results;
The second request results receiver module, for receiving the second request results of described at least one Equations of The Second Kind dns server feedback;
The 3rd analysis result processing module, if there is the second request results of the dns resolution result that does not belong to invalid for the second received request results, the second request results that does not belong to invalid dns resolution result is defined as to target dns resolution result corresponding to described target domain name, and give described handheld terminal by described target dns resolution result feedback, and will carry out caching process as historical map record about the map record of described target domain name and target dns resolution result.
9. device according to claim 7, is characterized in that, also comprises:
The first request module again, for when judge described target domain name be present in buffer memory in advance the historical map record about domain name and dns resolution result and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or the while, to target dns resolution result corresponding to target domain name described in described at least one first kind dns server request;
The 3rd request results receiver module, for receiving the 3rd request results of described at least one first kind dns server feedback;
The 4th analysis result processing module, if exist the 3rd request results of the dns resolution result that does not belong to invalid and described the 3rd request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 3rd request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 3rd request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
10. device according to claim 8, is characterized in that, also comprises:
The second request module again, for when judge described target domain name be present in buffer memory in advance the historical map record about domain name and dns resolution result and after handheld terminal feeds back the corresponding target dns resolution of the target domain name result of determining according to described historical map record or the while, to the target dns resolution result of target domain name described in described at least one first kind dns server request;
The 4th request results receiver module, for receiving the 4th request results of described at least one first kind dns server feedback;
The 5th analysis result processing module, if exist the 4th request results of the dns resolution result that does not belong to invalid and described the 4th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 4th request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 4th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal,
The 3rd request module again, if all belong to invalid dns resolution result for the 4th received request results, to the target dns resolution result of described at least one Equations of The Second Kind dns server request target domain name;
The 5th request results receiver module, for receiving the 5th request results of described at least one Equations of The Second Kind dns server feedback;
The 6th analysis result processing module, if exist the 5th request results of the dns resolution result that does not belong to invalid and described the 5th request results that does not the belong to invalid dns resolution result current target dns resolution result corresponding from the described target domain name of institute buffer memory different for received the 5th request results, described in the described corresponding target dns resolution of target domain name result being updated to, do not belong to the 5th request results of invalid dns resolution result, to ensure: again receive described handheld terminal and send after the DNS inquiry request about described target domain name, feed back the target dns resolution result after the corresponding renewal of described target domain name to described handheld terminal.
11. according to the device described in claim 7-10 any one, it is characterized in that, described invalid dns resolution result, comprising:
Showing to inquire about failed result or content is empty result.
12. according to the device described in claim 7-10 any one, it is characterized in that described default port-for-port 53.
CN201410416273.4A 2014-08-21 2014-08-21 Method and device for processing DNS query request Active CN104144231B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410416273.4A CN104144231B (en) 2014-08-21 2014-08-21 Method and device for processing DNS query request

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410416273.4A CN104144231B (en) 2014-08-21 2014-08-21 Method and device for processing DNS query request

Publications (2)

Publication Number Publication Date
CN104144231A true CN104144231A (en) 2014-11-12
CN104144231B CN104144231B (en) 2018-01-19

Family

ID=51853297

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410416273.4A Active CN104144231B (en) 2014-08-21 2014-08-21 Method and device for processing DNS query request

Country Status (1)

Country Link
CN (1) CN104144231B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104935683A (en) * 2015-06-29 2015-09-23 北京经天科技有限公司 Buffer processing method and device for domain name resolution
CN110636150A (en) * 2019-10-24 2019-12-31 北京小米移动软件有限公司 Domain name resolution method, domain name resolution device, and storage medium
CN112822305A (en) * 2021-02-03 2021-05-18 深圳市共进电子股份有限公司 Method, device, router and storage medium for processing DNS query request
WO2021190609A1 (en) * 2020-03-26 2021-09-30 维沃移动通信有限公司 Data transmission method and electronic device
CN113472914A (en) * 2021-06-28 2021-10-01 广州根链国际网络研究院有限公司 DNS directional prefetching caching method and system
CN114844866A (en) * 2022-03-29 2022-08-02 武汉斗鱼鱼乐网络科技有限公司 Network request connection method and related equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020188757A1 (en) * 2001-06-01 2002-12-12 Yoon Ki J. Method for resolution services of special domain names
CN1540543A (en) * 2003-10-31 2004-10-27 浙江大学 Contents server system and processing procedure
CN102025793A (en) * 2010-01-22 2011-04-20 中国移动通信集团北京有限公司 Domain name resolution method and system and DNS in IP network
CN102301682B (en) * 2011-04-29 2014-02-19 华为技术有限公司 Method and system for network caching, domain name system redirection sub-system thereof

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020188757A1 (en) * 2001-06-01 2002-12-12 Yoon Ki J. Method for resolution services of special domain names
CN1540543A (en) * 2003-10-31 2004-10-27 浙江大学 Contents server system and processing procedure
CN102025793A (en) * 2010-01-22 2011-04-20 中国移动通信集团北京有限公司 Domain name resolution method and system and DNS in IP network
CN102301682B (en) * 2011-04-29 2014-02-19 华为技术有限公司 Method and system for network caching, domain name system redirection sub-system thereof

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104935683A (en) * 2015-06-29 2015-09-23 北京经天科技有限公司 Buffer processing method and device for domain name resolution
CN110636150A (en) * 2019-10-24 2019-12-31 北京小米移动软件有限公司 Domain name resolution method, domain name resolution device, and storage medium
CN110636150B (en) * 2019-10-24 2023-04-18 北京小米移动软件有限公司 Domain name resolution method, domain name resolution device, and storage medium
WO2021190609A1 (en) * 2020-03-26 2021-09-30 维沃移动通信有限公司 Data transmission method and electronic device
CN112822305A (en) * 2021-02-03 2021-05-18 深圳市共进电子股份有限公司 Method, device, router and storage medium for processing DNS query request
CN112822305B (en) * 2021-02-03 2022-09-13 深圳市共进电子股份有限公司 Method, device, router and storage medium for processing DNS query request
CN113472914A (en) * 2021-06-28 2021-10-01 广州根链国际网络研究院有限公司 DNS directional prefetching caching method and system
CN113472914B (en) * 2021-06-28 2023-09-26 北京天地互连信息技术有限公司 DNS directional prefetching caching method and system
CN114844866A (en) * 2022-03-29 2022-08-02 武汉斗鱼鱼乐网络科技有限公司 Network request connection method and related equipment

Also Published As

Publication number Publication date
CN104144231B (en) 2018-01-19

Similar Documents

Publication Publication Date Title
CN104144231A (en) Method and device for processing DNS query request
TWI495315B (en) Methods, apparatuses, and computer program products for determining a network interface to access a network resource
CN103929796B (en) The method and device of shared access point
CN104202360B (en) The method of accessed web page, device and router
WO2018090933A1 (en) Method, apparatus, and system for resolving service platform address
CN105471931B (en) Method, device and system for inquiring service data
CN113132185B (en) Equipment distribution network binding method, system, mobile terminal and storage medium
CN104754073A (en) Resource access method and device
CN103457994A (en) Installing applications remotely
CN106797410A (en) Domain name analytic method and device
WO2014206276A1 (en) Domain name resolution method, domain name server, and domain name access method, system and terminal
JP2003044509A5 (en)
US9565161B2 (en) Automatically replacing localhost as hostname in URL with fully qualified domain name or IP address
JP2018523176A (en) Method, server, mobile terminal, and apparatus for exchanging data with in-vehicle infotainment
WO2016000507A1 (en) Traffic-saving mode search service method, server, client and system
JP2017535084A (en) Data communication system, method, apparatus, program, and recording medium
US20160234307A1 (en) Data transmission method, device, and system
CN112445700B (en) Test method and device
WO2019019670A1 (en) Application accessing method and device, computer apparatus, and storage medium
CN104506450A (en) Media resource feedback method and device
WO2020228013A1 (en) Account association method, device, system, server, and storage medium
CN104639409A (en) Method and device for automatically adding sound box to sound box ad-hoc network
WO2017166524A1 (en) Domain name parsing method and apparatus
CN105897758A (en) Container access control method and device
CN109995743A (en) A kind of processing method and terminal of multimedia file

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20181220

Address after: Room 105-53811, No. 6 Baohua Road, Hengqin New District, Zhuhai City, Guangdong Province

Patentee after: Zhuhai Leopard Technology Co.,Ltd.

Address before: 100085 East District, Second Floor, 33 Xiaoying West Road, Haidian District, Beijing

Patentee before: BEIJING KINGSOFT INTERNET SECURITY SOFTWARE Co.,Ltd.

TR01 Transfer of patent right