CN108449428A - A kind of method for connecting network, device, server and storage medium - Google Patents

A kind of method for connecting network, device, server and storage medium Download PDF

Info

Publication number
CN108449428A
CN108449428A CN201810365350.6A CN201810365350A CN108449428A CN 108449428 A CN108449428 A CN 108449428A CN 201810365350 A CN201810365350 A CN 201810365350A CN 108449428 A CN108449428 A CN 108449428A
Authority
CN
China
Prior art keywords
network request
direct
domain name
current network
white list
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.)
Pending
Application number
CN201810365350.6A
Other languages
Chinese (zh)
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.)
Shenzhen Fenqile Network Technology Co Ltd
Original Assignee
Shenzhen Fenqile Network Technology 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 Shenzhen Fenqile Network Technology Co Ltd filed Critical Shenzhen Fenqile Network Technology Co Ltd
Priority to CN201810365350.6A priority Critical patent/CN108449428A/en
Publication of CN108449428A publication Critical patent/CN108449428A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/45Network directories; Name-to-address mapping
    • H04L61/4505Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols
    • H04L61/4511Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols using domain name system [DNS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/02Network architectures or network communication protocols for network security for separating internal from external traffic, e.g. firewalls
    • H04L63/0227Filtering policies
    • H04L63/0236Filtering by address, protocol, port number or service, e.g. IP-address or URL

Abstract

The embodiment of the invention discloses a kind of method for connecting network, device, server and storage mediums.The method includes:Obtain current network request to be sent;If according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, determine that the current network request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with the associated IP address of domain name to generate new network request;Send the new network request.The embodiment of the present invention can improve spacing and connect into power, realize the network connection of safety.

Description

A kind of method for connecting network, device, server and storage medium
Technical field
The present embodiments relate to network technique field more particularly to a kind of method for connecting network, device, server and deposit Storage media.
Background technology
With the development of development of Mobile Internet technology, more and more mobile terminals can access internet whenever and wherever possible, It brings great convenience to people's work and life.When mobile terminal sends network request, by domain name system (Domain Name System, DNS) it parses in domain name to corresponding IP address, then access data are gone by IP address.
Existing network request mode, is generally accessed using domain name, if the network request hair that mobile terminal is sent When raw Domain Hijacking, DNS name resolution will appear exception, fail so as to cause network request.Therefore existing network connection method Success rate it is low.
Invention content
A kind of method for connecting network of offer of the embodiment of the present invention, device, server and storage medium can improve spacing company It is connected into power, realizes the network connection of safety.
In a first aspect, an embodiment of the present invention provides a kind of method for connecting network, including:
Obtain current network request to be sent;
If according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, the current network is determined Request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with the associated IP address of domain name with life The network request of Cheng Xin;
Send the new network request.
Second aspect, the embodiment of the present invention additionally provide a kind of network connection device, which includes:
Acquisition module, for obtaining current network request to be sent;
If direct-connected module determines for according to pre-set domain name white list and/or the direct-connected rules of pre-set IP The current network request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with domain name association IP address to generate new network request;
Sending module, for sending the new network request.
The third aspect, the embodiment of the present invention additionally provide a kind of server, and the server includes:
One or more processors;
Storage device, for storing one or more programs;
When one or more of programs are executed by one or more of processors so that one or more of processing Device realizes method for connecting network as described above.
Fourth aspect, the embodiment of the present invention additionally provide a kind of computer readable storage medium, are stored thereon with computer Program, the program realize method for connecting network as described above when being executed by processor.
The embodiment of the present invention is asked by obtaining current network to be sent, if according to pre-set domain name white list And/or the pre-set direct-connected rules of IP, determine that the current network request meets the direct-connected conditions of IP, then by the current network Domain name in request replaces with the associated IP address of domain name to generate new network request, and sends the new network and ask It asks.Subnetwork, which may be implemented, in the technical solution of the embodiment of the present invention asks progress IP direct-connected, can improve spacing successful connection Rate realizes the network connection of safety.
Description of the drawings
Fig. 1 is the flow chart of the method for connecting network in the embodiment of the present invention one.
Fig. 2 is the direct-connected schematic diagrames of the IP in the embodiment of the present invention one.
Fig. 3 is the flow chart of the method for connecting network in the embodiment of the present invention two.
Fig. 4 is the flow chart of the method for connecting network in the embodiment of the present invention three.
Fig. 5 is the structural schematic diagram of the network connection device in the embodiment of the present invention four.
Fig. 6 is the structural schematic diagram of the server in the embodiment of the present invention five.
Specific implementation mode
The present invention is described in further detail with reference to the accompanying drawings and examples.It is understood that this place is retouched The specific embodiment stated is used only for explaining the present invention rather than limitation of the invention.It also should be noted that in order to just Only the parts related to the present invention are shown in description, attached drawing rather than entire infrastructure.
Embodiment one
Fig. 1 is the flow chart of the method for connecting network in the embodiment of the present invention one, and the present embodiment is applicable to network connection The case where, this method can be executed by network connection device, which software may be used and/or the mode of hardware is realized, example Such as, which is configured in server.As shown in Figure 1, this method can specifically include:
Step 110 obtains current network request to be sent.
Specifically, current network request to be sent in mobile terminal APP can be obtained.
In the present embodiment, before obtaining current network request to be sent, may include:If network request is abnormal And/or Domain Hijacking occurs, then the domain name of the network request is added into domain name white list.Wherein, network request occurs different Can be often since data access caused by network speed or other odjective causes fails, it is the one of internet attack that domain name, which is kidnapped, Kind mode, the method by attacking DNS or forging DNS, targeted website domain name mapping to the address of mistake to realize user Can not access target website purpose.Specifically, according to web-based history ask record, if network request be abnormal and/or Domain Hijacking occurs, the domain name of the network request can be added into domain name white list, will can also referred to according to actual needs The domain name of fixed network request is added into domain name white list.Domain name white list can be configured by domain name list.
In addition, before obtaining current network request to be sent, can also include:If network request be abnormal and/or The quantity that Domain Hijacking occurs is more than preset value, then extracts the common characters feature of the domain name in the network request, and according to The direct-connected rules of IP are arranged in the common characters feature.Wherein, the preset value can be configured as needed, such as preset value It can be 100.The common characters are characterized as that the character feature according to the domain name of multiple network requests calculate It arrives, i.e., the described common characters feature can also screen the domain name for having same characteristic features other than domain name white list. The common characters feature of the domain name of specified network request can also be extracted as needed, and is set according to the common characters feature Set the direct-connected rules of IP.The direct-connected rules of IP can be configured by regular expression.The setting of the direct-connected rules of IP can carry The efficiency and coverage rate of height screening.
If step 120, according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, determine described in Current network request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with the associated IP of domain name Address is to generate new network request.
Wherein, mobile terminal refers to replacing the domain name of network request with IP address by the direct-connected progress data access of IP, As shown in Fig. 2, Fig. 2 is the schematic diagram direct-connected IP in the embodiment of the present invention one, detailed process may include:It is ready for sending current Network request;Obtain current network request to be sent;The domain name that current network is asked is replaced with into IP address;Network is sent to ask It asks.It illustratively, can be by " https://channel.fenqile.com/10.htmlAd_tag= WWW.MAIN.NAV.MOB " is substituted for " https://10.1.1.256/10.htmlAd_tag= WWW.MAIN.NAV.MOBILE ", wherein " channel.fenqile.com " of the network request are domain name, " 10.1.1.256 " For IP address.
Wherein, if current network request belongs to domain name white list or current network request is straight with IP Even rule match or current network request are not belonging to domain name white list still with the direct-connected rule match of IP, meet One of which can determine that the current network request meets the direct-connected conditions of IP.The associated IP address of domain name can be by looking into The configuration file comprising domain name and IP address incidence relation obtained from server is ask to obtain.
If specifically, according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, it may be determined that institute It states current network request and meets the direct-connected conditions of IP, then the domain name in can asking the current network replaces with domain name and closes The IP address of connection is to generate new network request.
Step 130 sends the new network request.
Specifically, sending the new network request, domain name is replaced with domain name and is associated with by the new network request IP address.
The present embodiment is asked by obtaining current network to be sent, if according to pre-set domain name white list and/or The pre-set direct-connected rules of IP determine that the current network request meets the direct-connected conditions of IP, then ask the current network In domain name replace with the associated IP address of domain name to generate new network request, and send the new network request. The technical solution of the present embodiment can improve efficiency and coverage rate, in fact by pre-setting domain name white list and the direct-connected rules of IP Existing subnetwork request progress IP is direct-connected, and improves spacing and connect into power, realizes the network connection of safety.
Based on the above technical solution, optionally, according to pre-set domain name white list and/or pre-set The direct-connected rules of IP, determine whether the current network request meets the direct-connected conditions of IP, may include:Determine that the current network is asked Whether the domain name in asking belongs to domain name white list;If belonging to, it is determined that the current network request meets the direct-connected conditions of IP; If being not belonging to, it is determined that whether the current network request matches with the direct-connected rules of the IP;If successful match, it is determined that described Current network request meets the direct-connected conditions of IP.
Optionally, after obtaining current network request to be sent, may include:If detecting, preset direct-connected pattern is opened Start or stop is dynamic, then determines that the current network is asked according to the direct-connected rule of pre-set domain name white list and/or pre-set IP Seeking Truth is no to meet the direct-connected conditions of IP.
Embodiment two
Fig. 3 is the flow chart of the method for connecting network in the embodiment of the present invention two, base of the present embodiment in above-described embodiment On plinth, above-mentioned method for connecting network has been advanced optimized.Correspondingly, the method for the present embodiment can specifically include:
Step 210 obtains current network request to be sent.
Specifically, current network request to be sent in mobile terminal APP can be obtained.
If step 220 detects that preset direct-connected mode switch starts.
Wherein, the direct-connected mode switch can control the direct-connected opening and closing of IP, if such as network request pass through IP Occur exception when direct-connected progress data access, it can be by closing the direct-connected mode switch to close the network request IP is direct-connected.
Specifically, whether the preset direct-connected mode switch of detection starts, 230 are entered step if starting.Wherein, direct-connected mould The startup of formula switch can be pre-set as needed with closing.
Step 230 determines whether the domain name in the current network request belongs to domain name white list.
Wherein, the record that domain name white list can be asked according to web-based history, exception will occur and/or domain name occurs The domain name of the network request of abduction is added into domain name white list, can also be according to actual needs by the domain name of specified network request It is added into domain name white list.Domain name white list can be configured by domain name list.
Specifically, it is first determined whether the domain name in the current network request belongs to domain name white list.
If step 240 belongs to, it is determined that the current network request meets the direct-connected conditions of IP.
If specifically, the domain name in current network request belongs to domain name white list, it is determined that the current net Network request meets the direct-connected conditions of IP, can pass through the direct-connected carry out data access of IP.
If step 250 is not belonging to, it is determined that whether the current network request matches with the direct-connected rules of the IP;If With success, it is determined that the current network request meets the direct-connected conditions of IP.
Wherein, the setting of the direct-connected rules of the IP may include:If network request is abnormal and/or occurs Domain Hijacking Quantity be more than preset value, then extract the common characters feature of the domain name in the network request, and according to the common characters The direct-connected rules of IP are arranged in feature.Wherein, it is more than preset value when network request is abnormal and/or the quantity of Domain Hijacking occurs, Quantity i.e. in domain name white list is more than preset value, or when the quantity of specified network request is more than preset value, can be direct Domain name white list is set as empty, directly carry out IP it is direct-connected it is regular whether matched judgement.
In the present embodiment, a configuration file can be set in mobile terminal, may include straight in the configuration file Even mode switch, domain name white list and the direct-connected rules of IP, the configuration file can be with real-time updates, can also be as needed every It is updated when secondary startup APP.
If specifically, the domain name in current network request is not belonging to domain name white list, judge described current Whether network request matches with the direct-connected rules of the IP;If successful match, it is determined that it is direct-connected that the current network request meets IP Condition can pass through the direct-connected carry out data access of IP.
Domain name in current network request is replaced with the associated IP address of domain name to generate newly by step 260 Network request.
Step 270 sends the new network request.
The technical solution of the present embodiment is asked by obtaining current network to be sent, if detecting preset direct-connected mould Formula switch starts, and determines whether the domain name in the current network request belongs to domain name white list, if belonging to, it is determined that institute It states current network request and meets the direct-connected conditions of IP, if being not belonging to, it is determined that the current network request and the direct-connected rules of the IP Whether match;If successful match, it is determined that the current network request meets the direct-connected conditions of IP, and the current network is asked In domain name replace with the associated IP address of domain name to generate new network request, send the new network request.This The technical solution of embodiment can match domain name white list and the direct-connected rule match of IP is combined, and direct-connected mode switch is arranged The direct-connected opening and closing of IP are controlled, efficiency, coverage rate and flexibility can be improved, it is straight to realize that subnetwork request carries out IP Even, it and improves spacing and connects into power, realize the network connection of safety.
Embodiment three
Fig. 4 is the flow chart of the method for connecting network in the embodiment of the present invention three, and the present embodiment can be with above-described embodiment The detailed process of method for connecting network is further detailed in basis, and domain name white list is arranged by domain name in the present embodiment Table is configured, and the direct-connected rules of IP are configured by regular expression.This method can specifically include:
Step 310 obtains current network request to be sent.
Specifically, current network request to be sent in mobile terminal APP can be obtained.
Step 320 judges whether direct-connected mode switch is opened.
Specifically, judging whether direct-connected mode switch is opened, if so, entering step 330;If it is not, then entering step 350。
Step 330 judges whether domain name list is empty.
Wherein, storage needs to carry out the direct-connected domain names of IP in domain name list, the note that can be asked according to web-based history Exception will occur and/or the domain name of the domain name and specified network request of the network request of Domain Hijacking occurs for record and actual needs It stores into domain name list.
Specifically, judging whether domain name list is empty, if so, entering step 360;If it is not, then entering step 340.
Whether step 340 judges the domain name of network request in domain name list.
Specifically, whether having the domain name of network request in nslookup list, if so, entering step 370;If it is not, then Enter step 350.
Step 350 sends network request.
Specifically, not modifying to network request, network request is directly transmitted.
Step 360 judges whether the domain name of network request matches regular expression.
Wherein, the regular expression, also known as regular expression, are usually used to retrieval or replace those and meet some mould The text of formula or rule.Regular expression is a kind of logical formula to string operation, exactly with some defined in advance The combination of specific character and these specific characters forms one " regular character string ", this " regular character string " is used for expressing pair A kind of filter logic of character string.
Illustratively, if the domain name used in APP have 200 " 1.fenqile.com, 2.fenqile.com ..., 100.fenqile.com " and " 1.fenqile.cn, 2.fenqile.cn ..., 100.fenqile.cn ".If according to history net The record of network request, needs " 1.fenqile.com, 2.fenqile.com ..., this 100 domains 100.fenqile.com " The network request progress IP of name is direct-connected, if need to carry out the direct-connected domain names of IP by domain name list to screen, needs 100 domains Name is filled in into domain name list, and efficiency is very low, and regular expression may be used at this time to screen.Regular expression could be provided as " .* .fenqile.com.* ", the regular expression can match " 1.fenqile.com, 2.fenqile.com ..., This 100 domain names of 100.fenqile.com ", and " 1.fenqile.cn, 2.fenqile.cn ..., 100.fenqile.cn " this 100 domain names will not be matched.The regular expression can also match other domain names with identical common characters feature, Such as " 105.fenqile.com " etc..
Specifically, judging whether the domain name of network request matches regular expression, if so, entering step 370;If it is not, Then enter step 350.
The domain name of network request is replaced with IP address and generates new network request by step 370.
Step 380 sends new network request.
The technical solution of the present embodiment is asked by obtaining current network to be sent, whether judges direct-connected mode switch It opens, when direct-connected mode switch is opened, by the domain name for judging whether to have network request in domain name list and judges network request Domain name whether match regular expression carry out the direct-connected network requests of IP screening.The technical solution of the present embodiment can be by domain List of file names matches and regular expression matching is combined, and the direct-connected opening and closing of direct-connected mode switch control IP are arranged, can To improve efficiency, coverage rate and flexibility, realize that subnetwork request progress IP is direct-connected, and improve spacing and connect into power, Realize the network connection of safety.
Example IV
Fig. 5 is the structural schematic diagram of the network connection device in the embodiment of the present invention four, which may include:
Acquisition module 410, for obtaining current network request to be sent;
Direct-connected module 420, if being used for according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, Determine that the current network request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with domain name Associated IP address is to generate new network request;
Sending module 430, for sending the new network request.
Further, the direct-connected module 420 specifically can be used for:
Determine whether the domain name in the current network request belongs to domain name white list;
If belonging to, it is determined that the current network request meets the direct-connected conditions of IP;
If being not belonging to, it is determined that whether the current network request matches with the direct-connected rules of the IP;If successful match, Determine that the current network request meets the direct-connected conditions of IP.
Further, which can also include:
Direct-connected rule module can be used for before obtaining current network request to be sent, if network request generation is different Often and/or the quantity of generation Domain Hijacking is more than preset value, then extracts the common characters feature of the domain name in the network request, And the direct-connected rules of IP are arranged according to the common characters feature.
Further, which can also include:
Switch module can be used for after obtaining current network request to be sent, if detecting preset direct-connected mould Formula switch starts, then determines the current net according to the direct-connected rule of pre-set domain name white list and/or pre-set IP Whether network request meets the direct-connected conditions of IP.
The network connection device that the embodiment of the present invention is provided can perform the network that any embodiment of the present invention is provided and connect Method is connect, has the corresponding function module of execution method and advantageous effect.
Embodiment five
Fig. 6 is the structural schematic diagram of the server in the embodiment of the present invention five.Fig. 6 is shown suitable for being used for realizing the present invention The block diagram of the exemplary servers 512 of embodiment.The server 512 that Fig. 6 is shown is only an example, should not be to the present invention The function and use scope of embodiment bring any restrictions.
As shown in fig. 6, server 512 is showed in the form of universal computing device.The component of server 512 may include but It is not limited to:One or more processor 516, system storage 528, connection different system component (including system storage 528 With processor 516) bus 518.
Bus 518 indicates one or more in a few class bus structures, including memory bus or Memory Controller, Peripheral bus, graphics acceleration port, processor 516 or total using the local of the arbitrary bus structures in a variety of bus structures Line.For example, these architectures include but not limited to industry standard architecture (ISA) bus, microchannel architecture (MAC) bus, enhanced isa bus, Video Electronics Standards Association (VESA) local bus and peripheral component interconnection (PCI) are total Line.
Server 512 typically comprises a variety of computer system readable media.These media can be it is any being capable of bedding and clothing The usable medium that business device 512 accesses, including volatile and non-volatile media, moveable and immovable medium.
System storage 528 may include the computer system readable media of form of volatile memory, such as deposit at random Access to memory (RAM) 530 and/or cache memory 532.Server 512 may further include it is other it is removable/can not Mobile, volatile/non-volatile computer system storage medium.Only as an example, storage system 534 can be used for reading and writing not Movably, non-volatile magnetic media (Fig. 6 do not show, commonly referred to as " hard disk drive ").It, can be with although being not shown in Fig. 6 It provides for the disc driver to moving non-volatile magnetic disk (such as " floppy disk ") read-write, and to removable non-volatile The CD drive of CD (such as CD-ROM, DVD-ROM or other optical mediums) read-write.In these cases, each driving Device can be connected by one or more data media interfaces with bus 518.Memory 528 may include at least one program There is one group of (for example, at least one) program module, these program modules to be configured to perform the present invention for product, the program product The function of each embodiment.
Program/utility 540 with one group of (at least one) program module 542, can be stored in such as memory In 528, such program module 542 includes but not limited to operating system, one or more application program, other program modules And program data, the realization of network environment may be included in each or certain combination in these examples.Program module 542 Usually execute the function and/or method in embodiment described in the invention.
Server 512 can also be with one or more external equipments 514 (such as keyboard, sensing equipment, display 524 etc.) Communication, can also be enabled a user to one or more equipment interact with the server 512 communicate, and/or with make the clothes Any equipment (such as network interface card, modem etc.) that business device 512 can be communicated with one or more of the other computing device Communication.This communication can be carried out by input/output (I/O) interface 522.Also, server 512 can also be suitable by network Orchestration 520 and one or more network (such as LAN (LAN), wide area network (WAN) and/or public network, such as because of spy Net) communication.As shown, network adapter 520 is communicated by bus 518 with other modules of server 512.It should be understood that Although not shown in the drawings, other hardware and/or software module can be used in conjunction with server 512, including but not limited to:Micro- generation Code, device driver, redundant processing unit, external disk drive array, RAID system, tape drive and data backup are deposited Storage system etc..
Processor 516 is stored in program in system storage 528 by operation, to perform various functions application and Data processing, such as realize the method for connecting network that the embodiment of the present invention is provided, this method includes:
Obtain current network request to be sent;
If according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, the current network is determined Request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with the associated IP address of domain name with life The network request of Cheng Xin;
Send the new network request.
Embodiment five
The embodiment of the present invention five additionally provides a kind of computer readable storage medium, is stored thereon with computer program, should Realize that the method for connecting network provided such as the embodiment of the present invention, this method include when program is executed by processor:
Obtain current network request to be sent;
If according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, the current network is determined Request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with the associated IP address of domain name with life The network request of Cheng Xin;
Send the new network request.
The arbitrary of one or more computer-readable media may be used in the computer storage media of the embodiment of the present invention Combination.Computer-readable medium can be computer-readable signal media or computer readable storage medium.It is computer-readable Storage medium for example can be-but be not limited to-electricity, magnetic, optical, electromagnetic, infrared ray or semiconductor system, device or device, Or the arbitrary above combination.The more specific example (non exhaustive list) of computer readable storage medium includes:With one The electrical connection of a or multiple conducting wires, portable computer diskette, hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, portable compact disc read-only memory (CD- ROM), light storage device, magnetic memory device or above-mentioned any appropriate combination.In this document, computer-readable storage Medium, which can be any, includes or the tangible medium of storage program, which can be commanded execution system, device or device Using or it is in connection.
Computer-readable signal media may include in a base band or as the data-signal that a carrier wave part is propagated, Wherein carry computer-readable program code.Diversified forms may be used in the data-signal of this propagation, including but unlimited In electromagnetic signal, optical signal or above-mentioned any appropriate combination.Computer-readable signal media can also be that computer can Any computer-readable medium other than storage medium is read, which can send, propagates or transmit and be used for By instruction execution system, device either device use or program in connection.
The program code for including on computer-readable medium can transmit with any suitable medium, including --- but it is unlimited In wireless, electric wire, optical cable, RF etc. or above-mentioned any appropriate combination.
It can be write with one or more programming languages or combinations thereof for executing the computer that operates of the present invention Program code, described program design language include object oriented program language-such as Java, Smalltalk, C++, Further include conventional procedural programming language-such as " C " language or similar programming language.Program code can be with It fully executes, partly execute on the user computer on the user computer, being executed as an independent software package, portion Divide and partly executes or executed on a remote computer or server completely on the remote computer on the user computer. It is related in the situation of remote computer, remote computer by the network-of any kind can include LAN (LAN) or wide Domain net (WAN)-be connected to subscriber computer, or, it may be connected to outer computer (such as provided using Internet service Quotient is connected by internet).
Note that above are only presently preferred embodiments of the present invention and institute's application technology principle.It will be appreciated by those skilled in the art that The present invention is not limited to specific embodiments described here, can carry out for a person skilled in the art it is various it is apparent variation, It readjusts and substitutes without departing from protection scope of the present invention.Therefore, although being carried out to the present invention by above example It is described in further detail, but the present invention is not limited only to above example, without departing from the inventive concept, also May include other more equivalent embodiments, and the scope of the present invention is determined by scope of the appended claims.

Claims (10)

1. a kind of method for connecting network, which is characterized in that including:
Obtain current network request to be sent;
If according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, the current network request is determined Meet the direct-connected conditions of IP, then it is new to generate that the domain name in asking the current network replaces with the associated IP address of domain name Network request;
Send the new network request.
2. according to the method described in claim 1, it is characterized in that, setting according to pre-set domain name white list and/or in advance The direct-connected rules of IP set, determine whether the current network request meets the direct-connected conditions of IP, including:
Determine whether the domain name in the current network request belongs to domain name white list;
If belonging to, it is determined that the current network request meets the direct-connected conditions of IP;
If being not belonging to, it is determined that whether the current network request matches with the direct-connected rules of the IP;If successful match, it is determined that The current network request meets the direct-connected conditions of IP.
3. according to the method described in claim 1, it is characterized in that, before obtaining current network request to be sent, including:
If the quantity that network request was abnormal and/or occurred Domain Hijacking is more than preset value, extract in the network request Domain name common characters feature, and according to the common characters feature be arranged the direct-connected rules of IP.
4. according to the method described in claim 1, it is characterized in that, after obtaining current network request to be sent, including:
If detecting, preset direct-connected mode switch starts, according to pre-set domain name white list and/or pre-set The direct-connected rules of IP determine whether the current network request meets the direct-connected conditions of IP.
5. a kind of network connection device, which is characterized in that including:
Acquisition module, for obtaining current network request to be sent;
Direct-connected module, if for according to pre-set domain name white list and/or the direct-connected rules of pre-set IP, determine described in Current network request meets the direct-connected conditions of IP, then the domain name in asking the current network replaces with the associated IP of domain name Address is to generate new network request;
Sending module, for sending the new network request.
6. according to the device described in claim 5, which is characterized in that the direct-connected module is specifically used for:
Determine whether the domain name in the current network request belongs to domain name white list;
If belonging to, it is determined that the current network request meets the direct-connected conditions of IP;
If being not belonging to, it is determined that whether the current network request matches with the direct-connected rules of the IP;If successful match, it is determined that The current network request meets the direct-connected conditions of IP.
7. device according to claim 5, which is characterized in that further include:
Direct-connected rule module is used for before obtaining current network request to be sent, if network request is abnormal and/or sends out The quantity of raw Domain Hijacking is more than preset value, then extracts the common characters feature of the domain name in the network request, and according to institute State the common characters feature setting direct-connected rules of IP.
8. device according to claim 5, which is characterized in that including:
Switch module, for after obtaining current network request to be sent, preset direct-connected mode switch to open if detecting It is dynamic, then determine that the current network request is according to the direct-connected rule of pre-set domain name white list and/or pre-set IP It is no to meet the direct-connected conditions of IP.
9. a kind of server, which is characterized in that the server includes:
One or more processors;
Storage device, for storing one or more programs;
When one or more of programs are executed by one or more of processors so that one or more of processors are real The now method for connecting network as described in any in claim 1-4.
10. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the program is by processor The method for connecting network as described in any in claim 1-4 is realized when execution.
CN201810365350.6A 2018-04-23 2018-04-23 A kind of method for connecting network, device, server and storage medium Pending CN108449428A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810365350.6A CN108449428A (en) 2018-04-23 2018-04-23 A kind of method for connecting network, device, server and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810365350.6A CN108449428A (en) 2018-04-23 2018-04-23 A kind of method for connecting network, device, server and storage medium

Publications (1)

Publication Number Publication Date
CN108449428A true CN108449428A (en) 2018-08-24

Family

ID=63200545

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810365350.6A Pending CN108449428A (en) 2018-04-23 2018-04-23 A kind of method for connecting network, device, server and storage medium

Country Status (1)

Country Link
CN (1) CN108449428A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109451053A (en) * 2018-12-18 2019-03-08 广州市百果园信息技术有限公司 Page resource request message sending method, device, medium and computer equipment
CN110633195A (en) * 2019-09-29 2019-12-31 北京博睿宏远数据科技股份有限公司 Performance data display method and device, electronic equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103607339A (en) * 2013-09-11 2014-02-26 北京京东尚科信息技术有限公司 Method and system based on content automatic adjustment mail sending strategy
CN106331215A (en) * 2016-08-30 2017-01-11 常州化龙网络科技股份有限公司 Data request processing system and processing method
CN106953898A (en) * 2017-02-28 2017-07-14 腾讯科技(深圳)有限公司 A kind of method and apparatus for obtaining software kit
CN107172176A (en) * 2017-06-02 2017-09-15 美味不用等(上海)信息科技股份有限公司 APP method for connecting network, equipment and configuration server based on configuration management
US9882868B1 (en) * 2017-01-26 2018-01-30 Red Hat, Inc. Domain name system network traffic management

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103607339A (en) * 2013-09-11 2014-02-26 北京京东尚科信息技术有限公司 Method and system based on content automatic adjustment mail sending strategy
CN106331215A (en) * 2016-08-30 2017-01-11 常州化龙网络科技股份有限公司 Data request processing system and processing method
US9882868B1 (en) * 2017-01-26 2018-01-30 Red Hat, Inc. Domain name system network traffic management
CN106953898A (en) * 2017-02-28 2017-07-14 腾讯科技(深圳)有限公司 A kind of method and apparatus for obtaining software kit
CN107172176A (en) * 2017-06-02 2017-09-15 美味不用等(上海)信息科技股份有限公司 APP method for connecting network, equipment and configuration server based on configuration management

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109451053A (en) * 2018-12-18 2019-03-08 广州市百果园信息技术有限公司 Page resource request message sending method, device, medium and computer equipment
CN109451053B (en) * 2018-12-18 2022-02-25 广州市百果园信息技术有限公司 Page resource request message sending method, device, medium and computer equipment
CN110633195A (en) * 2019-09-29 2019-12-31 北京博睿宏远数据科技股份有限公司 Performance data display method and device, electronic equipment and storage medium
CN110633195B (en) * 2019-09-29 2023-01-03 北京博睿宏远数据科技股份有限公司 Performance data display method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
CN104598257B (en) The method and apparatus of remote application operation
CN105430011B (en) A kind of method and apparatus detecting distributed denial of service attack
CN110830234B (en) User traffic distribution method and device
CN106462713B (en) The interface display method and terminal of terminal
CN105554752A (en) Hotspot sharing method and related equipment
CN108073351A (en) The date storage method and credible chip of nonvolatile storage space in chip
CN108769175A (en) Remote real machine access control method, device, storage medium and electronic equipment
CN110072268A (en) Method, equipment and the computer storage medium that wifi hotspot is shared
US10666793B1 (en) Secure call center communications
CN108540552A (en) Apparatus interconnection method, apparatus, system, equipment and storage medium
CN108449428A (en) A kind of method for connecting network, device, server and storage medium
CN103885666A (en) Transmission processing method and transmission processing system of shared information
CN107423395A (en) Navigation data processing system
CN110099041A (en) A kind of Internet of Things means of defence and equipment, system
CN108399128A (en) A kind of generation method of user data, device, server and storage medium
CN103023704A (en) Method and system for accessing virtual network service equipment
CN107766070A (en) A kind of service card upgrade method, device, equipment and computer-readable recording medium
CN115665265B (en) Request processing method, device, equipment, storage medium and system
CN110177096A (en) Client certificate method, apparatus, medium and calculating equipment
CN110213310A (en) A kind of method for obtaining path, device and the storage medium of network service
CN105991727A (en) Content pushing method and apparatus
CN113760450A (en) Automatic safety management method and device for private cloud virtual machine, terminal and storage medium
CN111800286A (en) Detection method and device of intranet assets and electronic equipment
CN111695012A (en) Method and device for acquiring internet surfing information, electronic equipment and computer storage medium
US10884673B2 (en) Virtual one-time programmable memory management

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20180824

RJ01 Rejection of invention patent application after publication