CN104539586A - Session management method and device - Google Patents
Session management method and device Download PDFInfo
- Publication number
- CN104539586A CN104539586A CN201410743120.0A CN201410743120A CN104539586A CN 104539586 A CN104539586 A CN 104539586A CN 201410743120 A CN201410743120 A CN 201410743120A CN 104539586 A CN104539586 A CN 104539586A
- Authority
- CN
- China
- Prior art keywords
- dns
- session
- tcp
- tcp session
- address
- 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
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L65/00—Network arrangements, protocols or services for supporting real-time applications in data packet communication
- H04L65/1066—Session management
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L61/00—Network arrangements, protocols or services for addressing or naming
- H04L61/45—Network directories; Name-to-address mapping
- H04L61/4505—Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols
- H04L61/4511—Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols using domain name system [DNS]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L2101/00—Indexing scheme associated with group H04L61/00
- H04L2101/60—Types of network addresses
- H04L2101/618—Details of network addresses
- H04L2101/663—Transport layer addresses, e.g. aspects of transmission control protocol [TCP] or user datagram protocol [UDP] ports
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/02—Network architectures or network communication protocols for network security for separating internal from external traffic, e.g. firewalls
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Business, Economics & Management (AREA)
- General Business, Economics & Management (AREA)
- Multimedia (AREA)
- Computer And Data Communications (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
本发明提供了一种会话管理方法和装置。涉及互联网领域;解决了防火墙会话数资源紧张的问题。该方法包括:为每个DNS客户端建立唯一的传输控制协议TCP会话;接收承载于用户数据包协议UDP会话的域名系统DNS查询请求;确认所述UDP会话对应的DNS客户端的TCP会话,通过所述TCP会话向DNS服务器转发所述DNS查询请求。本发明提供的技术方案适用于DNS查询过程,实现了在防火墙上将多个UDP会话汇聚成为一个TCP会话。
The invention provides a session management method and device. It involves the Internet field; it solves the problem of resource shortage of firewall sessions. The method includes: establishing a unique Transmission Control Protocol TCP session for each DNS client; receiving a Domain Name System DNS query request carried in the User Datagram Protocol UDP session; confirming the TCP session of the DNS client corresponding to the UDP session, and passing the The TCP session forwards the DNS query request to the DNS server. The technical solution provided by the invention is applicable to the DNS query process, and realizes the aggregation of multiple UDP sessions into one TCP session on the firewall.
Description
技术领域technical field
本发明涉及互联网领域,尤其涉及一种会话管理方法和装置。The invention relates to the Internet field, in particular to a session management method and device.
背景技术Background technique
随着互联网爆炸式发展,特别是网页中外链接和图片越来越多,网络上的域名系统(DNS,Domain Name System)报文越来越多,而每个DNS查询都会占用一个防火墙的会话,且如果这个DNS查询多承载在用户数据包协议(UDP,User Datagram Protocol)上,则查询结束无法主动释放会话,会浪费大量防火墙会话数。目前测算,DNS已经占整个网络20%的会话数目,防火墙上的会话数资源日趋紧张。With the explosive development of the Internet, especially with more and more internal and external links and pictures on the webpage, there are more and more Domain Name System (DNS, Domain Name System) messages on the network, and each DNS query will occupy a session of the firewall. And if the DNS query is mostly carried on the User Datagram Protocol (UDP, User Datagram Protocol), the session cannot be actively released after the query ends, and a large number of firewall sessions will be wasted. According to current calculations, DNS has already accounted for 20% of the number of sessions in the entire network, and the number of sessions on the firewall is increasingly tight.
发明内容Contents of the invention
本发明提供了一种会话管理方法和装置,解决了防火墙会话数资源紧张的问题。The invention provides a session management method and device, which solves the problem of shortage of firewall session number resources.
一种会话管理方法,包括:A session management method comprising:
为每个DNS客户端建立唯一的传输控制协议TCP会话;Establish a unique Transmission Control Protocol TCP session for each DNS client;
接收承载于用户数据包协议UDP会话的域名系统DNS查询请求;receiving a domain name system DNS query request carried in a UDP session;
确认所述UDP会话对应的DNS客户端的TCP会话,通过所述TCP会话向DNS服务器转发所述DNS查询请求。Confirm the TCP session of the DNS client corresponding to the UDP session, and forward the DNS query request to the DNS server through the TCP session.
优选的,所述为每个DNS客户端建立唯一的TCP会话包括:Preferably, the establishment of a unique TCP session for each DNS client includes:
在首次接收到所述用户发送的DNS查询报文时,根据所述DNS查询报文携带的五元组建立TCP会话所述,五元组包括:DNS客户端地址、DNS服务端地址、本地分配端口号、53端口和PROTO.TCP;When receiving the DNS query message sent by the user for the first time, establish a TCP session according to the five-tuple carried by the DNS query message. The five-tuple includes: DNS client address, DNS server address, local allocation Port number, port 53 and PROTO.TCP;
以DNS客户端地址、DNS服务端地址和查询请求编号TransID为索引建立所述TCP会话的映射表。A mapping table of the TCP session is established with the DNS client address, the DNS server address and the query request number TransID as indexes.
优选的,确认所述UDP会话对应的DNS客户端的TCP会话,通过所述TCP会话向DNS服务器转发所述DNS查询请求包括:Preferably, confirming the TCP session of the DNS client corresponding to the UDP session, forwarding the DNS query request to the DNS server through the TCP session includes:
提取接收到的DNS查询请求的DNS客户端地址、DNS服务端地址和TransID;Extract the DNS client address, DNS server address and TransID of the received DNS query request;
根据所述DNS查询请求的DNS客户端地址、DNS服务端地址和TransID查询所述映射表,确定相应的TCP会话。The mapping table is queried according to the DNS client address, the DNS server address, and the TransID requested by the DNS query, and a corresponding TCP session is determined.
优选的,该方法还包括:Preferably, the method also includes:
接收DNS服务器发送的承载于TCP会话的DNS应答报文;Receive the DNS response message carried by the TCP session sent by the DNS server;
根据该DNS应答报文的DNS客户端地址、DNS服务端地址和TransID,查找所述映射表,找到归属的UDP会话;Search the mapping table according to the DNS client address, DNS server address and TransID of the DNS response message, and find the belonging UDP session;
将所述DNS应答报文承载于归属的UDP会话中,向DNS客户端发送。Carry the DNS response message in the UDP session to which it belongs, and send it to the DNS client.
本发明还提供了一种会话管理装置,包括:The present invention also provides a session management device, including:
TCP会话建立模块,用于为每个DNS客户端建立唯一的TCP会话;A TCP session establishment module, used to establish a unique TCP session for each DNS client;
请求接收模块,用于接收承载于UDP会话的DNS查询请求;A request receiving module, configured to receive a DNS query request carried in a UDP session;
承载转换模块,用于确认所述UDP会话对应的DNS客户端的TCP会话,通过所述TCP会话向DNS服务器转发所述DNS查询请求。The bearer conversion module is configured to confirm the TCP session of the DNS client corresponding to the UDP session, and forward the DNS query request to the DNS server through the TCP session.
优选的,所述TCP会话建立模块包括:Preferably, the TCP session establishment module includes:
会话创建单元,用于在首次接收到所述用户发送的DNS查询报文时,根据所述DNS查询报文携带的DNS客户端地址、DNS服务端地址、本地分配端口号、53端口和PROTO.TCP为五元组建立TCP会话;The session creation unit is configured to, when receiving the DNS query message sent by the user for the first time, according to the DNS client address, DNS server address, locally assigned port number, port 53 and PROTO. TCP establishes a TCP session for the five-tuple;
映射管理单元,用于以DNS客户端地址、DNS服务端地址和TransID为索引建立所述TCP会话的映射表。The mapping management unit is configured to use DNS client address, DNS server address and TransID as indexes to establish the mapping table of the TCP session.
优选的,所述承载转换模块包括:Preferably, the bearer conversion module includes:
信息提取单元,用于提取接收到的DNS查询请求的DNS客户端地址、DNS服务端地址和TransID;An information extraction unit, configured to extract the DNS client address, DNS server address and TransID of the DNS query request received;
查询单元,用于根据所述DNS查询请求的DNS客户端地址、DNS服务端地址和TransID查询所述映射表,确定相应的TCP会话;A query unit, configured to query the mapping table according to the DNS client address, DNS server address and TransID requested by the DNS query, and determine the corresponding TCP session;
转换单元,用于将所述DNS查询请求承载于所述相应的TCP会话上,向DNS服务器发送。A conversion unit, configured to carry the DNS query request on the corresponding TCP session and send it to the DNS server.
优选的,该装置还包括:Preferably, the device also includes:
应答接收模块,用于接收DNS服务器发送的承载于TCP会话的DNS应答报文;A response receiving module, configured to receive a DNS response message sent by a DNS server and carried in a TCP session;
UDP会话查询模块,用于根据该DNS应答报文的DNS客户端地址、DNS服务端地址、TransID,查找所述映射表,找到归属的UDP会话;The UDP session query module is used to search the mapping table according to the DNS client address, DNS server address, and TransID of the DNS response message, and find the belonging UDP session;
报文转发模块,用于将所述DNS应答报文承载于归属的UDP会话中,向DNS客户端发送。A message forwarding module, configured to carry the DNS response message in the UDP session to which it belongs, and send it to the DNS client.
本发明提供了一种会话管理方法和装置,为每个用户建立唯一的TCP会话,接收承载于UDP会话的DNS,确认所述UDP会话对应的DNS客户端的TCP会话,通过所述TCP会话向DNS服务器转发所述DNS查询请求。实现了在防火墙上将多个UDP会话汇聚成为一个TCP会话,减少了资源占用,解决了防火墙会话数资源紧张的问题。The present invention provides a session management method and device, which establishes a unique TCP session for each user, receives the DNS carried in the UDP session, confirms the TCP session of the DNS client corresponding to the UDP session, and reports to DNS through the TCP session. The server forwards the DNS query request. It realizes the convergence of multiple UDP sessions into one TCP session on the firewall, reduces resource occupation, and solves the problem of resource shortage of firewall sessions.
附图说明Description of drawings
图1为本发明的实施例一提供的一种会话管理方法的流程图;FIG. 1 is a flowchart of a session management method provided by Embodiment 1 of the present invention;
图2为DNS会话汇聚流程图;Fig. 2 is a flow chart of DNS session aggregation;
图3为DNS会话反向映射流程图;Fig. 3 is a DNS session reverse mapping flow chart;
图4为本发明的实施例二提供的一种会话管理装置的结构示意图;FIG. 4 is a schematic structural diagram of a session management device provided by Embodiment 2 of the present invention;
图5为图4中TCP会话建立模块的结构示意图;Fig. 5 is a schematic structural diagram of a TCP session establishment module in Fig. 4;
图6为图4中承载转换模块403的结构示意图。FIG. 6 is a schematic structural diagram of the bearer conversion module 403 in FIG. 4 .
具体实施方式Detailed ways
每个DNS查询都会占用一个防火墙的会话,且如果这个DNS查询多承载在UDP上,则查询结束无法主动主动释放会话,会浪费大量防火墙会话数。Each DNS query will occupy a session of the firewall, and if the DNS query is mostly carried on UDP, the session cannot be actively released after the query is completed, and a large number of firewall sessions will be wasted.
为了解决上述问题,本发明的实施例提供了一种会话管理方法和装置。在用户面功能实体(SAE-GW,System Architecture Evolution Gateway)实现DNS汇聚功能,利用一种映射方式,将一个用户发起的多个DNS UDP会话,汇聚成一个TCP会话发送给DNS服务器,达到减少PDN侧会话数的目的。In order to solve the above problems, embodiments of the present invention provide a session management method and device. The DNS aggregation function is implemented in the user plane functional entity (SAE-GW, System Architecture Evolution Gateway). Using a mapping method, multiple DNS UDP sessions initiated by a user are aggregated into one TCP session and sent to the DNS server to reduce PDN. side session count purposes.
下文中将结合附图对本发明的实施例进行详细说明。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互任意组合。Embodiments of the present invention will be described in detail below in conjunction with the accompanying drawings. It should be noted that, in the case of no conflict, the embodiments in the present application and the features in the embodiments can be combined arbitrarily with each other.
本发明中所述方法是在SAE-GW上实现DNS UDP会话的汇聚,使一个用户发起的DNS UDP会话,汇聚成一个与DNS服务器的TCP会话。The method described in the present invention is to realize the aggregation of DNS UDP sessions on the SAE-GW, so that the DNS UDP sessions initiated by a user are aggregated into a TCP session with the DNS server.
首先结合附图,对本发明的实施例一进行说明。First, Embodiment 1 of the present invention will be described with reference to the accompanying drawings.
本发明实施例提供了一种会话管理方法,在用户发起一次web访问的过程中,有多次DNS查询(参见图1),且每次查询端口号不同。SAE-GW收到第一个UDP的查询时,由SAE-GW与DNS服务器建立一个TCP会话,并把该次查询的内容承载在该TCP会话上发送给DNS服务器,同时SAE-GW上保存该用户该次查询的UDP会话信息。SAE-GW收到查询结果后,反向映射到用户的UDP会话上,发送给用户。后续的DNS查询,都走同一个TCP会话。The embodiment of the present invention provides a session management method. During a web access process initiated by a user, there are multiple DNS queries (see FIG. 1 ), and each query port number is different. When SAE-GW receives the first UDP query, SAE-GW establishes a TCP session with the DNS server, and sends the content of the query to the DNS server on the TCP session, and saves the content on the SAE-GW at the same time. UDP session information queried by the user this time. After SAE-GW receives the query result, it maps back to the user's UDP session and sends it to the user. Subsequent DNS queries all go through the same TCP session.
根据DNS协议,DNS报文中的查询请求编号(TransID)由DNS客户端分配,每次查询分配一个,所以以DNS客户端地址+DNS服务端地址+TransID为索引建立映射表可以唯一确定一个DNS UDP会话,实现UDP会话到TCP会话的多对一映射。According to the DNS protocol, the query request number (TransID) in the DNS message is allocated by the DNS client, and one is allocated for each query. Therefore, a DNS can be uniquely determined by establishing a mapping table with the DNS client address + DNS server address + TransID as the index. UDP session, realize the many-to-one mapping from UDP session to TCP session.
具体实施方式是:The specific implementation method is:
图1为本发明实施例的DNS会话汇聚交互图,包括以下步骤:Fig. 1 is the DNS session aggregation interactive figure of the embodiment of the present invention, comprises the following steps:
步骤101、DNS客户端发起DNS查询,建立DNS UDP会话1。Step 101, the DNS client initiates a DNS query, and establishes a DNS UDP session 1.
步骤102、SAE-GW使用“DNS客户端地址、DNS服务端地址、本地分配端口号1、53端口、PROTO.TCP”为五元组与DNS服务器建立TCP会话1,其中,53端口是为DNS服务包传输预留的端口,PROTO.TCP表明该会话的类型为TCP会话。本发明实施例中,为每个用户建立唯一的TCP会话,将来自于同一用户的UDP会话汇聚于同一TCP会话。在首次接收到所述用户发送的DNS查询报文时,根据所述DNS查询报文携带的DNS客户端地址、DNS服务端地址、本地分配端口号、53端口、PROTO.TCP为五元组建立TCP会话;以DNS客户端地址、DNS服务端地址、TransID为索引建立所述TCP会话的映射表。Step 102, SAE-GW uses "DNS client address, DNS server address, locally assigned port number 1, port 53, PROTO.TCP" to establish a TCP session 1 with the DNS server for the quintuple, wherein port 53 is for DNS Port reserved for service packet transmission, PROTO.TCP indicates that the session type is a TCP session. In the embodiment of the present invention, a unique TCP session is established for each user, and UDP sessions from the same user are aggregated into the same TCP session. When receiving the DNS query message sent by the user for the first time, according to the DNS client address, DNS server address, locally assigned port number, port 53, and PROTO.TCP carried by the DNS query message, the five-tuple is established A TCP session; establishing a mapping table of the TCP session with DNS client address, DNS server address, and TransID as indexes.
步骤103、SAE-GW将DNS UDP会话1的查询请求,承载在TCP会话1上,发送给DNS服务器,同时保存DNS UDP会话1。Step 103, SAE-GW carries the query request of DNS UDP session 1 on TCP session 1, sends it to the DNS server, and saves DNS UDP session 1 at the same time.
在完成TCP会话的创建后,SAE-GW即可将接收到的承载于UDP会话DNS查询请求的承载到该UDP会话对应的用户的TCP会话上,通过TCP会话向DNS服务器转发所述DNS查询请求。在接收到DNS查询请求时,提取接收到的DNS查询请求的DNS客户端地址、DNS服务端地址、TransID,再根据所述DNS查询请求的DNS客户端地址、DNS服务端地址、TransID查询所述映射表,确定相应的TCP会话将所述DNS查询请求承载于所述相应的TCP会话上,向DNS服务器发送。After the creation of the TCP session is completed, the SAE-GW can carry the DNS query request received in the UDP session to the TCP session of the user corresponding to the UDP session, and forward the DNS query request to the DNS server through the TCP session . When a DNS query request is received, extract the DNS client address, DNS server address, and TransID of the DNS query request received, and then query the DNS client address, DNS server address, and TransID according to the DNS query request. The mapping table determines the corresponding TCP session, carries the DNS query request on the corresponding TCP session, and sends it to the DNS server.
步骤104、SAE-GW收到承载TCP会话1上的应答消息,反向映射到UDP会话1上。In step 104, the SAE-GW receives the response message on the bearer TCP session 1, and reversely maps it to the UDP session 1.
在接收到DNS服务器发送的承载于TCP会话的DNS应答报文时,亦可根据该DNS应答报文的DNS客户端地址、DNS服务端地址、TransID,查找所述映射表,找到归属的UDP会话,将所述DNS应答报文承载于归属的UDP会话中,向DNS客户端发送。When receiving the DNS response message sent by the DNS server and carried in the TCP session, the mapping table can also be searched according to the DNS client address, DNS server address, and TransID of the DNS response message to find the UDP session to which it belongs. , carrying the DNS response message in the belonging UDP session, and sending it to the DNS client.
步骤105、SAE-GW将DNS应答承载的UDP会话1上发送给DNS客户端。Step 105, the SAE-GW sends the UDP session 1 carried by the DNS response to the DNS client.
步骤106、DNS客户端发新的DNS查询,建立DNS UDP会话2。Step 106, the DNS client sends a new DNS query, and establishes a DNS UDP session 2.
步骤107、SAE-GW将DNS UDP会话2的查询请求,承载在TCP会话1上,发送给DNS服务器,同时保存DNS UDP会话2。Step 107, SAE-GW carries the query request of DNS UDP session 2 on TCP session 1, sends it to the DNS server, and saves DNS UDP session 2 at the same time.
步骤108、SAE-GW收到承载TCP会话1上的应答消息,反向映射到UDP会话2上。In step 108, the SAE-GW receives the response message on bearer TCP session 1, and reversely maps it to UDP session 2.
步骤109、SAE-GW将DNS应答承载的UDP会话2上发送给DNS客户端。Step 109, the SAE-GW sends the UDP session 2 carried by the DNS response to the DNS client.
图2是DNS会话汇聚流程图,包括如下步骤:Figure 2 is a flowchart of DNS session aggregation, including the following steps:
步骤201、SAE-GW收到DNS查询报文触发DNS会话汇聚处理流程。In step 201, the SAE-GW receives a DNS query message and triggers a DNS session aggregation process.
步骤202、判断是否已建立TCP会话,已建立进入步骤204、未建立进入步骤203。Step 202, judging whether the TCP session has been established, if established, proceed to step 204, and if not established, proceed to step 203.
步骤203、以(DNS客户端地址、DNS服务端地址、本地分配端口号、53、PROTO.TCP)为五元组建立TCP会话。Step 203: Establish a TCP session with (DNS client address, DNS server address, locally assigned port number, 53, PROTO.TCP) as a quintuple.
步骤204、以(DNS客户端地址、DNS服务端地址、TransID)为索引建立映射表。Step 204: Establish a mapping table with (DNS client address, DNS server address, TransID) as an index.
步骤205、该DNS查询报文承载在TCP会话上发送到DNS服务端。Step 205, the DNS query message is carried on the TCP session and sent to the DNS server.
图3是DNS会话反向映射流程图,包括如下步骤:Figure 3 is a flow chart of DNS session reverse mapping, including the following steps:
步骤301、SAE-GW收到DNS应答报文触发DNS会话反向映射处理流程。In step 301, the SAE-GW receives a DNS response message and triggers a DNS session reverse mapping process.
步骤302、以(DNS客户端地址、DNS服务端地址、TransID)为索引查找映射表,找到归属的UDP会话。Step 302, look up the mapping table with (DNS client address, DNS server address, TransID) as an index, and find the belonging UDP session.
步骤303、该DNS应答报文承载在原UDP会话上发送到DNS客户端。Step 303, the DNS response message is carried on the original UDP session and sent to the DNS client.
下面结合附图,对本发明的实施例二进行说明。Embodiment 2 of the present invention will be described below with reference to the accompanying drawings.
本发明实施例提供了一种会话管理装置,该装置的结构如图4所示,包括:An embodiment of the present invention provides a session management device, the structure of which is shown in Figure 4, including:
TCP会话建立模块401,用于为每个用户建立唯一的TCP会话;A TCP session establishment module 401, configured to set up a unique TCP session for each user;
请求接收模块402,用于接收承载于UDP会话的DNS查询请求;A request receiving module 402, configured to receive a DNS query request carried in a UDP session;
承载转换模块403,用于确认所述UDP会话对应的DNS客户端的TCP会话,通过所述TCP会话向DNS服务器转发所述DNS查询请求。The bearer conversion module 403 is configured to confirm the TCP session of the DNS client corresponding to the UDP session, and forward the DNS query request to the DNS server through the TCP session.
优选的,所述TCP会话建立模块401的结构如图5所示,包括:Preferably, the structure of the TCP session establishment module 401 is as shown in Figure 5, including:
会话创建单元4011,用于在首次接收到所述用户发送的DNS查询报文时,根据所述DNS查询报文携带的DNS客户端地址、DNS服务端地址、本地分配端口号、53端口、PROTO.TCP为五元组建立TCP会话;The session creation unit 4011 is configured to, when receiving the DNS query message sent by the user for the first time, according to the DNS client address, DNS server address, locally assigned port number, port 53, PROTO .TCP establishes a TCP session for the five-tuple;
映射管理单元4012,用于以DNS客户端地址、DNS服务端地址、TransID为索引建立所述TCP会话的映射表。The mapping management unit 4012 is configured to use the DNS client address, DNS server address, and TransID as indexes to create a mapping table for the TCP session.
优选的,所述承载转换模块403的结构如图6所示,包括:Preferably, the structure of the bearer conversion module 403 is as shown in Figure 6, including:
信息提取单元4031,用于提取接收到的DNS查询请求的DNS客户端地址、DNS服务端地址、TransID;An information extraction unit 4031, configured to extract the DNS client address, DNS server address, and TransID of the DNS query request received;
查询单元4032,用于根据所述DNS查询请求的DNS客户端地址、DNS服务端地址、TransID查询所述映射表,确定相应的TCP会话;The query unit 4032 is configured to query the mapping table according to the DNS client address, DNS server address, and TransID requested by the DNS query, and determine the corresponding TCP session;
转换单元4033,用于将所述DNS查询请求承载于所述相应的TCP会话上,向DNS服务器发送。The conversion unit 4033 is configured to carry the DNS query request on the corresponding TCP session and send it to the DNS server.
优选的,该装置还包括:Preferably, the device also includes:
应答接收模块404,用于接收DNS服务器发送的承载于TCP会话的DNS应答报文;A response receiving module 404, configured to receive a DNS response message sent by the DNS server and carried in the TCP session;
UDP会话查询模块405,用于根据该DNS应答报文的DNS客户端地址、DNS服务端地址、TransID,查找所述映射表,找到归属的UDP会话;The UDP session query module 405 is used to search the mapping table according to the DNS client address, DNS server address, and TransID of the DNS response message, and find the belonging UDP session;
报文转发模块406,用于将所述DNS应答报文承载于归属的UDP会话中,向DNS客户端发送。A message forwarding module 406, configured to carry the DNS response message in the UDP session to which it belongs, and send it to the DNS client.
上述会话管理装置可集成于SAE-GW,由SAE-GW完成相应功能。The above session management device can be integrated in the SAE-GW, and the SAE-GW can complete corresponding functions.
本发明的实施例提供了一种会话管理方法和装置,为每个用户建立唯一的TCP会话,接收承载于UDP会话的DNS,确认所述UDP会话对应的DNS客户端的TCP会话,通过所述TCP会话向DNS服务器转发所述DNS查询请求。实现了在防火墙上将多个UDP会话汇聚成为一个TCP会话,减少了资源占用,解决了防火墙会话数资源紧张的问题。The embodiment of the present invention provides a session management method and device, which establishes a unique TCP session for each user, receives the DNS carried in the UDP session, confirms the TCP session of the DNS client corresponding to the UDP session, and passes the TCP The session forwards the DNS query request to the DNS server. It realizes the convergence of multiple UDP sessions into one TCP session on the firewall, reduces resource occupation, and solves the problem of resource shortage of firewall sessions.
本领域普通技术人员可以理解上述实施例的全部或部分步骤可以使用计算机程序流程来实现,所述计算机程序可以存储于一计算机可读存储介质中,所述计算机程序在相应的硬件平台上(如系统、设备、装置、器件等)执行,在执行时,包括方法实施例的步骤之一或其组合。Those of ordinary skill in the art can understand that all or part of the steps of the above-mentioned embodiments can be implemented using a computer program flow, the computer program can be stored in a computer-readable storage medium, and the computer program can be run on a corresponding hardware platform (such as system, device, device, device, etc.), and when executed, includes one or a combination of the steps of the method embodiment.
可选地,上述实施例的全部或部分步骤也可以使用集成电路来实现,这些步骤可以被分别制作成一个个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明不限制于任何特定的硬件和软件结合。Optionally, all or part of the steps in the above embodiments can also be implemented using integrated circuits, and these steps can be fabricated into individual integrated circuit modules, or multiple modules or steps among them can be fabricated into a single integrated circuit module accomplish. As such, the present invention is not limited to any specific combination of hardware and software.
上述实施例中的各装置/功能模块/功能单元可以采用通用的计算装置来实现,它们可以集中在单个的计算装置上,也可以分布在多个计算装置所组成的网络上。The devices/functional modules/functional units in the above embodiments can be realized by general-purpose computing devices, and they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices.
上述实施例中的各装置/功能模块/功能单元以软件功能模块的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。上述提到的计算机可读取存储介质可以是只读存储器,磁盘或光盘等。When each device/functional module/functional unit in the above-mentioned embodiments is realized in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. The computer-readable storage medium mentioned above may be a read-only memory, a magnetic disk or an optical disk, and the like.
任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应以权利要求所述的保护范围为准。Anyone skilled in the art within the technical scope disclosed in the present invention can easily think of changes or substitutions, which should be covered by the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope described in the claims.
Claims (8)
Priority Applications (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201410743120.0A CN104539586A (en) | 2014-12-08 | 2014-12-08 | Session management method and device |
| PCT/CN2015/084702 WO2016090921A1 (en) | 2014-12-08 | 2015-07-21 | Session control method and device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201410743120.0A CN104539586A (en) | 2014-12-08 | 2014-12-08 | Session management method and device |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN104539586A true CN104539586A (en) | 2015-04-22 |
Family
ID=52855055
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201410743120.0A Pending CN104539586A (en) | 2014-12-08 | 2014-12-08 | Session management method and device |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN104539586A (en) |
| WO (1) | WO2016090921A1 (en) |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2016090921A1 (en) * | 2014-12-08 | 2016-06-16 | 中兴通讯股份有限公司 | Session control method and device |
| CN107872503A (en) * | 2016-11-07 | 2018-04-03 | 中国移动通信集团湖南有限公司 | A method and device for monitoring the number of firewall sessions |
| CN109474667A (en) * | 2018-10-12 | 2019-03-15 | 广州雷迅创新科技有限公司 | A kind of UAV Communication method based on TCP and UDP |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109361749B (en) | 2018-10-24 | 2022-03-29 | 华为云计算技术有限公司 | Message processing method, related equipment and computer storage medium |
| CN113810349B (en) * | 2020-06-17 | 2023-05-12 | 腾讯科技(深圳)有限公司 | Data transmission method, device, computer equipment and storage medium |
Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101212522A (en) * | 2006-12-29 | 2008-07-02 | 华为技术有限公司 | Method, device and system for associating sessions |
| CN101217788A (en) * | 2008-01-08 | 2008-07-09 | 中兴通讯股份有限公司 | A calling method for multimedia session continuity service |
| CN101227728A (en) * | 2008-02-04 | 2008-07-23 | 中兴通讯股份有限公司 | A session merging method for multimedia session continuity service |
| US20100191863A1 (en) * | 2009-01-23 | 2010-07-29 | Cisco Technology, Inc., A Corporation Of California | Protected Device Initiated Pinhole Creation to Allow Access to the Protected Device in Response to a Domain Name System (DNS) Query |
| CN102185723A (en) * | 2011-05-27 | 2011-09-14 | 杭州迪普科技有限公司 | Session management method and device |
Family Cites Families (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101547134B (en) * | 2008-03-27 | 2011-12-28 | 北京铭万互联科技有限公司 | Method and system for mutually converting UDP connection and TCP connection and transfer server |
| CN102480477B (en) * | 2010-11-30 | 2015-03-11 | 中国移动通信集团北京有限公司 | Method, device and system for accessing service by client terminal |
| US9396330B2 (en) * | 2013-05-15 | 2016-07-19 | Citrix Systems, Inc. | Systems and methods for reducing denial of service attacks against dynamically generated next secure records |
| CN104539586A (en) * | 2014-12-08 | 2015-04-22 | 中兴通讯股份有限公司 | Session management method and device |
-
2014
- 2014-12-08 CN CN201410743120.0A patent/CN104539586A/en active Pending
-
2015
- 2015-07-21 WO PCT/CN2015/084702 patent/WO2016090921A1/en not_active Ceased
Patent Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101212522A (en) * | 2006-12-29 | 2008-07-02 | 华为技术有限公司 | Method, device and system for associating sessions |
| CN101217788A (en) * | 2008-01-08 | 2008-07-09 | 中兴通讯股份有限公司 | A calling method for multimedia session continuity service |
| CN101227728A (en) * | 2008-02-04 | 2008-07-23 | 中兴通讯股份有限公司 | A session merging method for multimedia session continuity service |
| US20100191863A1 (en) * | 2009-01-23 | 2010-07-29 | Cisco Technology, Inc., A Corporation Of California | Protected Device Initiated Pinhole Creation to Allow Access to the Protected Device in Response to a Domain Name System (DNS) Query |
| CN102185723A (en) * | 2011-05-27 | 2011-09-14 | 杭州迪普科技有限公司 | Session management method and device |
Cited By (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2016090921A1 (en) * | 2014-12-08 | 2016-06-16 | 中兴通讯股份有限公司 | Session control method and device |
| CN107872503A (en) * | 2016-11-07 | 2018-04-03 | 中国移动通信集团湖南有限公司 | A method and device for monitoring the number of firewall sessions |
| CN107872503B (en) * | 2016-11-07 | 2020-08-14 | 中国移动通信集团湖南有限公司 | Method and device for monitoring the number of firewall sessions |
| CN109474667A (en) * | 2018-10-12 | 2019-03-15 | 广州雷迅创新科技有限公司 | A kind of UAV Communication method based on TCP and UDP |
| CN109474667B (en) * | 2018-10-12 | 2021-05-25 | 广州雷迅创新科技股份有限公司 | Unmanned aerial vehicle communication method based on TCP and UDP |
Also Published As
| Publication number | Publication date |
|---|---|
| WO2016090921A1 (en) | 2016-06-16 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN103780679B (en) | Long-delay remote call method based on HTTP protocol | |
| WO2015143983A1 (en) | Method and apparatus for implementing acceleration processing on vnf | |
| CN106375176A (en) | Method for accessing physical machine to cloud platform | |
| CN104780115A (en) | Load balancing method and load balancing system in cloud computing environment | |
| WO2015096681A1 (en) | Method and device for processing service access | |
| WO2022116848A1 (en) | Packet transmission method and apparatus, computer device, and storage medium | |
| CN102377833B (en) | Method and device for managing network address translation | |
| CN104539586A (en) | Session management method and device | |
| WO2013097484A1 (en) | Method, server and system for balancing loads of virtual machine cluster | |
| CN109040232A (en) | Load balancing method, device and equipment for video conference and storage medium thereof | |
| EP3113539A1 (en) | Load balancing user plane traffic in a telecommunication network | |
| CN104780232B (en) | A kind of resource allocation methods, controller and system | |
| CN103780467A (en) | Communication connection method, communication device and communication system | |
| CN103581325A (en) | Cloud computing resource pool system and implement method thereof | |
| CN106210058A (en) | A kind of reverse proxy method of multi-core parallel concurrent | |
| CN106411742B (en) | Method and device for message transmission | |
| CN111124589A (en) | A service discovery system, method, apparatus and device | |
| CN105657078B (en) | A kind of data transmission method, device and multitiered network manager | |
| CN105279263A (en) | Database connection system and method capable of supporting multi-application sharing | |
| CN105791147B (en) | Load balancer connection method, service instantiation deployment method and device | |
| CN104735073B (en) | IPv4-IPv6 transition protocols dispatching method and device | |
| CN104488240A (en) | Session management method, address management method and relevant device | |
| US8855015B2 (en) | Techniques for generic pruning in a trill network | |
| CN105681266B (en) | A kind of communication cluster method and device of mediaphone MMTel | |
| CN104753852A (en) | Virtualization platform and security protection method and device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| WD01 | Invention patent application deemed withdrawn after publication | ||
| WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20150422 |