US-20260128922-A1 - WIRELESS COMMUNICATION METHOD, COMMUNICATION APPARATUS, AND COMMUNICATION SYSTEM
Abstract
A wireless communication method includes: obtaining subnet information of a first subnet corresponding to a first session; receiving a data packet, where the data packet is a multicast packet or a broadcast packet; determining, based on the subnet information, that the data packet corresponds to the first session in the first subnet; and sending the data packet via the first session.
Inventors
- Pengtao ZHAO
- Yan Li
Assignees
- HUAWEI TECHNOLOGIES CO., LTD.
Dates
- Publication Date
- 20260507
- Application Date
- 20251219
- Priority Date
- 20210312
Claims (20)
- 1 - 20 . (canceled)
- 21 . A method, comprising:obtaining, by a session management network element, subnet information of a first subnet corresponding to a first session;sending, by the session management network element, the subnet information to a user plane network element;receiving, by the user plane network element, the subnet information;receiving, by the user plane network element, a data packet, wherein the data packet is a multicast packet or a broadcast packet;determining, by the user plane network element and based on the subnet information, that the data packet corresponds to the first session in the first subnet; andsending, by the user plane network element, the data packet via the first session.
- 22 . The method according to claim 21 , wherein determining, based on the subnet information, that the data packet corresponds to the first session in the first subnet comprises:determining subnet information corresponding to a source Internet Protocol (IP) address in the data packet; andwhen the subnet information corresponding to the first session is the same as the subnet information corresponding to the source IP address in the data packet, determining that the data packet corresponds to the first session.
- 23 . The method according to claim 21 , wherein sending, by the session management network element, the subnet information to the user plane network element comprises:sending, by the session management network element, a packet detection rule to the user plane network element, wherein the packet detection rule comprises the subnet information; and wherein receiving, by the user plane network element, the subnet information comprises:receiving, by the user plane network element, the packet detection rule from the session management network element.
- 24 . The method according to claim 23 , further comprising:sending, by the session management network element, indication information to the user plane network element, wherein the indication information indicates to detect a data packet used for configuring internet protocol (IP) information for the first session, and the first session is an EtherType session;receiving, by the user plane network element, the indication information from the session management network element;detecting, by the user plane network element, and based on the indication information, the data packet used for configuring IP information for the first session, wherein the data packet used for configuring IP information for the first session comprises IP information corresponding to the first session;sending, by the user plane network element, the IP information corresponding to the first session to the session management network element, wherein the IP information corresponding to the first session is used to determine the subnet information;receiving, by the session management network element and from the user plane network element, the IP information corresponding to the first session; anddetermining, by the session management network element, the subnet information based on the IP information corresponding to the first session.
- 25 . The method according to claim 21 , wherein determining, by the user plane network element and based on the subnet information, that the data packet corresponds to the first session in the first subnet comprises:obtaining, by the user plane network element, an identifier of a first virtual local area network (VLAN) in the data packet;obtaining a VLAN set, wherein the VLAN set comprises one or more VLANs in the first subnet; andwhen the first VLAN belongs to the VLAN set, determining that the data packet corresponds to the first session.
- 26 . The method according to claim 25 , wherein obtaining the VLAN set comprises:receiving a packet detection rule from the session management network element, wherein the packet detection rule comprises the VLAN set.
- 27 . The method according to claim 21 , wherein obtaining the subnet information comprises:receiving the subnet information from an authentication, authorization and accounting server or a terminal.
- 28 . The method according to claim 27 , further comprising:sending, by the authentication, authorization and accounting server, or by the terminal, the subnet information.
- 29 . A system, comprising:a session management network element, configured to:obtain subnet information of a first subnet corresponding to a first session; andsend the subnet information to a user plane network element; andthe user plane network element, configured to:receive the subnet information;receive a data packet, wherein the data packet is a multicast packet or a broadcast packet;determine, based on the subnet information, that the data packet corresponds to the first session in the first subnet; andsend the data packet via the first session.
- 30 . The system according to claim 29 , wherein determining, based on the subnet information, that the data packet corresponds to the first session in the first subnet comprises:determining subnet information corresponding to a source Internet Protocol (IP) address in the data packet; andwhen the subnet information corresponding to the first session is the same as the subnet information corresponding to the source IP address, determining that the data packet corresponds to the first session.
- 31 . The system according to claim 29 , wherein sending the subnet information to the user plane network element comprises:sending a packet detection rule to the user plane network element, wherein the packet detection rule comprises the subnet information; andwherein receiving the subnet information comprises:receiving the packet detection rule from the session management network element.
- 32 . The system according to claim 31 , wherein the session management network element is further configured to:send indication information to the user plane network element, wherein the indication information indicates to detect a data packet used for configuring internet protocol (IP) information for the first session, and the first session is an EtherType session; andwherein the user plane network element is further configured to:receive the indication information from the session management network element; detect, based on the indication information, the data packet used for configuring IP information for the first session, wherein the data packet used for configuring IP information for the first session comprises IP information corresponding to the first session; and send the IP information corresponding to the first session to the session management network element, wherein the IP information corresponding to the first session is used to determine the subnet information; and wherein the session management network element is further configured to:receive from the user plane network element, the IP information corresponding to the first session; anddetermine the subnet information based on the IP information corresponding to the first session.
- 33 The system according to claim 29 , wherein determining, based on the subnet information, that the data packet corresponds to the first session in the first subnet comprises:obtaining an identifier of a first virtual local area network (VLAN) in the data packet;obtaining a VLAN set, wherein the VLAN set comprises one or more VLANs in the first subnet; andwhen the first VLAN belongs to the VLAN set, determining that the data packet corresponds to the first session.
- 34 The system according to claim 33 , wherein obtaining the VLAN set comprises:receiving a packet detection rule from the session management network element, wherein the packet detection rule comprises the VLAN set.
- 35 The system according to claim 29 , wherein obtaining the subnet information comprises: receiving the subnet information from an authentication, authorization and accounting server or a terminal.
- 36 . The system according to claim 35 , further comprising:the authentication, authorization and accounting server, or the terminal, configured to:send the subnet information.
- 37 . An apparatus, comprising:at least one processor coupled to memory, wherein the at least one processor is configured to invoke a program stored in the memory, to cause the apparatus to:obtain subnet information of a first subnet corresponding to a first session;receive a data packet, wherein the data packet is a multicast packet or a broadcast packet;determine, based on the subnet information, that the data packet corresponds to the first session in the first subnet; andsend the data packet via the first session.
- 38 . The apparatus according to claim 37 , wherein determining, based on the subnet information, that the data packet corresponds to the first session in the first subnet comprises:determining subnet information corresponding to a source Internet Protocol (IP) address in the data packet; andwhen the subnet information corresponding to the first session is the same as the subnet information corresponding to the source IP address in the data packet, determining that the data packet corresponds to the first session.
- 39 The apparatus according to claim 37 , wherein obtaining the subnet information of the first subnet corresponding to the first session comprises: receiving a packet detection rule from a session management network element, wherein the packet detection rule comprises the subnet information.
Description
CROSS-REFERENCE TO RELATED APPLICATIONS This application is a continuation of U.S. Patent Application No. 18/464, 916, filed on September, 11, 2023, which is a continuation of International Application No. PCT/CN2022/073852, filed on January 25, 2022, which claims priority to Chinese Patent Application No. 202110268015.6, filed on March 12, 2021. All of the afore-mentioned patent applications are hereby incorporated by reference in their entireties. TECHNICAL FIELD This application relates to the field of wireless communication technologies, and in particular, to a wireless communication method, a communication apparatus, and a communication system. BACKGROUND After registering with a network, a terminal may initiate session establishment to the network, and the terminal and the network may subsequently communicate with each other via an established session. When a user plane network element receives a multicast packet or a broadcast packet, currently, there is no good method for sending the multicast packet or the broadcast packet by the user plane network element via which session. SUMMARY Embodiments of this application provide a wireless communication method, a communication apparatus, and a communication system, to send a multicast packet or a broadcast packet at a granularity of a subnet, thereby precisely sending the multicast packet or the broadcast packet. According to a first aspect, an embodiment of this application provides a wireless communication method. The method may be performed by a user plane network element or a module (for example, a chip) in a user plane network element. The method includes: obtaining subnet information of a first subnet corresponding to a first session; receiving a data packet, where the data packet is a multicast packet or a broadcast packet; determining, based on the subnet information, that the data packet corresponds to the first session in the first subnet; and sending the data packet via the first session. According to the method, the user plane network element may obtain a correspondence between the first session and the subnet information of the first subnet, so as to send the received multicast packet or broadcast packet via a corresponding session at a granularity of a subnet, thereby precisely sending the data packet. In a possible implementation method, the method includes: determining subnet information corresponding to a source IP address in the data packet; and if the subnet information corresponding to the first session is the same as the subnet information corresponding to the source IP address, determining that the data packet corresponds to the first session. According to the method, a session corresponding to a data packet can be accurately determined. In a possible implementation method, the method includes: receiving a packet detection rule from a session management network element, where the packet detection rule includes the subnet information. In a possible implementation method, the method includes: receiving indication information from the session management network element; detecting, based on the indication information, a data packet used for configuring IP information for the first session, where the data packet used for configuring IP information for the first session includes IP information corresponding to the first session, and the first session is an EtherType session; and sending the IP information to the session management network element, where the IP information is used to determine the subnet information. In a possible implementation method, the method includes: obtaining an identifier of a first VLAN in the data packet; obtaining a VLAN set, where the VLAN set includes one or more VLANs in the first subnet; and if the first VLAN belongs to the VLAN set, determining that the data packet corresponds to the first session. According to the method, a session corresponding to a data packet can be accurately determined. In a possible implementation method, the method includes: receiving a packet detection rule from a session management network element, where the packet detection rule includes the VLAN set. According to a second aspect, an embodiment of this application provides a wireless communication method. The method may be performed by a session management network element or a module (for example, a chip) in a session management network element. The method includes: obtaining subnet information of a first subnet corresponding to a first session; and sending the subnet information to a user plane network element, where the subnet information is used to detect a data packet that matches the subnet information. In a possible implementation method, the method includes: sending a packet detection rule to the user plane network element, where the packet detection rule includes the subnet information. In a possible implementation method, the method includes: sending indication information to the user plane network element, where the ind