WO2015039307A1 - Charging method and device - Google Patents

Charging method and device Download PDF

Info

Publication number
WO2015039307A1
WO2015039307A1 PCT/CN2013/083780 CN2013083780W WO2015039307A1 WO 2015039307 A1 WO2015039307 A1 WO 2015039307A1 CN 2013083780 W CN2013083780 W CN 2013083780W WO 2015039307 A1 WO2015039307 A1 WO 2015039307A1
Authority
WO
WIPO (PCT)
Prior art keywords
application
entity
charging
identifier
tdf
Prior art date
Application number
PCT/CN2013/083780
Other languages
French (fr)
Chinese (zh)
Inventor
陆伟
李岩
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Priority to PCT/CN2013/083780 priority Critical patent/WO2015039307A1/en
Priority to CN201380004532.6A priority patent/CN104769978B/en
Publication of WO2015039307A1 publication Critical patent/WO2015039307A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/24Accounting or billing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0893Assignment of logical groups to network elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0894Policy-based network configuration management

Definitions

  • the embodiments of the present invention relate to communication technologies, and in particular, to a charging method and device.
  • the wireless communication network mainly includes two parts, namely an access network and a core network.
  • the core network mainly includes mobile management network elements, gateway devices, and Policy and Charging Control (PCC) functional entities.
  • the PCC functional entity is further divided into a Policy Control and Charging Rules Function (PCRF) entity and a Policy and Charging Enforcement Function entity.
  • PCRF Policy Control and Charging Rules Function
  • the PCRF entity mainly formulates corresponding policies according to factors such as the operator's policy, restrictions on the user's access to the network, user subscription data, and service information of the service data flow (SDF) currently being performed by the user.
  • the PCC rule is a PCC rule.
  • the PCEF entity performs the traffic statistics and accounting for the service data of the user equipment (User Equipment, UE for short).
  • Embodiments of the present invention provide a charging method and device for implementing charging based on an application data stream.
  • the first aspect provides a charging method, including:
  • the policy control and charging rule function determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged;
  • the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the user equipment UE, the policy and charging execution PCEF entity, and the service detection function TDF, respectively. Entity, to enable the UE and the TDF entity to add the charging identifier to the data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the identifier of the first application.
  • the charging identifier allocated for the first application separately charges the data packet carrying the charging identifier from the UE and the TDF entity separately.
  • the PCRF entity sends an identifier of the first application and a charging identifier allocated to the first application to a UE and a PCEF entity, respectively , including:
  • IP-CAN session establishment response message Sending, by the PCRF entity, an internet connection access network IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocation for the first application
  • the fee identifier is configured to enable the PCEF entity to send the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the PCRF entity receives an IP-CAN session establishment request message sent by the PCEF entity.
  • the PCRF entity The identifier of the first application and the charging identifier TDF entity allocated to the first application, including: the PCRF entity sending a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the first An identifier of the application and a charging identifier assigned to the first application.
  • the method further includes:
  • the PCRF entity receives a TDF session setup response message sent by the TDF entity.
  • the determining, by the PCRF entity, the first application that needs to be charged includes:
  • a service flow detection event sent by the TDF entity where the service flow detection event is sent by the TDF entity after detecting a data packet of the first application that needs to be charged, and the service flow is
  • the detecting event includes an identifier of the first application;
  • the PCRF entity determines the first application according to the identifier of the first application.
  • the PCRF entity, the identifier of the first application, and the accounting allocated for the first application The identifiers are sent to the UE and the PCEF entity respectively, including:
  • the PCRF entity sends a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application, so that the The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the PCRF entity And the identifier and the TFP entity assigned to the first application including:
  • the PCRF entity sends a modify application probe control ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the second aspect provides a charging method, including:
  • the policy and charging execution PCEF entity receives the policy control and charging rule function.
  • the identifier of the first application that needs to be separately charged and the charging identifier that is allocated to the first application determined by the PCRF entity sent by the PCRF entity;
  • the PCEF entity sends the identifier of the first application and the charging identifier allocated to the first application to the user equipment UE through the serving gateway device, so that the UE is in the uplink data packet of the first application. Adding the charging identifier to the PCEF entity;
  • the PCEF entity receives an uplink data packet that is sent by the UE and carries the charging identifier, and performs independent charging on the uplink data packet that carries the charging identifier according to the charging identifier.
  • the method further includes: receiving, by the PCEF entity, a downlink data packet that is sent by the TDF entity and carrying the charging identifier, and Performing separate charging on the downlink data packet carrying the charging identifier according to the charging identifier.
  • the PCEF entity receives, by the PCRF entity, The identifier of the first application and the charging identifier assigned to the first application, the package Includes:
  • IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocation for the first application Billing identifier;
  • the PCEF entity receives the policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the method before the PCEF entity receives the IP-CAN session establishment response message sent by the PCRF entity, the method further includes:
  • the PCEF entity sends an IP-CAN Session Establishment Request message to the PCRF entity.
  • the PCEF entity sends the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
  • the PCEF entity sends an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application, And causing the serving gateway device to send the identifier of the first application and the charging identifier allocated for the first application to the UE.
  • the method before the sending, by the PCEF entity, the IP-CAN bearer setup response message to the serving gateway device, the method further includes:
  • the PCEF entity receives an IP-CAN bearer setup request message sent by the serving gateway device, where the IP-CAN bearer setup request message includes an identifier of the UE.
  • the third aspect provides a charging method, including:
  • the service detection function TDF entity receives the policy control and charging rule function.
  • the identifier of the first application that needs to be separately charged determined by the PCRF entity sent by the PCRF entity and the charging identifier allocated for the first application;
  • the TDF entity Determining, by the TDF entity, the downlink data packet of the first application according to the identifier of the first application, and adding the charging identifier to a downlink data packet of the first application;
  • the TDF entity sends the downlink data packet that adds the charging identifier to the policy and charging execution PCEF entity, so that the PCEF entity separately counts the downlink data packet of the first application based on the charging identifier. fee.
  • the TDF entity receives, by the PCRF entity, an identifier of the first application that is required to be separately charged by the PCRF entity, and is the first Apply the assigned billing identifier, including:
  • the TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes an identifier of the first application and a subscription identifier allocated for the first application.
  • the method further includes:
  • the TDF entity sends a TDF Session Establishment Response message to the PCRF entity.
  • the TDF entity receives, by the PCRF entity, an identifier of the first application that is required to be separately charged by the PCRF entity, and is the first Before applying the assigned billing identifier, it also includes:
  • the TDF entity detects a data packet of the first application that needs to be separately charged, and after detecting the data packet of the first application, sends a service flow detection event to the PCRF entity, where the service flow detection event
  • the identifier of the first application is included, so that the PCRF entity determines that the first application needs to be separately charged according to the identifier of the first application.
  • the TDF entity receives, by the PCRF entity, the first application that is required to be separately charged by the PCRF entity
  • the identifier and the charging identifier assigned to the first application including:
  • the TDF entity receives the modified application probe control ADC rule message sent by the PCRF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the fourth aspect provides a charging method, including:
  • the PCRF entity sends a Policy and Charging Control PCC Rule Identity and/or Service Data Flow SDF Template to the Traffic Detection Function TDF entity for the TDF entity to determine the impact policy and the charging execution PCEF entity is based on
  • the first application of the SDF granularity charging result belongs to The identifier of the SDF and the traffic of the data packet of the first application;
  • the PCRF entity Receiving, by the PCRF entity, the identifier of the SDF to which the first application belongs according to the PCC rule identifier and/or the SDF template, and the flow of the data packet of the first application, the PCRF entity
  • the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application are sent to the PCEF entity, so that the PCEF entity is based on the identifier of the SDF to which the first application belongs and the first
  • the traffic of the applied data packet is adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE.
  • the data packet of the first application belongs to the uplink data packet from the UE.
  • the PCC rule identifier and/or the SDF template sent by the PCRF entity to the TDF entity includes:
  • the PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the method further includes:
  • the PCRF entity receives a TDF session setup response message sent by the TDF entity.
  • the PCRF entity The identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application are sent to the
  • PCEF entities including:
  • the PCRF entity sends an Internet connection access network IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and data of the first application.
  • IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and data of the first application.
  • the fifth aspect provides a charging method, including:
  • the policy and charging execution PCEF entity receives the policy control and charging rule function.
  • the identifier sent by the PCRF entity affecting the PCEF entity based on the service data flow SDF granularity charging result, and the identifier of the SDF and the first application The traffic of the data packet, where the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application are the policy and charging control PCC rule identifier sent by the service detection function TDF entity according to the PCRF entity. / or SDF template is determined and sent to The PCRF entity;
  • the PCEF entity adjusts an uplink data packet from the user equipment UE based on the SDF granularity charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the The data packet of the first application belongs to an uplink data packet from the UE.
  • the PCEF entity receives an identifier of an SDF that is sent by a PCRF entity and affects a SDF granularity-based charging result of the PCEF entity.
  • the method further includes:
  • the PCEF entity performs SDF granularity based charging on uplink data packets from the UE.
  • the PCEF entity receives, by the PCRF entity, an effect of the SDF granularity that affects the PCEF entity
  • the identifier of the SDF to which the first application of the fee belongs and the traffic of the data packet of the first application including:
  • IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and the first application The traffic of the packet.
  • a sixth aspect provides a charging method, including:
  • Service detection function TDF entity receives policy control and charging rule function The policy and charging control sent by the PCRF entity PCC rule identification and / or service data flow SDF template;
  • the identifier of the associated SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE, where the data packet of the first application belongs to the UE Upstream packet.
  • the receiving, by the TDF entity, the PCC rule identifier and/or the SDF template sent by the PCRF entity includes:
  • the TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the method further includes:
  • the TDF entity sends a TDF Session Establishment Response message to the PCRF entity.
  • determining, by the PCC rule identifier and/or the SDF template, the identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity and the traffic of the data packet of the first application including: the TDF entity according to the The PCC rule identifies the indicated PCC rule, determines an application to which the data packet discarded by performing the application-based flow control belongs, and determines, as the first application, the traffic of the discarded data packet as the data of the first application. The traffic of the packet, and determining the SDF to which the first application belongs; or
  • the TDF entity determines, according to the SDF template, that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, from all data packets having the same IP address information.
  • the application to which the data packet that actually needs to be charged belongs is used as the first application, and the traffic of the data packet that needs to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined; Or,
  • the TDF entity When the TDF entity detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the TDF entity determines that it is unnecessary from all data packets having the same IP address information.
  • the application to which the billed data packet belongs is used as the first application, and the traffic of the data packet that does not need to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined.
  • a seventh aspect provides a charging method, including:
  • the service detection function TDF entity After receiving the uplink data packet sent by the PCEF entity, the service detection function TDF entity determines the reflow data, and adds a charging identifier to the reflow data, where the reflow data refers to the impact information in the uplink data packet.
  • the TDF entity sends the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity performs charging based on the SDF granularity according to the reflow data carrying the charging identifier.
  • the results are adjusted.
  • the TDF entity receives the uplink data packet sent by the PCEF entity, determines the reflow data, and adds a charging identifier to the reflow data, Also includes:
  • the TDF entity receives the policy control and charging rule function, and the PCRF entity sent by the PCRF entity allocates the charging identifier for the reflow data.
  • the TDF entity receives, by the PCRF entity, the PCRF entity that is allocated by the PCRF entity Fee identification, including:
  • the TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
  • the method further includes:
  • the TDF entity sends a TDF Session Establishment Response message to the PCRF entity.
  • the eighth aspect provides a charging method, including:
  • the policy and charging execution PCEF entity receives the reflow data carrying the charging identifier sent by the service detecting function TDF entity after performing the service data stream SDF granularity charging on the uplink data packet, where the reflow data is the TDF entity. Determining, in the uplink data packet, a data packet that affects the SDF granularity-based charging result of the uplink data packet by the PCEF entity;
  • the PCEF entity determines, according to the charging identifier, that the received data is the reflow data, determines an SDF to which the reflow data belongs, and adjusts the charging result of the determined SDF.
  • the method before the PCEF entity receives the reflow data that is sent by the TDF entity and carries the charging identifier, the method includes:
  • the PCEF entity receives the policy control and charging rule function, and the PCRF entity sent by the PCRF entity allocates the charging identifier for the reflow data.
  • the PCEF entity receives, by the PCRF entity, the PCRF entity to allocate the reflow data Fee identification, including:
  • the PCEF entity receives an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier.
  • the method before the receiving, by the PCEF entity, the IP-CAN session establishment response message sent by the PCRF entity, the method further includes:
  • the PCEF entity sends an IP-CAN Session Establishment Request message to the PCRF entity.
  • a ninth aspect provides a charging method, including:
  • the PCRF entity determines the charging identifier that needs to be assigned to the reflow packet, which refers to the service data flow in the uplink packet affecting the policy and charging execution PCEF entity to the upstream packet. a data packet of the SDF granularity charging result;
  • the sending, by the PCRF entity, the charging identifier to the TDF entity includes:
  • the PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session setup request message includes the charging identifier.
  • the method further includes:
  • the PCRF entity receives a TDF session setup response message sent by the TDF entity.
  • the PCRF entity The billing identifier is sent to the PCEF entity, including:
  • the PCRF entity sends an internet connection access network IP-CAN session establishment response message to the PCEF entity, and the IP-CAN session establishment response message includes the charging identifier.
  • the PCRF entity receives an IP-CAN session establishment request message sent by the PCEF entity.
  • the tenth aspect provides a policy control and charging rule function PCRF entity, including:
  • a determining module configured to determine a first application that needs to be billed
  • An allocating module configured to allocate a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged;
  • a sending module configured to send the identifier of the first application determined by the determining module and the charging identifier allocated by the allocating module to the first application to a user equipment UE, a policy and a charging execution PCEF entity, and The service detection function TDF entity, so that the UE and the TDF entity add the charging identifier to the data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the first
  • the identifier of the application and the charging identifier allocated for the first application separately charge the data packet carrying the charging identifier from the UE and the TDF entity separately.
  • the sending module is configured to send an identifier of the first application and a charging identifier allocated to the first application to a UE and a PCEF entities, including:
  • the sending module is specifically configured to send an Internet connection access network IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and is used by the first application.
  • the assigned charging identifier so that the PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the sending module the identifier of the first application is the first application
  • the assigned billing identifier TDF entity including:
  • the sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the determining module is specifically configured to receive a service flow detection event that is sent by the TDF entity, where the service flow detection event is the TDF entity detection And sending, after the data packet of the first application that needs to be charged, the service flow detection event includes an identifier of the first application; determining the first application according to the identifier of the first application.
  • the sending module is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE and the PCEF entity, respectively, including:
  • the sending module is specifically configured to send a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, And causing the PCEF entity to send, by the serving gateway device, the identifier of the first application and the charging identifier allocated for the first application to the UE.
  • the sending module is configured to use the first The identifier of the application and the charging identifier TDF entity allocated for the first application, including:
  • the sending module is specifically configured to send a modified application detection control ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the eleventh aspect provides a policy and charging execution PCEF entity, including:
  • a receiving module configured to receive a policy control and charging rule function, the identifier of the first application that is separately billed by the PCRF entity sent by the PCRF entity, and the charging identifier allocated for the first application;
  • a sending module configured to send, by the serving gateway device, the identifier of the first application and the charging identifier that is configured by the receiving module to the user equipment, to enable the UE to be in the Adding the charging identifier to an uplink data packet of an application, and sending the charging identifier to the PCEF entity;
  • the receiving module is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier;
  • the charging module is configured to separately charge the uplink data packet that is received by the receiving module and that carries the charging identifier according to the charging identifier.
  • the receiving module is further configured to receive a downlink data packet that is sent by the TDF entity and that carries the charging identifier.
  • the charging module is further configured to separately charge the downlink data packet that is received by the receiving module and that carries the charging identifier according to the charging identifier.
  • the receiving module is configured to receive, by the PCRF entity,
  • the identifier of the first application that needs to be separately charged and the charging identifier that is allocated for the first application, which is determined by the PCRF entity, includes:
  • the receiving module is specifically configured to receive an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and is the first application. Allocated billing identifier; or
  • the receiving module is specifically configured to receive a policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the sending The module is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
  • the sending module is specifically configured to send an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a billing allocated for the first application. And the identifier is sent to the serving gateway device to send the identifier of the first application and the charging identifier allocated to the first application to the UE.
  • the twelfth aspect provides a service detection function TDF entity, including:
  • a receiving module configured to receive a policy control and charging rule function, the identifier of the first application that is separately billed by the PCRF entity sent by the PCRF entity, and the charging identifier allocated for the first application;
  • an adding module configured to determine, according to the identifier of the first application received by the receiving module, a downlink data packet of the first application, and adding, in a downlink data packet of the first application, a received by the receiving module Description of the charging identifier;
  • a sending module configured to send a downlink data packet that adds the charging identifier to a policy and charging execution PCEF entity, so that the PCEF entity separately performs downlink data packets of the first application based on the charging identifier Billing.
  • the receiving module is configured to receive, by the PCRF entity, an identifier of the first application that is separately billed by the PCRF entity and
  • the charging identifier allocated by the first application includes:
  • the receiving module is specifically configured to receive a TDF session establishment request sent by the PCRF entity.
  • the TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the TDF entity further includes: a detecting module, configured to detect a data packet of the first application that needs to be separately charged;
  • the sending module is further configured to: after the detecting module detects the data packet of the first application, send a service flow detecting event to the PCRF entity, where the service flow detecting event includes an identifier of the first application, And causing the PCRF entity to determine, according to the identifier of the first application, that the first application needs to be separately charged.
  • the receiving module is configured to receive, by the PCRF entity, The identifier of the first application and the charging identifier allocated to the first application, the method includes: the receiving module is configured to receive a modified application detection control ADC rule message sent by the PCRF entity, where the modifying the ADC rule message includes An identifier of the first application and a charging identifier assigned to the first application.
  • the thirteenth aspect provides a policy control and charging rule function PCRF entity, including: a processor, configured to determine a first application that needs to be charged, and allocate a charging identifier to the first application, where the charging identifier is Used to identify that the first application needs to be separately charged;
  • a transmitter configured to send, by the processor, an identifier of the first application and a charging identifier allocated by the processor to the first application to a user equipment UE, a policy and charging execution PCEF entity, and The service detecting function TDF entity, so that the UE and the TDF entity add the charging identifier to the data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the first
  • the identifier of the application and the charging identifier allocated for the first application separately charge the data packet carrying the charging identifier from the UE and the TDF entity separately.
  • a fourteenth aspect provides a policy and charging enforcement PCEF entity, including:
  • a receiver configured to receive a policy control and charging rule function, and the identifier of the first application that is separately billed by the PCRF entity and the charging identifier that is allocated for the first application determined by the PCRF entity;
  • a transmitter configured to send, by the serving gateway device, an identifier of the first application and a charging identifier that is allocated by the receiver to the user equipment, to enable the UE to be in the Adding the charging identifier to an uplink data packet of an application, and sending the identifier to the PCEF entity;
  • the receiver is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier;
  • the processor is configured to separately charge the uplink data packet that is received by the receiver and that carries the charging identifier according to the charging identifier.
  • the fifteenth aspect provides a service detection function TDF entity, including:
  • a receiver configured to receive a policy control and charging rule function, and the identifier of the first application that is separately billed by the PCRF entity and the charging identifier that is allocated for the first application determined by the PCRF entity;
  • a processor configured to determine, according to the identifier of the first application received by the receiver, a downlink data packet of the first application, and add, in a downlink data packet of the first application, the received by the receiver Billing identifier
  • a transmitter configured to send a downlink data packet that adds the charging identifier to a policy and charging execution
  • PCEF entity to enable the PCEF entity to separately charge the downlink data packet of the first application based on the charging identifier.
  • the sixteenth aspect provides a policy control and charging rule function PCRF entity, including: a sending module, a policy and charging control PCC rule identifier and/or a service data flow SDF template sent to the service detecting function TDF entity, Determining, by the TDF entity, an identifier of the SDF to which the first application to which the impact policy and the charging execution PCEF entity performs the SDF granularity based charging result and the traffic of the data packet of the first application;
  • a receiving module configured to receive, according to the PCC rule identifier, sent by the TDF entity, and/or
  • the sending module is further configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity is based on the first application
  • the identifier of the SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE; wherein the data packet of the first application belongs to the UE from the UE Upstream packet.
  • the sending, by the sending module, the PCC rule identifier and/or the SDF template that is sent to the TDF entity includes:
  • the sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where The TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the sending module is configured to: And sending the traffic of the data packet of the first application to the PCEF entity, including:
  • the sending module is specifically configured to send an internet connection access network to the PCEF entity
  • the IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application.
  • the seventeenth aspect provides a policy and charging execution PCEF entity, including:
  • a receiving module configured to receive, by the policy control and charging rule function, the identifier of the SDF that is sent by the first application that affects the PCEF entity based on the serving data flow SDF granularity, and the data packet of the first application
  • the traffic of the SDF to which the first application belongs and the traffic of the data packet of the first application are the service detection function TDF entity according to the policy and charging control PCC rule identifier sent by the PCRF entity and/or
  • the SDF template is determined and sent to the PCRF entity;
  • the charging adjustment module is configured to adjust, according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, the uplink data packet from the user equipment UE, based on the SDF granularity charging result, where The data packet of the first application belongs to an uplink data packet from the UE.
  • the PCEF entity further includes: a charging module, configured to receive, at the receiving module, an identifier and a location of an SDF to which the first application belongs Before the traffic of the data packet of the first application, the SDF granularity based charging is performed on the uplink data packet from the UE.
  • a charging module configured to receive, at the receiving module, an identifier and a location of an SDF to which the first application belongs Before the traffic of the data packet of the first application, the SDF granularity based charging is performed on the uplink data packet from the UE.
  • the receiving module is configured to receive, by the PCRF entity, the PCEF entity
  • the identifier of the SDF to which the first application belongs to the SDF granularity-based charging result and the traffic of the data packet of the first application including:
  • the receiving module is specifically configured to receive an Internet connection access network IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs, and the The traffic of an application's packets.
  • the eighteenth aspect provides a service detection function TDF entity, including:
  • a receiving module configured to receive a policy control and charging rule function, a policy and a meter sent by a PCRF entity Fee control PCC rule identification and / or service data flow SDF template;
  • a determining module configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiving module, an identifier and a location of the SDF to which the first application belongs to the SDF granularity-based charging result of the PCEF entity The traffic of the data packet of the first application;
  • a sending module configured to send, by the PCRF entity, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, to make the PCEF
  • the entity adjusts the uplink data packet from the user equipment UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the first application is The data packet belongs to an upstream data packet from the UE.
  • the receiving module is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity, including:
  • the receiving module is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the determining module is configured to receive the PCC according to the receiving module The rule identifier and/or the SDF template, the identifier of the SDF to which the first application that affects the charging result of the SDF granularity of the PCEF entity is determined, and the traffic of the data packet of the first application, the determining module is specifically configured to be used according to the Determining, by the receiving module, the PCC rule indicated by the PCC rule identifier, determining, by using the application that belongs to the data packet that is discarded by performing the application-based flow control, as the first application, determining the traffic of the discarded data packet As the traffic of the data packet of the first application, and determining the SDF to which the first application belongs; or
  • the determining module is specifically configured to: when the SDF template received by the receiving module detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the same IP is obtained.
  • the application to which the data packet actually required to be charged belongs is determined as the first application, and the traffic of the data packet actually required to be charged is determined as the traffic of the data packet of the first application, and is determined.
  • the SDF to which the first application belongs or
  • the determining module is specifically configured to: when the SDF template received by the receiving module detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the same IP is obtained. All data packets of the address information, determining an application to which the data packet that does not need to be charged belongs as the first application, determining traffic of the data packet that does not need to be charged as the first The traffic of an application's data packet, and determines the SDF to which the first application belongs.
  • a nineteenth aspect provides a policy control and charging rule function PCRF entity, including: a transmitter, a policy and charging control PCC rule identifier and/or a service data flow SDF template sent to a service detection function TDF entity, Determining, by the TDF entity, an identifier of the SDF to which the first application to which the impact policy and the charging execution PCEF entity performs the SDF granularity based charging result and the traffic of the data packet of the first application;
  • a receiver configured to receive, by the TDF entity, the identifier of the SDF to which the first application belongs according to the PCC rule identifier and/or the SDF template, and the flow of the data packet of the first application And sending, to the PCEF entity, the identifier of the SDF to which the first application belongs and the data packet of the first application, so that the PCEF entity is based on the identifier of the SDF to which the first application belongs
  • the traffic of the data packet of the first application is adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE; wherein the data packet of the first application belongs to an uplink data packet from the UE.
  • the twentieth aspect provides a policy and charging execution PCEF entity, including:
  • a receiver configured to receive, by the policy control and charging rule function, the identifier of the SDF that is sent by the first application that affects the PCEF entity based on the service data flow SDF granularity charging result, and the data packet of the first application
  • the traffic of the SDF to which the first application belongs and the traffic of the data packet of the first application are the service detection function TDF entity according to the policy and charging control PCC rule identifier sent by the PCRF entity and/or
  • the SDF template is determined and sent to the PCRF entity;
  • a processor configured to adjust an uplink data packet from the user equipment UE according to an SDF granularity charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where The data packet of the first application belongs to an uplink data packet from the UE.
  • the twenty-first aspect provides a service detection function TDF entity, including:
  • Receiver for receiving policy control and charging rule functions, policy and charging control sent by the PCRF entity, PCC rule identification and/or service data flow SDF template;
  • a processor configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiver, an identifier and a location of an SDF to which the first application that affects the policy and charging execution PCEF entity based on the SDF granularity charging result
  • the traffic of the data packet of the first application a transmitter, configured to send, by the processor, an identifier of an SDF to which the first application belongs and a traffic of a data packet of the first application to the PCEF entity by using the PCRF entity, to enable the PCEF
  • the entity adjusts the uplink data packet from the user equipment UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the first application is The data packet belongs to an upstream data packet from the UE.
  • the twenty-second aspect provides a service detection function TDF entity, including:
  • a receiving module configured to receive an uplink data packet sent by the PCEF entity by using a policy and a charging
  • determining an adding module configured to: after the receiving module receives the uplink data packet, determine reflow data, and add the reflow data a billing identifier, where the reflow data refers to a data packet in the uplink data packet that affects the charging result of the PCEF entity based on the service data stream SDF granularity of the uplink data packet;
  • a sending module configured to send the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity is based on the SDF granularity of the uplink data packet according to the reflow data carrying the charging identifier The fee results are adjusted.
  • the receiving module is further configured to: before the determining adding module adds a charging identifier to the reflow data, receiving a policy control And the charging identifier that is sent by the PCRF entity sent by the PCRF entity to the reflow data.
  • the receiving module is configured to receive, by the PCRF entity, the PCRF entity as the reflow
  • the charging identifier of the data distribution includes:
  • the receiving module is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
  • the twenty-third aspect provides a policy and charging execution PCEF entity, including:
  • a receiving module configured to: after performing service-based data stream SDF granularity charging on the uplink data packet, receive, by the service detecting function TDF entity, reflow data carrying the charging identifier, where the reflow data is determined by the TDF entity a data packet in the uplink data packet that affects an SDF granularity-based charging result of the uplink data packet by the PCEF entity;
  • a billing adjustment module configured to determine, according to the billing identifier, that the data received by the receiving module is the reflow data, determine an SDF to which the reflow data belongs, and charge the determined SDF The results are adjusted.
  • the receiving module is further configured to receive a policy before receiving the reflow data carried by the TDF entity and carrying the charging identifier
  • the control and charging rule function sends the charging identifier assigned by the PCRF entity to the reflow data.
  • the receiving module is configured to receive, by the PCRF entity, the PCRF entity as the reflow
  • the charging identifier of the data distribution includes:
  • the receiving module is specifically configured to receive an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier.
  • the twenty-fourth aspect provides a policy control and charging rule function PCRF entity, including: a determining module, configured to determine a charging identifier that needs to be allocated to a reflow data packet, where the reflow data refers to an impact policy in the uplink data packet Charging a data packet of a service data flow SDF granularity based charging result of the uplink data packet by the PCEF entity;
  • a sending module configured to send the charging identifier to the service detecting function TDF entity and the PCEF entity, where the TDF entity determines the reflow data from the uplink data packet from the PCEF entity Adding the charging identifier to the PCEF entity, and sending the PCEF entity to determine, according to the charging identifier, the reflow data, and based on the reflow data, the uplink data packet is based on The billing result of the SDF granularity is adjusted.
  • the sending by the sending, the sending, by the sending,
  • the sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the charging identifier.
  • the sending module is configured to send the charging identifier To the PCEF entity, including:
  • the sending module is specifically configured to send an internet connection access network IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes the charging identifier.
  • the twenty-fifth aspect provides a service detection function TDF entity, including:
  • a receiver configured to receive an uplink data packet sent by the PCEF entity
  • a processor configured to: after the receiver receives the uplink data packet, determine reflow data, and add a meter for the reflow data a fee identifier, where the reflow data refers to a data packet in the uplink data packet that affects the charging result of the PCEF entity based on the service data flow SDF granularity of the uplink data packet;
  • a transmitter configured to send the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity is based on the reflow data carrying the charging identifier, and the uplink data packet is based on
  • the billing result of the SDF granularity is adjusted.
  • the twenty-sixth aspect provides a policy and charging execution PCEF entity, including:
  • a receiver configured to receive reflow data carried by the service detection function TDF entity and carrying the charging identifier, after the serving data stream SDF granularity charging of the uplink data packet, where the reflow data is determined by the TDF entity a data packet in the uplink data packet that affects an SDF granularity-based charging result of the uplink data packet by the PCEF entity;
  • a processor configured to determine, according to the charging identifier, that the data received by the receiver is the backflow data, determine an SDF to which the reflow data belongs, and adjust a charging result of the determined SDF.
  • the twenty-seventh aspect provides a policy control and charging rule function PCRF entity, including: a processor, configured to determine a charging identifier that needs to be allocated to a reflow packet, where the reflow data refers to an impact policy in an uplink packet Charging a data packet of a service data flow SDF granularity based charging result of the uplink data packet by the PCEF entity;
  • a transmitter configured to send the charging identifier to a service detecting function TDF entity and the PCEF entity, where the TDF entity determines the reflow data from the uplink data packet from the PCEF entity Adding the charging identifier to the PCEF entity, adding the charging identifier to the PCEF entity, causing the PCEF entity to determine the reflow data according to the charging identifier, and based on the reflow data, the uplink data packet is based on The billing result of the SDF granularity is adjusted.
  • the charging method and the device provided by the embodiment of the present invention allocate a charging identifier for an application that needs to be separately charged, and implement an identifier for an application that needs to be separately charged, and implement independent charging for the application based on the charging identifier. .
  • BRIEF DESCRIPTION OF THE DRAWINGS In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, a brief description of the drawings used in the embodiments or the prior art description will be briefly described below. The drawings are some embodiments of the present invention, and those skilled in the art can obtain other drawings based on these drawings without any inventive labor.
  • FIG. 1 is a schematic diagram of three access technologies in a current wireless communication network according to an embodiment of the present invention.
  • FIG. 2 is a data flow interface and a direction of a control plane and a user plane in control and management of a wireless communication system according to an embodiment of the present invention.
  • FIG. 3 is a flowchart of a charging method according to an embodiment of the present invention.
  • FIG. 4 is a flowchart of another charging method according to an embodiment of the present invention.
  • FIG. 5 is a flowchart of still another charging method according to an embodiment of the present invention.
  • FIG. 6 is a flowchart of still another charging method according to an embodiment of the present invention.
  • FIG. 7 is a structural diagram of a PCRF entity according to an embodiment of the present invention.
  • FIG. 8 is a block diagram of another PCRF entity according to an embodiment of the present invention.
  • FIG. 9 is a schematic structural diagram of a PCEF entity according to an embodiment of the present invention.
  • FIG. 10 is a diagram of another PCEF entity according to an embodiment of the present invention.
  • Figure 1 1 is the present invention: ;
  • FIG. 12 is a view of the present invention: another TDF entity provided by the embodiment
  • Figure 13 is the present invention:; another embodiment of the PCRF body provided;
  • Figure 14 is the present invention:; another embodiment of the PCRF body provided;
  • Figure 15 is the present invention:; another embodiment of the PCEF body provided by the embodiment;
  • Figure 16 is the present invention:; another embodiment of the PCEF body provided by the embodiment;
  • Figure 17 is a view of the present invention: - TDF % provided by the embodiment;
  • Figure 18 is a view of the present invention.
  • Figure 19 is a view of the present invention:
  • Figure 20 is a view of the present invention.
  • Figure 21 is the present invention:; another embodiment of the PCEF body provided by the embodiment;
  • Figure 22 is the present invention:; another embodiment of the PCEF ⁇ body provided;
  • FIG. 24 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention.
  • the current wireless communication network has three access technologies, one is the Global System of Mobile communication (GSM), commonly referred to as 2G; - Wozhong is the Universal Mobile Telecommunications system (Universal Mobile Telecommunications) System, Jane is UMTS), commonly referred to as 3G; and Long Term Evolved (LTE) system, commonly referred to as 4G.
  • GSM Global System of Mobile communication
  • 2G Global System of Mobile communication
  • - Wozhong is the Universal Mobile Telecommunications system (Universal Mobile Telecommunications) System
  • Jane UMTS
  • LTE Long Term Evolved
  • the access network part is mainly responsible for radio access layer signaling and user data transmission.
  • the access network part mainly refers to GERAN (English: GSM EDGE Radio Access Network) in Figure 1, including BTS and BSC;
  • GSM Global System for Mobile communications
  • UMTS the access network part mainly refers to the UTRAN in FIG. 1, including the RNC and the NodeB;
  • the access network part mainly refers to the E-UTRAN in FIG. 1, including the eNodeB.
  • the other part of the architecture shown in Figure 1 except the access network part is the core network part.
  • the SGSN of GSM and UMTS and the ⁇ E of the LTE system are called mobility management network elements, which are mainly used to acquire users. Signing data, responsible for NAS signaling and NAS signaling encryption, roaming, tracking, etc., assigning user temporary identity, security functions, etc.
  • the GGSN in GSM and UMTS and the PGW in the LTE system are gateway devices, which are mainly responsible for policy enforcement and charging and lawful interception related functions.
  • an important component of the core network is the PCC part, which includes a PCRF entity and a PCEF entity.
  • the PCEF entity is usually combined with a gateway device, such as a GGSN or a PGW, and is subscribed to a database (Subscription Profile Repository, SPR for short). ), Application Function (AF) entities, etc. together implement the PCC part. SPR is not shown in Figure 1.
  • the PCRF entity is mainly based on the operator's policy, restrictions on user access to the network, and number of user subscriptions. According to factors such as the service information of the SDF currently being performed by the user, a corresponding policy is formulated, which is called a PCC rule; the PCEF entity mainly performs a PCC rule formulated by the PCRF entity, for example, detecting and measuring the SDF according to the PCC rule, Quality of Service (QoS), user-side traffic detection, and session management for triggering control planes.
  • QoS Quality of Service
  • IP Internet Protocol
  • PCEF will serve the data flow and bearer according to the QoS parameters of the SDF.
  • Binding, for example, the QoS Class Identifier (QCI) is the same as the Address Resolution Protocol (ARP) service data flow on the same bearer, so as to facilitate other core networks.
  • the network element performs flow control based on the bearer.
  • the PCEF will also receive the service data stream according to the charging policy and charging method delivered by the PCRF.
  • TDF Traffic Detection Function
  • the TDF entity is a functional entity of the Deep Packet Inspection (DPI) device, and can perform detection on the data packet according to the detection rule of the data packet sent by the PCRF entity, for example, detecting a certain type of application (QQ).
  • the data packet, or the data packet of the specified Uniform Resource Locator (URL), is detected, and the packet event is reported to the PCRF entity after detecting the application data packet that satisfies the condition.
  • the TDF entity may also perform flow control on the detected application data packets, such as the maximum bit rate limit of uplink and downlink.
  • Figure 2 shows the data flow interface and direction of the control plane and the user plane in the control and management of the wireless communication system. As shown by the dotted line with an arrow in FIG.
  • the uplink data packet sent by the UE first passes through the PCEF entity, and then passes through the TDF entity to reach the network side, correspondingly, as shown by the solid line with an arrow in FIG. 2, the network The downlink data packet sent by the side must pass through the TDF entity before passing through the PCEF entity to reach the UE.
  • the PCEF entity for the uplink data packet, it is possible to pass the SDF granularity-based charging of the PCEF entity, and then the TDF entity is based on the application data flow-based charging, and the repeated charging causes the charging to be inaccurate;
  • the PCEF entity is to implement the SDF QoS policy Slightly, the packets that have been billed in the TDF entity may be discarded, which may result in inaccurate billing.
  • the TDF entity after detecting the application to which the downlink data packet belongs, the TDF entity identifies the downlink data packet, so that the PCEF entity identifies the application to which the downlink data packet belongs according to the identifier, and performs charging, thereby implementing Based on the application data flow-based charging, but for the uplink data packet, the PCEF entity cannot identify the application to which the uplink data packet belongs, and only after performing the SDF granularity-based charging, the uplink data packet is sent to the TDF entity, and the TDF entity detects The application to which the uplink data packet belongs is fed back to the PCEF entity. At this time, the PCEF entity charges the uplink data packet to implement charging based on the application data flow, which has the problem of repeated charging, and also causes charging. Inaccurate.
  • the main idea of the first charging method provided by the present invention is: determining, by the PCRF entity, the first application that needs to be charged, and assigning a charging identifier to the first application, where the charging identifier needs to be used for the first application. Separate billing; then the PCRF entity sends the identifier of the first application and the charging identifier assigned to the first application to the TDF entity, the PCEF entity, and the UE respectively; thus, before the UE sends the uplink packet of the first application to the PCEF entity, Adding the charging identifier to the uplink data packet of the first application, and then sending the uplink data packet that adds the charging identifier to the PCEF entity, where the PCEF entity can receive the received uplink carrying the charging identifier.
  • the data packet is separately charged, and the first application is separately charged in the uplink direction, and since the uplink data packet of the first application can be identified, there is no problem of repeated charging; similarly, the TDF entity sends the data to the PCEF entity.
  • adding the charging identifier to the downlink data packet of the first application, and then adding the charging identifier The uplink data packet is sent to the PCEF entity, and the PCEF entity can separately charge the received downlink data packet carrying the charging identifier to implement separate charging for the first application in the downlink direction, because the first packet can be identified.
  • the downlink packet of the application does not have the problem of repeated charging.
  • the flow of the first charging method is described in detail from the perspective of a PCRF entity, a PCEF entity, a TDF entity, and a UE.
  • the method flow described from the perspective of the PCRF entity includes:
  • the PCRF entity determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged.
  • the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE, the PCEF entity, and the TDF entity, respectively, so that the UE and the TDF entity are in the data packet of the first application.
  • the data packet of the charging identifier is separately charged, thereby implementing separate charging for the first application.
  • the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE, including:
  • the PCRF entity sends an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an assigned charging identifier for the first application, so that The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the method further includes: the PCRF entity receiving the IP-CAN session establishment request message sent by the PCEF entity.
  • the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, including:
  • the PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the method further includes: the PCRF entity receiving the TDF session establishment response message sent by the TDF entity.
  • the PCRF entity determines the first application that needs to be charged, and the method includes: the PCRF entity receives a service flow detection event sent by the TDF entity, where the service flow detection event is that the TDF entity detects that the charging is required. After the data packet of the first application is sent, the service flow detection event includes an identifier of the first application, and the PCRF entity determines the first application according to the identifier of the first application.
  • the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE and the PCEF entity, based on the foregoing method for detecting the first application that needs to be charged by the TDF entity, including:
  • the PCRF entity sends a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, so that The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, including: the PCRF entity to the TDF, based on the solution that the TDF entity detects the first application that needs to be charged. Entity sends modify application probe control (Appl ication
  • the detection control (referred to as ADC) rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the method flow described from the perspective of the PCEF entity includes:
  • the PCEF entity receives an identifier of the first application that is separately billed by the PCRF entity and a charging identifier that is allocated for the first application, which is sent by the PCRF entity;
  • the PCEF entity sends the identifier of the first application and the charging identifier allocated to the first application to the UE by using the serving gateway device, so that the UE adds the meter to the uplink data packet of the first application. After the fee is identified, it is sent to the PCEF entity;
  • the PCEF entity receives the uplink data packet that is sent by the UE and carries the charging identifier, and performs independent charging on the uplink data packet carrying the charging identifier according to the charging identifier.
  • the method further includes:
  • the PCEF entity receives the downlink data packet that is sent by the TDF entity and carries the charging identifier, and performs independent charging on the downlink data packet carrying the charging identifier according to the charging identifier.
  • the PCEF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and includes:
  • the PCEF entity receives the IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application.
  • the PCEF entity before receiving the IP-CAN session establishment response message sent by the PCRF entity, the PCEF entity further includes: the PCEF entity sending an IP-CAN session establishment request message to the PCRF entity.
  • the CEF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and includes:
  • the PCEF entity Receiving, by the PCEF entity, a policy and charging rule message sent by the PCRF entity, where the policy and The charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the PCEF entity sends the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
  • the PCEF entity sends an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application, so that The serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE.
  • the method further includes: the PCEF entity receiving the IP-CAN bearer setup request message sent by the serving gateway device, the IP-CAN bearer setup request The message includes an identification of the UE.
  • the method flow described from the perspective of the TDF entity includes:
  • the TDF entity receives the identifier of the first application that needs to be separately charged and the charging identifier that is allocated for the first application, which is determined by the PCRF entity sent by the PCRF entity;
  • the TDF entity sends the downlink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity separately charges the downlink data packet of the first application based on the charging identifier.
  • the TDF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and includes:
  • the TDF entity receives the TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the identifier of the first application and the charging identifier allocated for the first application.
  • the method further includes: the TDF entity sending a TDF session establishment response message to the PCRF entity.
  • the TDF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and further includes
  • the TDF entity detects a data packet of the first application that needs to be separately charged, and after detecting the data packet of the first application, sends a service flow detection event to the PCRF entity, where the service flow probe The event includes an identifier of the first application, so that the PCRF entity determines that the first application needs to be charged according to the identifier of the first application.
  • the TDF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, including:
  • the TDF entity receives the modified ADC rule message sent by the PCRF entity, and the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the method flow described from the perspective of the UE includes:
  • the identifier of the first application determines an uplink data packet of the first application, and adds the charging identifier to an uplink data packet of the first application;
  • the UE sends the uplink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity separately charges the uplink data packet of the first application based on the charging identifier.
  • the flow of the first charging method provided by the present invention is further described in detail from the perspective of multi-network element interaction.
  • FIG. 3 is a flowchart of a charging method according to an embodiment of the present invention. As shown in FIG. 3, the method includes:
  • the PCEF entity receives an IP-Connectivity Access Network (IP-CAN) bearer setup request message sent by the serving gateway device.
  • IP-CAN IP-Connectivity Access Network
  • the PCEF entity receives the service gateway device, for example, an IP-CAN bearer setup request message sent by the SGW, where the IP-CAN bearer setup request message includes information such as the identifier of the UE, and is used to establish a bearer.
  • the service gateway device for example, an IP-CAN bearer setup request message sent by the SGW, where the IP-CAN bearer setup request message includes information such as the identifier of the UE, and is used to establish a bearer.
  • the PCEF entity sends an IP-CAN session establishment request message to the PCRF entity.
  • the PCRF entity determines the first application that needs to be charged, and allocates a charging identifier to the first application that needs to be charged, to identify that the first application needs to be separately charged.
  • the first application here may be any application that needs to be charged.
  • it is referred to as "first”, but there is no limit to the number.
  • the PCRF may allocate a corresponding differentiated service code point (DSCP) value to the first application, so that the DSCP bit in the IP header of the data packet is identified by the corresponding value to be used for the first application.
  • Billing. 14 The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application (APPLICATION ID) and a charging identifier, such as a DSCP value.
  • APPLICATION ID an identifier of the first application
  • a charging identifier such as a DSCP value.
  • the TDF entity sends a TDF session setup response message to the PCRF entity.
  • the method provided in this embodiment may further include: after receiving the identifier of the first application and the charging identifier allocated to the first application, the TDF entity adds the charging identifier to the downlink data packet of the first application, And sending the downlink data packet of the first application that adds the charging identifier to the PCEF entity; when receiving the downlink data packet that is sent by the TDF entity and carrying the charging identifier, the PCEF entity performs charging for the data packet.
  • the TDF entity After the PCRF entity allocates the charging identifier to the first application, the TDF entity initiates a TDF session establishing process to provide the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, so that the TDF is in the downlink direction.
  • the first application is identified by the charging identifier (for example, the DSCP value), so that the PCEF entity can recognize that the downlink data packet belongs to the first application that needs to be charged, and then in the downlink direction, after receiving the downlink data packet sent by the TDF.
  • a separate billing for the first application is implemented, and there is no problem of repeated billing.
  • the PCRF entity sends an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and a charging identifier assigned to the first application, for example, a DSCP value.
  • the identifier of the first application is the identifier of the application to be charged (Char ged-app 1 i cat i on identifier).
  • the PCRF entity After assigning the charging identifier to the first application, the PCRF entity provides the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, and the identifier of the first application is also required to be An application-assigned charging identifier is provided to the PCEF entity, so that the PCEF entity charges the uplink and downlink data packets of the first application based on the two information.
  • the PCEF entity sends an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application.
  • the PCEF entity may add the identifier of the first application and the charging identifier allocated for the first application to a Protocol Configuration Option (PC0) in the IP-CAN bearer setup response message, and provide the Service gateway device.
  • PC0 Protocol Configuration Option
  • this embodiment does not limit the implementation of the identifier of the first application.
  • the stomach. sina.com as the identifier of the first application in the PC0, but is not limited thereto.
  • the mobility management network element transparently transmits the identifier of the first application and the charging identifier allocated to the first application to the UE, for example, the IP may be transparently transmitted to the UE.
  • the UE After receiving the identifier of the first application and the charging identifier allocated for the first application, the UE adds the charging identifier to the uplink data packet of the first application, and adds the uplink data of the first application of the charging identifier.
  • the package is sent to the PCEF entity.
  • the PCEF entity When receiving the uplink data packet carrying the charging identifier sent by the UE, the PCEF entity performs separate charging on the received data packet.
  • the PCEF entity After receiving the uplink data packet sent by the UE, the PCEF entity can learn, by using the charging identifier carried by the PCEF, that the uplink data packet belongs to the first application that needs to be charged, thereby implementing the uplink application in the uplink direction. Separate billing for an application.
  • the PCEF entity can learn that the downlink data packet belongs to the first application that needs to be charged by using the charging identifier carried by the PCEF entity, thereby implementing a separate application for the first application in the downlink direction. fee.
  • the charging method provided in this embodiment is implemented on the PCEF entity, and the SDF-based charging in the prior art is performed on the same device. Therefore, there is no problem of charging inaccuracy caused by repeated charging.
  • FIG. 4 is a flowchart of another charging method according to an embodiment of the present invention. As shown in Figure 4, the method includes:
  • the TSF entity When the TDF entity detects the data packet of the first application to be charged, the TSF entity reports the service flow detection event to the PCRF entity, where the service flow detection event includes information such as the identifier of the first application.
  • the TDF entity may detect the received data packet according to the detection rule of the data packet sent by the PCRF entity. Based on this, the TDF entity can detect which application packets need to be billed separately. Which applications need to be billed separately can be determined according to the requirements of the operator.
  • the first application may be any application that requires charging. When the first application that needs to be charged is detected, the TDF entity reports the service flow detection event to the PCRF entity, so that the PCRF entity allocates a charging identifier to the first application and determines to modify the ADC rule.
  • the PCRF entity After receiving the service flow detection event, the PCRF entity determines the first application according to the identifier of the first application, and allocates a charging identifier to the first application.
  • the allocated charging identifier may be a DSCP value.
  • the charging identifier is mainly used to identify that the data packet of the first application needs to be charged, for example, For the UE, the charging identifier needs to be added to the uplink data packet of the first application. For the PCEF entity, the first application that needs to be charged and the uplink data packet of the first application are determined based on the charging identifier. For the TDF entity, the charging identifier needs to be added to the downlink data packet of the first application. For the PCEF entity, the first application that needs to be charged and the first application are determined based on the charging identifier. Downstream packet.
  • the PCRF entity sends a modified ADC rule message to the TDF entity, where the message includes an identifier of the first application (APPLICATION ID) and a charging identifier assigned to the first application, such as a DSCP value.
  • APPLICATION ID an identifier of the first application
  • a charging identifier assigned to the first application such as a DSCP value.
  • the method provided in this embodiment may further include: after receiving the identifier of the first application and the charging identifier allocated to the first application, the TDF entity adds the charging identifier to the downlink data packet of the first application, And sending the downlink data packet of the first application that adds the charging identifier to the PCEF entity; when receiving the downlink data packet that is sent by the TDF entity and carrying the charging identifier, the PCEF entity performs charging for the data packet.
  • the PCRF entity After assigning the charging identifier to the first application, the PCRF entity provides the TDF entity with the identifier of the first application and the charging identifier allocated for the first application, so that the TDF entity can identify the first application and the charging allocated to the first application.
  • the charging identifier for example, a DSCP value
  • the PCEF entity can identify the downlink data packet after receiving the downlink data packet sent by the TDF. It belongs to the first application that needs to perform charging, so that separate charging for the first application is implemented in the downlink direction, and there is no problem of repeated charging.
  • the PCRF entity sends a policy and charging rule message to the PCEF entity, where the message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the identifier of the first application is the identifier of the application to be charged (Char ged-app 1 i cat i on identifier ).
  • the PCRF entity After assigning the charging identifier to the first application, the PCRF entity provides the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, and the identifier of the first application is also required to be An application-assigned charging identifier is provided to the PCEF entity, so that the PCEF entity charges the uplink and downlink data packets of the first application based on the two information.
  • the PCEF entity sends an IP-CAN bearer setup request message to the serving gateway device, where the IP-CAN bearer setup request message includes an identifier of the first application and a charging identifier assigned to the first application.
  • the PCEF entity may add the identifier of the first application and the charging identifier allocated for the first application to the PC0 in the IP-CAN bearer setup request message, and provide the information to the serving gateway device.
  • this embodiment does not limit the implementation of the identifier of the first application. For example, if it is necessary to charge the application data packet of the Sina (Sina) webpage, it is possible to include the stomach. sina.com as the identifier of the first application in the PC0, but is not limited thereto.
  • the mobility management network element transparently transmits the identifier of the first application and the charging identifier allocated for the first application to the UE, for example,
  • the UE transparently transmits PC0 in the IP-CAN bearer setup request message.
  • the UE After receiving the identifier of the first application and the charging identifier allocated for the first application, the UE adds the charging identifier to the uplink data packet of the first application, and adds the uplink data of the first application of the charging identifier.
  • the package is sent to the PCEF entity.
  • the PCEF entity When receiving the uplink data packet carrying the charging identifier sent by the UE, the PCEF entity performs separate charging on the received data packet.
  • the PCEF entity After receiving the uplink data packet sent by the UE, the PCEF entity can learn, by using the charging identifier carried by the PCEF, that the uplink data packet belongs to the first application that needs to be charged, thereby implementing the uplink application in the uplink direction. Separate billing for an application.
  • the PCEF entity can learn that the downlink data packet belongs to the first application that needs to be charged by using the charging identifier carried by the PCEF entity, thereby implementing a separate application for the first application in the downlink direction. fee.
  • the charging method provided in this embodiment is implemented on the PCEF entity, and is performed on the same device as the SDF-based charging in the prior art. Therefore, there is no problem of inaccurate charging caused by repeated charging.
  • the second charging method provided by the present invention is mainly for performing SDF granularity-based charging in a PCEF entity.
  • the TDF entity may perform flow control on some applications, causing data packets of some applications.
  • the problem that the accounting is inaccurate is discarded, or the same identifier is used for the data packets with the same uplink and downlink IP address for charging.
  • the actual charging requirement may be only the partial data packet of the IP address causing the excessive charging. The question was raised.
  • the main idea of the second charging method is: After the PCEF entity performs SDF granularity-based charging on the data packet, when the data packet arrives at the TDF entity, the TDF entity determines the influence according to the PCC rule identifier and/or the SDF template provided by the PCRF entity.
  • the PCEF entity sends the traffic of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF by the PCRF entity, and then sends the traffic of the data packet of the first application to the PCEF by the PCRF entity.
  • An entity so that the PCEF entity adjusts the SDF granularity based charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application.
  • the flow of the second charging method is described in detail from the perspective of the PCRF entity, the PCEF entity, and the TDF entity.
  • the method flow described from the perspective of the PCRF entity includes:
  • the PCRF entity receives, according to the PCC rule identifier and/or the SDF template, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application sent by the TDF entity;
  • the PCRF entity sends the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity is based on the identifier of the SDF to which the first application belongs and the
  • the traffic of the data packet of an application adjusts the SDF granularity-based charging result of the uplink data packet from the UE; wherein the data packet of the first application belongs to the uplink data packet from the UE.
  • the PCC rule identifier and/or the SDF template sent by the PCRF entity to the TDF entity includes:
  • the PCRF entity sends a TDF Session Establishment Request message to the TDF entity, the TDF Session Setup Request message including the PCC Rule Identity and/or SDF Template.
  • the method further includes: the PCRF entity receiving the TDF session establishment response message sent by the TDF entity.
  • the PCRF entity sends the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, including:
  • the PCRF entity sends an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application.
  • the method flow described from the perspective of the PCEF entity includes:
  • the PCEF entity receives the identifier of the SDF to which the first application to which the PCEF entity sends the SDF granularity-based charging result, and the traffic of the data packet of the first application, where the PCEF entity receives the identifier of the SDF to which the first application belongs.
  • the traffic of the data packet of the first application is determined by the TDF entity according to the PCC rule identifier and/or the SDF template sent by the PCRF entity, and sent to the PCRF entity;
  • the PCEF entity adjusts the SDF granularity-based charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application; where the data packet of the first application belongs to the uplink from the UE data pack.
  • the PCEF entity before receiving, by the PCF entity, the identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity and the traffic of the data packet of the first application, the PCEF entity further includes:
  • the PCEF entity performs SDF granularity based charging on all packets arriving.
  • the PCEF entity receives, by the PCRF entity, the identifier of the SDF that belongs to the first application that affects the charging result of the PCEF entity based on the SDF granularity, and the traffic of the data packet of the first application, including:
  • the PCEF entity receives the IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application.
  • the method flow described from the perspective of the TDF entity includes:
  • the TDF entity receives the PCC rule identifier and/or the SDF template sent by the PCRF entity;
  • the TDF entity determines, according to the PCC rule identifier and/or the SDF template, the identifier of the SDF to which the first application that affects the charging result of the PCEF entity based on the SDF granularity and the traffic of the data packet of the first application;
  • the identifier of the SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the UE, where the data packet of the first application belongs to the uplink data packet from the UE .
  • the TDF entity receives the PCC rule identifier and/or the SDF template sent by the PCRF entity, including:
  • the TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or the SDF template.
  • the TDF entity further includes: the TDF entity sending a TDF session establishment response message to the PCRF entity.
  • the TDF entity identifies and/or the SDF template according to the PCC rule. Determining the identifier of the SDF to which the first application that affects the charging result of the SDF granularity of the PCEF entity belongs and the traffic of the data packet of the first application, including:
  • the TDF entity Determining, by the TDF entity, the application to which the data packet discarded by performing the application-based flow control belongs as the first application according to the PCC rule indicated by the PCC rule identifier, determining the traffic of the discarded data packet as the The traffic of the data packet of the first application, and determining the SDF to which the first application belongs;
  • the TDF entity determines, according to the SDF template, that it is not required to charge all data packets having the same IP address information in the uplink data packet from the UE, and determines actual needs from all data packets having the same IP address information.
  • the application to which the billing data packet belongs is used as the first application, and the traffic of the data packet that needs to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined; or
  • the TDF entity When the TDF entity detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the TDF entity determines that it is unnecessary from all data packets having the same IP address information.
  • the application to which the billed data packet belongs is used as the first application, and the traffic of the data packet that does not need to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined.
  • FIG. 5 is a flowchart of still another charging method according to an embodiment of the present invention. As shown in Figure 5, the method includes:
  • the PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes a PCC rule id and/or an SDF template.
  • the PCC rule identifier is used to indicate a PCC rule, and the PCC rule includes a lot of information, which is used to perform service flow control and charging rules.
  • the charging rule indicates which application or applications are billed.
  • the SDF template is a set of quintuple information used to indicate the bearer of the application flow. In general, it indicates which bearer the application flow should go in.
  • the TDF entity sends a TDF session setup response message to the PCRF entity.
  • the TDF entity determines, according to the PCC rule identifier and/or the SDF template, the traffic of the SDF to which the first application belongs and the data packet of the first application, so that the PCEF entity belongs according to the first application. SDF and traffic flow adjustment for the first application based on SDF granularity Billing result.
  • the TDF entity can identify the SDF to which the first application that needs to be charged belongs according to the PCC rule and/or the SDF template indicated by the PCC rule.
  • the first application is an application that affects the SDF granularity-based charging result of the PCEF entity, and may be, for example, an application to which the TDF entity discards the data packet discarded by the flow control, or an application determined by the TDF entity that needs to be separately charged. It can be an application determined by the TDF entity that does not require separate billing.
  • the TDF entity may determine the discarded data packet according to the information such as the IP address of the application.
  • the SDF to which it belongs; At this time, the application to which the dropped packet belongs is the first application.
  • the TDF entity detects from the SDF template that it is not required to charge all data packets having the same IP address information, the data packets of the application that actually need to be charged are determined from all the data packets having the same IP address information, and The SDF to which the application that needs to be charged belongs is determined. At this time, the application that actually needs to be charged is the first application.
  • the TDF entity may also determine, from all the data packets having the same IP address information, the data packets that are not in the application that need to be charged, and determine the SDF to which the data packets that do not need to be charged belong; The application to which the data packet that does not need to be charged belongs is the first application.
  • the TDF entity sends the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCRF entity.
  • the PCRF entity sends an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the flow of the data packet of the first application.
  • the PCEF entity adjusts the charging result of the SDF to which the first application belongs according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, so as to achieve accurate charging.
  • the TDF entity performs detection on the data flow, and the traffic of the SDF that belongs to the data packet that is discarded by performing the flow control and the traffic of the discarded data packet are passed through the PCRF.
  • the entity notifies the PCEF entity, so that the PCEF entity adjusts the charging result based on the SDF, or the data that has the same IP address information, the SDF and the traffic to which the application that actually needs to be charged belongs, or the application that does not need to be charged
  • the SDF and traffic are sent to the PCEF entity through the PCRF entity, so that the PCEF entity adjusts the SDF granularity based charging result. In order to achieve accurate billing, the problem of inaccurate billing is solved.
  • the third charging method provided by the present invention is mainly for performing SDF granularity-based charging in a PCEF entity.
  • the TDF entity may perform flow control on some applications, causing data packets of some applications.
  • the problem that the accounting is inaccurate is discarded, or the same identifier is used for the data packets with the same uplink and downlink IP address for charging.
  • the actual charging requirement may be only the partial data packet of the IP address causing the excessive charging. The question was raised.
  • the main idea of the third charging method is: First, the PCRF entity, the PCEF entity, and the TDF entity determine a charging identifier assigned to the reflow data, and the charging identifier is used to identify the reflow data.
  • the PCEF entity performs SDF granularity-based charging on the data packet
  • the TDF entity determines the reflow data, and re-sends the reflow data to the PCEF entity, so that the PCEF entity is based on the
  • the fee identifier determines the reflow data, and adjusts the SDF granularity based charging result according to the reflow data to achieve accurate charging.
  • the reflow data refers to data that affects the charging result of the PCEF entity based on the SDF granularity.
  • the following describes the flow of the second charging method from the perspective of the TDF entity, the PCEF entity, and the PCRF entity.
  • the method flow described from the perspective of the TDF entity includes:
  • the TDF entity After receiving the uplink data packet sent by the PCEF entity, the TDF entity determines the reflow data, and adds a charging identifier to the reflow data, where the reflow data refers to affecting the uplink data by the PCEF entity in the uplink data packet. a packet based on the SDF granularity of the charging result;
  • the TDF entity sends the reflow data carrying the charging identifier to the PCEF entity to enable the
  • the PCEF entity adjusts the charging result of the uplink data packet based on the SDF granularity according to the reflow data carrying the charging identifier.
  • the method further includes:
  • the TDF entity receives the charging identifier allocated by the PCRF entity sent by the PCRF entity for the reflow data.
  • the TDF entity receives the charging identifier that is sent by the PCRF entity to the loopback data, and includes:
  • the TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier. After the TDF entity receives the TDF session establishment request message sent by the PCRF entity, the method further includes:
  • the TDF entity sends a TDF Session Setup Response message to the PCRF entity.
  • the method flow described from the perspective of the PCEF entity includes:
  • the PCEF entity After performing the SDF granularity-based charging on the uplink data packet, the PCEF entity receives the reflow data carried by the TDF entity and carries the charging identifier, where the reflow data is in the uplink data packet determined by the TDF entity. a data packet of the SDF granularity based charging result of the uplink data packet by the PCEF entity;
  • the PCEF entity determines, according to the charging identifier, that the received data is reflow data, determines an SDF to which the reflow data belongs, and adjusts the charging result of the determined SDF.
  • the PCEF entity before receiving the reflow data carried by the TDF entity and carrying the charging identifier, the PCEF entity further includes:
  • the PCEF entity receives the charging identifier allocated by the PCRF entity sent by the PCRF entity for the reflow data.
  • the PCEF entity receives the charging identifier that is sent by the PCRF entity and is sent by the PCRF entity to the backflow data, and includes:
  • the PCEF entity receives an IP-CAN session setup response message sent by the PCRF entity, and the IP-CAN session setup response message includes the charging identifier.
  • the method further includes:
  • the PCEF entity sends an IP-CAN Session Setup Request message to the PCRF entity.
  • the method flow described from the perspective of the PCRF entity includes:
  • the PCRF entity determines a charging identifier that needs to be allocated to the reflow packet, and the reflow data refers to a packet in the uplink packet that affects the SDF granularity-based charging result of the PCEF entity to the uplink packet;
  • the PCRF entity sends the charging identifier to the TDF entity, including: the PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the charging identifier.
  • the method further includes: the PCRF entity receiving the TDF session establishment response message sent by the TDF entity.
  • the PCRF entity sends the charging identifier to the PCEF entity, including:
  • the PCRF entity sends an IP-CAN session setup response message to the PCEF entity, and the IP-CAN session setup response message includes the charging identifier.
  • the method further includes: the PCRF entity receiving the IP-CAN session establishment request message sent by the PCEF entity.
  • FIG. 6 is a flowchart of still another charging method according to an embodiment of the present invention. As shown in Figure 6, the method includes:
  • the PCEF entity receives an IP-CAN bearer setup request message sent by the serving gateway device.
  • the PCEF entity sends an IP-CAN session establishment request message to the PCRF entity.
  • the PCRF entity determines a charging identifier that needs to be assigned to the reflow data.
  • the reflow data in this embodiment refers to the data that affects the charging accuracy, and is used by the PCEF entity to adjust the SDF granularity-based charging result, which is returned by the TDF entity to the PCEF entity, for example,
  • the TDF entity performs charging based on the application data stream, or data that is discarded by the TDF entity to perform flow control.
  • the PCRF entity allocates a charging identifier for the reflow data, and the purpose is to enable the TDF entity to identify the reflow data, and the second is to enable the PCEF entity to identify the reflow data from the received downlink data based on the charging identifier.
  • the charging identifier assigned by the PCRF entity to the reflow data may be a DSCP value so that the DSCP bit in the IP header of the packet identifies the reflow data with a corresponding value.
  • the PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes a charging identifier assigned to the reflow data, such as a DSCP value.
  • the TDF entity sends a TDF session setup response message to the PCRF entity.
  • the PCRF entity sends an IP-CAN session establishment response message to the PCEF entity, the IP-CAN
  • the session setup response message includes a charging identifier assigned to the reflow data, such as a DSCP value.
  • the PCRF entity cooperates with the TDF entity and the PCEF entity to allocate a charging identifier for the reflow data, and provides the TDF entity and the PCEF entity respectively, so that the subsequent TDF entity and the PCEF entity are based on the charging identifier of the reflow data. Perform more accurate billing operations.
  • the TDF entity determines the reflow data. For example, the TDF entity may perform a flow control policy, determine the uplink data packet to be discarded as the reflow data, or the uplink data of the application that the TDF entity will charge based on the application data flow.
  • the package acts as reflux data.
  • the TDF entity forwards the determined reflow data to the PCEF entity, and includes a charging identifier, such as a DSCP value, allocated to the reflow data in the reflow data, so that the PCEF entity can recognize the received data when receiving the reflow data.
  • the reflow data is the uplink data packet discarded by the TDF entity or the uplink data packet that the TDF entity performs charging based on the application data flow.
  • the TDF entity may reverse information such as the IP address of the outer IP header of the reflow data, and then forward the information to the PCEF entity.
  • the PCEF entity After receiving the reflow data, the PCEF entity determines, according to the charging identifier in the reflow data, that the reflow data is received, determining the SDF to which the reflow data belongs according to the IP information of the inner layer of the reflow packet, such as an IP address. And adjust the billing result for the SDF to facilitate accurate billing.
  • the PPCEF entity can count the traffic of the reflow data, and deduct the fee generated by the traffic of the reflow data from the charging result of the SDF to which the reflow data belongs, so as to achieve accurate charging.
  • the charging identifier corresponding to the reflow data is pre-negotiated, and the charging identifier is used to indicate that the PCEF entity adjusts the SDF granularity-based charging result, after the PCEF entity completes the SDF granularity charging, The data packet arrives at the TDF entity.
  • the data packet of the operation is determined as the reflow data and carries the charging identifier therein, and then forwarded to the PCEF entity, so as to facilitate
  • the PCEF entity determines the reflow data based on the charging identifier in the reflow data, and then adjusts the charging result of the SDF according to the SDF to which the reflow data belongs, so as to achieve accurate charging.
  • the above data packet is described as an example, and the downlink data packet can be processed in a manner similar to the embodiment shown in Fig. 6.
  • FIG. 7 is a schematic structural diagram of a PCRF entity according to an embodiment of the present invention.
  • the PCRF entity includes: a determining module 71, an allocating module 72, and a sending module 73.
  • the determining module 71 is configured to determine a first application that needs to be charged.
  • the allocating module 72 is connected to the determining module 71, and configured to allocate a charging identifier to the first application determined by the determining module 71, where the charging identifier is used to identify that the first application needs to be separately charged.
  • the sending module 73 is connected to the determining module 71 and the assigning module 72, and is configured to send the identifier of the first application determined by the determining module 71 and the charging identifier allocated by the allocating module 72 to the first application to the UE and the PCEF respectively.
  • An entity and a TDF entity so that the UE and the TDF entity add the charging identifier to a data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the first application.
  • the identifier and the charging identifier allocated for the first application separately charge the data packet carrying the charging identifier from the UE and the TDF entity separately.
  • the sending module 73 is configured to send the identifier of the first application and the charging identifier allocated to the first application to the UE and the PCEF entity, respectively, including:
  • the sending module 73 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application. And sending, by the serving gateway device, the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the sending module 73 adds the identifier of the first application and the charging identifier TDF entity allocated for the first application, including:
  • the sending module 73 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application and a subscription identifier allocated for the first application.
  • the determining module 71 is specifically configured to receive a service flow detection event sent by the TDF entity, where the service flow detection event is that the TDF entity detects data of the first application that needs to be charged. After the packet is sent, the service flow detection event includes an identifier of the first application; and the first application is determined according to the identifier of the first application.
  • the sending module 73 is configured to send the identifier of the first application and the charging identifier allocated to the first application to the UE and the PCEF entity, respectively. Sending a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, so that the PCEF entity passes
  • the serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE.
  • the sending module 73 is configured to: use the identifier of the first application and the charging identifier TDF entity allocated to the first application, including:
  • the sending module 73 is specifically configured to send a modified ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the PCEF entity may further include: a receiving module.
  • the receiving module can be configured to receive the IP-CAN session establishment request message by the PCEF entity before the sending module 73 sends an IP-CAN session establishment response message to the PCEF entity.
  • the receiving module is further configured to: after the sending module 73 sends a TDF session establishment request message to the TDF entity, receive a TDF session establishment response message sent by the TDF entity.
  • the functional modules of the PCRF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiments.
  • the specific working principle is not described here. For details, refer to the description of the method embodiments.
  • the PCRF entity provided in this embodiment determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier needs to separately charge the first application, and then the first application is And the charging identifier assigned to the first application is sent to the TDF entity, the PCEF entity, and the UE, respectively, so that the UE and the TDF entity add the charging identifier to the data packet of the first application sent to the PCEF entity, and the PCEF entity
  • the received data packet carrying the charging identifier can be separately charged to implement separate charging for the first application in the uplink direction.
  • the PCRF entity provided in this embodiment does not have the problem of repeated charging by assigning a charging identifier to the first application because the data packet of the first application can be identified.
  • FIG. 8 is a schematic structural diagram of another PCRF entity according to an embodiment of the present invention.
  • the PCRF entity includes: a processor 81, a transmitter 82, and a memory 83.
  • Memory 83 can include read only memory and random access memory and provides instructions and data to processor 81. A portion of the memory 83 may also include non-volatile random access memory (NVRAM)
  • NVRAM non-volatile random access memory
  • Memory 83 stores the following elements, executable modules or data structures, or a subset thereof, or their extended set:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 81 calls the operation instruction stored in the memory 83 (the The operation instructions can be stored in the operating system), and the following operations are performed:
  • Determining a first application that needs to be charged and assigning a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged.
  • the transmitter 82 is configured to send the identifier of the first application determined by the processor 81 and the charging identifier allocated by the processor 81 to the first application to the UE, the PCEF entity, and the TDF entity, respectively, to enable the UE And the TDF entity adds the charging identifier to the data packet of the first application, and sends the charging identifier to the PCEF entity, so that the PCEF entity allocates the first application according to the identifier of the first application.
  • the charging identifier separately charges the data packet carrying the charging identifier from the UE and the TDF entity.
  • the PCRF entity may further include: a receiver 84.
  • the processor 81 controls the operation of the PCRF entity, and the processor 81 may also be referred to as a Central Processing Unit (CPU).
  • Memory 83 can include read only memory and random access memory and provides instructions and data to processor 81. A portion of the memory 83 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the PCRF entity are coupled together by a bus system 85.
  • the bus system 85 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 85 in the figure.
  • Processor 81 may be an integrated circuit chip with signal processing capabilities. In the implementation process, the steps of the above method may be completed by an integrated logic circuit of hardware in the processor 81 or an instruction in the form of software.
  • the processor 81 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by the hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 83, and the processor 81 reads the information in the memory 83 and combines the hardware to perform the steps of the above method.
  • the transmitter 82 is configured to identify the identifier of the first application as the first
  • the charging identifiers allocated by the application are respectively sent to the UE and the PCEF entity, including:
  • the transmitter 82 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application. And sending, by the serving gateway device, the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the transmitter 82 identifies the identifier of the first application and the charging identifier TDF entity allocated for the first application, including:
  • the transmitter 82 is specifically configured to send a TDF session establishment request message to the TDF entity, where
  • the TDF session establishment request message includes an identifier of the first application and a subscription identifier assigned to the first application.
  • the processor 81 is specifically configured to receive, by the receiver 84, a service flow detection event sent by the TDF entity, where the service flow detection event is that the TDF entity detects that the charging is required. And transmitting, after the data packet of the application, the service flow detection event includes an identifier of the first application; and determining the first application according to the identifier of the first application received by the receiver 84.
  • the transmitter 82 is configured to send the identifier of the first application and the charging identifier allocated to the first application to the UE and the PCEF entity, respectively, including:
  • the transmitter 82 is specifically configured to send a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, so that The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
  • the transmitter 82 is configured to: use the identifier of the first application and the charging identifier TDF entity allocated for the first application, including:
  • the transmitter 82 is specifically configured to send a modified ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the receiver 84 is configured to receive the IP-CAN session establishment request message by the PCEF entity before the transmitter 82 sends the IP-CAN session establishment response message to the PCEF entity.
  • the receiver 84 is further configured to: after the transmitter 82 sends a TDF session establishment request message to the TDF entity, receive a TDF session establishment response message sent by the TDF entity.
  • the PCRF entity provided in this embodiment may be used to perform the first charging party in the foregoing method embodiment.
  • the specific working principle of the method of the method will not be described again. For details, refer to the description of the method embodiment.
  • the PCRF entity provided in this embodiment determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier needs to separately charge the first application, and then the first application is And the charging identifier assigned to the first application is sent to the TDF entity, the PCEF entity, and the UE, respectively, so that the UE and the TDF entity add the charging identifier to the data packet of the first application sent to the PCEF entity, and the PCEF entity
  • the received data packet carrying the charging identifier can be separately charged to implement separate charging for the first application in the uplink direction.
  • the PCRF entity provided in this embodiment does not have the problem of repeated charging by assigning a charging identifier to the first application because the data packet of the first application can be identified.
  • FIG. 9 is a schematic structural diagram of a PCEF entity according to an embodiment of the present invention. As shown in FIG. 9, the PCEF entity includes: a receiving module 91, a sending module 92, and a billing module 93.
  • the receiving module 91 is configured to receive, by the PCRF entity, an identifier of the first application that needs to be separately charged, and a charging identifier that is allocated to the first application.
  • the sending module 92 is connected to the receiving module 91, and configured to send, by the serving gateway device, the identifier of the first application received by the receiving module 91 and the charging identifier allocated to the first application to the UE, so that the UE And adding the charging identifier to the uplink data packet of the first application, and sending the identifier to the PCEF entity.
  • the receiving module 91 is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier.
  • the charging module 93 is connected to the receiving module 91, and is configured to separately charge the uplink data packet that is received by the receiving module 91 and that carries the charging identifier according to the charging identifier received by the receiving module 91.
  • the receiving module 91 is further configured to receive a downlink data packet that is sent by the TDF entity and that carries the charging identifier.
  • the charging module 93 is further configured to separately charge the downlink data packet that is received by the receiving module 91 and that carries the charging identifier according to the charging identifier received by the receiving module 91.
  • the receiving module 91 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
  • the receiving module 91 is specifically configured to receive an IP-CAN session establishment response sent by the PCRF entity.
  • the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application; or
  • the receiving module 91 is specifically configured to receive the policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the sending module 92 is further configured to send an IP-CAN session establishment request message to the PCRF entity before the receiving module 91 receives the IP-CAN session setup response message sent by the PCRF entity.
  • the sending module 92 is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
  • the sending module 92 is specifically configured to send an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier allocated to the first application. So that the serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE.
  • the receiving module 91 is further configured to send, at the sending module 92, the serving gateway device.
  • the IP-CAN bearer setup request message sent by the serving gateway device is received.
  • the function modules of the PCEF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiments.
  • the specific working principle is not described here. For details, refer to the description of the method embodiments.
  • the PCEF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, according to the identifier of the first application and the accounting allocated for the first application. Identifying, separately charging, for the data packet of the first application that carries the charging identifier from the UE or the TDF entity, and because the data packet of the first application can be identified by using the charging identifier, there is no repetition Billing issue.
  • FIG. 10 is a schematic structural diagram of another PCEF entity according to an embodiment of the present invention.
  • the PCEF entity includes: a receiver 1001, a transmitter 1002, a processor 1003, and a memory 1004.
  • the receiver 1001 is configured to receive, by the PCRF entity, an identifier of the first application that needs to be separately charged, and a charging identifier that is allocated to the first application.
  • a transmitter 1002 configured to use the identifier of the first application received by the receiver 1001 as The charging identifier of the first application is sent to the UE by the serving gateway device, so that the UE sends the charging identifier to the PCEF entity after adding the charging identifier to the uplink data packet of the first application.
  • the receiver 1001 is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier.
  • Memory 1004 can include read only memory and random access memory and provides instructions and data to processor 1003. A portion of memory 1004 may also include non-volatile random access memory (NVRAM) o
  • NVRAM non-volatile random access memory
  • Memory 1004 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 1003 performs the following operations by calling an operation instruction stored in the memory 1004 (the operation instruction can be stored in the operating system):
  • the uplink data packet that is received by the receiver 1001 and carries the charging identifier is separately charged according to the charging identifier received by the receiver 1001.
  • the processor 1003 controls the operation of the PCEF entity, which may also be referred to as a CPU.
  • the memory 1004 can include read only memory and random access memory and provides instructions and data to the processor 1003.
  • a portion of the memory 1004 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the PCEF entity are coupled together by a bus system 1005.
  • the bus system 1005 may include a power bus, a control bus, a status signal bus, and the like in addition to the data bus. However, for clarity of description, various buses are labeled as a bus system in the figure.
  • the method disclosed in the above embodiments of the present invention may be applied to the processor 1003 or implemented by the processor 1003.
  • the processor 1003 may be an integrated circuit chip with signal processing capabilities.
  • each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 1003 or an instruction in a form of software.
  • the processor 1003 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware.
  • DSP digital signal processor
  • ASIC application specific integrated circuit
  • FPGA off-the-shelf programmable gate array
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like. Combined with this
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented by the hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 1004.
  • the processor 1003 reads the information in the memory 1004 and completes the steps of the above method in combination with the hardware.
  • the receiver 1001 is further configured to receive a downlink data packet that is sent by the TDF entity and that carries the charging identifier.
  • the processor 1003 is further configured to separately charge the downlink data packet that is received by the receiver 1001 and that carries the charging identifier according to the charging identifier received by the receiver 1001.
  • the receiver 1001 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
  • the receiver 1001 is specifically configured to receive an IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging for the first application. Identification; or
  • the receiver 1001 is specifically configured to receive a policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the transmitter 1002 is further configured to send an IP-CAN session establishment request message to the PCRF entity before the receiver 1001 receives the IP-CAN session establishment response message sent by the PCRF entity.
  • the transmitter 1002 is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
  • the transmitter 1002 is specifically configured to send an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application. So that the serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE.
  • the receiver 1001 is further configured to receive an IP-CAN bearer setup request message sent by the serving gateway device before the transmitter 1002 sends an IP-CAN bearer setup response message to the serving gateway device.
  • the PCEF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the PCEF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, according to the identifier of the first application and the accounting allocated for the first application. Identifying, separately charging, for the data packet of the first application that carries the charging identifier from the UE or the TDF entity, and because the data packet of the first application can be identified by using the charging identifier, there is no repetition Billing issue.
  • FIG. 1 is a schematic structural diagram of a TDF entity according to an embodiment of the present invention.
  • the TDF entity includes: a receiving module 1101, a determining adding module 1102, and a sending module 1103.
  • the receiving module 1101 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and a charging identifier that is allocated to the first application.
  • the determining module 1102 is configured to be connected to the receiving module 1101, configured to determine, according to the identifier of the first application received by the receiving module 1101, the downlink data packet of the first application, and add and receive the downlink data packet of the first application.
  • the sending module 1103 is connected to the determining adding module 1102, and configured to send the downlink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity downlinks the first application based on the charging identifier. Packets are billed separately.
  • the receiving module 1101 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
  • the receiving module 1101 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the sending module 1103 is further configured to send a TDF session establishment response message to the PCRF entity after the receiving module 1101 receives the TDF session establishment request message sent by the PCRF entity.
  • the PCEF entity further includes: a detecting module, configured to detect a data packet of the first application that needs to be separately charged.
  • the sending module 1103 is further configured to: after the detecting module detects the data packet of the first application, send a service flow detecting event to the PCRF entity, where the service flow detecting event includes the first application The identifier, so that the PCRF entity is determined according to the identifier of the first application. It is necessary to separately charge the first application.
  • the receiving module 1101 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and a charging that is allocated to the first application. Identification, including:
  • the receiving module 1101 is specifically configured to receive a modified ADC rule message sent by the PCRF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the function modules of the TDF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the TDF entity provided in this embodiment receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated for the first application, according to the identifier of the first application and the accounting allocated for the first application.
  • the identifier is sent to the PCEF entity in the downlink data packet of the first application, and is sent to the PCEF entity, so that the PCEF entity can be based on the identifier of the first application sent by the PCRF entity and the charging identifier allocated for the first application.
  • the downlink data packet carrying the charging identifier of the TDF entity is separately charged, and the individual charging for the first application is implemented, and the problem of repeated charging does not occur.
  • FIG. 12 is a schematic structural diagram of another TDF entity according to an embodiment of the present invention. As shown in FIG. 12, the TDF entity includes: a receiver 1201, a processor 1202, a transmitter 1203, and a memory 1204.
  • the receiver 1201 is configured to receive, by the PCRF entity, an identifier of the first application that needs to be separately charged, and a charging identifier that is allocated to the first application.
  • Memory 1204 can include read only memory and random access memory and provides instructions and data to processor 1202. A portion of memory 1204 may also include non-volatile random access memory (NVRAM)
  • NVRAM non-volatile random access memory
  • Memory 1204 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 1202 calls the operation instruction stored in the memory 1204. (The operation instruction can be stored in the operating system), do the following:
  • the transmitter 1203 is configured to send the downlink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity separately charges the downlink data packet of the first application based on the charging identifier.
  • the processor 1202 controls the operation of the TDF entity, and the processor 1202 may also be referred to as a CPU.
  • Memory 1204 can include read only memory and random access memory and provides instructions and data to processor 1202.
  • a portion of memory 1204 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the various components of the TDF entity are coupled together by a bus system 1205, wherein the bus system 1205 can include, in addition to the data bus, a power bus, a control bus, and a status signal bus.
  • bus system 1205 can include, in addition to the data bus, a power bus, a control bus, and a status signal bus.
  • various buses are labeled as bus system 1205 in the figure.
  • Processor 1202 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method may be completed by an integrated logic circuit of hardware in the processor 1202 or an instruction in the form of software.
  • the processor 1202 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in conventional memory, such as random memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 1204, and the processor 1202 reads the information in the memory 1204 and combines the hardware to perform the steps of the above method.
  • the receiver 1201 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
  • the receiver 1201 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes an identifier of the first application and is allocated for the first application. Billing ID.
  • the transmitter 1203 is further configured to send a TDF session establishment response message to the PCRF entity after the receiver 1201 receives the TDF session establishment request message sent by the PCRF entity.
  • the processor 1202 is further configured to detect a data packet of the first application that needs to be separately charged.
  • the transmitter 1203 is further configured to: after the processor 1202 detects the data packet of the first application, send a service flow detection event to the PCRF entity, where the service flow detection event includes the first application And determining, by the PCRF entity, determining, according to the identifier of the first application, that the first application needs to be separately charged.
  • the receiver 1201 is configured to receive, by the PCRF entity, an identifier of a first application that is separately billed by the PCRF entity and a charging identifier that is allocated to the first application, where Includes:
  • the receiver 1201 is specifically configured to receive a modified ADC rule message sent by the PCRF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
  • the TDF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the TDF entity provided in this embodiment receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated for the first application, according to the identifier of the first application and the accounting allocated for the first application.
  • the identifier is sent to the PCEF entity in the downlink data packet of the first application, and is sent to the PCEF entity, so that the PCEF entity can be based on the identifier of the first application sent by the PCRF entity and the charging identifier allocated for the first application.
  • the downlink data packet carrying the charging identifier of the TDF entity is separately charged, and the individual charging for the first application is implemented, and the problem of repeated charging does not occur.
  • FIG. 13 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention.
  • the PCRF entity includes: a sending module 1301 and a receiving module 1302.
  • the sending module 1301 is configured to send the PCC rule identifier and/or the SDF template to the TDF entity, where the TDF entity determines the identifier and the first application of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result belongs The traffic of the packet.
  • the receiving module 1302 is configured to receive, according to the PCC rule identifier, sent by the TDF entity, And the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application determined by the SDF template.
  • the sending module 1301 is connected to the receiving module 1302, and is further configured to send, by the receiving module 1302, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that The PCEF entity adjusts the uplink data packet from the UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the first application is The data packet belongs to an upstream data packet from the UE.
  • the sending module 1301 is configured to send the PCC rule identifier and/or the SDF template to the TDF entity, including:
  • the sending module 1301 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the receiving module 1302 is further configured to: after the sending module 1301 sends a TDF session establishment request message to the TDF entity, receive a TDF session establishment response message sent by the TDF entity.
  • the sending module 1301 is configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, including:
  • the sending module 1301 is specifically configured to send an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. flow.
  • the function modules of the PCRF entity provided in this embodiment may be used to perform the process of the second charging method in the foregoing method embodiments.
  • the specific working principle is not described here. For details, refer to the description of the method embodiments.
  • the PCRF entity provided in this embodiment sends a PCC rule identifier and/or an SDF template to the TDF entity, so that the TDF entity determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and returns the data to the embodiment.
  • the PCRF entity, the PCRF entity of the embodiment sends the identifier of the first application and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity re-pairs according to the identifier of the first application and the traffic of the data packet of the first application.
  • the billing result based on the SDF granularity is adjusted to achieve accurate billing.
  • FIG. 14 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention.
  • the PCRF entity includes: a transmitter 1401, a receiver 1402, a processor 1403, and a memory 1404.
  • a transmitter 1401 configured to send a PCC rule identifier and/or an SDF template to the TDF entity, And determining, by the TDF entity, an identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result and a traffic of the data packet of the first application.
  • the receiver 1402 is configured to receive, by the TDF entity, the identifier of the SDF to which the first application belongs according to the PCC rule identifier and/or the SDF template, and the traffic of the data packet of the first application.
  • the transmitter 1401 is further configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity is based on the first application belongs to
  • the identifier of the SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the UE, where the data packet of the first application belongs to the uplink data packet from the UE .
  • the memory 1404 can include read only memory and random access memory, and provides instructions and data to the processor 1403.
  • a portion of memory 1404 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • Memory 1404 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 1403 performs a corresponding operation by calling an operation instruction stored in the memory 1404 (which can be stored in the operating system), thereby controlling the operation of the PCRF entity.
  • the processor 1403 controls the operation of the PCRF entity, and the processor 1403 may also be referred to as a CPU.
  • Memory 1404 can include read only memory and random access memory and provides instructions and data to processor 1403.
  • a portion of memory 1404 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the PCRF entity are coupled together by a bus system 1405.
  • the bus system 1405 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 1405 in the figure.
  • the method disclosed in the foregoing embodiment of the present invention may be applied to the processor 1403 or implemented by the processor 1403.
  • the processor 1403 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 1403 or an instruction in a form of software.
  • the processor 1403 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 1404.
  • the processor 1403 reads the information in the memory 1404 and completes the steps of the above method in combination with hardware.
  • the transmitter 1401 is configured to send the PCC rule identifier and/or the SDF template to the TDF entity, including:
  • the transmitter 1401 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the receiver 1402 is further configured to: after the transmitter 1401 sends a TDF session setup request message to the TDF entity, receive a TDF session setup response message sent by the TDF entity.
  • the transmitter 1401 is configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, including:
  • the transmitter 1401 is specifically configured to send an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. flow.
  • the PCRF entity provided in this embodiment can be used to perform the process of the second charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the PCRF entity provided in this embodiment sends a PCC rule identifier and/or an SDF template to the TDF entity, so that the TDF entity determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and returns the data to the embodiment.
  • the PCRF entity, the PCRF entity of the embodiment sends the identifier of the first application and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity re-pairs according to the identifier of the first application and the traffic of the data packet of the first application.
  • the billing result based on the SDF granularity is adjusted to achieve accurate billing.
  • FIG. 15 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention. As shown in Figure 15 The PCEF entity includes: a receiving module 1501 and a charging adjustment module 1502.
  • the receiving module 1501 is configured to receive, by the PCRF entity, an identifier of the SDF that is affected by the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application, where the first The identifier of the SDF to which the application belongs and the traffic of the data packet of the first application are determined by the TDF entity according to the PCC rule identifier and/or the SDF template sent by the PCRF entity, and sent to the PCRF entity.
  • the charging adjustment module 1502 is configured to be connected to the receiving module 1501, configured to determine, according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application received by the receiving module 1501, the uplink data packet from the UE is based on The charging result of the SDF granularity is adjusted, wherein the data packet of the first application belongs to an uplink data packet from the UE.
  • the PCEF entity further includes: a charging module, configured to: before the receiving module 1501 receives the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, The uplink data packet of the UE performs charging based on SDF granularity.
  • a charging module configured to: before the receiving module 1501 receives the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, The uplink data packet of the UE performs charging based on SDF granularity.
  • the receiving module 1501 is configured to receive, by the PCRF entity, an identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application. , including:
  • the receiving module 1501 is specifically configured to receive an IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. Traffic.
  • the PCEF entity in this embodiment may further include: a sending module, configured to receive the module
  • the 1501 After receiving the IP-CAN session modification request message sent by the PCRF entity, the 1501 sends an IP-CAN session modification response message to the PCRF entity.
  • the function modules of the PCEF entity provided in this embodiment may be used to perform the process of the second charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the PCEF entity receives the identifier of the first application that needs to be separately charged and the data packet of the first application that is determined by the TDF entity and is sent by the PCRF entity, according to the identifier of the first application and the first application.
  • the traffic of the data packet is re-adjusted based on the SDF granularity charging result to achieve accurate charging.
  • FIG. 16 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention.
  • the PCEF entity includes: a receiver 1601, a processor 1602, and a memory 1603.
  • the receiver 1601 is configured to receive, by the PCRF entity, an identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application, where the first The identifier of the SDF to which the application belongs and the traffic of the data packet of the first application are determined by the TDF entity according to the PCC rule identifier and/or the SDF template sent by the PCRF entity, and sent to the PCRF entity.
  • Memory 1603 can include read only memory and random access memory and provides instructions and data to processor 1602. A portion of memory 1603 may also include non-volatile random access memory (NVRAM) o
  • NVRAM non-volatile random access memory
  • Memory 1603 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 1602 performs the following operations by calling an operation instruction stored in the memory 1603 (the operation instruction can be stored in the operating system):
  • the PCEF entity may further include: a transmitter 1604.
  • the processor 1602 controls the operation of the PCEF entity, which may also be referred to as a CPU.
  • Memory 1603 can include read only memory and random access memory and provides instructions and data to processor 1602.
  • a portion of memory 1603 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the PCEF entity are coupled together by a bus system 1605.
  • the bus system 1605 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 1605 in the figure.
  • the method disclosed in the foregoing embodiments of the present invention may be applied to the processor 1602 or implemented by the processor 1602.
  • the processor 1602 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method may be completed by an integrated logic circuit of hardware in the processor 1602 or an instruction in a form of software.
  • the processor 1602 described above may be a general purpose processor, a digital Signal processor (DSP), application specific integrated circuit (ASIC), off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware component.
  • DSP digital Signal processor
  • ASIC application specific integrated circuit
  • FPGA off-the-shelf programmable gate array
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 1603, and the processor 1602 reads the information in the memory 1603, and completes the steps of the above method in combination with the hardware thereof.
  • the processor 1602 is further configured to: after receiving, by the receiver 1601, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, the uplink data packet from the UE Perform SDF granularity based charging.
  • the receiver 1601 is configured to receive, by the PCRF entity, an identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application. , including:
  • the receiver 1601 is specifically configured to receive an IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. Traffic.
  • the transmitter 1604 is configured to send an IP-CAN session modification response message to the PCRF entity after the receiver 1601 receives the IP-CAN session modification request message sent by the PCRF entity.
  • the PCEF entity provided in this embodiment may be used to perform the process of the second charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the PCEF entity receives the identifier of the first application that needs to be separately charged and the data packet of the first application that is determined by the TDF entity and is sent by the PCRF entity, according to the identifier of the first application and the first application.
  • the traffic of the data packet is re-adjusted based on the SDF granularity charging result to achieve accurate charging.
  • FIG. 17 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention.
  • the TDF entity includes: a receiving module 1701, a determining module 1702, and a sending module 1703.
  • the receiving module 1701 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity.
  • the determining module 1702 is connected to the receiving module 1701 for receiving according to the receiving module 1701.
  • the PCC rule identifier and/or the SDF template determines an identifier of the SDF to which the first application that affects the PCEF entity based on the SDF granularity charging result and a traffic of the data packet of the first application.
  • the sending module 1703 is connected to the determining module 1702, and configured to send, by the PCRF entity, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application determined by the determining module 1702 to the PCEF entity. And adjusting, by the PCEF entity, the SDL granularity-based charging result of the uplink data packet from the UE, based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application; The data packet of the first application belongs to an uplink data packet from the UE.
  • the receiving module 1701 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity, including:
  • the receiving module 1701 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the sending module 1703 is further configured to send a TDF session establishment response message to the PCRF entity after the receiving module 1701 receives the TDF session establishment request message sent by the PCRF entity.
  • the determining module 1702 is configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiving module 1701, an identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result belongs. And the traffic of the data packet of the first application, where: the determining module 1702 is specifically configured to determine, according to the PCC rule indicated by the PCC rule identifier received by the receiving module 1701, a data packet that is discarded due to performing application-based flow control. As the first application, the associated application determines the traffic of the discarded data packet as the traffic of the data packet of the first application, and determines the SDF to which the first application belongs; or
  • the determining module 1702 is specifically configured to: when the SDF template received by the receiving module 1701 detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the same IP address information is obtained. In all the data packets, the application to which the data packet actually required to be charged belongs is determined as the first application, and the traffic of the data packet actually required to be charged is determined as the traffic of the data packet of the first application, and the The SDF to which the first application belongs; or the determining module 1702 is specifically configured to detect, according to the SDF template received by the receiving module 1701, that all data packets having the same IP address information in the uplink data packet from the UE are not required to be counted.
  • Time-consuming determining, from all the data packets having the same IP address information, an application to which the data packet that does not need to be charged belongs is used as the first application, and determining the traffic of the data packet that does not need to be charged as the The traffic of the first application's data packet, and determining the SDF to which the first application belongs.
  • the function modules of the TDF entity provided in this embodiment can be used to perform the process of the second charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the TDF entity receives the PCC rule identifier and/or the SDF template sent by the PCRF entity, and determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and then passes the PCRF.
  • the entity sends the entity to the PCEF entity, so that the PCEF entity can re-adjust the charging result based on the SDF granularity according to the identifier of the first application and the traffic of the data packet of the first application, so as to implement accurate charging.
  • FIG. 18 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention.
  • the TDF entity includes: a receiver 1801, a processor 1802, a transmitter 1803, and a memory 1804.
  • the receiver 1801 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity.
  • Memory 1804 can include read only memory and random access memory and provides instructions and data to processor 602. A portion of memory 1804 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • Memory 1804 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 1802 performs the following operations by calling an operation instruction stored in the memory 1804 (which can be stored in the operating system):
  • a transmitter 1803 configured to send, by the processor 1802, an identifier of an SDF to which the first application belongs and a traffic of a data packet of the first application to the PCEF entity by using the PCRF entity, to enable the PCEF
  • the entity adjusts the uplink data packet from the UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application; where the data packet of the first application is It belongs to the uplink data packet from the UE.
  • the processor 1802 controls the operation of the TDF entity, and the processor 1802 may also be referred to as a CPU.
  • Memory 1804 can include read only memory and random access memory and provides instructions and data to processor 1802.
  • a portion of the memory 1804 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the TDF entity are coupled together by a bus system 1805.
  • the bus system 1805 may include a power bus, a control bus, and a status signal bus in addition to the data bus.
  • various buses are labeled as bus system 1805 in the figure.
  • Processor 1802 may be an integrated circuit chip with signal processing capabilities. In an implementation process, the steps of the above method may be performed by an integrated logic circuit of hardware in the processor 1802 or an instruction in the form of software.
  • the processor 1802 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in conventional memory, such as random memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in memory 1804, and processor 1802 reads the information in memory 1804 and, in conjunction with its hardware, performs the steps of the above method.
  • the receiver 1801 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity, including:
  • the receiver 1801 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
  • the transmitter 1803 is further configured to send a TDF session establishment response message to the PCRF entity after the receiver 1801 receives the TDF session establishment request message sent by the PCRF entity.
  • the processor 1802 is configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiver 1801, an identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result belongs. And the traffic of the data packet of the first application, including:
  • the processor 1802 is specifically configured to determine, according to the PCC rule indicated by the PCC rule identifier received by the receiver 1801, an application to which the data packet discarded by performing application-based flow control belongs Determining, by the first application, the traffic of the discarded data packet as the traffic of the data packet of the first application, and determining the SDF to which the first application belongs; or
  • the processor 1802 is specifically configured to: when the SDF template received by the receiver 1801 detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the slave device has the same IP address information. In all the data packets, the application to which the data packet actually required to be charged belongs is determined as the first application, and the traffic of the data packet actually required to be charged is determined as the traffic of the data packet of the first application, and the The SDF to which the first application belongs; or,
  • the processor 1802 is specifically configured to: when the SDF template received by the receiver 1801 detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the slave device has the same IP address information. Determining, by the application, the application to which the data packet that does not need to be charged belongs, as the first application, determining the traffic of the data packet that does not need to be charged as the traffic of the data packet of the first application, and determining the The SDF to which the first application belongs.
  • the TDF entity provided in this embodiment can be used to perform the process of the second charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the TDF entity receives the PCC rule identifier and/or the SDF template sent by the PCRF entity, and determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and then passes the PCRF.
  • the entity sends the entity to the PCEF entity, so that the PCEF entity can re-adjust the charging result based on the SDF granularity according to the identifier of the first application and the traffic of the data packet of the first application, so as to implement accurate charging.
  • FIG. 19 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention.
  • the TDF entity includes: a receiving module 1901, a determining adding module 1902, and a sending module 1903.
  • the receiving module 1901 is configured to receive an uplink data packet sent by the PCEF entity.
  • the determining module 1902 is connected to the receiving module 1901, and configured to: after the receiving module 1901 receives the uplink data packet, determine reflow data, and add a charging identifier to the reflow data, where the reflow data refers to the uplink A data packet in the data packet that affects the charging result of the SDF granularity of the uplink data packet by the PCEF entity.
  • the sending module 1903 is connected to the determining adding module 1902, and configured to send, by the determining the adding module 1902, the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity is configured to carry the charging identifier.
  • the data is reflowed, and the uplink data packet is adjusted based on the SDF granularity charging result.
  • the receiving module 1901 is further configured to: before determining that the adding module 1902 adds a charging identifier to the reflow data, receiving, by the PCRF entity, the charging that is allocated by the PCRF entity for the reflow data. logo.
  • the receiving module 1901 is further connected to the determining adding module 1902, and configured to provide the charging identifier to the determining adding module 1902.
  • the receiving module 1901 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes:
  • the receiving module 1901 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
  • the sending module 1903 is further configured to send a TDF session establishment response message to the PCRF entity after the receiving module 1901 receives the TDF session establishment request message sent by the PCRF entity.
  • the functional modules of the TDF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiments.
  • the specific working principle is not described here. For details, refer to the description of the method embodiments.
  • the TDF entity provided in this embodiment determines the reflow data in the uplink data packet from the PCEF entity, and adds the recurring data to the PCEF entity after adding the charging identifier, so that the PCEF entity can determine, according to the charging identifier, that the TDF entity sends the The data is reflowed, and the SDF granularity based charging result is readjusted based on the flow of the reflow data to achieve accurate charging.
  • FIG. 20 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention.
  • the TDF entity includes: a receiver 2001, a processor 2002, a transmitter 2003, and a memory.
  • the receiver 2001 is configured to receive an uplink data packet sent by a PCEF entity.
  • Memory 2004 can include read only memory and random access memory and provides instructions and data to processor 2002. A portion of the memory 2004 may also include non-volatile random access memory (NVRAM) o
  • NVRAM non-volatile random access memory
  • Memory 2004 stores the following elements, executable modules or data structures, or a subset of them, or their extended set:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 2002 performs the following operations by calling an operation instruction stored in the memory 2004 (the operation instruction can be stored in the operating system): After receiving the uplink data packet, the receiver 2001 determines the reflow data, and adds a charging identifier to the reflow data, where the reflow data refers to the uplink data packet affecting the PCEF entity to the uplink data. A packet based on the SDF granularity of the charging result.
  • the transmitter 2003 is configured to send the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity performs the SDF granularity on the uplink data packet according to the reflow data carrying the charging identifier.
  • the billing result is adjusted.
  • the processor 2002 controls the operation of the TDF entity, and the processor 2002 may also be referred to as a CPU.
  • Memory 2004 can include read only memory and random access memory and provides instructions and data to processor 2002.
  • a portion of the memory 2004 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the TDF entity are coupled together by a bus system 2005, which may include a power bus, a control bus, and a status signal bus in addition to the data bus.
  • bus system 2005 may include a power bus, a control bus, and a status signal bus in addition to the data bus.
  • various buses are labeled as bus system 2005 in the figure.
  • the method disclosed in the foregoing embodiments of the present invention may be applied to the processor 2002 or implemented by the processor 2002.
  • the processor 2002 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method may be completed by an integrated logic circuit of hardware in the processor 2002 or an instruction in the form of software.
  • the processor 2002 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in conventional memory, such as random memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 2004, and the processor 2002 reads the information in the memory 2004 and combines the hardware to perform the steps of the above method.
  • the receiver 2001 is further configured to: before the processor 2002 adds the charging identifier to the reflow data, receive, by the PCRF entity, the charging identifier that is sent by the PCRF entity to the reflow data. And providing the charging identifier to the processor 2002.
  • the receiver 2001 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes: The receiver 2001 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
  • the transmitter 2003 is further configured to send a TDF session establishment response message to the PCRF entity after the receiver 2001 receives the TDF session establishment request message sent by the PCRF entity.
  • the TDF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the TDF entity provided in this embodiment determines the reflow data in the uplink data packet from the PCEF entity, and adds the recurring data to the PCEF entity after adding the charging identifier, so that the PCEF entity can determine, according to the charging identifier, that the TDF entity sends the The data is reflowed, and the SDF granularity based charging result is readjusted based on the flow of the reflow data to achieve accurate charging.
  • FIG. 21 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention.
  • the PCEF entity includes: a receiving module 2101 and a charging adjustment module 2102.
  • the receiving module 2101 is configured to: after performing the SDF granularity-based charging on the uplink data packet, receive the reflow data that is sent by the TDF entity and that carries the charging identifier, where the reflow data is the uplink data packet that is determined by the TDF entity. a data packet affecting the SDF granularity based charging result of the uplink data packet by the PCEF entity.
  • the billing adjustment module 2102 is connected to the receiving module 2101, and configured to determine, according to the billing identifier, that the data received by the receiving module 2101 is the reflow data, determine an SDF to which the reflow data belongs, and determine the SDF of the reflow data. The billing result is adjusted.
  • the receiving module 2101 is further configured to: before receiving the reflow data carrying the charging identifier sent by the TDF entity, receiving, by the PCRF entity, the PCRF entity to allocate the reflow data Billing ID.
  • the receiving module 2101 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes:
  • the receiving module 2101 is specifically configured to receive an IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier.
  • the PCEF entity in this embodiment may further include: a sending module, configured to receive the module
  • the functional modules of the PCEF entity provided in this embodiment may be used to execute the foregoing method embodiment.
  • the PCEF entity provided in this embodiment receives the reflow data carried by the TDF entity and carries the charging identifier. After determining that the received data is reflow data according to the charging identifier, determining the SDF to which the reflow data belongs, and then determining the SDF. The SDF billing result is adjusted to achieve accurate billing.
  • FIG. 22 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention.
  • the PCEF entity includes: a receiver 2201, a processor 2202, and a memory 2203.
  • the receiver 2201 is configured to receive, after the SDF granularity-based charging of the uplink data packet, the reflow data that is sent by the TDF entity and that carries the charging identifier, where the reflow data is the uplink data packet that is determined by the TDF entity. And a data packet affecting the SDF granularity-based charging result of the uplink data packet by the PCEF entity.
  • Memory 2203 can include read only memory and random access memory and provides instructions and data to processor 2202. A portion of memory 2203 may also include non-volatile random access memory (NVRAM) o
  • NVRAM non-volatile random access memory
  • the memory 2203 stores the following elements, executable modules or data structures, or a subset thereof, or their extended set:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 2202 performs the following operations by calling an operation instruction stored in the memory 2203 (which can be stored in the operating system):
  • the PCEF entity in this embodiment further includes: a transmitter 2204.
  • the processor 2202 controls the operation of the PCEF entity, which may also be referred to as a CPU.
  • Memory 2203 can include read only memory and random access memory and provides instructions and data to processor 2202.
  • a portion of the memory 2203 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the PCEF entity are coupled together by a bus system 2205.
  • the bus system 2205 may include a power bus, a control bus, a status signal bus, and the like in addition to the data bus. However, for clarity of description, various buses are labeled as bus system 2205 in the figure.
  • the method disclosed in the foregoing embodiment of the present invention may be applied to the processor 2202 or implemented by the processor 2202.
  • Processor 2202 may be an integrated circuit chip with signal processing capabilities.
  • each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 2202 or an instruction in a form of software.
  • the processor 2202 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 2203.
  • the processor 2202 reads the information in the memory 2203 and completes the steps of the above method in combination with the hardware.
  • the receiver 2201 is further configured to: before receiving the reflow data carrying the charging identifier sent by the TDF entity, receiving, by the PCRF entity, the PCRF entity to allocate the reflow data Billing ID.
  • the receiver 2201 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes:
  • the receiver 2201 is specifically configured to receive an IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier.
  • the transmitter 2204 is configured to receive, by the receiver 2201, the sent by the PCRF entity.
  • IP-CAN Session Establishment Request message is sent to the PCEF entity prior to the IP-CAN Session Setup Response message.
  • the PCEF entity provided in this embodiment can be used to perform the process of the third charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the PCEF entity receives the reflow data carried by the TDF entity and carries the charging identifier. After determining that the received data is reflow data according to the charging identifier, determining the SDF to which the reflow data belongs, and then determining the SDF. The SDF billing result is adjusted to achieve accurate billing.
  • FIG. 23 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention.
  • the PCRF entity includes: a determining module 2301 and a sending module 2302.
  • a determining module 2301 configured to determine a charging identifier that needs to be allocated to a reflow packet, the reflow
  • the data refers to a data packet in the uplink data packet that affects the SDF granularity-based charging result of the uplink data packet by the PCEF entity.
  • the sending module 2302 is connected to the determining module 2301, and configured to send the charging identifier determined by the determining module 2301 to the TDF entity and the PCEF entity, where the TDF entity sends the uplink data from the PCEF entity.
  • the charging identifier is added to the reflow data, and then sent to the PCEF entity, so that the PCEF entity determines the reflow data according to the charging identifier and is based on the reflow.
  • the data adjusts the SDF granularity based charging result of the uplink data packet.
  • the sending module 2302 is configured to send the charging identifier to the TDF entity, including:
  • the sending module 2302 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the charging identifier.
  • the PCRF entity may further include: a receiving module, configured to: after the sending module 2302 sends a TDF session establishment request message to the TDF entity, receive the TDF entity to send a TDF session establishment response message.
  • a receiving module configured to: after the sending module 2302 sends a TDF session establishment request message to the TDF entity, receive the TDF entity to send a TDF session establishment response message.
  • the sending module 2302 is configured to send the charging identifier to the PCEF entity, including:
  • the sending module 2302 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes the charging identifier.
  • the receiving module is further configured to receive an IP-CAN session establishment request message sent by the PCEF entity before the sending module 2302 sends an IP-CAN session establishment response message to the PCEF entity.
  • the function modules of the PCRF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiments.
  • the specific working principle is not described here. For details, refer to the description of the method embodiments.
  • the PCRF entity determines the charging identifiers that are allocated to the reflow data, and sends them to the TDF entity and the PCEF entity, respectively, so that the TDF entity adds the charging identifier to the determined reflow data and sends the charging identifier to the PCEF entity.
  • the PCEF entity determines that the data from the TDF entity is the reflow data based on the charging identifier, and then determines the SDF to which the reflow data belongs, and adjusts the determined SDF charging result to implement accurate charging.
  • FIG. 24 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention.
  • the PCRF entity includes: a processor 2401, a transmitter 2402, and a memory 2403.
  • Memory 2403 can include read only memory and random access memory and provides instructions and data to processor 2401.
  • a portion of the memory 2403 may also include non-volatile random access memory (NVRAM) o
  • NVRAM non-volatile random access memory
  • Memory 2403 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
  • Operation instructions Includes various operation instructions for implementing various operations.
  • Operating System Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
  • the processor 2401 performs the following operations by calling an operation instruction stored in the memory 2403 (the operation instruction can be stored in the operating system):
  • a charging identifier that needs to be allocated to the reflow packet is determined, and the reflow data refers to a packet in the uplink packet that affects the SDF granularity-based charging result of the uplink packet by the PCEF entity.
  • a transmitter 2402 configured to send the charging identifier to a TDF entity and the PCEF entity, where the TDF entity determines the reflow data from the uplink data packet from the PCEF entity Adding the charging identifier to the PCEF entity, and then sending, by the PCEF entity, the reflow data according to the charging identifier, and based on the reflow data, based on the SDF granularity of the uplink data packet.
  • the billing results are adjusted.
  • the PCRF entity may further include: a receiver 2404.
  • the processor 2401 controls the operation of the PCRF entity, which may also be referred to as a CPU.
  • the memory 2403 can include read only memory and random access memory and provides instructions and data to the processor 2401.
  • a portion of the memory 2403 may also include non-volatile random access memory (NVRAM).
  • NVRAM non-volatile random access memory
  • the components of the PCRF entity are coupled together by a bus system 2405.
  • the bus system 2405 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 2405 in the figure.
  • the method disclosed in the foregoing embodiments of the present invention may be applied to the processor 2401 or implemented by the processor 2401.
  • the processor 2401 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 2401 or an instruction in a form of software.
  • the processor 2401 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA), or Other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
  • the general purpose processor may be a microprocessor or the processor or any conventional processor or the like.
  • the steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor.
  • the software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like.
  • the storage medium is located in the memory 2403, and the processor 2401 reads the information in the memory 2403 and completes the steps of the above method in combination with the hardware thereof.
  • the transmitter 2402 is configured to send the charging identifier to the TDF entity, including:
  • the transmitter 2402 is specifically configured to send a TDF session establishment request message to the TDF entity, where
  • the TDF session establishment request message includes the charging identifier.
  • the receiver 2404 is configured to: after the transmitter 2402 sends a TDF session setup request message to the TDF entity, receive the TDF entity to send a TDF session setup response message.
  • the transmitter 2402 is configured to send the charging identifier to the PCEF entity, including:
  • the transmitter 2402 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes the charging identifier.
  • the receiver 2404 is further configured to receive an IP-CAN session establishment request message sent by the PCEF entity before the transmitter 2402 sends an IP-CAN session establishment response message to the PCEF entity.
  • the PCRF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiment.
  • the specific working principle is not described here. For details, refer to the description of the method embodiment.
  • the PCRF entity determines the charging identifiers that are allocated to the reflow data, and sends them to the TDF entity and the PCEF entity, respectively, so that the TDF entity adds the charging identifier to the determined reflow data and sends the charging identifier to the PCEF entity.
  • the PCEF entity determines that the data from the TDF entity is the reflow data based on the charging identifier, and then determines the SDF to which the reflow data belongs, and adjusts the determined SDF charging result to implement accurate charging.
  • the foregoing storage medium includes: a medium that can store program codes, such as a ROM, a RAM, a magnetic disk, or an optical disk.

Abstract

Provided are a charging method and device. The method comprises: a PCRF entity determines a first application that needs to be charged, and allocates a charging identifier for the first application; and the PCRF entity respectively sends an identifier of the first application and the charging identifier allocated to the first application to a UE, a PCEF entity and a TDF entity, so that the UE and the TDF entity add the charging identifier to a data packet of the first application, and then send same to the PCEF entity, and the PCEF entity independently charges data packets that carry the charging identifier from the UE and the TDF entity respectively on the basis of the identifier of the first application and the charging identifier allocated to the first application. The technical solution of the present invention can realize application-based charging.

Description

计费方法及设备 技术领域  Billing method and equipment
本发明实施例涉及通信技术, 尤其涉及一种计费方法及设备。  The embodiments of the present invention relate to communication technologies, and in particular, to a charging method and device.
背景技术 Background technique
无线通信网络主要包括两部分, 即接入网和核心网。 核心网主要包括移 动性管理网元、 网关设备以及策略与计费控制 (Policy and Charging Control , 简称为 PCC) 功能实体。 PCC功能实体又分为策略控制与计费规则 控制功能 (Policy Control and Charging Rules Function, 简称为 PCRF) 实体禾口策略禾口计费执行功會 (Policy and Charging Enforcement Function) 实体。 其中, PCRF实体主要是根据运营商策略、 对用户接入网络的限制、 用 户签约数据以及用户当前正在进行的服务数据流 (Service Data flow, 简称 为 SDF)的业务信息等因素,制定对应的策略,该策略称为 PCC规则 (PCC rule); PCEF 实体主要是执行 PCRF 实体制定的 PCC 规则, 对用户设备 (User Equipment , 简称为 UE) 的业务数据执行流量统计与计费。  The wireless communication network mainly includes two parts, namely an access network and a core network. The core network mainly includes mobile management network elements, gateway devices, and Policy and Charging Control (PCC) functional entities. The PCC functional entity is further divided into a Policy Control and Charging Rules Function (PCRF) entity and a Policy and Charging Enforcement Function entity. The PCRF entity mainly formulates corresponding policies according to factors such as the operator's policy, restrictions on the user's access to the network, user subscription data, and service information of the service data flow (SDF) currently being performed by the user. The PCC rule is a PCC rule. The PCEF entity performs the traffic statistics and accounting for the service data of the user equipment (User Equipment, UE for short).
目前,对用户的业务数据进行计费是由 PCEF实体执行基于 SDF粒度的计 费。在当前的 3GPP组织中正在讨论基于应用数据流的计费, 但目前并没有相 应的解决方案。 发明内容  Currently, charging the user's business data is performed by the PCEF entity based on the SDF granularity. Application data flow based charging is being discussed in current 3GPP organizations, but there is currently no corresponding solution. Summary of the invention
本发明实施例提供一种计费方法及设备, 用以实现基于应用数据流的计 费。  Embodiments of the present invention provide a charging method and device for implementing charging based on an application data stream.
第一方面提供一种计费方法, 包括:  The first aspect provides a charging method, including:
策略控制和计费规则功能 PCRF实体确定需要计费的第一应用,并为所述 第一应用分配计费标识, 所述计费标识用于标识需要对所述第一应用进行单 独计费;  The policy control and charging rule function, the PCRF entity, determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged;
所述 PCRF 实体将所述第一应用的标识和为所述第一应用分配的计费标 识分别发送给用户设备 UE、 策略和计费执行 PCEF实体和业务检测功能 TDF 实体, 以使所述 UE和所述 TDF实体在所述第一应用的数据包中添加所述计费 标识后发送给所述 PCEF实体, 使所述 PCEF实体基于所述第一应用的标识和 为所述第一应用分配的计费标识分别对来自所述 UE和所述 TDF实体的携带有 所述计费标识的数据包进行单独计费。 The PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the user equipment UE, the policy and charging execution PCEF entity, and the service detection function TDF, respectively. Entity, to enable the UE and the TDF entity to add the charging identifier to the data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the identifier of the first application. The charging identifier allocated for the first application separately charges the data packet carrying the charging identifier from the UE and the TDF entity separately.
结合第一方面, 在第一方面的第一种可能的实现方式中, 所述 PCRF实体 将所述第一应用的标识和为所述第一应用分配的计费标识分别发送给 UE 和 PCEF实体, 包括:  With reference to the first aspect, in a first possible implementation manner of the first aspect, the PCRF entity sends an identifier of the first application and a charging identifier allocated to the first application to a UE and a PCEF entity, respectively , including:
所述 PCRF实体向所述 PCEF实体发送互联网连接访问网络 IP-CAN会话建 立响应消息,所述 IP-CAN会话建立响应消息包括所述第一应用的标识和为所 述第一应用的分配的计费标识, 以使所述 PCEF实体通过服务网关设备将所述 第一应用的标识和为所述第一应用分配的计费标识发送给所述 UE。  Sending, by the PCRF entity, an internet connection access network IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocation for the first application The fee identifier is configured to enable the PCEF entity to send the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
结合第一方面的第一种可能的实现方式, 在第一方面的第二种可能的实 现方式中,所述 PCRF实体向所述 PCEF实体发送 IP-CAN会话建立响应消息之 前, 还包括 Γ  In conjunction with the first possible implementation of the first aspect, in a second possible implementation manner of the first aspect, before the sending, by the PCRF entity, the IP-CAN session establishment response message to the PCEF entity,
所述 PCRF实体接收所述 PCEF实体发送的 IP-CAN会话建立请求消息。 结合第一方面或第一方面的第一种可能的实现方式或第一方面的第二种 可能的实现方式, 在第一方面的第三种可能的实现方式中, 所述 PCRF实体将 所述第一应用的标识和为所述第一应用分配的计费标识 TDF实体, 包括: 所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会 话建立请求消息包括所述第一应用的标识和为所述第一应用分配的计费标 识。  The PCRF entity receives an IP-CAN session establishment request message sent by the PCEF entity. With reference to the first aspect or the first possible implementation of the first aspect, or the second possible implementation of the first aspect, in a third possible implementation manner of the first aspect, the PCRF entity The identifier of the first application and the charging identifier TDF entity allocated to the first application, including: the PCRF entity sending a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the first An identifier of the application and a charging identifier assigned to the first application.
结合第一方面的第三种可能的实现方式, 在第一方面的第四种可能的实 现方式中, 所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息之后, 还包括:  With the third possible implementation of the first aspect, in a fourth possible implementation manner of the first aspect, after the sending, by the PCRF entity, the TDF session establishment request message to the TDF entity, the method further includes:
所述 PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。  The PCRF entity receives a TDF session setup response message sent by the TDF entity.
结合第一方面, 在第一方面的第五种可能的实现方式中, 所述 PCRF实体 确定需要计费的第一应用, 包括:  With reference to the first aspect, in a fifth possible implementation manner of the foregoing aspect, the determining, by the PCRF entity, the first application that needs to be charged, includes:
所述 PCRF实体接收所述 TDF实体发送的业务流探测事件,所述业务流探 测事件是所述 TDF实体探测到需要计费的所述第一应用的数据包后发送的, 且所述业务流探测事件包括所述第一应用的标识; 所述 PCRF实体根据所述第一应用的标识确定所述第一应用。 结合第一方面的第五种可能的实现方式, 在第一方面的第六种可能的实 现方式中,所述 PCRF实体将所述第一应用的标识和为所述第一应用分配的计 费标识分别发送给 UE和 PCEF实体, 包括: Receiving, by the PCRF entity, a service flow detection event sent by the TDF entity, where the service flow detection event is sent by the TDF entity after detecting a data packet of the first application that needs to be charged, and the service flow is The detecting event includes an identifier of the first application; The PCRF entity determines the first application according to the identifier of the first application. With reference to the fifth possible implementation of the first aspect, in a sixth possible implementation manner of the first aspect, the PCRF entity, the identifier of the first application, and the accounting allocated for the first application The identifiers are sent to the UE and the PCEF entity respectively, including:
所述 PCRF实体向所述 PCEF实体发送策略与计费规则消息, 所述策略与 计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费标识, 以使所述 PCEF 实体通过服务网关设备将所述第一应用的标识和为所述第一 应用分配的计费标识发送给所述 UE。  The PCRF entity sends a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application, so that the The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
结合第一方面的第五种可能的实现方式或第一方面的第六种可能的实现 方式, 在第一方面的第七种可能的实现方式中, 所述 PCRF实体将所述第一应 用的标识和为所述第一应用分配的计费标识 TDF实体, 包括:  In conjunction with the fifth possible implementation of the first aspect, or the sixth possible implementation of the first aspect, in a seventh possible implementation of the first aspect, the PCRF entity And the identifier and the TFP entity assigned to the first application, including:
所述 PCRF实体向所述 TDF实体发送修改应用探测控制 ADC规则消息,所 述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配的计费 标识。  The PCRF entity sends a modify application probe control ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
第二方面提供一种计费方法, 包括:  The second aspect provides a charging method, including:
策略和计费执行 PCEF实体接收策略控制和计费规则功能 PCRF实体发送 的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用 分配的计费标识;  The policy and charging execution PCEF entity receives the policy control and charging rule function. The identifier of the first application that needs to be separately charged and the charging identifier that is allocated to the first application determined by the PCRF entity sent by the PCRF entity;
所述 PCEF 实体将所述第一应用的标识和为所述第一应用分配的计费标 识通过服务网关设备发送给用户设备 UE, 以使所述 UE在所述第一应用的上 行数据包中添加所述计费标识后向所述 PCEF实体发送;  The PCEF entity sends the identifier of the first application and the charging identifier allocated to the first application to the user equipment UE through the serving gateway device, so that the UE is in the uplink data packet of the first application. Adding the charging identifier to the PCEF entity;
所述 PCEF实体接收所述 UE发送的携带有所述计费标识的上行数据包, 并根据所述计费标识对携带有所述计费标识的上行数据包进行单独计费。  The PCEF entity receives an uplink data packet that is sent by the UE and carries the charging identifier, and performs independent charging on the uplink data packet that carries the charging identifier according to the charging identifier.
结合第二方面, 在第二方面的第一种可能的实现方式中, 所述方法还包 括:所述 PCEF实体接收业务检测功能 TDF实体发送的携带有所述计费标识的 下行数据包, 并根据所述计费标识对携带有所述计费标识的下行数据包进行 单独计费。  With reference to the second aspect, in a first possible implementation manner of the second aspect, the method further includes: receiving, by the PCEF entity, a downlink data packet that is sent by the TDF entity and carrying the charging identifier, and Performing separate charging on the downlink data packet carrying the charging identifier according to the charging identifier.
结合第二方面或第二方面的第一种可能的实现方式, 在第二方面的第二 种可能的实现方式中,所述 PCEF实体接收 PCRF实体发送的所述 PCRF实体确 定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标识, 包 括: With reference to the second aspect or the first possible implementation manner of the second aspect, in a second possible implementation manner of the second aspect, the PCEF entity receives, by the PCRF entity, The identifier of the first application and the charging identifier assigned to the first application, the package Includes:
所述 PCEF实体接收所述 PCRF实体发送的互联网连接访问网络 IP-CAN会 话建立响应消息,所述 IP-CAN会话建立响应消息包括所述第一应用的标识和 为所述第一应用的分配的计费标识; 或者  Receiving, by the PCEF entity, an internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocation for the first application Billing identifier; or
所述 PCEF实体接收所述 PCRF实体发送的策略与计费规则消息, 所述策 略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费标 识。  The PCEF entity receives the policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
结合第二方面的第二种可能的实现方式, 在第二方面的第三种可能的实 现方式中,所述 PCEF实体接收所述 PCRF实体发送的 IP-CAN会话建立响应消 息之前, 还包括:  With the second possible implementation of the second aspect, in a third possible implementation manner of the second aspect, before the PCEF entity receives the IP-CAN session establishment response message sent by the PCRF entity, the method further includes:
所述 PCEF实体向所述 PCRF实体发送 IP-CAN会话建立请求消息。  The PCEF entity sends an IP-CAN Session Establishment Request message to the PCRF entity.
结合第二方面或第二方面的第一种可能的实现方式或第二方面的第二种 可能的实现方式或第二方面的第三种可能的实现方式, 在第二方面的第四种 可能的实现方式中,所述 PCEF实体将所述第一应用的标识和为所述第一应用 分配的计费标识通过服务网关设备发送给 UE, 包括:  With reference to the second aspect or the first possible implementation of the second aspect or the second possible implementation of the second aspect or the third possible implementation of the second aspect, the fourth possibility in the second aspect In the implementation manner, the PCEF entity sends the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
所述 PCEF实体向所述服务网关设备发送 IP-CAN承载建立响应消息, 所 述 IP-CAN承载建立响应消息包括所述第一应用的标识和为所述第一应用分 配的计费标识, 以使所述服务网关设备将所述第一应用的标识和为所述第一 应用分配的计费标识发送给所述 UE。  The PCEF entity sends an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application, And causing the serving gateway device to send the identifier of the first application and the charging identifier allocated for the first application to the UE.
结合第二方面的第四种可能的实现方式, 在第二方面的第五种可能的实 现方式中, 所述 PCEF实体向所述服务网关设备发送 IP-CAN承载建立响应消 息之前, 还包括:  With the fourth possible implementation of the second aspect, in a fifth possible implementation manner of the second aspect, before the sending, by the PCEF entity, the IP-CAN bearer setup response message to the serving gateway device, the method further includes:
所述 PCEF实体接收所述服务网关设备发送的 IP-CAN承载建立请求消息, 所述 IP-CAN承载建立请求消息包括所述 UE的标识。  The PCEF entity receives an IP-CAN bearer setup request message sent by the serving gateway device, where the IP-CAN bearer setup request message includes an identifier of the UE.
第三方面提供一种计费方法, 包括:  The third aspect provides a charging method, including:
业务检测功能 TDF实体接收策略控制和计费规则功能 PCRF实体发送的所 述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配 的计费标识;  The service detection function TDF entity receives the policy control and charging rule function. The identifier of the first application that needs to be separately charged determined by the PCRF entity sent by the PCRF entity and the charging identifier allocated for the first application;
所述 TDF 实体根据所述第一应用的标识确定所述第一应用的下行数据 包, 在所述第一应用的下行数据包中添加所述计费标识; 所述 TDF实体将添加所述计费标识的下行数据包发送给策略和计费执行 PCEF实体, 以使所述 PCEF实体基于所述计费标识对所述第一应用的下行数 据包进行单独计费。 Determining, by the TDF entity, the downlink data packet of the first application according to the identifier of the first application, and adding the charging identifier to a downlink data packet of the first application; The TDF entity sends the downlink data packet that adds the charging identifier to the policy and charging execution PCEF entity, so that the PCEF entity separately counts the downlink data packet of the first application based on the charging identifier. fee.
结合第三方面, 在第三方面的第一种可能的实现方式中, 所述 TDF实体 接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第一应用的标识 和为所述第一应用分配的计费标识, 包括:  With reference to the third aspect, in a first possible implementation manner of the third aspect, the TDF entity receives, by the PCRF entity, an identifier of the first application that is required to be separately charged by the PCRF entity, and is the first Apply the assigned billing identifier, including:
所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用分配的计 费标识。  The TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes an identifier of the first application and a subscription identifier allocated for the first application.
结合第三方面的第一种可能的实现方式, 在第三方面的第二种可能的实 现方式中,所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息之 后, 还包括:  With reference to the first possible implementation manner of the third aspect, in a second possible implementation manner of the third aspect, after the TDF entity receives the TDF session establishment request message sent by the PCRF entity, the method further includes:
所述 TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。  The TDF entity sends a TDF Session Establishment Response message to the PCRF entity.
结合第三方面, 在第三方面的第三种可能的实现方式中, 所述 TDF实体 接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第一应用的标识 和为所述第一应用分配的计费标识之前, 还包括:  With reference to the third aspect, in a third possible implementation manner of the third aspect, the TDF entity receives, by the PCRF entity, an identifier of the first application that is required to be separately charged by the PCRF entity, and is the first Before applying the assigned billing identifier, it also includes:
所述 TDF实体探测需要单独计费的所述第一应用的数据包, 并在探测到 所述第一应用的数据包后, 向所述 PCRF实体发送业务流探测事件, 所述业务 流探测事件包括所述第一应用的标识, 以使所述 PCRF实体根据所述第一应用 的标识确定需要对所述第一应用进行单独计费。  The TDF entity detects a data packet of the first application that needs to be separately charged, and after detecting the data packet of the first application, sends a service flow detection event to the PCRF entity, where the service flow detection event The identifier of the first application is included, so that the PCRF entity determines that the first application needs to be separately charged according to the identifier of the first application.
结合第三方面的第三种可能的实现方式, 在第三方面的第四种可能的实 现方式中, 所述 TDF实体接收 PCRF实体发送的所述 PCRF实体确定的需要单 独计费的第一应用的标识和为所述第一应用分配的计费标识, 包括:  With reference to the third possible implementation manner of the third aspect, in a fourth possible implementation manner of the third aspect, the TDF entity receives, by the PCRF entity, the first application that is required to be separately charged by the PCRF entity The identifier and the charging identifier assigned to the first application, including:
所述 TDF实体接收所述 PCRF实体发送的修改应用探测控制 ADC规则消 息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配 的计费标识。  The TDF entity receives the modified application probe control ADC rule message sent by the PCRF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
第四方面提供一种计费方法, 包括:  The fourth aspect provides a charging method, including:
策略控制和计费规则功能 PCRF实体向业务检测功能 TDF实体发送的策略 与计费控制 PCC规则标识和 /或服务数据流 SDF模板, 以供所述 TDF实体确定 影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和第一应用的数据包的流量; Policy Control and Charging Rules Function The PCRF entity sends a Policy and Charging Control PCC Rule Identity and/or Service Data Flow SDF Template to the Traffic Detection Function TDF entity for the TDF entity to determine the impact policy and the charging execution PCEF entity is based on The first application of the SDF granularity charging result belongs to The identifier of the SDF and the traffic of the data packet of the first application;
所述 PCRF实体接收所述 TDF实体发送的根据所述 PCC规则标识和 /或 SDF 模板确定的所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流 所述 PCRF实体将所述第一应用所属的 SDF的标识和所述第一应用的数据 包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应用所属 的 SDF的标识和所述第一应用的数据包的流量对来自用户设备 UE的上行数据 包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包属于来 自所述 UE的上行数据包。  Receiving, by the PCRF entity, the identifier of the SDF to which the first application belongs according to the PCC rule identifier and/or the SDF template, and the flow of the data packet of the first application, the PCRF entity The identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application are sent to the PCEF entity, so that the PCEF entity is based on the identifier of the SDF to which the first application belongs and the first The traffic of the applied data packet is adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE. The data packet of the first application belongs to the uplink data packet from the UE.
结合第四方面, 在第四方面的第一种可能的实现方式中, 所述 PCRF实体 向 TDF实体发送的 PCC规则标识和 /或 SDF模板, 包括:  With reference to the fourth aspect, in a first possible implementation manner of the fourth aspect, the PCC rule identifier and/or the SDF template sent by the PCRF entity to the TDF entity includes:
所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会 话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。  The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
结合第四方面的第一种可能的实现方式, 在第四方面的第二种可能的实 现方式中, 所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息之后, 还包括:  With the first possible implementation of the fourth aspect, in a second possible implementation manner of the fourth aspect, after the sending, by the PCRF entity, the TDF session establishment request message to the TDF entity, the method further includes:
所述 PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。  The PCRF entity receives a TDF session setup response message sent by the TDF entity.
结合第四方面或第四方面的第一种可能的实现方式或第四方面的第二种 可能的实现方式, 在第四方面的第三种可能的实现方式中, 所述 PCRF实体将 所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量发送给所述 With reference to the fourth aspect, or the first possible implementation manner of the fourth aspect, or the second possible implementation manner of the fourth aspect, in a third possible implementation manner of the fourth aspect, the PCRF entity The identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application are sent to the
PCEF实体, 包括: PCEF entities, including:
所述 PCRF实体向所述 PCEF实体发送互联网连接访问网络 IP-CAN会话修 改请求消息,所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的 标识和所述第一应用的数据包的流量。  The PCRF entity sends an Internet connection access network IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and data of the first application. The flow of the package.
第五方面提供一种计费方法, 包括:  The fifth aspect provides a charging method, including:
策略和计费执行 PCEF实体接收策略控制和计费规则功能 PCRF实体发送 的影响所述 PCEF实体基于服务数据流 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量; 其中, 所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流量是业务检测功能 TDF 实体根据所述 PCRF实体发送的策略与计费控制 PCC规则标识和 /或 SDF模板确定并发送给 所述 PCRF实体的; The policy and charging execution PCEF entity receives the policy control and charging rule function. The identifier sent by the PCRF entity affecting the PCEF entity based on the service data flow SDF granularity charging result, and the identifier of the SDF and the first application The traffic of the data packet, where the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application are the policy and charging control PCC rule identifier sent by the service detection function TDF entity according to the PCRF entity. / or SDF template is determined and sent to The PCRF entity;
所述 PCEF实体根据所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量,对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行 调整, 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。  The PCEF entity adjusts an uplink data packet from the user equipment UE based on the SDF granularity charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the The data packet of the first application belongs to an uplink data packet from the UE.
结合第五方面, 在第五方面的第一种可能的实现方式中, 所述 PCEF实体 接收 PCRF实体发送的影响所述 PCEF实体基于 SDF粒度的计费结果的第一应 用所属的 SDF的标识和所述第一应用的数据包的流量之前, 还包括:  With reference to the fifth aspect, in a first possible implementation manner of the fifth aspect, the PCEF entity receives an identifier of an SDF that is sent by a PCRF entity and affects a SDF granularity-based charging result of the PCEF entity. Before the traffic of the data packet of the first application, the method further includes:
所述 PCEF实体对来自所述 UE的上行数据包进行基于 SDF粒度的计费。 结合第五方面或第五方面的第一种可能的实现方式, 在第五方面的第二 种可能的实现方式中,所述 PCEF实体接收 PCRF实体发送的影响所述 PCEF实 体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用的 数据包的流量, 包括:  The PCEF entity performs SDF granularity based charging on uplink data packets from the UE. With reference to the fifth aspect, or the first possible implementation manner of the fifth aspect, in a second possible implementation manner of the fifth aspect, the PCEF entity receives, by the PCRF entity, an effect of the SDF granularity that affects the PCEF entity The identifier of the SDF to which the first application of the fee belongs and the traffic of the data packet of the first application, including:
所述 PCEF实体接收所述 PCRF实体发送的互联网连接访问网络 IP-CAN会 话修改请求消息, 所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量。  Receiving, by the PCEF entity, an Internet connection access network IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and the first application The traffic of the packet.
第六方面提供一种计费方法, 包括:  A sixth aspect provides a charging method, including:
业务检测功能 TDF实体接收策略控制和计费规则功能 PCRF实体发送的策 略与计费控制 PCC规则标识和 /或服务数据流 SDF模板;  Service detection function TDF entity receives policy control and charging rule function The policy and charging control sent by the PCRF entity PCC rule identification and / or service data flow SDF template;
所述 TDF实体根据所述 PCC规则标识和 /或 SDF模板,确定影响策略和计 费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所 述第一应用的数据包的流量;  Determining, by the TDF entity, the identifier of the SDF to which the first application belongs to the SDF granularity-based charging result, and the data packet of the first application, according to the PCC rule identifier and/or the SDF template. Traffic flow
所述 TDF实体将所述第一应用所属的 SDF的标识和所述第一应用的数据 包的流量通过所述 PCRF实体发送给所述 PCEF实体, 以使所述 PCEF实体基于 所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量对来自用户 设备 UE的上行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应 用的数据包属于来自所述 UE的上行数据包。  Transmitting, by the TDF entity, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity by using the PCRF entity, so that the PCEF entity is based on the first application The identifier of the associated SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE, where the data packet of the first application belongs to the UE Upstream packet.
结合第六方面, 在第六方面的第一种可能的实现方式中, 所述 TDF实体 接收 PCRF实体发送的 PCC规则标识和 /或 SDF模板, 包括:  With reference to the sixth aspect, in a first possible implementation manner of the sixth aspect, the receiving, by the TDF entity, the PCC rule identifier and/or the SDF template sent by the PCRF entity includes:
所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。 结合第六方面的第一种可能的实现方式, 在第六方面的第二种可能的实 现方式中,所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息之 后, 还包括: The TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template. With reference to the first possible implementation manner of the sixth aspect, in a second possible implementation manner of the sixth aspect, after the TDF entity receives the TDF session establishment request message sent by the PCRF entity, the method further includes:
所述 TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。  The TDF entity sends a TDF Session Establishment Response message to the PCRF entity.
结合第六方面或第六方面的第一种可能的实现方式或第六方面的第二种 可能的实现方式, 在第六方面的第三种可能的实现方式中, 所述 TDF实体根 据所述 PCC规则标识和 /或 SDF模板, 确定影响 PCEF实体基于 SDF粒度的计 费结果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量,包括: 所述 TDF实体根据所述 PCC规则标识指示的 PCC规则, 确定因执行基于 应用的流控而被丢弃的数据包所属的应用作为所述第一应用, 确定所述被丢 弃的数据包的流量作为所述第一应用的数据包的流量, 并确定所述第一应用 所属的 SDF; 或者  With reference to the sixth aspect, or the first possible implementation manner of the sixth aspect, or the second possible implementation manner of the sixth aspect, in a third possible implementation manner of the sixth aspect, And determining, by the PCC rule identifier and/or the SDF template, the identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity and the traffic of the data packet of the first application, including: the TDF entity according to the The PCC rule identifies the indicated PCC rule, determines an application to which the data packet discarded by performing the application-based flow control belongs, and determines, as the first application, the traffic of the discarded data packet as the data of the first application. The traffic of the packet, and determining the SDF to which the first application belongs; or
所述 TDF实体根据所述 SDF模板探测到不需要对来自所述 UE的上行数据 包中具有相同 IP地址信息的所有数据包进行计费时, 从具有相同 IP地址信 息的所有数据包中, 确定实际需要计费的数据包所属的应用作为所述第一应 用, 确定实际需要计费的数据包的流量作为所述第一应用的数据包的流量, 并确定所述第一应用所属的 SDF; 或者,  The TDF entity determines, according to the SDF template, that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, from all data packets having the same IP address information. The application to which the data packet that actually needs to be charged belongs is used as the first application, and the traffic of the data packet that needs to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined; Or,
TDF实体根据所述 SDF模板探测到不需要对来自所述 UE的上行数据包中 具有相同 IP地址信息的所有数据包进行计费时, 从具有相同 IP地址信息的 所有数据包, 确定出不需要计费的数据包所属的应用作为所述第一应用, 确 定不需要计费的数据包的流量作为所述第一应用的数据包的流量, 并确定所 述第一应用所属的 SDF。  When the TDF entity detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the TDF entity determines that it is unnecessary from all data packets having the same IP address information. The application to which the billed data packet belongs is used as the first application, and the traffic of the data packet that does not need to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined.
第七方面提供一种计费方法, 包括:  A seventh aspect provides a charging method, including:
业务检测功能 TDF实体接收到策略和计费执行 PCEF实体发送的上行数据 包后, 确定回流数据, 并为所述回流数据添加计费标识, 所述回流数据是指 所述上行数据包中影响所述 PCEF实体对所述上行数据包基于服务数据流 SDF 粒度的计费结果的数据包;  After receiving the uplink data packet sent by the PCEF entity, the service detection function TDF entity determines the reflow data, and adds a charging identifier to the reflow data, where the reflow data refers to the impact information in the uplink data packet. a data packet of a PCEF entity for charging the uplink data packet based on a service data flow SDF granularity;
所述 TDF实体将携带所述计费标识的回流数据发送给所述 PCEF实体, 以 使所述 PCEF实体根据携带所述计费标识的回流数据,对所述上行数据包基于 SDF粒度的计费结果进行调整。 结合第七方面, 在第七方面的第一种可能的实现方式中, 所述 TDF实体 接收到 PCEF实体发送的上行数据包后, 确定回流数据, 并为所述回流数据添 加计费标识之前, 还包括: The TDF entity sends the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity performs charging based on the SDF granularity according to the reflow data carrying the charging identifier. The results are adjusted. With reference to the seventh aspect, in a first possible implementation manner of the seventh aspect, after the TDF entity receives the uplink data packet sent by the PCEF entity, determines the reflow data, and adds a charging identifier to the reflow data, Also includes:
所述 TDF实体接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识。  The TDF entity receives the policy control and charging rule function, and the PCRF entity sent by the PCRF entity allocates the charging identifier for the reflow data.
结合第七方面的第一种可能的实现方式, 在第七方面的第二种可能的实 现方式中, 所述 TDF实体接收 PCRF实体发送的所述 PCRF实体为所述回流数 据分配的所述计费标识, 包括:  With reference to the first possible implementation manner of the seventh aspect, in a second possible implementation manner of the seventh aspect, the TDF entity receives, by the PCRF entity, the PCRF entity that is allocated by the PCRF entity Fee identification, including:
所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述计费标识。  The TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
结合第七方面的第二种可能的实现方式, 在第七方面的第三种可能的实 现方式中,所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息之 后, 还包括:  With reference to the second possible implementation manner of the seventh aspect, in a third possible implementation manner of the seventh aspect, after the TDF entity receives the TDF session establishment request message sent by the PCRF entity, the method further includes:
所述 TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。  The TDF entity sends a TDF Session Establishment Response message to the PCRF entity.
第八方面提供一种计费方法, 包括:  The eighth aspect provides a charging method, including:
策略和计费执行 PCEF实体在对上行数据包进行基于服务数据流 SDF粒度 的计费之后,接收业务检测功能 TDF实体发送的携带有计费标识的回流数据, 所述回流数据是所述 TDF实体确定的所述上行数据包中影响所述 PCEF实体对 所述上行数据包的基于 SDF粒度的计费结果的数据包;  The policy and charging execution PCEF entity receives the reflow data carrying the charging identifier sent by the service detecting function TDF entity after performing the service data stream SDF granularity charging on the uplink data packet, where the reflow data is the TDF entity. Determining, in the uplink data packet, a data packet that affects the SDF granularity-based charging result of the uplink data packet by the PCEF entity;
所述 PCEF实体根据所述计费标识确定接收到的数据是所述回流数据,确 定所述回流数据所属的 SDF, 对所述确定的 SDF的计费结果进行调整。  The PCEF entity determines, according to the charging identifier, that the received data is the reflow data, determines an SDF to which the reflow data belongs, and adjusts the charging result of the determined SDF.
结合第八方面, 在第八方面的第一种可能的实现方式中, 所述 PCEF实体 接收 TDF实体发送的携带有计费标识的回流数据之前, 包括:  With reference to the eighth aspect, in a first possible implementation manner of the eighth aspect, before the PCEF entity receives the reflow data that is sent by the TDF entity and carries the charging identifier, the method includes:
所述 PCEF实体接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识。  The PCEF entity receives the policy control and charging rule function, and the PCRF entity sent by the PCRF entity allocates the charging identifier for the reflow data.
结合第八方面的第一种可能的实现方式, 在第八方面的第二种可能的实 现方式中,所述 PCEF实体接收 PCRF实体发送的所述 PCRF实体为所述回流数 据分配的所述计费标识, 包括:  With reference to the first possible implementation manner of the eighth aspect, in a second possible implementation manner of the eighth aspect, the PCEF entity receives, by the PCRF entity, the PCRF entity to allocate the reflow data Fee identification, including:
所述 PCEF实体接收所述 PCRF实体发送的互联网连接访问网络 IP-CAN会 话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标识。 结合第八方面的第二种可能的实现方式, 在第八方面的第三种可能的实 现方式中,所述 PCEF实体接收所述 PCRF实体发送的 IP-CAN会话建立响应消 息之前, 还包括: The PCEF entity receives an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier. With the second possible implementation of the eighth aspect, in a third possible implementation manner of the eighth aspect, before the receiving, by the PCEF entity, the IP-CAN session establishment response message sent by the PCRF entity, the method further includes:
所述 PCEF实体向所述 PCRF实体发送 IP-CAN会话建立请求消息。  The PCEF entity sends an IP-CAN Session Establishment Request message to the PCRF entity.
第九方面提供一种计费方法, 包括:  A ninth aspect provides a charging method, including:
策略控制和计费规则功能 PCRF 实体确定需要分配给回流数据包的计费 标识,所述回流数据是指上行数据包中影响策略和计费执行 PCEF实体对所述 上行数据包的基于服务数据流 SDF粒度的计费结果的数据包;  Policy Control and Charging Rules Function The PCRF entity determines the charging identifier that needs to be assigned to the reflow packet, which refers to the service data flow in the uplink packet affecting the policy and charging execution PCEF entity to the upstream packet. a data packet of the SDF granularity charging result;
所述 PCRF实体将所述计费标识发送给业务检测功能 TDF实体和所述 PCEF 实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确定出所 述回流数据后在所述回流数据中添加所述计费标识后向所述 PCEF实体发送, 使所述 PCEF 实体根据所述计费标识确定所述回流数据并基于所述回流数据 对所述上行数据包的基于 SDF粒度的计费结果进行调整。  Sending, by the PCRF entity, the charging identifier to a service detecting function TDF entity and the PCEF entity, where the TDF entity determines the reflow data from the uplink data packet from the PCEF entity. Adding the charging identifier to the PCEF entity, sending the PCEF entity to determine the reflow data according to the charging identifier, and based on the reflow data, based on the SDF of the uplink data packet The granularity of the billing result is adjusted.
结合第九方面, 在第九方面的第一种可能的实现方式中, 所述 PCRF实体 将所述计费标识发送给 TDF实体, 包括:  With reference to the ninth aspect, in a first possible implementation manner of the ninth aspect, the sending, by the PCRF entity, the charging identifier to the TDF entity includes:
所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会 话建立请求消息包括所述计费标识。  The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session setup request message includes the charging identifier.
结合第九方面的第一种可能的实现方式, 在第九方面的第二种可能的实 现方式中, 所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息之后, 还包括:  With reference to the first possible implementation manner of the ninth aspect, in a second possible implementation manner of the ninth aspect, after the sending, by the PCRF entity, the TDF session establishment request message to the TDF entity, the method further includes:
所述 PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。  The PCRF entity receives a TDF session setup response message sent by the TDF entity.
结合第九方面或第九方面的第一种可能的实现方式或第九方面的第二种 可能的实现方式, 在第九方面的第三种可能的实现方式中, 所述 PCRF实体将 所述计费标识发送给所述 PCEF实体, 包括:  With reference to the ninth aspect, or the first possible implementation manner of the ninth aspect, or the second possible implementation manner of the ninth aspect, in a third possible implementation manner of the ninth aspect, the PCRF entity The billing identifier is sent to the PCEF entity, including:
所述 PCRF实体向所述 PCEF实体发送互联网连接访问网络 IP-CAN会话建 立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标识。  The PCRF entity sends an internet connection access network IP-CAN session establishment response message to the PCEF entity, and the IP-CAN session establishment response message includes the charging identifier.
结合第九方面的第三种可能的实现方式, 在第九方面的第四种可能的实 现方式中,所述 PCRF实体向所述 PCEF实体发送 IP-CAN会话建立响应消息之 前, 还包括 Γ  In conjunction with the third possible implementation of the ninth aspect, in a fourth possible implementation manner of the ninth aspect, before the sending, by the PCRF entity, the IP-CAN session establishment response message to the PCEF entity,
所述 PCRF实体接收所述 PCEF实体发送的 IP-CAN会话建立请求消息。 第十方面提供一种策略控制和计费规则功能 PCRF实体, 包括: The PCRF entity receives an IP-CAN session establishment request message sent by the PCEF entity. The tenth aspect provides a policy control and charging rule function PCRF entity, including:
确定模块, 用于确定需要计费的第一应用;  a determining module, configured to determine a first application that needs to be billed;
分配模块, 用于为所述第一应用分配计费标识, 所述计费标识用于标识 需要对所述第一应用进行单独计费;  An allocating module, configured to allocate a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged;
发送模块, 用于将所述确定模块确定的所述第一应用的标识和所述分配 模块为所述第一应用分配的计费标识分别发送给用户设备 UE、 策略和计费执 行 PCEF实体和业务检测功能 TDF实体, 以使所述 UE和所述 TDF实体在所述 第一应用的数据包中添加所述计费标识后发送给所述 PCEF实体,使所述 PCEF 实体基于所述第一应用的标识和为所述第一应用分配的计费标识分别对来自 所述 UE和所述 TDF实体的携带有所述计费标识的数据包进行单独计费。  a sending module, configured to send the identifier of the first application determined by the determining module and the charging identifier allocated by the allocating module to the first application to a user equipment UE, a policy and a charging execution PCEF entity, and The service detection function TDF entity, so that the UE and the TDF entity add the charging identifier to the data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the first The identifier of the application and the charging identifier allocated for the first application separately charge the data packet carrying the charging identifier from the UE and the TDF entity separately.
结合第十方面, 在第十方面的第一种可能的实现方式中, 所述发送模块 用于将所述第一应用的标识和为所述第一应用分配的计费标识分别发送给 UE 和 PCEF实体, 包括:  With the tenth aspect, in a first possible implementation manner of the tenth aspect, the sending module is configured to send an identifier of the first application and a charging identifier allocated to the first application to a UE and a PCEF entities, including:
所述发送模块具体用于向所述 PCEF 实体发送互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述第一应 用的标识和为所述第一应用的分配的计费标识, 以使所述 PCEF实体通过服务 网关设备将所述第一应用的标识和为所述第一应用分配的计费标识发送给所 述 UE。  The sending module is specifically configured to send an Internet connection access network IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and is used by the first application. The assigned charging identifier, so that the PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
结合第十方面或第十方面的第一种可能的实现方式, 在第十方面的第二 种可能的实现方式中, 所述发送模块将所述第一应用的标识和为所述第一应 用分配的计费标识 TDF实体, 包括:  With reference to the tenth aspect, or the first possible implementation manner of the tenth aspect, in the second possible implementation manner of the tenth aspect, the sending module, the identifier of the first application is the first application The assigned billing identifier TDF entity, including:
所述发送模块具体用于向所述 TDF实体发送 TDF会话建立请求消息, 所 述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用分配的 计费标识。  The sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
结合第十方面, 在第十方面的第三种可能的实现方式中, 所述确定模块 具体用于接收所述 TDF实体发送的业务流探测事件, 所述业务流探测事件是 所述 TDF实体探测到需要计费的所述第一应用的数据包后发送的, 且所述业 务流探测事件包括所述第一应用的标识; 根据所述第一应用的标识确定所述 第一应用。  With reference to the tenth aspect, in a third possible implementation manner of the tenth aspect, the determining module is specifically configured to receive a service flow detection event that is sent by the TDF entity, where the service flow detection event is the TDF entity detection And sending, after the data packet of the first application that needs to be charged, the service flow detection event includes an identifier of the first application; determining the first application according to the identifier of the first application.
结合第十方面的第三种可能的实现方式, 在第十方面的第四种可能的实 现方式中, 所述发送模块用于将所述第一应用的标识和为所述第一应用分配 的计费标识分别发送给 UE和 PCEF实体, 包括: In conjunction with the third possible implementation of the tenth aspect, the fourth possible implementation in the tenth aspect In the current mode, the sending module is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE and the PCEF entity, respectively, including:
所述发送模块具体用于向所述 PCEF实体发送策略与计费规则消息,所述 策略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费 标识, 以使所述 PCEF实体通过服务网关设备将所述第一应用的标识和为所述 第一应用分配的计费标识发送给所述 UE。  The sending module is specifically configured to send a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, And causing the PCEF entity to send, by the serving gateway device, the identifier of the first application and the charging identifier allocated for the first application to the UE.
结合第十方面的第三种可能的实现方式或第十方面的第四种可能的实现 方式, 在第十方面的第五种可能的实现方式中, 所述发送模块用于将所述第 一应用的标识和为所述第一应用分配的计费标识 TDF实体, 包括:  With the third possible implementation of the tenth aspect, or the fourth possible implementation of the tenth aspect, in a fifth possible implementation manner of the tenth aspect, the sending module is configured to use the first The identifier of the application and the charging identifier TDF entity allocated for the first application, including:
所述发送模块具体用于向所述 TDF实体发送修改应用探测控制 ADC规则 消息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分 配的计费标识。  The sending module is specifically configured to send a modified application detection control ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
第十一方面提供一种策略和计费执行 PCEF实体, 包括:  The eleventh aspect provides a policy and charging execution PCEF entity, including:
接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识;  a receiving module, configured to receive a policy control and charging rule function, the identifier of the first application that is separately billed by the PCRF entity sent by the PCRF entity, and the charging identifier allocated for the first application;
发送模块, 用于将所述接收模块接收的所述第一应用的标识和为所述第 一应用分配的计费标识通过服务网关设备发送给用户设备 UE , 以使所述 UE 在所述第一应用的上行数据包中添加所述计费标识后向所述 PCEF实体发送; 所述接收模块,还用于接收所述 UE发送的携带有所述计费标识的上行数 据包;  a sending module, configured to send, by the serving gateway device, the identifier of the first application and the charging identifier that is configured by the receiving module to the user equipment, to enable the UE to be in the Adding the charging identifier to an uplink data packet of an application, and sending the charging identifier to the PCEF entity; the receiving module is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier;
计费模块, 用于根据所述计费标识对所述接收模块接收的携带有所述计 费标识的上行数据包进行单独计费。  The charging module is configured to separately charge the uplink data packet that is received by the receiving module and that carries the charging identifier according to the charging identifier.
结合第十一方面, 在第十一方面的第一种可能的实现方式中, 所述接收 模块还用于接收业务检测功能 TDF实体发送的携带有所述计费标识的下行数 据包;  With the eleventh aspect, in a first possible implementation manner of the eleventh aspect, the receiving module is further configured to receive a downlink data packet that is sent by the TDF entity and that carries the charging identifier.
所述计费模块, 还用于根据所述计费标识对所述接收模块接收的携带有 所述计费标识的下行数据包进行单独计费。  The charging module is further configured to separately charge the downlink data packet that is received by the receiving module and that carries the charging identifier according to the charging identifier.
结合第十一方面或第十一方面的第一种可能的实现方式, 在第十一方面 的第二种可能的实现方式中, 所述接收模块用于接收 PCRF 实体发送的所述 PCRF实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计 费标识, 包括: With the first possible implementation of the eleventh aspect or the eleventh aspect, in a second possible implementation manner of the eleventh aspect, the receiving module is configured to receive, by the PCRF entity, The identifier of the first application that needs to be separately charged and the charging identifier that is allocated for the first application, which is determined by the PCRF entity, includes:
所述接收模块具体用于接收所述 PCRF 实体发送的互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述第一应 用的标识和为所述第一应用的分配的计费标识; 或者  The receiving module is specifically configured to receive an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and is the first application. Allocated billing identifier; or
所述接收模块具体用于接收所述 PCRF实体发送的策略与计费规则消息, 所述策略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的 计费标识。  The receiving module is specifically configured to receive a policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
结合第十一方面或第十一方面的第一种可能的实现方式或第十一方面的 第二种可能的实现方式, 在第十一方面的第三种可能的实现方式中, 所述发 送模块用于将所述第一应用的标识和为所述第一应用分配的计费标识通过服 务网关设备发送给 UE, 包括:  With reference to the eleventh aspect or the first possible implementation manner of the eleventh aspect, or the second possible implementation manner of the eleventh aspect, in a third possible implementation manner of the eleventh aspect, the sending The module is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
所述发送模块具体用于向所述服务网关设备发送 IP-CAN承载建立响应 消息,所述 IP-CAN承载建立响应消息包括所述第一应用的标识和为所述第一 应用分配的计费标识, 以使所述服务网关设备将所述第一应用的标识和为所 述第一应用分配的计费标识发送给所述 UE。  The sending module is specifically configured to send an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a billing allocated for the first application. And the identifier is sent to the serving gateway device to send the identifier of the first application and the charging identifier allocated to the first application to the UE.
第十二方面提供一种业务检测功能 TDF实体, 包括:  The twelfth aspect provides a service detection function TDF entity, including:
接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识;  a receiving module, configured to receive a policy control and charging rule function, the identifier of the first application that is separately billed by the PCRF entity sent by the PCRF entity, and the charging identifier allocated for the first application;
确定添加模块, 用于根据所述接收模块接收的所述第一应用的标识确定 所述第一应用的下行数据包, 在所述第一应用的下行数据包中添加所述接收 模块接收的所述计费标识;  Determining an adding module, configured to determine, according to the identifier of the first application received by the receiving module, a downlink data packet of the first application, and adding, in a downlink data packet of the first application, a received by the receiving module Description of the charging identifier;
发送模块, 用于将添加所述计费标识的下行数据包发送给策略和计费执 行 PCEF实体, 以使所述 PCEF实体基于所述计费标识对所述第一应用的下行 数据包进行单独计费。  a sending module, configured to send a downlink data packet that adds the charging identifier to a policy and charging execution PCEF entity, so that the PCEF entity separately performs downlink data packets of the first application based on the charging identifier Billing.
结合第十二方面, 在第十二方面的第一种可能的实现方式中, 所述接收 模块用于接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第一应 用的标识和为所述第一应用分配的计费标识, 包括:  With reference to the twelfth aspect, in a first possible implementation manner of the twelfth aspect, the receiving module is configured to receive, by the PCRF entity, an identifier of the first application that is separately billed by the PCRF entity and The charging identifier allocated by the first application includes:
所述接收模块具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用 分配的计费标识。 The receiving module is specifically configured to receive a TDF session establishment request sent by the PCRF entity. The TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
结合第十二方面, 在第十二方面的第二种可能的实现方式中, 所述 TDF 实体还包括: 探测模块, 用于探测需要单独计费的所述第一应用的数据包; 所述发送模块,还用于在所述探测模块探测到所述第一应用的数据包后, 向所述 PCRF实体发送业务流探测事件,所述业务流探测事件包括所述第一应 用的标识, 以使所述 PCRF实体根据所述第一应用的标识确定需要对所述第一 应用进行单独计费。  In conjunction with the twelfth aspect, in a second possible implementation of the twelfth aspect, the TDF entity further includes: a detecting module, configured to detect a data packet of the first application that needs to be separately charged; The sending module is further configured to: after the detecting module detects the data packet of the first application, send a service flow detecting event to the PCRF entity, where the service flow detecting event includes an identifier of the first application, And causing the PCRF entity to determine, according to the identifier of the first application, that the first application needs to be separately charged.
结合第十二方面的第二种可能的实现方式, 在第十二方面的第三种可能 的实现方式中, 所述接收模块用于接收 PCRF实体发送的所述 PCRF实体确定 的需要单独计费的第一应用的标识和为所述第一应用分配的计费标识,包括: 所述接收模块具体用于接收所述 PCRF实体发送的修改应用探测控制 ADC 规则消息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应 用分配的计费标识。  With the second possible implementation of the twelfth aspect, in a third possible implementation manner of the twelfth aspect, the receiving module is configured to receive, by the PCRF entity, The identifier of the first application and the charging identifier allocated to the first application, the method includes: the receiving module is configured to receive a modified application detection control ADC rule message sent by the PCRF entity, where the modifying the ADC rule message includes An identifier of the first application and a charging identifier assigned to the first application.
第十三方面提供一种策略控制和计费规则功能 PCRF实体, 包括: 处理器, 用于确定需要计费的第一应用, 并为所述第一应用分配计费标 识, 所述计费标识用于标识需要对所述第一应用进行单独计费;  The thirteenth aspect provides a policy control and charging rule function PCRF entity, including: a processor, configured to determine a first application that needs to be charged, and allocate a charging identifier to the first application, where the charging identifier is Used to identify that the first application needs to be separately charged;
发射器, 用于将所述处理器确定的所述第一应用的标识和所述处理器为 所述第一应用分配的计费标识分别发送给用户设备 UE、策略和计费执行 PCEF 实体和业务检测功能 TDF实体, 以使所述 UE和所述 TDF实体在所述第一应用 的数据包中添加所述计费标识后发送给所述 PCEF实体, 使所述 PCEF实体基 于所述第一应用的标识和为所述第一应用分配的计费标识分别对来自所述 UE 和所述 TDF实体的携带有所述计费标识的数据包进行单独计费。  a transmitter, configured to send, by the processor, an identifier of the first application and a charging identifier allocated by the processor to the first application to a user equipment UE, a policy and charging execution PCEF entity, and The service detecting function TDF entity, so that the UE and the TDF entity add the charging identifier to the data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the first The identifier of the application and the charging identifier allocated for the first application separately charge the data packet carrying the charging identifier from the UE and the TDF entity separately.
第十四方面提供一种策略和计费执行 PCEF实体, 包括:  A fourteenth aspect provides a policy and charging enforcement PCEF entity, including:
接收器, 用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识;  a receiver, configured to receive a policy control and charging rule function, and the identifier of the first application that is separately billed by the PCRF entity and the charging identifier that is allocated for the first application determined by the PCRF entity;
发射器, 用于将所述接收器接收的所述第一应用的标识和为所述第一应 用分配的计费标识通过服务网关设备发送给用户设备 UE, 以使所述 UE在所 述第一应用的上行数据包中添加所述计费标识后向所述 PCEF实体发送; 所述接收器,还用于接收所述 UE发送的携带有所述计费标识的上行数据 包; a transmitter, configured to send, by the serving gateway device, an identifier of the first application and a charging identifier that is allocated by the receiver to the user equipment, to enable the UE to be in the Adding the charging identifier to an uplink data packet of an application, and sending the identifier to the PCEF entity; The receiver is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier;
处理器, 用于根据所述计费标识对所述接收器接收的携带有所述计费标 识的上行数据包进行单独计费。  The processor is configured to separately charge the uplink data packet that is received by the receiver and that carries the charging identifier according to the charging identifier.
第十五方面提供一种业务检测功能 TDF实体, 包括:  The fifteenth aspect provides a service detection function TDF entity, including:
接收器, 用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识;  a receiver, configured to receive a policy control and charging rule function, and the identifier of the first application that is separately billed by the PCRF entity and the charging identifier that is allocated for the first application determined by the PCRF entity;
处理器, 用于根据所述接收器接收的所述第一应用的标识确定所述第一 应用的下行数据包, 在所述第一应用的下行数据包中添加所述接收器接收的 所述计费标识;  a processor, configured to determine, according to the identifier of the first application received by the receiver, a downlink data packet of the first application, and add, in a downlink data packet of the first application, the received by the receiver Billing identifier
发射器, 用于将添加所述计费标识的下行数据包发送给策略和计费执行 a transmitter, configured to send a downlink data packet that adds the charging identifier to a policy and charging execution
PCEF实体, 以使所述 PCEF实体基于所述计费标识对所述第一应用的下行数 据包进行单独计费。 And a PCEF entity, to enable the PCEF entity to separately charge the downlink data packet of the first application based on the charging identifier.
第十六方面提供一种策略控制和计费规则功能 PCRF实体, 包括: 发送模块, 用于向业务检测功能 TDF实体发送的策略与计费控制 PCC规 则标识和 /或服务数据流 SDF模板, 以供所述 TDF实体确定影响策略和计费执 行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和第一应 用的数据包的流量;  The sixteenth aspect provides a policy control and charging rule function PCRF entity, including: a sending module, a policy and charging control PCC rule identifier and/or a service data flow SDF template sent to the service detecting function TDF entity, Determining, by the TDF entity, an identifier of the SDF to which the first application to which the impact policy and the charging execution PCEF entity performs the SDF granularity based charging result and the traffic of the data packet of the first application;
接收模块, 用于接收所述 TDF实体发送的根据所述 PCC规则标识和 /或 a receiving module, configured to receive, according to the PCC rule identifier, sent by the TDF entity, and/or
SDF模板确定的所述第一应用所属的 SDF的标识和所述第一应用的数据包的 流量; The identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application determined by the SDF template;
所述发送模块, 还用于将所述第一应用所属的 SDF的标识和所述第一应 用的数据包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一 应用所属的 SDF的标识和所述第一应用的数据包的流量对来自用户设备 UE的 上行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据 包属于来自所述 UE的上行数据包。  The sending module is further configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity is based on the first application The identifier of the SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE; wherein the data packet of the first application belongs to the UE from the UE Upstream packet.
结合第十六方面, 在第十六方面的第一种可能的实现方式中, 所述发送 模块用于向 TDF实体发送的 PCC规则标识和 /或 SDF模板, 包括:  In conjunction with the sixteenth aspect, in a first possible implementation manner of the sixteenth aspect, the sending, by the sending module, the PCC rule identifier and/or the SDF template that is sent to the TDF entity includes:
所述发送模块具体用于向所述 TDF实体发送 TDF会话建立请求消息, 所 述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。 结合第十六方面或第十六方面的第一种可能的实现方式, 在第十六方面 的第二种可能的实现方式中, 所述发送模块用于将所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流量发送给所述 PCEF实体, 包括: The sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where The TDF session establishment request message includes the PCC rule identifier and/or an SDF template. In conjunction with the sixteenth aspect or the first possible implementation manner of the sixteenth aspect, in a second possible implementation manner of the sixteenth aspect, the sending module is configured to: And sending the traffic of the data packet of the first application to the PCEF entity, including:
所述发送模块具体用于向所述 PCEF 实体发送互联网连接访问网络 The sending module is specifically configured to send an internet connection access network to the PCEF entity
IP-CAN会话修改请求消息, 所述 IP-CAN会话修改请求消息包括所述第一应 用所属的 SDF的标识和所述第一应用的数据包的流量。 The IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application.
第十七方面提供一种策略和计费执行 PCEF实体, 包括:  The seventeenth aspect provides a policy and charging execution PCEF entity, including:
接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的影响所述 PCEF实体基于服务数据流 SDF粒度的计费结果的第一应用所属的 SDF的标识 和所述第一应用的数据包的流量; 其中, 所述第一应用所属的 SDF的标识和 所述第一应用的数据包的流量是业务检测功能 TDF实体根据所述 PCRF实体发 送的策略与计费控制 PCC规则标识和 /或 SDF模板确定并发送给所述 PCRF实 体的;  a receiving module, configured to receive, by the policy control and charging rule function, the identifier of the SDF that is sent by the first application that affects the PCEF entity based on the serving data flow SDF granularity, and the data packet of the first application The traffic of the SDF to which the first application belongs and the traffic of the data packet of the first application are the service detection function TDF entity according to the policy and charging control PCC rule identifier sent by the PCRF entity and/or The SDF template is determined and sent to the PCRF entity;
计费调整模块, 用于根据所述第一应用所属的 SDF的标识和所述第一应 用的数据包的流量,对来自用户设备 UE的上行数据包基于 SDF粒度的计费结 果进行调整, 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。  The charging adjustment module is configured to adjust, according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, the uplink data packet from the user equipment UE, based on the SDF granularity charging result, where The data packet of the first application belongs to an uplink data packet from the UE.
结合第十七方面, 在第十七方面的第一种可能的实现方式中, 所述 PCEF 实体还包括: 计费模块, 用于在所述接收模块接收第一应用所属的 SDF的标 识和所述第一应用的数据包的流量之前,对来自所述 UE的上行数据包进行基 于 SDF粒度的计费。  In conjunction with the seventeenth aspect, in a first possible implementation of the seventeenth aspect, the PCEF entity further includes: a charging module, configured to receive, at the receiving module, an identifier and a location of an SDF to which the first application belongs Before the traffic of the data packet of the first application, the SDF granularity based charging is performed on the uplink data packet from the UE.
结合第十七方面或第十七方面的第一种可能的实现方式, 在第十七方面 的第二种可能的实现方式中,所述接收模块用于接收 PCRF实体发送的影响所 述 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第 一应用的数据包的流量, 包括:  With reference to the seventeenth aspect, or the first possible implementation manner of the seventeenth aspect, in a second possible implementation manner of the seventeenth aspect, the receiving module is configured to receive, by the PCRF entity, the PCEF entity The identifier of the SDF to which the first application belongs to the SDF granularity-based charging result and the traffic of the data packet of the first application, including:
所述接收模块具体用于接收所述 PCRF 实体发送的互联网连接访问网络 IP-CAN会话修改请求消息, 所述 IP-CAN会话修改请求消息包括所述第一应 用所属的 SDF的标识和所述第一应用的数据包的流量。  The receiving module is specifically configured to receive an Internet connection access network IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs, and the The traffic of an application's packets.
第十八方面提供一种业务检测功能 TDF实体, 包括:  The eighteenth aspect provides a service detection function TDF entity, including:
接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的策略与计 费控制 PCC规则标识和 /或服务数据流 SDF模板; a receiving module, configured to receive a policy control and charging rule function, a policy and a meter sent by a PCRF entity Fee control PCC rule identification and / or service data flow SDF template;
确定模块,用于根据所述接收模块接收的所述 PCC规则标识和 /或 SDF模 板,确定影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用 所属的 SDF的标识和所述第一应用的数据包的流量;  a determining module, configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiving module, an identifier and a location of the SDF to which the first application belongs to the SDF granularity-based charging result of the PCEF entity The traffic of the data packet of the first application;
发送模块, 用于将所述确定模块确定的所述第一应用所属的 SDF的标识 和所述第一应用的数据包的流量通过所述 PCRF实体发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行调 整; 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。  a sending module, configured to send, by the PCRF entity, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, to make the PCEF The entity adjusts the uplink data packet from the user equipment UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the first application is The data packet belongs to an upstream data packet from the UE.
结合第十八方面, 在第十八方面的第一种可能的实现方式中, 所述接收 模块用于接收 PCRF实体发送的 PCC规则标识和 /或 SDF模板, 包括:  In conjunction with the eighteenth aspect, in a first possible implementation of the eighteenth aspect, the receiving module is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity, including:
所述接收模块具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。  The receiving module is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
结合第十八方面或第十八方面的第一种可能的实现方式, 在第十八方面 的第二种可能的实现方式中, 所述确定模块用于根据所述接收模块接收的所 述 PCC规则标识和 /或 SDF模板, 确定影响 PCEF实体基于 SDF粒度的计费结 果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量, 包括: 所述确定模块具体用于根据所述接收模块接收的所述 PCC规则标识指示 的 PCC规则, 确定因执行基于应用的流控而被丢弃的数据包所属的应用作为 所述第一应用, 确定所述被丢弃的数据包的流量作为所述第一应用的数据包 的流量, 并确定所述第一应用所属的 SDF; 或者  In conjunction with the eighteenth aspect, or the first possible implementation manner of the eighteenth aspect, in a second possible implementation manner of the eighteenth aspect, the determining module is configured to receive the PCC according to the receiving module The rule identifier and/or the SDF template, the identifier of the SDF to which the first application that affects the charging result of the SDF granularity of the PCEF entity is determined, and the traffic of the data packet of the first application, the determining module is specifically configured to be used according to the Determining, by the receiving module, the PCC rule indicated by the PCC rule identifier, determining, by using the application that belongs to the data packet that is discarded by performing the application-based flow control, as the first application, determining the traffic of the discarded data packet As the traffic of the data packet of the first application, and determining the SDF to which the first application belongs; or
所述确定模块具体用于根据所述接收模块接收的所述 SDF模板探测到不 需要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进行 计费时, 从具有相同 IP地址信息的所有数据包中, 确定实际需要计费的数据 包所属的应用作为所述第一应用, 确定实际需要计费的数据包的流量作为所 述第一应用的数据包的流量, 并确定所述第一应用所属的 SDF; 或者,  The determining module is specifically configured to: when the SDF template received by the receiving module detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the same IP is obtained. In the data packet of the address information, the application to which the data packet actually required to be charged belongs is determined as the first application, and the traffic of the data packet actually required to be charged is determined as the traffic of the data packet of the first application, and is determined. The SDF to which the first application belongs; or
所述确定模块具体用于根据所述接收模块接收的所述 SDF模板探测到不 需要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进行 计费时, 从具有相同 IP地址信息的所有数据包, 确定出不需要计费的数据包 所属的应用作为所述第一应用, 确定不需要计费的数据包的流量作为所述第 一应用的数据包的流量, 并确定所述第一应用所属的 SDF。 The determining module is specifically configured to: when the SDF template received by the receiving module detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the same IP is obtained. All data packets of the address information, determining an application to which the data packet that does not need to be charged belongs as the first application, determining traffic of the data packet that does not need to be charged as the first The traffic of an application's data packet, and determines the SDF to which the first application belongs.
第十九方面提供一种策略控制和计费规则功能 PCRF实体, 包括: 发射器, 用于向业务检测功能 TDF实体发送的策略与计费控制 PCC规则 标识和 /或服务数据流 SDF模板, 以供所述 TDF实体确定影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和第一应用 的数据包的流量;  A nineteenth aspect provides a policy control and charging rule function PCRF entity, including: a transmitter, a policy and charging control PCC rule identifier and/or a service data flow SDF template sent to a service detection function TDF entity, Determining, by the TDF entity, an identifier of the SDF to which the first application to which the impact policy and the charging execution PCEF entity performs the SDF granularity based charging result and the traffic of the data packet of the first application;
接收器, 用于接收所述 TDF实体发送的根据所述 PCC规则标识和 /或 SDF 模板确定的所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流 所述发射器, 还用于将所述第一应用所属的 SDF的标识和所述第一应用 的数据包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应 用所属的 SDF的标识和所述第一应用的数据包的流量对来自用户设备 UE的上 行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包 属于来自所述 UE的上行数据包。  a receiver, configured to receive, by the TDF entity, the identifier of the SDF to which the first application belongs according to the PCC rule identifier and/or the SDF template, and the flow of the data packet of the first application And sending, to the PCEF entity, the identifier of the SDF to which the first application belongs and the data packet of the first application, so that the PCEF entity is based on the identifier of the SDF to which the first application belongs The traffic of the data packet of the first application is adjusted according to the SDF granularity charging result of the uplink data packet from the user equipment UE; wherein the data packet of the first application belongs to an uplink data packet from the UE.
第二十方面提供一种策略和计费执行 PCEF实体, 包括:  The twentieth aspect provides a policy and charging execution PCEF entity, including:
接收器, 用于接收策略控制和计费规则功能 PCRF 实体发送的影响所述 PCEF实体基于服务数据流 SDF粒度的计费结果的第一应用所属的 SDF的标识 和所述第一应用的数据包的流量; 其中, 所述第一应用所属的 SDF的标识和 所述第一应用的数据包的流量是业务检测功能 TDF实体根据所述 PCRF实体发 送的策略与计费控制 PCC规则标识和 /或 SDF模板确定并发送给所述 PCRF实 体的;  a receiver, configured to receive, by the policy control and charging rule function, the identifier of the SDF that is sent by the first application that affects the PCEF entity based on the service data flow SDF granularity charging result, and the data packet of the first application The traffic of the SDF to which the first application belongs and the traffic of the data packet of the first application are the service detection function TDF entity according to the policy and charging control PCC rule identifier sent by the PCRF entity and/or The SDF template is determined and sent to the PCRF entity;
处理器, 用于根据所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量,对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行 调整, 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。  a processor, configured to adjust an uplink data packet from the user equipment UE according to an SDF granularity charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where The data packet of the first application belongs to an uplink data packet from the UE.
第二十一方面提供一种业务检测功能 TDF实体, 包括:  The twenty-first aspect provides a service detection function TDF entity, including:
接收器,用于接收策略控制和计费规则功能 PCRF实体发送的策略与计费 控制 PCC规则标识和 /或服务数据流 SDF模板;  Receiver for receiving policy control and charging rule functions, policy and charging control sent by the PCRF entity, PCC rule identification and/or service data flow SDF template;
处理器, 用于根据所述接收器接收的所述 PCC规则标识和 /或 SDF模板, 确定影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属 的 SDF的标识和所述第一应用的数据包的流量; 发射器, 用于将所述处理器确定的所述第一应用所属的 SDF的标识和所 述第一应用的数据包的流量通过所述 PCRF实体发送给所述 PCEF实体, 以使 所述 PCEF实体基于所述第一应用所属的 SDF的标识和所述第一应用的数据包 的流量对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。 a processor, configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiver, an identifier and a location of an SDF to which the first application that affects the policy and charging execution PCEF entity based on the SDF granularity charging result The traffic of the data packet of the first application; a transmitter, configured to send, by the processor, an identifier of an SDF to which the first application belongs and a traffic of a data packet of the first application to the PCEF entity by using the PCRF entity, to enable the PCEF The entity adjusts the uplink data packet from the user equipment UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the first application is The data packet belongs to an upstream data packet from the UE.
第二十二方面提供一种业务检测功能 TDF实体, 包括:  The twenty-second aspect provides a service detection function TDF entity, including:
接收模块, 用于接收策略和计费执行 PCEF实体发送的上行数据包; 确定添加模块, 用于在所述接收模块接收到所述上行数据包之后, 确定 回流数据, 并为所述回流数据添加计费标识, 所述回流数据是指所述上行数 据包中影响所述 PCEF实体对所述上行数据包基于服务数据流 SDF粒度的计费 结果的数据包;  a receiving module, configured to receive an uplink data packet sent by the PCEF entity by using a policy and a charging, and determining an adding module, configured to: after the receiving module receives the uplink data packet, determine reflow data, and add the reflow data a billing identifier, where the reflow data refers to a data packet in the uplink data packet that affects the charging result of the PCEF entity based on the service data stream SDF granularity of the uplink data packet;
发送模块, 用于将携带所述计费标识的回流数据发送给所述 PCEF实体, 以使所述 PCEF实体根据携带所述计费标识的回流数据,对所述上行数据包基 于 SDF粒度的计费结果进行调整。  a sending module, configured to send the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity is based on the SDF granularity of the uplink data packet according to the reflow data carrying the charging identifier The fee results are adjusted.
结合第二十二方面, 在第二十二方面的第一种可能的实现方式中, 所述 接收模块还用于在所述确定添加模块为所述回流数据添加计费标识之前, 接 收策略控制和计费规则功能 PCRF实体发送的所述 PCRF实体为所述回流数据 分配的所述计费标识。  With reference to the twenty-second aspect, in a first possible implementation manner of the twenty-second aspect, the receiving module is further configured to: before the determining adding module adds a charging identifier to the reflow data, receiving a policy control And the charging identifier that is sent by the PCRF entity sent by the PCRF entity to the reflow data.
结合第二十二方面的第一种可能的实现方式, 在第二十二方面的第二种 可能的实现方式中, 所述接收模块用于接收 PCRF实体发送的所述 PCRF实体 为所述回流数据分配的所述计费标识, 包括:  With reference to the first possible implementation of the twenty-second aspect, in a second possible implementation manner of the second aspect, the receiving module is configured to receive, by the PCRF entity, the PCRF entity as the reflow The charging identifier of the data distribution includes:
所述接收模块具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述计费标识。  The receiving module is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
第二十三方面提供一种策略和计费执行 PCEF实体, 包括:  The twenty-third aspect provides a policy and charging execution PCEF entity, including:
接收模块, 用于在对上行数据包进行基于服务数据流 SDF粒度的计费之 后, 接收业务检测功能 TDF实体发送的携带有计费标识的回流数据, 所述回 流数据是所述 TDF实体确定的所述上行数据包中影响所述 PCEF实体对所述上 行数据包的基于 SDF粒度的计费结果的数据包;  a receiving module, configured to: after performing service-based data stream SDF granularity charging on the uplink data packet, receive, by the service detecting function TDF entity, reflow data carrying the charging identifier, where the reflow data is determined by the TDF entity a data packet in the uplink data packet that affects an SDF granularity-based charging result of the uplink data packet by the PCEF entity;
计费调整模块, 用于根据所述计费标识确定所述接收模块接收到的数据 是所述回流数据, 确定所述回流数据所属的 SDF, 对所述确定的 SDF的计费 结果进行调整。 a billing adjustment module, configured to determine, according to the billing identifier, that the data received by the receiving module is the reflow data, determine an SDF to which the reflow data belongs, and charge the determined SDF The results are adjusted.
结合第二十三方面, 在第二十三方面的第一种可能的实现方式中, 所述 接收模块还用于在接收所述 TDF 实体发送的携带有计费标识的回流数据之 前, 接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF实体为所述回 流数据分配的所述计费标识。  In conjunction with the twenty-third aspect, in a first possible implementation manner of the twenty-third aspect, the receiving module is further configured to receive a policy before receiving the reflow data carried by the TDF entity and carrying the charging identifier The control and charging rule function sends the charging identifier assigned by the PCRF entity to the reflow data.
结合第二十三方面的第一种可能的实现方式, 在第二十三方面的第二种 可能的实现方式中, 所述接收模块用于接收 PCRF实体发送的所述 PCRF实体 为所述回流数据分配的所述计费标识, 包括:  With reference to the first possible implementation of the twenty-third aspect, in a second possible implementation manner of the twenty-third aspect, the receiving module is configured to receive, by the PCRF entity, the PCRF entity as the reflow The charging identifier of the data distribution includes:
所述接收模块具体用于接收所述 PCRF 实体发送的互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标 识。  The receiving module is specifically configured to receive an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier.
第二十四方面提供一种策略控制和计费规则功能 PCRF实体, 包括: 确定模块, 用于确定需要分配给回流数据包的计费标识, 所述回流数据 是指上行数据包中影响策略和计费执行 PCEF 实体对所述上行数据包的基于 服务数据流 SDF粒度的计费结果的数据包;  The twenty-fourth aspect provides a policy control and charging rule function PCRF entity, including: a determining module, configured to determine a charging identifier that needs to be allocated to a reflow data packet, where the reflow data refers to an impact policy in the uplink data packet Charging a data packet of a service data flow SDF granularity based charging result of the uplink data packet by the PCEF entity;
发送模块, 用于将所述计费标识发送给业务检测功能 TDF 实体和所述 PCEF实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确 定出所述回流数据后在所述回流数据中添加所述计费标识后向所述 PCEF 实 体发送,使所述 PCEF实体根据所述计费标识确定所述回流数据并基于所述回 流数据对所述上行数据包的基于 SDF粒度的计费结果进行调整。  a sending module, configured to send the charging identifier to the service detecting function TDF entity and the PCEF entity, where the TDF entity determines the reflow data from the uplink data packet from the PCEF entity Adding the charging identifier to the PCEF entity, and sending the PCEF entity to determine, according to the charging identifier, the reflow data, and based on the reflow data, the uplink data packet is based on The billing result of the SDF granularity is adjusted.
结合第二十四方面, 在第二十四方面的第一种可能的实现方式中, 所述 发送模块用于将所述计费标识发送给 TDF实体, 包括:  In conjunction with the twenty-fourth aspect, in a first possible implementation of the twenty-fourth aspect, the sending, by the sending, the sending, by the sending,
所述发送模块具体用于向所述 TDF实体发送 TDF会话建立请求消息, 所 述 TDF会话建立请求消息包括所述计费标识。  The sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the charging identifier.
结合第二十四方面或第二十四方面的第一种可能的实现方式, 在第二十 四方面的第二种可能的实现方式中, 所述发送模块用于将所述计费标识发送 给所述 PCEF实体, 包括:  With reference to the twenty-fourth aspect or the first possible implementation manner of the twenty-fourth aspect, in a second possible implementation manner of the twenty-fourth aspect, the sending module is configured to send the charging identifier To the PCEF entity, including:
所述发送模块具体用于向所述 PCEF 实体发送互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标 识。 第二十五方面提供一种业务检测功能 TDF实体, 包括: The sending module is specifically configured to send an internet connection access network IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes the charging identifier. The twenty-fifth aspect provides a service detection function TDF entity, including:
接收器, 用于接收策略和计费执行 PCEF实体发送的上行数据包; 处理器, 用于在所述接收器接收到所述上行数据包之后, 确定回流数据, 并为所述回流数据添加计费标识, 所述回流数据是指所述上行数据包中影响 所述 PCEF实体对所述上行数据包基于服务数据流 SDF粒度的计费结果的数据 包;  a receiver, configured to receive an uplink data packet sent by the PCEF entity, and a processor, configured to: after the receiver receives the uplink data packet, determine reflow data, and add a meter for the reflow data a fee identifier, where the reflow data refers to a data packet in the uplink data packet that affects the charging result of the PCEF entity based on the service data flow SDF granularity of the uplink data packet;
发射器, 用于将携带所述计费标识的回流数据发送给所述 PCEF实体, 以 使所述 PCEF实体根据携带所述计费标识的回流数据,对所述上行数据包基于 a transmitter, configured to send the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity is based on the reflow data carrying the charging identifier, and the uplink data packet is based on
SDF粒度的计费结果进行调整。 The billing result of the SDF granularity is adjusted.
第二十六方面提供一种策略和计费执行 PCEF实体, 包括:  The twenty-sixth aspect provides a policy and charging execution PCEF entity, including:
接收器,用于在对上行数据包进行基于服务数据流 SDF粒度的计费之后, 接收业务检测功能 TDF实体发送的携带有计费标识的回流数据, 所述回流数 据是所述 TDF实体确定的所述上行数据包中影响所述 PCEF实体对所述上行数 据包的基于 SDF粒度的计费结果的数据包;  a receiver, configured to receive reflow data carried by the service detection function TDF entity and carrying the charging identifier, after the serving data stream SDF granularity charging of the uplink data packet, where the reflow data is determined by the TDF entity a data packet in the uplink data packet that affects an SDF granularity-based charging result of the uplink data packet by the PCEF entity;
处理器, 用于根据所述计费标识确定所述接收器接收到的数据是所述回 流数据, 确定所述回流数据所属的 SDF, 对所述确定的 SDF的计费结果进行 调整。  And a processor, configured to determine, according to the charging identifier, that the data received by the receiver is the backflow data, determine an SDF to which the reflow data belongs, and adjust a charging result of the determined SDF.
第二十七方面提供一种策略控制和计费规则功能 PCRF实体, 包括: 处理器, 用于确定需要分配给回流数据包的计费标识, 所述回流数据是 指上行数据包中影响策略和计费执行 PCEF 实体对所述上行数据包的基于服 务数据流 SDF粒度的计费结果的数据包;  The twenty-seventh aspect provides a policy control and charging rule function PCRF entity, including: a processor, configured to determine a charging identifier that needs to be allocated to a reflow packet, where the reflow data refers to an impact policy in an uplink packet Charging a data packet of a service data flow SDF granularity based charging result of the uplink data packet by the PCEF entity;
发射器, 用于将所述计费标识发送给业务检测功能 TDF实体和所述 PCEF 实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确定出所 述回流数据后在所述回流数据中添加所述计费标识后向所述 PCEF实体发送, 使所述 PCEF 实体根据所述计费标识确定所述回流数据并基于所述回流数据 对所述上行数据包的基于 SDF粒度的计费结果进行调整。  a transmitter, configured to send the charging identifier to a service detecting function TDF entity and the PCEF entity, where the TDF entity determines the reflow data from the uplink data packet from the PCEF entity Adding the charging identifier to the PCEF entity, adding the charging identifier to the PCEF entity, causing the PCEF entity to determine the reflow data according to the charging identifier, and based on the reflow data, the uplink data packet is based on The billing result of the SDF granularity is adjusted.
本发明实施例提供的计费方法及设备, 为需要单独计费的应用分配计费 标识, 用于实现对需要单独计费的应用的标识, 基于该计费标识实现对该应 用的单独计费。 附图说明 为了更清楚地说明本发明实施例或现有技术中的技术方案, 下面将对实 施例或现有技术描述中所需要使用的附图作一简单地介绍, 显而易见地, 下 面描述中的附图是本发明的一些实施例, 对于本领域普通技术人员来讲, 在 不付出创造性劳动性的前提下, 还可以根据这些附图获得其他的附图。 The charging method and the device provided by the embodiment of the present invention allocate a charging identifier for an application that needs to be separately charged, and implement an identifier for an application that needs to be separately charged, and implement independent charging for the application based on the charging identifier. . BRIEF DESCRIPTION OF THE DRAWINGS In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, a brief description of the drawings used in the embodiments or the prior art description will be briefly described below. The drawings are some embodiments of the present invention, and those skilled in the art can obtain other drawings based on these drawings without any inventive labor.
图 1为本发明实施例提供的当前无线通信网络中三种接入技术构成的系 图 2为本发明实施例提供的无线通信***控制与管理中, 控制面与用户 面的数据流接口与方向的示意图;  FIG. 1 is a schematic diagram of three access technologies in a current wireless communication network according to an embodiment of the present invention. FIG. 2 is a data flow interface and a direction of a control plane and a user plane in control and management of a wireless communication system according to an embodiment of the present invention. Schematic diagram
图 3为本发明实施例提供的一种计费方法的流程图;  FIG. 3 is a flowchart of a charging method according to an embodiment of the present invention;
图 4为本发明实施例提供的另一种计费方法的流程图  4 is a flowchart of another charging method according to an embodiment of the present invention.
图 5为本发明实施例提供的又一种计费方法的流程图  FIG. 5 is a flowchart of still another charging method according to an embodiment of the present invention;
图 6为本发明实施例提供的又一种计费方法的流程图  6 is a flowchart of still another charging method according to an embodiment of the present invention.
图 7为本发明实施例提供的一种 PCRF实体的结构 ^  FIG. 7 is a structural diagram of a PCRF entity according to an embodiment of the present invention.
图 8为本发明实施例提供的另一种 PCRF实体的结木  FIG. 8 is a block diagram of another PCRF entity according to an embodiment of the present invention.
图 9为本发明实施例提供的一种 PCEF实体的结构 ^  FIG. 9 is a schematic structural diagram of a PCEF entity according to an embodiment of the present invention.
图 10为本发明实施例提供的另一种 PCEF实体的结  FIG. 10 is a diagram of another PCEF entity according to an embodiment of the present invention.
图 1 1为本发明: ;施例提供的一种 TDF实体的结构 ^  Figure 1 1 is the present invention: ; The structure of a TDF entity provided by the example ^
图 12为本发明: ;施例提供的另一种 TDF实体的结木  Figure 12 is a view of the present invention: another TDF entity provided by the embodiment
图 13为本发明: ;施例提供的又 -种 PCRF 体的;  Figure 13 is the present invention:; another embodiment of the PCRF body provided;
图 14为本发明: ;施例提供的又 -种 PCRF 体的;  Figure 14 is the present invention:; another embodiment of the PCRF body provided;
图 15为本发明: ;施例提供的又 -种 PCEF 体的;  Figure 15 is the present invention:; another embodiment of the PCEF body provided by the embodiment;
图 16为本发明: ;施例提供的又 -种 PCEF 体的;  Figure 16 is the present invention:; another embodiment of the PCEF body provided by the embodiment;
图 17为本发明: ;施例提供的又 -种 TDF %;体的  Figure 17 is a view of the present invention: - TDF % provided by the embodiment;
图 18为本发明: ;施例提供的又 -种 TDF %;体的  Figure 18 is a view of the present invention;
图 19为本发明: ;施例提供的又 -种 TDF %;体的  Figure 19 is a view of the present invention:
图 20为本发明: ;施例提供的又 -种 TDF %;体的  Figure 20 is a view of the present invention;
图 21为本发明: ;施例提供的又 -种 PCEF ^体的;  Figure 21 is the present invention:; another embodiment of the PCEF body provided by the embodiment;
图 22为本发明: ;施例提供的又 -种 PCEF ^体的;  Figure 22 is the present invention:; another embodiment of the PCEF ^ body provided;
图 23为本发明: ;施例提供的又 -种 PCRF ^体的; 图 24为本发明实施例提供的又一种 PCRF实体的结构示意图。 Figure 23 is the present invention:; another embodiment of the PCRF ^ body provided; FIG. 24 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention.
具体实施方式 为使本发明实施例的目的、 技术方案和优点更加清楚, 下面将结合本发 明实施例中的附图, 对本发明实施例中的技术方案进行清楚、 完整地描述, 显然, 所描述的实施例是本发明一部分实施例, 而不是全部的实施例。 基于 本发明中的实施例, 本领域普通技术人员在没有作出创造性劳动前提下所获 得的所有其他实施例, 都属于本发明保护的范围。 The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. The embodiments are a part of the embodiments of the invention, and not all of the embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative efforts are within the scope of the present invention.
当前的无线通信网络有三种接入技术,一种是全球移动通讯***(Global System of Mobile communication, 简称为 GSM) , 通常称为 2G; ——禾中是通 用禾多动通信*** (Universal Mobile Telecommunications System, 简禾尔为 UMTS) , 通常称为 3G; 以及长期演进 (Long Term Evolved, 简称为 LTE) 系 统, 通常称为 4G。 三种接入技术下的***架构如图 1所示。  The current wireless communication network has three access technologies, one is the Global System of Mobile communication (GSM), commonly referred to as 2G; - Wozhong is the Universal Mobile Telecommunications system (Universal Mobile Telecommunications) System, Jane is UMTS), commonly referred to as 3G; and Long Term Evolved (LTE) system, commonly referred to as 4G. The system architecture under the three access technologies is shown in Figure 1.
无论是哪种接入技术下的网络架构均可分成两个部分, 一个是接入网部 分, 一个核心网部分。 核心网部分又分为移动性管理网元、 网关设备及 PCC 部分。 接入网部分主要负责无线接入层信令以及用户数据传输, 具体的, 在 GSM中,接入网部分主要是指图 1中的 GERAN (英文为: GSM EDGE Radio Access Network),包括 BTS和 BSC;在 UMTS中,接入网部分主要是指图 1中的 UTRAN, 包括 RNC和 NodeB; 在 LTE***中, 接入网部分主要是指图 1中的 E-UTRAN, 包括 eNodeB。 图 1所示架构中除接入网部分之外的其它部分为核心网部分, 其中, GSM和 UMTS的 SGSN以及 LTE***中的匪 E被称为移动性管理网元, 主要用于获取用户的签约数据, 负责 NAS信令和 NAS信令加密以及漫游、 跟 踪等功能, 分配用户临时身份标识、 安全功能等。 GSM和 UMTS中的 GGSN以 及 LTE***中的 PGW是网关设备, 主要负责策略执行和计费以及合法监听相 关功能。 另外, 核心网中还有一个重要组成部分是 PCC部分, 其包括 PCRF实 体和 PCEF实体, PCEF实体通常与网关设备, 例如 GGSN或 PGW合设, 并与用 户签约数据库 (Subscription Profile Repository, 简称为 SPR) 、 应用功 能 (Application Function, 简称为 AF) 实体等一起实现 PCC部分的作用。 图 1中未示出 SPR。  No matter which access technology network architecture can be divided into two parts, one is the access network part, one core network part. The core network part is further divided into a mobility management network element, a gateway device, and a PCC part. The access network part is mainly responsible for radio access layer signaling and user data transmission. Specifically, in GSM, the access network part mainly refers to GERAN (English: GSM EDGE Radio Access Network) in Figure 1, including BTS and BSC; In UMTS, the access network part mainly refers to the UTRAN in FIG. 1, including the RNC and the NodeB; in the LTE system, the access network part mainly refers to the E-UTRAN in FIG. 1, including the eNodeB. The other part of the architecture shown in Figure 1 except the access network part is the core network part. The SGSN of GSM and UMTS and the 匪E of the LTE system are called mobility management network elements, which are mainly used to acquire users. Signing data, responsible for NAS signaling and NAS signaling encryption, roaming, tracking, etc., assigning user temporary identity, security functions, etc. The GGSN in GSM and UMTS and the PGW in the LTE system are gateway devices, which are mainly responsible for policy enforcement and charging and lawful interception related functions. In addition, an important component of the core network is the PCC part, which includes a PCRF entity and a PCEF entity. The PCEF entity is usually combined with a gateway device, such as a GGSN or a PGW, and is subscribed to a database (Subscription Profile Repository, SPR for short). ), Application Function (AF) entities, etc. together implement the PCC part. SPR is not shown in Figure 1.
PCRF实体主要是根据运营商策略、 对用户接入网络的限制、 用户签约数 据以及用户当前正在进行的 SDF的业务信息等因素, 制定对应的策略, 该策 略称为 PCC规则; PCEF实体主要是执行 PCRF实体制定的 PCC规则, 例如根 据 PCC 规则, 对 SDF进行检测和测量, 保证业务的服务质量 (Quality of Service, 简称为 QoS) , 用户面流量检测和触发控制面的会话管理等等。 进 一步说明,为保证业务的 QoS,UE发出的所有互联网协议(Internet Protocol , 简称为 IP) 数据包或待接收的所有 IP数据包需要经过 PCEF, 由 PCEF根据 SDF的 QoS参数将服务数据流与承载绑定, 比如将 QoS分类标识 (QoS Class Identifier, 简称为 QCI ) 与地址解析协议 (Address Resolution Protocol , 简称为 ARP) 相同的服务数据流绑定在同一个承载上, 以便于核心网中的其 他网元基于承载执行流控。 另外, PCEF还会根据 PCRF下发的计费策略与计 费方式等, 对收到的服务数据流等。 The PCRF entity is mainly based on the operator's policy, restrictions on user access to the network, and number of user subscriptions. According to factors such as the service information of the SDF currently being performed by the user, a corresponding policy is formulated, which is called a PCC rule; the PCEF entity mainly performs a PCC rule formulated by the PCRF entity, for example, detecting and measuring the SDF according to the PCC rule, Quality of Service (QoS), user-side traffic detection, and session management for triggering control planes. Further, in order to guarantee the QoS of the service, all Internet Protocol (IP) data packets sent by the UE or all IP data packets to be received need to pass through the PCEF, and the PCEF will serve the data flow and bearer according to the QoS parameters of the SDF. Binding, for example, the QoS Class Identifier (QCI) is the same as the Address Resolution Protocol (ARP) service data flow on the same bearer, so as to facilitate other core networks. The network element performs flow control based on the bearer. In addition, the PCEF will also receive the service data stream according to the charging policy and charging method delivered by the PCRF.
目前,对用户的业务数据进行计费是由 PCEF实体执行基于 SDF粒度的计 费。 当前的 3GPP组织中正在讨论基于应用数据流的计费。 针对当前 3GPP组 织正在讨论的基于应用数据流的计费, 本发明实施例提供了以下两种解决方 案。 一种是在业务检测功能 (Traffic Detection Function, 简称为 TDF) 实体上执行基于应用数据流的计费方案,另一种是在 PCEF实体上执行基于应 用数据流的计费方案。  Currently, charging the user's business data is performed by the PCEF entity based on the SDF granularity. Application data flow based charging is being discussed in current 3GPP organizations. The present invention provides the following two solutions for the application data flow based charging that is currently being discussed by the 3GPP organization. One is to implement an application data flow-based charging scheme on a Traffic Detection Function (TDF) entity, and the other is to implement an application data flow-based charging scheme on a PCEF entity.
其中, TDF实体是深度包检测 (Deep Packet Inspection, 简称为 DPI ) 设备的一种功能实体,能够根据 PCRF实体下发的对数据包的探测规则对数据 包执行检测, 例如检测某类应用 (QQ) 的数据包, 或者检测指定的统一资源 定位符 (Uniform Resource Locator, 简称为 URL) 的数据包等, 在检测到 满足条件的应用数据包后, 向 PCRF实体上报该数据包事件。 另外, TDF实体 也可能对检测到的应用数据包执行流控, 例如上下行的最大比特率限制。 图 2所示为无线通信***控制与管理中, 控制面与用户面的数据流接口与方向。 如图 2所示中带箭头的虚线所示, UE发送的上行数据包要先经过 PCEF实体, 再经过 TDF实体才能到达网络侧, 相应的, 如图 2中带箭头的实线所示, 网 络侧发送的下行数据包要先经过 TDF实体, 再经过 PCEF实体才能到达 UE。  The TDF entity is a functional entity of the Deep Packet Inspection (DPI) device, and can perform detection on the data packet according to the detection rule of the data packet sent by the PCRF entity, for example, detecting a certain type of application (QQ). The data packet, or the data packet of the specified Uniform Resource Locator (URL), is detected, and the packet event is reported to the PCRF entity after detecting the application data packet that satisfies the condition. In addition, the TDF entity may also perform flow control on the detected application data packets, such as the maximum bit rate limit of uplink and downlink. Figure 2 shows the data flow interface and direction of the control plane and the user plane in the control and management of the wireless communication system. As shown by the dotted line with an arrow in FIG. 2, the uplink data packet sent by the UE first passes through the PCEF entity, and then passes through the TDF entity to reach the network side, correspondingly, as shown by the solid line with an arrow in FIG. 2, the network The downlink data packet sent by the side must pass through the TDF entity before passing through the PCEF entity to reach the UE.
在第一种解决方案中, 对于上行数据包来说, 有可能经过 PCEF实体基于 SDF粒度的计费后, 又经过 TDF实体基于应用数据流的计费, 存在重复计费 导致计费不准确; 对于下行数据流来说, 由于 PCEF实体要执行 SDF的 QoS策 略, 可能会丢弃在 TDF实体已经计费的数据包, 也会导致计费不准确。 In the first solution, for the uplink data packet, it is possible to pass the SDF granularity-based charging of the PCEF entity, and then the TDF entity is based on the application data flow-based charging, and the repeated charging causes the charging to be inaccurate; For the downlink data stream, because the PCEF entity is to implement the SDF QoS policy Slightly, the packets that have been billed in the TDF entity may be discarded, which may result in inaccurate billing.
在第二种解决方案中, TDF 实体探测到下行数据包所属的应用后, 标识 这种下行数据包, 以便于 PCEF实体根据该标识识别下行数据包所属的应用, 并对其进行计费, 实现基于应用数据流的计费, 但是对于上行数据包, PCEF 实体无法识别上行数据包所属的应用,只有在执行完基于 SDF粒度的计费后, 将上行数据包送入 TDF实体, 由 TDF实体检测上行数据包所属的应用, 并反 馈给 PCEF实体, 此时 PCEF实体再对该上行数据包进行计费, 实现基于应用 数据流的计费, 这就存在重复计费的问题, 也会导致计费不准确。  In the second solution, after detecting the application to which the downlink data packet belongs, the TDF entity identifies the downlink data packet, so that the PCEF entity identifies the application to which the downlink data packet belongs according to the identifier, and performs charging, thereby implementing Based on the application data flow-based charging, but for the uplink data packet, the PCEF entity cannot identify the application to which the uplink data packet belongs, and only after performing the SDF granularity-based charging, the uplink data packet is sent to the TDF entity, and the TDF entity detects The application to which the uplink data packet belongs is fed back to the PCEF entity. At this time, the PCEF entity charges the uplink data packet to implement charging based on the application data flow, which has the problem of repeated charging, and also causes charging. Inaccurate.
针对当前 3GPP组织中正在讨论基于应用数据流的计费, 以及本发明上面 提供的解决方案存在的问题, 本发明以下实施例给出了更加详细完善的解决 方案。  The following embodiments of the present invention provide a more detailed and complete solution to the problems that are currently being discussed in application-based data flow-based charging in the 3GPP organization, and the solutions provided above.
本发明提供的第一种计费方法的主要思路是: 由 PCRF实体确定需要计费 的第一应用, 并为第一应用分配计费标识, 通过所述计费标识标识需要对第 一应用进行单独计费;然后 PCRF实体将第一应用的标识和为第一应用分配的 计费标识分别发送给 TDF实体、 PCEF实体和 UE; 这样, UE向 PCEF实体发送 第一应用的上行数据包之前,在第一应用的上行数据包中添加所述计费标识, 然后将添加所述计费标识的上行数据包发送给 PCEF实体, PCEF实体就可以 对接收到的携带有所述计费标识的上行数据包进行单独计费, 实现在上行方 向对第一应用的单独计费, 并且因为可以标识第一应用的上行数据包因此不 存在重复计费的问题; 同理, TDF实体在向 PCEF实体发送第一应用的下行数 据包之前, 在第一应用的下行数据包中添加所述计费标识, 然后将添加所述 计费标识的上行数据包发送给 PCEF实体, PCEF实体就可以对接收到的携带 有所述计费标识的下行数据包进行单独计费, 实现在下行方向上对第一应用 的单独计费, 因为可以标识第一应用的下行数据包所以不存在重复计费的问 题。  The main idea of the first charging method provided by the present invention is: determining, by the PCRF entity, the first application that needs to be charged, and assigning a charging identifier to the first application, where the charging identifier needs to be used for the first application. Separate billing; then the PCRF entity sends the identifier of the first application and the charging identifier assigned to the first application to the TDF entity, the PCEF entity, and the UE respectively; thus, before the UE sends the uplink packet of the first application to the PCEF entity, Adding the charging identifier to the uplink data packet of the first application, and then sending the uplink data packet that adds the charging identifier to the PCEF entity, where the PCEF entity can receive the received uplink carrying the charging identifier. The data packet is separately charged, and the first application is separately charged in the uplink direction, and since the uplink data packet of the first application can be identified, there is no problem of repeated charging; similarly, the TDF entity sends the data to the PCEF entity. Before the downlink data packet of the first application, adding the charging identifier to the downlink data packet of the first application, and then adding the charging identifier The uplink data packet is sent to the PCEF entity, and the PCEF entity can separately charge the received downlink data packet carrying the charging identifier to implement separate charging for the first application in the downlink direction, because the first packet can be identified. The downlink packet of the application does not have the problem of repeated charging.
基于第一种计费方法的主要思路, 下面分别从 PCRF实体、 PCEF实体、 TDF实体以及 UE的角度详细说明第一种计费方法的流程。  Based on the main idea of the first charging method, the flow of the first charging method is described in detail from the perspective of a PCRF entity, a PCEF entity, a TDF entity, and a UE.
从 PCRF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the PCRF entity includes:
PCRF实体确定需要计费的第一应用, 并为第一应用分配计费标识, 所述 计费标识用于标识需要对所述第一应用单独进行计费; PCRF实体将所述第一应用的标识和为所述第一应用分配的计费标识分别 发送给 UE、 PCEF实体和 TDF实体, 以使所述 UE和 TDF实体在所述第一应用 的数据包中添加所述计费标识后发送给所述 PCEF实体, 使所述 PCEF实体根 据所述第一应用的标识和为所述第一应用分配的计费标识分别对来自 UE 和 TDF 实体的携带有所述计费标识的数据包进行单独计费, 从而实现对第一应 用的单独计费。 The PCRF entity determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged. The PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE, the PCEF entity, and the TDF entity, respectively, so that the UE and the TDF entity are in the data packet of the first application. Adding the charging identifier to the PCEF entity, and causing the PCEF entity to carry the bearer from the UE and the TDF entity according to the identifier of the first application and the charging identifier allocated for the first application, respectively. The data packet of the charging identifier is separately charged, thereby implementing separate charging for the first application.
在一可选实施方式中, PCRF实体将所述第一应用的标识和为所述第一应 用分配的计费标识发送给 UE, 包括:  In an optional implementation, the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE, including:
PCRF实体向所述 PCEF实体发送 IP-CAN会话建立响应消息,所述 IP-CAN 会话建立响应消息包括所述第一应用的标识和为所述第一应用的分配的计费 标识, 以使所述 PCEF实体通过服务网关设备将所述第一应用的标识和为所述 第一应用分配的计费标识发送给所述 UE。  The PCRF entity sends an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an assigned charging identifier for the first application, so that The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
基于上述, PCRF实体向所述 PCEF实体发送 IP-CAN会话建立响应消息之 前, 还包括: PCRF实体接收 PCEF实体发送的 IP-CAN会话建立请求消息。  Based on the foregoing, before the PCRF entity sends the IP-CAN session establishment response message to the PCEF entity, the method further includes: the PCRF entity receiving the IP-CAN session establishment request message sent by the PCEF entity.
在一可选实施方式中, PCRF实体将所述第一应用的标识和为所述第一应 用分配的计费标识发送给 TDF实体, 包括:  In an optional implementation, the PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, including:
PCRF实体向所述 TDF实体发送 TDF会话建立请求消息, 所述 TDF会话建 立请求消息包括所述第一应用的标识和为所述第一应用分配的计费标识。  The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
进一步可选的, PCRF实体向所述 TDF实体发送 TDF会话建立请求消息之 后, 还包括: PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。  Further, after the PCRF entity sends the TDF session establishment request message to the TDF entity, the method further includes: the PCRF entity receiving the TDF session establishment response message sent by the TDF entity.
在一可选实施方式中, PCRF实体确定需要计费的第一应用, 包括: PCRF 实体接收 TDF实体发送的业务流探测事件, 所述业务流探测事件是所述 TDF 实体探测到需要计费的所述第一应用的数据包后发送的, 且所述业务流探测 事件包括所述第一应用的标识,所述 PCRF实体根据所述第一应用的标识确定 所述第一应用。  In an optional implementation, the PCRF entity determines the first application that needs to be charged, and the method includes: the PCRF entity receives a service flow detection event sent by the TDF entity, where the service flow detection event is that the TDF entity detects that the charging is required. After the data packet of the first application is sent, the service flow detection event includes an identifier of the first application, and the PCRF entity determines the first application according to the identifier of the first application.
基于上述 TDF实体探测需要计费的第一应用的方案, PCRF实体将所述第 一应用的标识和为所述第一应用分配的计费标识发送给 UE和 PCEF实体, 包 括:  The PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE and the PCEF entity, based on the foregoing method for detecting the first application that needs to be charged by the TDF entity, including:
PCRF实体向所述 PCEF实体发送策略与计费规则消息, 所述策略与计费 规则消息包括所述第一应用的标识和为所述第一应用分配的计费标识, 以使 所述 PCEF 实体通过服务网关设备将所述第一应用的标识和为所述第一应用 分配的计费标识发送给所述 UE。 The PCRF entity sends a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, so that The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
基于上述 TDF实体探测需要计费的第一应用的方案, PCRF实体将所述第 一应用的标识和为所述第一应用分配的计费标识发送给 TDF实体, 包括: PCRF 实体向所述 TDF 实体发送修改应用探测控制 (Appl ication The PCRF entity sends the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, including: the PCRF entity to the TDF, based on the solution that the TDF entity detects the first application that needs to be charged. Entity sends modify application probe control (Appl ication
Detection Control , 简称为 ADC) 规则消息, 所述修改 ADC规则消息包括所 述第一应用的标识和为所述第一应用分配的计费标识。 The detection control (referred to as ADC) rule message, the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
从 PCEF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the PCEF entity includes:
PCEF实体接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第 一应用的标识和为所述第一应用分配的计费标识;  The PCEF entity receives an identifier of the first application that is separately billed by the PCRF entity and a charging identifier that is allocated for the first application, which is sent by the PCRF entity;
PCEF实体将所述第一应用的标识和为所述第一应用分配的计费标识通过 服务网关设备发送给 UE, 以使所述 UE在所述第一应用的上行数据包中添加 所述计费标识后向所述 PCEF实体发送;  The PCEF entity sends the identifier of the first application and the charging identifier allocated to the first application to the UE by using the serving gateway device, so that the UE adds the meter to the uplink data packet of the first application. After the fee is identified, it is sent to the PCEF entity;
PCEF实体接收所述 UE发送的携带有所述计费标识的上行数据包, 并根 据所述计费标识对携带有所述计费标识的上行数据包进行单独计费。  The PCEF entity receives the uplink data packet that is sent by the UE and carries the charging identifier, and performs independent charging on the uplink data packet carrying the charging identifier according to the charging identifier.
在一可选实施方式中, 所述方法还包括:  In an optional implementation, the method further includes:
PCEF实体接收 TDF实体发送的携带有所述计费标识的下行数据包, 并根 据所述计费标识对携带有所述计费标识的下行数据包进行单独计费。  The PCEF entity receives the downlink data packet that is sent by the TDF entity and carries the charging identifier, and performs independent charging on the downlink data packet carrying the charging identifier according to the charging identifier.
在一可选实施方式中, PCEF实体接收 PCRF实体发送的所述 PCRF实体确 定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标识, 包 括:  In an optional implementation, the PCEF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and includes:
PCEF实体接收所述 PCRF实体发送的 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述第一应用的标识和为所述第一应用的分配 的计费标识。  The PCEF entity receives the IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application.
基于上述, PCEF实体接收所述 PCRF实体发送的 IP-CAN会话建立响应消 息之前,还包括: PCEF实体向所述 PCRF实体发送 IP-CAN会话建立请求消息。  Based on the foregoing, before receiving the IP-CAN session establishment response message sent by the PCRF entity, the PCEF entity further includes: the PCEF entity sending an IP-CAN session establishment request message to the PCRF entity.
在一可选实施方式中, CEF实体接收 PCRF实体发送的所述 PCRF实体确 定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标识, 包 括:  In an optional implementation, the CEF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and includes:
PCEF实体接收所述 PCRF实体发送的策略与计费规则消息, 所述策略与 计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费标识。 在一可选实施方式中, PCEF实体将所述第一应用的标识和为所述第一应 用分配的计费标识通过服务网关设备发送给 UE , 包括: Receiving, by the PCEF entity, a policy and charging rule message sent by the PCRF entity, where the policy and The charging rule message includes an identifier of the first application and a charging identifier allocated for the first application. In an optional implementation, the PCEF entity sends the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
PCEF 实体向所述服务网关设备发送 IP-CAN 承载建立响应消息, 所述 IP-CAN承载建立响应消息包括所述第一应用的标识和为所述第一应用分配的 计费标识, 以使所述服务网关设备将所述第一应用的标识和为所述第一应用 分配的计费标识发送给所述 UE。  The PCEF entity sends an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application, so that The serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE.
基于上述, PCEF实体向所述服务网关设备发送 IP-CAN承载建立响应消 息之前, 还包括: PCEF实体接收所述服务网关设备发送的 IP-CAN承载建立 请求消息, 所述 IP-CAN承载建立请求消息包括所述 UE的标识。  Before the PCEF entity sends the IP-CAN bearer setup response message to the serving gateway device, the method further includes: the PCEF entity receiving the IP-CAN bearer setup request message sent by the serving gateway device, the IP-CAN bearer setup request The message includes an identification of the UE.
从 TDF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the TDF entity includes:
TDF实体接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第 一应用的标识和为所述第一应用分配的计费标识;  The TDF entity receives the identifier of the first application that needs to be separately charged and the charging identifier that is allocated for the first application, which is determined by the PCRF entity sent by the PCRF entity;
TDF 实体根据所述第一应用的标识确定所述第一应用的下行数据包, 在 所述第一应用的下行数据包中添加所述计费标识;  Determining, by the TDF entity, the downlink data packet of the first application according to the identifier of the first application, and adding the charging identifier to the downlink data packet of the first application;
TDF实体将添加所述计费标识的下行数据包发送给 PCEF实体, 以使所述 PCEF实体基于所述计费标识对所述第一应用的下行数据包进行单独计费。  The TDF entity sends the downlink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity separately charges the downlink data packet of the first application based on the charging identifier.
在一可选实施方式中, TDF实体接收 PCRF实体发送的所述 PCRF实体确 定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标识, 包 括:  In an optional implementation, the TDF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and includes:
TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会 话建立请求消息包括所述第一应用的标识和为所述第一应用分配的计费标 识。  The TDF entity receives the TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the identifier of the first application and the charging identifier allocated for the first application.
进一步可选的, TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消 息之后, 还包括: TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。  Further, after the TDF entity receives the TDF session establishment request message sent by the PCRF entity, the method further includes: the TDF entity sending a TDF session establishment response message to the PCRF entity.
在一可选实施方式中, TDF实体接收 PCRF实体发送的所述 PCRF实体确 定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标识之 前, 还包括 Γ  In an optional implementation, the TDF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, and further includes
TDF 实体探测需要单独计费的所述第一应用的数据包, 并在探测到所述 第一应用的数据包后, 向所述 PCRF实体发送业务流探测事件, 所述业务流探 测事件包括所述第一应用的标识, 以使所述 PCRF实体根据所述第一应用的标 识确定需要对所述第一应用进行计费。 The TDF entity detects a data packet of the first application that needs to be separately charged, and after detecting the data packet of the first application, sends a service flow detection event to the PCRF entity, where the service flow probe The event includes an identifier of the first application, so that the PCRF entity determines that the first application needs to be charged according to the identifier of the first application.
基于上述, TDF实体接收 PCRF实体发送的所述 PCRF实体确定的需要单 独计费的第一应用的标识和为所述第一应用分配的计费标识, 包括:  Based on the foregoing, the TDF entity receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, including:
TDF实体接收所述 PCRF实体发送的修改 ADC规则消息, 所述修改 ADC规 则消息包括所述第一应用的标识和为所述第一应用分配的计费标识。  The TDF entity receives the modified ADC rule message sent by the PCRF entity, and the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
从 UE的角度进行描述的方法流程包括:  The method flow described from the perspective of the UE includes:
UE接收服务网关设备发送的第一应用的标识和为所述第一应用分配的计 费标识; 其中, 所述计费标识用于标识需要对所述第一应用单独进行计费; UE根据所述第一应用的标识确定所述第一应用的上行数据包, 在所述第 一应用的上行数据包中添加所述计费标识;  Receiving, by the UE, the identifier of the first application that is sent by the serving gateway device, and the charging identifier that is allocated to the first application, where the charging identifier is used to identify that the first application needs to be separately charged; The identifier of the first application determines an uplink data packet of the first application, and adds the charging identifier to an uplink data packet of the first application;
UE将添加所述计费标识的上行数据包发送给 PCEF实体, 以使所述 PCEF 实体基于所述计费标识对所述第一应用的上行数据包进行单独计费。  The UE sends the uplink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity separately charges the uplink data packet of the first application based on the charging identifier.
下面从多网元交互的角度, 进一步对本发明提供的第一种计费方法的流 程进行详细描述。  The flow of the first charging method provided by the present invention is further described in detail from the perspective of multi-network element interaction.
图 3为本发明实施例提供的一种计费方法的流程图。 如图 3所示, 所述 方法包括:  FIG. 3 is a flowchart of a charging method according to an embodiment of the present invention. As shown in FIG. 3, the method includes:
11、 PCEF 实体接收服务网关设备发送的互联网连接访问网络 ( IP-Connectivity Access Network, 简称为 IP-CAN) 承载建立请求消息。  11. The PCEF entity receives an IP-Connectivity Access Network (IP-CAN) bearer setup request message sent by the serving gateway device.
具体的, PCEF实体接收服务网关设备, 例如 SGW发送的 IP-CAN承载建 立请求消息, 所述 IP-CAN承载建立请求消息包括 UE的标识等信息, 用于建 立承载。  Specifically, the PCEF entity receives the service gateway device, for example, an IP-CAN bearer setup request message sent by the SGW, where the IP-CAN bearer setup request message includes information such as the identifier of the UE, and is used to establish a bearer.
12、 PCEF实体向 PCRF实体发送 IP-CAN会话建立请求消息。  12. The PCEF entity sends an IP-CAN session establishment request message to the PCRF entity.
13、 PCRF实体确定需要计费的第一应用, 并为需要计费的第一应用分配 计费标识, 以标识需要对第一应用进行单独计费。  13. The PCRF entity determines the first application that needs to be charged, and allocates a charging identifier to the first application that needs to be charged, to identify that the first application needs to be separately charged.
在此说明, 这里的第一应用可以是任何需要进行计费的应用, 为便于描 述, 冠以 "第一" , 但并没有个数限定的意思。  Herein, the first application here may be any application that needs to be charged. For the convenience of description, it is referred to as "first", but there is no limit to the number.
例如, PCRF可以为第一应用分配相应的差分服务代码点(Differentiated Services Code Point, 简称为 DSCP) 值, 以便于在数据包的 IP头中的 DSCP 位采用相应的值标识需要对第一应用进行计费。 14、 PCRF实体向 TDF实体发送 TDF会话建立请求消息, 该 TDF会话建立 请求消息包括第一应用的标识 (APPLICATION ID) 以及计费标识, 例如 DSCP 值。 For example, the PCRF may allocate a corresponding differentiated service code point (DSCP) value to the first application, so that the DSCP bit in the IP header of the data packet is identified by the corresponding value to be used for the first application. Billing. 14. The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application (APPLICATION ID) and a charging identifier, such as a DSCP value.
15、 TDF实体向 PCRF实体发送 TDF会话建立响应消息。  15. The TDF entity sends a TDF session setup response message to the PCRF entity.
可选的, 本实施例提供的方法还可以包括: TDF 实体收到第一应用的标 识和为第一应用分配的计费标识后, 在第一应用的下行数据包中添加该计费 标识, 并将添加计费标识的第一应用的下行数据包发送给 PCEF 实体; PCEF 实体收到 TDF实体发送的携带有计费标识的下行数据包时, 对该类数据包执 行计费。  Optionally, the method provided in this embodiment may further include: after receiving the identifier of the first application and the charging identifier allocated to the first application, the TDF entity adds the charging identifier to the downlink data packet of the first application, And sending the downlink data packet of the first application that adds the charging identifier to the PCEF entity; when receiving the downlink data packet that is sent by the TDF entity and carrying the charging identifier, the PCEF entity performs charging for the data packet.
PCRF实体为第一应用分配计费标识后, 向 TDF实体发起 TDF会话建立流 程, 以将第一应用的标识和为第一应用分配的计费标识提供给 TDF实体, 以 便于 TDF在下行方向对该第一应用按照所述计费标识(例如 DSCP值)进行标 识,使得 PCEF实体收到 TDF发送的下行数据包后能够识别出下行数据包属于 需要进行计费的第一应用, 从而在下行方向上实现对第一应用的单独计费, 且不存在重复计费的问题。  After the PCRF entity allocates the charging identifier to the first application, the TDF entity initiates a TDF session establishing process to provide the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, so that the TDF is in the downlink direction. The first application is identified by the charging identifier (for example, the DSCP value), so that the PCEF entity can recognize that the downlink data packet belongs to the first application that needs to be charged, and then in the downlink direction, after receiving the downlink data packet sent by the TDF. A separate billing for the first application is implemented, and there is no problem of repeated billing.
16、 PCRF实体向 PCEF实体发送 IP-CAN会话建立响应消息, 该 IP-CAN 会话建立响应消息包括第一应用的标识和为第一应用分配的计费标识, 例如 DSCP值。  The PCRF entity sends an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and a charging identifier assigned to the first application, for example, a DSCP value.
其中 , 第一应用 的标识也就是需要计费的应用 的标识 ( Char ged-app 1 i cat i on identifier) 。  The identifier of the first application is the identifier of the application to be charged (Char ged-app 1 i cat i on identifier).
PCRF实体在为第一应用分配计费标识后, 一方面将第一应用的标识和为 第一应用分配的计费标识提供给 TDF实体, 另一方面还需要将第一应用的标 识和为第一应用分配的计费标识提供给 PCEF实体, 以便于 PCEF实体基于这 两个信息, 对第一应用的上行和下行数据包进行计费。  After assigning the charging identifier to the first application, the PCRF entity provides the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, and the identifier of the first application is also required to be An application-assigned charging identifier is provided to the PCEF entity, so that the PCEF entity charges the uplink and downlink data packets of the first application based on the two information.
17、 PCEF实体向服务网关设备发送 IP-CAN承载建立响应消息,该 IP-CAN 承载建立响应消息包括第一应用的标识和为第一应用分配的计费标识。  17. The PCEF entity sends an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application.
可选的, PCEF实体可以将第一应用的标识和为第一应用分配的计费标识 添加到 IP-CAN 承载建立响应消息中的协议配置选项 ( Protocol Configuration Options , 简称为 PC0) 中, 提供给服务网关设备。  Optionally, the PCEF entity may add the identifier of the first application and the charging identifier allocated for the first application to a Protocol Configuration Option (PC0) in the IP-CAN bearer setup response message, and provide the Service gateway device.
另外, 本实施例对第一应用的标识的实现不做限定。 举例说明, 如果需 要对新浪(Sina ) 网页的应用数据包计费, 那么可能将胃 . sina. com作为第 一应用的标识包含在 PC0中, 但不限于此。 In addition, this embodiment does not limit the implementation of the identifier of the first application. For example, if needed To charge the application data package of the Sina (Sina) webpage, it is possible to include the stomach. sina.com as the identifier of the first application in the PC0, but is not limited thereto.
18、服务网关设备接收到 IP-CAN承载建立响应消息后, 经过移动性管理 网元向 UE 透传第一应用的标识和为第一应用分配的计费标识, 例如可以向 UE透传 IP-CAN承载建立响应消息中的 PC0。  After the service gateway device receives the IP-CAN bearer setup response message, the mobility management network element transparently transmits the identifier of the first application and the charging identifier allocated to the first application to the UE, for example, the IP may be transparently transmitted to the UE. The CAN bearers the PC0 in the response message.
19、 UE收到第一应用的标识和为第一应用分配的计费标识后, 在第一应 用的上行数据包中添加该计费标识, 并将添加计费标识的第一应用的上行数 据包发送给 PCEF实体。  After receiving the identifier of the first application and the charging identifier allocated for the first application, the UE adds the charging identifier to the uplink data packet of the first application, and adds the uplink data of the first application of the charging identifier. The package is sent to the PCEF entity.
20、 PCEF实体收到 UE发送的携带有计费标识的上行数据包时, 对接收 到的数据包执行单独计费。  20. When receiving the uplink data packet carrying the charging identifier sent by the UE, the PCEF entity performs separate charging on the received data packet.
通过本实施例的方法, PCEF实体收到 UE发送的上行数据包后, 能够通过其 携带的计费标识获知该上行数据包属于需要进行计费的第一应用, 从而实现 在上行方向上对第一应用的单独计费。 另外, PCEF实体收到 TDF实体发送的 下行数据包后, 能够通过其携带的计费标识获知该下行数据包属于需要进行 计费的第一应用, 从而实现在下行方向上对第一应用的单独计费。 另外, 本 实施例提供的计费方法在 PCEF实体上实现,与现有技术中基于 SDF的计费在 同一设备上执行, 因此, 不存在重复计费造成的计费不准确的问题。  After receiving the uplink data packet sent by the UE, the PCEF entity can learn, by using the charging identifier carried by the PCEF, that the uplink data packet belongs to the first application that needs to be charged, thereby implementing the uplink application in the uplink direction. Separate billing for an application. In addition, after receiving the downlink data packet sent by the TDF entity, the PCEF entity can learn that the downlink data packet belongs to the first application that needs to be charged by using the charging identifier carried by the PCEF entity, thereby implementing a separate application for the first application in the downlink direction. fee. In addition, the charging method provided in this embodiment is implemented on the PCEF entity, and the SDF-based charging in the prior art is performed on the same device. Therefore, there is no problem of charging inaccuracy caused by repeated charging.
图 4为本发明实施例提供的另一种计费方法的流程图。 如图 4所示, 所 述方法包括:  FIG. 4 is a flowchart of another charging method according to an embodiment of the present invention. As shown in Figure 4, the method includes:
41、 TDF实体探测到需计费的第一应用的数据包时, 向 PCRF实体上报业 务流探测事件, 该业务流探测事件包括第一应用的标识等信息。  When the TDF entity detects the data packet of the first application to be charged, the TSF entity reports the service flow detection event to the PCRF entity, where the service flow detection event includes information such as the identifier of the first application.
具体的, TDF实体可以根据 PCRF实体之前下发的对数据包的探测规则, 对接收到的数据包进行探测。 基于此, TDF 实体可以探测到哪些应用的数据 包需要进行单独计费。 具体需要对哪些应用进行单独进行计费可以根据运营 商的要求而定。 其中, 第一应用可以是任何需要计费的应用。 当探测到需要 计费的第一应用时, TDF实体向 PCRF实体上报业务流探测事件, 以使 PCRF 实体为第一应用分配计费标识并确定修改 ADC规则。  Specifically, the TDF entity may detect the received data packet according to the detection rule of the data packet sent by the PCRF entity. Based on this, the TDF entity can detect which application packets need to be billed separately. Which applications need to be billed separately can be determined according to the requirements of the operator. The first application may be any application that requires charging. When the first application that needs to be charged is detected, the TDF entity reports the service flow detection event to the PCRF entity, so that the PCRF entity allocates a charging identifier to the first application and determines to modify the ADC rule.
42、 PCRF实体收到业务流探测事件后, 根据其中第一应用的标识确定第 一应用,并为第一应用分配计费标识,例如所分配的计费标识可以是 DSCP值。  After receiving the service flow detection event, the PCRF entity determines the first application according to the identifier of the first application, and allocates a charging identifier to the first application. For example, the allocated charging identifier may be a DSCP value.
其中, 计费标识主要用于标识需要对第一应用的数据包进行计费, 例如 对于 UE来说, 需要在第一应用的上行数据包中添加该计费标识, 对于 PCEF 实体来说, 需要基于该计费标识, 确定需要计费的第一应用以及第一应用的 上行数据包; 而对 TDF实体来说, 需要在第一应用的下行数据包中添加该计 费标识, 对于 PCEF实体来说, 需要基于该计费标识, 确定需要计费的第一应 用以及第一应用的下行数据包。 The charging identifier is mainly used to identify that the data packet of the first application needs to be charged, for example, For the UE, the charging identifier needs to be added to the uplink data packet of the first application. For the PCEF entity, the first application that needs to be charged and the uplink data packet of the first application are determined based on the charging identifier. For the TDF entity, the charging identifier needs to be added to the downlink data packet of the first application. For the PCEF entity, the first application that needs to be charged and the first application are determined based on the charging identifier. Downstream packet.
43、 PCRF实体向 TDF实体发送修改 ADC规则消息, 该消息包括第一应用 的标识 (APPLICATION ID) 以及为第一应用分配的计费标识, 例如 DSCP值。  43. The PCRF entity sends a modified ADC rule message to the TDF entity, where the message includes an identifier of the first application (APPLICATION ID) and a charging identifier assigned to the first application, such as a DSCP value.
可选的, 本实施例提供的方法还可以包括: TDF 实体收到第一应用的标 识和为第一应用分配的计费标识后, 在第一应用的下行数据包中添加该计费 标识, 并将添加计费标识的第一应用的下行数据包发送给 PCEF 实体; PCEF 实体收到 TDF实体发送的携带有计费标识的下行数据包时, 对该类数据包执 行计费。  Optionally, the method provided in this embodiment may further include: after receiving the identifier of the first application and the charging identifier allocated to the first application, the TDF entity adds the charging identifier to the downlink data packet of the first application, And sending the downlink data packet of the first application that adds the charging identifier to the PCEF entity; when receiving the downlink data packet that is sent by the TDF entity and carrying the charging identifier, the PCEF entity performs charging for the data packet.
PCRF实体在为第一应用分配计费标识后, 将第一应用的标识和为第一应 用分配的计费标识提供 TDF实体, 使得 TDF实体可以识别第一应用与分配给 第一应用的计费标识之间的对应关系, 进而便于 TDF在下行方向对该第一应 用按照所述计费标识 (例如 DSCP值) 进行标识, 使得 PCEF实体收到 TDF发 送的下行数据包后能够识别出下行数据包属于需要进行计费的第一应用, 从 而在下行方向上实现对第一应用的单独计费, 且不存在重复计费的问题。  After assigning the charging identifier to the first application, the PCRF entity provides the TDF entity with the identifier of the first application and the charging identifier allocated for the first application, so that the TDF entity can identify the first application and the charging allocated to the first application. Corresponding relationship between the identifiers, so that the TDF can identify the first application according to the charging identifier (for example, a DSCP value) in the downlink direction, so that the PCEF entity can identify the downlink data packet after receiving the downlink data packet sent by the TDF. It belongs to the first application that needs to perform charging, so that separate charging for the first application is implemented in the downlink direction, and there is no problem of repeated charging.
44、 PCRF实体向 PCEF实体发送策略与计费规则消息, 该消息包括第一 应用的标识和为第一应用分配的计费标识。  44. The PCRF entity sends a policy and charging rule message to the PCEF entity, where the message includes an identifier of the first application and a charging identifier allocated for the first application.
其中 , 第一应用 的标识也就是需要计费的应用 的标识 ( Char ged-app 1 i cat i on identifier ) 。  The identifier of the first application is the identifier of the application to be charged (Char ged-app 1 i cat i on identifier ).
PCRF实体在为第一应用分配计费标识后, 一方面将第一应用的标识和为 第一应用分配的计费标识提供给 TDF实体, 另一方面还需要将第一应用的标 识和为第一应用分配的计费标识提供给 PCEF实体, 以便于 PCEF实体基于这 两个信息, 对第一应用的上行和下行数据包进行计费。  After assigning the charging identifier to the first application, the PCRF entity provides the identifier of the first application and the charging identifier allocated for the first application to the TDF entity, and the identifier of the first application is also required to be An application-assigned charging identifier is provided to the PCEF entity, so that the PCEF entity charges the uplink and downlink data packets of the first application based on the two information.
45、 PCEF实体向服务网关设备发送 IP-CAN承载建立请求消息,该 IP-CAN 承载建立请求消息包括第一应用的标识和为第一应用分配的计费标识。  The PCEF entity sends an IP-CAN bearer setup request message to the serving gateway device, where the IP-CAN bearer setup request message includes an identifier of the first application and a charging identifier assigned to the first application.
可选的, PCEF实体可以将第一应用的标识和为第一应用分配的计费标识 添加到 IP-CAN承载建立请求消息中的 PC0中, 提供给服务网关设备。 另外, 本实施例对第一应用的标识的实现不做限定。 举例说明, 如果需 要对新浪(Sina ) 网页的应用数据包计费, 那么可能将胃 . sina. com作为第 一应用的标识包含在 PC0中, 但不限于此。 Optionally, the PCEF entity may add the identifier of the first application and the charging identifier allocated for the first application to the PC0 in the IP-CAN bearer setup request message, and provide the information to the serving gateway device. In addition, this embodiment does not limit the implementation of the identifier of the first application. For example, if it is necessary to charge the application data packet of the Sina (Sina) webpage, it is possible to include the stomach. sina.com as the identifier of the first application in the PC0, but is not limited thereto.
46、服务网关设备接收到 IP-CAN承载建立请求消息后, 经过移动性管理 网元向 UE 透传第一应用的标识和为第一应用分配的计费标识, 例如可以向 After the service gateway device receives the IP-CAN bearer setup request message, the mobility management network element transparently transmits the identifier of the first application and the charging identifier allocated for the first application to the UE, for example,
UE透传 IP-CAN承载建立请求消息中的 PC0。 The UE transparently transmits PC0 in the IP-CAN bearer setup request message.
47、 UE收到第一应用的标识和为第一应用分配的计费标识后, 在第一应 用的上行数据包中添加该计费标识, 并将添加计费标识的第一应用的上行数 据包发送给 PCEF实体。  After receiving the identifier of the first application and the charging identifier allocated for the first application, the UE adds the charging identifier to the uplink data packet of the first application, and adds the uplink data of the first application of the charging identifier. The package is sent to the PCEF entity.
48、 PCEF实体收到 UE发送的携带有计费标识的上行数据包时, 对接收 到的数据包执行单独计费。  48. When receiving the uplink data packet carrying the charging identifier sent by the UE, the PCEF entity performs separate charging on the received data packet.
通过本实施例的方法, PCEF实体收到 UE发送的上行数据包后, 能够通 过其携带的计费标识获知该上行数据包属于需要进行计费的第一应用, 从而 实现在上行方向上对第一应用的单独计费。 另外, PCEF实体收到 TDF实体发 送的下行数据包后, 能够通过其携带的计费标识获知该下行数据包属于需要 进行计费的第一应用, 从而实现在下行方向上对第一应用的单独计费。另外, 本实施例提供的计费方法在 PCEF实体上实现,与现有技术中基于 SDF的计费 在同一设备上执行, 因此, 不存在重复计费造成的计费不准确的问题。  After receiving the uplink data packet sent by the UE, the PCEF entity can learn, by using the charging identifier carried by the PCEF, that the uplink data packet belongs to the first application that needs to be charged, thereby implementing the uplink application in the uplink direction. Separate billing for an application. In addition, after receiving the downlink data packet sent by the TDF entity, the PCEF entity can learn that the downlink data packet belongs to the first application that needs to be charged by using the charging identifier carried by the PCEF entity, thereby implementing a separate application for the first application in the downlink direction. fee. In addition, the charging method provided in this embodiment is implemented on the PCEF entity, and is performed on the same device as the SDF-based charging in the prior art. Therefore, there is no problem of inaccurate charging caused by repeated charging.
本发明提供的第二种计费方法主要针对在 PCEF实体执行基于 SDF粒度的 计费, 当数据包到达 TDF实体后, 由于 TDF实体可能对某些应用执行流控, 引起某些应用的数据包被丢弃而造成计费不准确的问题, 或者针对上下行 IP 地址相同的数据包打相同标识进行计费,但实际需要计费的可能仅是该 IP地 址的部分数据包造成该过量计费的问题而提出的。  The second charging method provided by the present invention is mainly for performing SDF granularity-based charging in a PCEF entity. When a data packet arrives at a TDF entity, the TDF entity may perform flow control on some applications, causing data packets of some applications. The problem that the accounting is inaccurate is discarded, or the same identifier is used for the data packets with the same uplink and downlink IP address for charging. However, the actual charging requirement may be only the partial data packet of the IP address causing the excessive charging. The question was raised.
第二种计费方法的主要思路是: PCEF实体对数据包执行基于 SDF粒度的 计费之后, 当数据包到达 TDF实体时, TDF实体根据 PCRF实体提供的 PCC规 则标识和 /或 SDF模板确定影响 PCEF实体基于 SDF粒度计费结果的第一应用 所属的 SDF和第一应用的数据包的流量,然后通过 PCRF实体将第一应用所属 的 SDF的标识和第一应用的数据包的流量发送给 PCEF实体, 以使所述 PCEF 实体根据第一应用所属的 SDF 的标识和第一应用的数据包的流量调整基于 SDF粒度的计费结果。 基于第二种计费方法的主要思路, 下面分别从 PCRF实体、 PCEF实体以 及 TDF实体的角度详细说明第二种计费方法的流程。 The main idea of the second charging method is: After the PCEF entity performs SDF granularity-based charging on the data packet, when the data packet arrives at the TDF entity, the TDF entity determines the influence according to the PCC rule identifier and/or the SDF template provided by the PCRF entity. The PCEF entity sends the traffic of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF by the PCRF entity, and then sends the traffic of the data packet of the first application to the PCEF by the PCRF entity. An entity, so that the PCEF entity adjusts the SDF granularity based charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application. Based on the main idea of the second charging method, the flow of the second charging method is described in detail from the perspective of the PCRF entity, the PCEF entity, and the TDF entity.
从 PCRF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the PCRF entity includes:
PCRF实体向 TDF实体发送的 PCC规则标识和 /或 SDF模板, 以供 TDF实 体确定影响 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识 和第一应用的数据包的流量;  a PCC rule identifier and/or an SDF template sent by the PCRF entity to the TDF entity, for the TDF entity to determine the identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result and the traffic of the data packet of the first application;
PCRF实体接收 TDF实体发送的根据所述 PCC规则标识和 /或 SDF模板确 定的所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量;  The PCRF entity receives, according to the PCC rule identifier and/or the SDF template, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application sent by the TDF entity;
PCRF实体将所述第一应用所属的 SDF的标识和所述第一应用的数据包的 流量发送给 PCEF实体, 以使所述 PCEF实体基于所述第一应用所属的 SDF的 标识和所述第一应用的数据包的流量对来自 UE的上行数据包的基于 SDF粒度 的计费结果进行调整; 其中, 第一应用的数据包属于来自所述 UE的上行数据 包。  The PCRF entity sends the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity is based on the identifier of the SDF to which the first application belongs and the The traffic of the data packet of an application adjusts the SDF granularity-based charging result of the uplink data packet from the UE; wherein the data packet of the first application belongs to the uplink data packet from the UE.
在一可选实施方式中, PCRF实体向 TDF实体发送的 PCC规则标识和 /或 SDF模板, 包括:  In an optional implementation, the PCC rule identifier and/or the SDF template sent by the PCRF entity to the TDF entity includes:
PCRF实体向 TDF实体发送 TDF会话建立请求消息, 所述 TDF会话建立请 求消息包括所述 PCC规则标识和 /或 SDF模板。  The PCRF entity sends a TDF Session Establishment Request message to the TDF entity, the TDF Session Setup Request message including the PCC Rule Identity and/or SDF Template.
基于上述, PCRF实体向 TDF实体发送 TDF会话建立请求消息之后, 还包 括: PCRF实体接收 TDF实体发送的 TDF会话建立响应消息。  Based on the foregoing, after the PCRF entity sends the TDF session establishment request message to the TDF entity, the method further includes: the PCRF entity receiving the TDF session establishment response message sent by the TDF entity.
在一可选实施方式中, PCRF实体将所述第一应用所属的 SDF的标识和所 述第一应用的数据包的流量发送给 PCEF实体, 包括:  In an optional implementation, the PCRF entity sends the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, including:
PCRF实体向 PCEF实体发送 IP-CAN会话修改请求消息, 所述 IP-CAN会 话修改请求消息包括所述第一应用所属的 SDF的标识和所述第一应用的数据 包的流量。  The PCRF entity sends an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application.
从 PCEF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the PCEF entity includes:
PCEF实体接收 PCRF实体发送的影响 PCEF实体基于 SDF粒度的计费结果 的第一应用所属的 SDF的标识和所述第一应用的数据包的流量; 其中, 所述 第一应用所属的 SDF的标识和所述第一应用的数据包的流量是 TDF实体根据 所述 PCRF实体发送的 PCC规则标识和 /或 SDF模板确定并发送给所述 PCRF实 体的; PCEF实体根据所述第一应用所属的 SDF的标识和所述第一应用的数据包 的流量对基于 SDF粒度的计费结果进行调整; 其中, 第一应用的数据包属于 来自所述 UE的上行数据包。 The PCEF entity receives the identifier of the SDF to which the first application to which the PCEF entity sends the SDF granularity-based charging result, and the traffic of the data packet of the first application, where the PCEF entity receives the identifier of the SDF to which the first application belongs. And the traffic of the data packet of the first application is determined by the TDF entity according to the PCC rule identifier and/or the SDF template sent by the PCRF entity, and sent to the PCRF entity; The PCEF entity adjusts the SDF granularity-based charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application; where the data packet of the first application belongs to the uplink from the UE data pack.
在一可选实施方式中, PCEF实体接收 PCRF实体发送的影响 PCEF实体基 于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用的数据 包的流量之前, 还包括:  In an optional implementation, before receiving, by the PCF entity, the identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity and the traffic of the data packet of the first application, the PCEF entity further includes:
PCEF实体对到达的所有数据包进行基于 SDF粒度的计费。  The PCEF entity performs SDF granularity based charging on all packets arriving.
在一可选实施方式中, PCEF实体接收 PCRF实体发送的影响 PCEF实体基 于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用的数据 包的流量, 包括:  In an optional implementation manner, the PCEF entity receives, by the PCRF entity, the identifier of the SDF that belongs to the first application that affects the charging result of the PCEF entity based on the SDF granularity, and the traffic of the data packet of the first application, including:
PCEF实体接收 PCRF实体发送的 IP-CAN会话修改请求消息,所述 IP-CAN 会话修改请求消息包括所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量。  The PCEF entity receives the IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application.
从 TDF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the TDF entity includes:
TDF实体接收 PCRF实体发送的 PCC规则标识和 /或 SDF模板;  The TDF entity receives the PCC rule identifier and/or the SDF template sent by the PCRF entity;
TDF实体根据所述 PCC规则标识和 /或 SDF模板, 确定影响 PCEF实体基 于 SDF粒度的计费结果的第一应用所属的 SDF的标识和第一应用的数据包的 流量;  The TDF entity determines, according to the PCC rule identifier and/or the SDF template, the identifier of the SDF to which the first application that affects the charging result of the PCEF entity based on the SDF granularity and the traffic of the data packet of the first application;
TDF实体将所述第一应用所属的 SDF的标识和所述第一应用的数据包的 流量通过所述 PCRF实体发送给所述 PCEF实体, 以使所述 PCEF实体基于所述 第一应用所属的 SDF的标识和所述第一应用的数据包的流量对来自 UE的上行 数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包属 于来自所述 UE的上行数据包。  Transmitting, by the TDF entity, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity by using the PCRF entity, so that the PCEF entity is based on the The identifier of the SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the UE, where the data packet of the first application belongs to the uplink data packet from the UE .
在一可选实施方式中, TDF实体接收 PCRF实体发送的 PCC规则标识和 / 或 SDF模板, 包括:  In an optional implementation, the TDF entity receives the PCC rule identifier and/or the SDF template sent by the PCRF entity, including:
TDF实体接收 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建 立请求消息包括所述 PCC规则标识和 /或 SDF模板。  The TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or the SDF template.
基于上述, 可选的, TDF实体接收 PCRF实体发送的 TDF会话建立请求消 息之后, 还包括: TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。  Based on the foregoing, optionally, after receiving the TDF session establishment request message sent by the PCRF entity, the TDF entity further includes: the TDF entity sending a TDF session establishment response message to the PCRF entity.
在一可选实施方式中, TDF实体根据所述 PCC规则标识和 /或 SDF模板, 确定影响 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和 第一应用的数据包的流量, 包括: In an optional implementation, the TDF entity identifies and/or the SDF template according to the PCC rule. Determining the identifier of the SDF to which the first application that affects the charging result of the SDF granularity of the PCEF entity belongs and the traffic of the data packet of the first application, including:
TDF实体根据所述 PCC规则标识指示的 PCC规则, 确定因执行基于应用 的流控而被丢弃的数据包所属的应用作为所述第一应用, 确定所述被丢弃的 数据包的流量作为所述第一应用的数据包的流量, 并确定所述第一应用所属 的 SDF; 或者  Determining, by the TDF entity, the application to which the data packet discarded by performing the application-based flow control belongs as the first application according to the PCC rule indicated by the PCC rule identifier, determining the traffic of the discarded data packet as the The traffic of the data packet of the first application, and determining the SDF to which the first application belongs; or
TDF实体根据所述 SDF模板探测到不需要对来自所述 UE的上行数据包中 具有相同 IP地址信息的所有数据包进行计费时, 从具有相同 IP地址信息的 所有数据包中, 确定实际需要计费的数据包所属的应用作为所述第一应用, 确定实际需要计费的数据包的流量作为所述第一应用的数据包的流量, 并确 定所述第一应用所属的 SDF; 或者,  The TDF entity determines, according to the SDF template, that it is not required to charge all data packets having the same IP address information in the uplink data packet from the UE, and determines actual needs from all data packets having the same IP address information. The application to which the billing data packet belongs is used as the first application, and the traffic of the data packet that needs to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined; or
TDF实体根据所述 SDF模板探测到不需要对来自所述 UE的上行数据包中 具有相同 IP地址信息的所有数据包进行计费时, 从具有相同 IP地址信息的 所有数据包, 确定出不需要计费的数据包所属的应用作为所述第一应用, 确 定不需要计费的数据包的流量作为所述第一应用的数据包的流量, 并确定所 述第一应用所属的 SDF。  When the TDF entity detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the TDF entity determines that it is unnecessary from all data packets having the same IP address information. The application to which the billed data packet belongs is used as the first application, and the traffic of the data packet that does not need to be charged is determined as the traffic of the data packet of the first application, and the SDF to which the first application belongs is determined.
下面从多网元交互的角度, 进一步对本发明提供的第二种计费方法的流 程进行详细描述。  The flow of the second charging method provided by the present invention is further described in detail from the perspective of multi-network element interaction.
图 5为本发明实施例提供的又一种计费方法的流程图。 如图 5所示, 所 述方法包括:  FIG. 5 is a flowchart of still another charging method according to an embodiment of the present invention. As shown in Figure 5, the method includes:
51、 PCRF实体向 TDF实体发送 TDF会话建立请求消息, 该 TDF会话建立 请求消息包括 PCC规则标识 (PCC rule id ) 和 /或 SDF模板。  51. The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes a PCC rule id and/or an SDF template.
其中, PCC规则标识用于指示 PCC规则, 该 PCC规则包括很多信息, 用 于执行业务流控制以及计费规则等。 在本实施例中, 所述计费规则会指示具 体对哪个或哪些应用进行计费。 SDF模板就是一组五元组信息, 用于指示应 用流所走的承载, 通俗来说就是指示应用流应该走在哪个承载中。  The PCC rule identifier is used to indicate a PCC rule, and the PCC rule includes a lot of information, which is used to perform service flow control and charging rules. In this embodiment, the charging rule indicates which application or applications are billed. The SDF template is a set of quintuple information used to indicate the bearer of the application flow. In general, it indicates which bearer the application flow should go in.
52、 TDF实体向 PCRF实体发送 TDF会话建立响应消息。  52. The TDF entity sends a TDF session setup response message to the PCRF entity.
53、 当数据包到达 TDF实体时, TDF实体根据 PCC规则标识和 /或 SDF模 板, 确定第一应用所属的 SDF和所述第一应用的数据包的流量, 以便于 PCEF 实体根据第一应用所属的 SDF和第一应用的数据包的流量调整基于 SDF粒度 的计费结果。 When the data packet arrives at the TDF entity, the TDF entity determines, according to the PCC rule identifier and/or the SDF template, the traffic of the SDF to which the first application belongs and the data packet of the first application, so that the PCEF entity belongs according to the first application. SDF and traffic flow adjustment for the first application based on SDF granularity Billing result.
在本实施例中, TDF实体根据 PCC规则标识所指示的 PCC规则和 /或 SDF 模板, 可以获知需要计费的第一应用所属的 SDF。 第一应用是指影响 PCEF实 体基于 SDF粒度的计费结果的应用, 例如可以是 TDF实体因执行流控而丢弃 的数据包所属的应用, 或者是 TDF实体确定的需要单独计费的应用, 还可以 是 TDF实体确定的不需要单独计费的应用。  In this embodiment, the TDF entity can identify the SDF to which the first application that needs to be charged belongs according to the PCC rule and/or the SDF template indicated by the PCC rule. The first application is an application that affects the SDF granularity-based charging result of the PCEF entity, and may be, for example, an application to which the TDF entity discards the data packet discarded by the flow control, or an application determined by the TDF entity that needs to be separately charged. It can be an application determined by the TDF entity that does not require separate billing.
具体的, 如果 TDF实体根据 PCC规则标识指示的 PCC规则, 确定要执行 基于应用的流控, 比如丢弃某应用的部分数据包, 那么 TDF实体可以根据该 应用的 IP地址等信息确定丢弃的数据包所属的 SDF; 此时, 丢弃数据包所属 的应用即为第一应用。  Specifically, if the TDF entity determines that the application-based flow control is to be performed according to the PCC rule indicated by the PCC rule, for example, discarding part of the data packet of the application, the TDF entity may determine the discarded data packet according to the information such as the IP address of the application. The SDF to which it belongs; At this time, the application to which the dropped packet belongs is the first application.
如果 TDF实体根据 SDF模板探测到并不需要对具有相同 IP地址信息的所 有数据包进行计费时, 从具有相同 IP地址信息的所有数据包中, 确定实际需 要计费的应用的数据包, 并确定需要计费的应用所属的 SDF; 此时, 实际需 要计费的应用即为所述第一应用。 或者, TDF实体还可以从具有相同 IP地址 信息的所有数据包, 确定出不属于实际需要计费的应用的数据包, 并确定这 些不需要计费的数据包所属的 SDF; 此时, 所述不需要计费的数据包所属的 应用即为第一应用。  If the TDF entity detects from the SDF template that it is not required to charge all data packets having the same IP address information, the data packets of the application that actually need to be charged are determined from all the data packets having the same IP address information, and The SDF to which the application that needs to be charged belongs is determined. At this time, the application that actually needs to be charged is the first application. Alternatively, the TDF entity may also determine, from all the data packets having the same IP address information, the data packets that are not in the application that need to be charged, and determine the SDF to which the data packets that do not need to be charged belong; The application to which the data packet that does not need to be charged belongs is the first application.
54、 TDF实体将第一应用所属的 SDF的标识和第一应用的数据包的流量 发送给 PCRF实体。  54. The TDF entity sends the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCRF entity.
55、 PCRF实体向 PCEF实体发送 IP-CAN会话修改请求消息, 所述 IP-CAN 会话修改请求消息包括第一应用所属的 SDF的标识和第一应用的数据包的流  55. The PCRF entity sends an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes the identifier of the SDF to which the first application belongs and the flow of the data packet of the first application.
56、 PCEF实体根据第一应用所属的 SDF的标识和第一应用的数据包的流 量, 对第一应用所属的 SDF的计费结果进行调整, 以达到准确计费的目的。 The PCEF entity adjusts the charging result of the SDF to which the first application belongs according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, so as to achieve accurate charging.
在本实施例中, 在 PCEF实体执行基于 SDF粒度的计费后, TDF实体对该 数据流执行检测, 通过将执行流控而丢弃的数据包所属 SDF的标识以及丢弃 的数据包的流量通过 PCRF实体通知 PCEF实体, 使得 PCEF实体对基于该 SDF 的计费结果进行调整, 或者将具有相同 IP地址信息的数据中, 实际需要计费 的应用所属的 SDF和流量, 或不需要计费的应用所属的 SDF和流量经过 PCRF 实体发送给 PCEF实体, 以便于 PCEF实体对基于 SDF粒度的计费结果进行调 整, 从而达到准确计费的目的, 解决计费不准确的问题。 In this embodiment, after the PCEF entity performs the SDF granularity-based charging, the TDF entity performs detection on the data flow, and the traffic of the SDF that belongs to the data packet that is discarded by performing the flow control and the traffic of the discarded data packet are passed through the PCRF. The entity notifies the PCEF entity, so that the PCEF entity adjusts the charging result based on the SDF, or the data that has the same IP address information, the SDF and the traffic to which the application that actually needs to be charged belongs, or the application that does not need to be charged The SDF and traffic are sent to the PCEF entity through the PCRF entity, so that the PCEF entity adjusts the SDF granularity based charging result. In order to achieve accurate billing, the problem of inaccurate billing is solved.
本发明提供的第三种计费方法主要针对在 PCEF实体执行基于 SDF粒度的 计费, 当数据包到达 TDF实体后, 由于 TDF实体可能对某些应用执行流控, 引起某些应用的数据包被丢弃而造成计费不准确的问题, 或者针对上下行 IP 地址相同的数据包打相同标识进行计费,但实际需要计费的可能仅是该 IP地 址的部分数据包造成该过量计费的问题而提出的。  The third charging method provided by the present invention is mainly for performing SDF granularity-based charging in a PCEF entity. When a data packet arrives at a TDF entity, the TDF entity may perform flow control on some applications, causing data packets of some applications. The problem that the accounting is inaccurate is discarded, or the same identifier is used for the data packets with the same uplink and downlink IP address for charging. However, the actual charging requirement may be only the partial data packet of the IP address causing the excessive charging. The question was raised.
第三种计费方法的主要思路是: 首先, PCRF实体、 PCEF实体和 TDF实体 确定为回流数据分配的计费标识, 该计费标识用于标识回流数据。 PCEF实体 对数据包执行基于 SDF粒度的计费之后, 当数据包到达 TDF实体时, TDF实 体确定回流数据, 并将回流数据打上计费标识后重新发送给 PCEF实体, 使得 PCEF实体基于所述计费标识确定回流数据, 并根据回流数据对基于 SDF粒度 的计费结果进行调整, 以达到准确计费的目的。 其中, 所述回流数据是指影 响 PCEF实体基于 SDF粒度的计费结果的数据。  The main idea of the third charging method is: First, the PCRF entity, the PCEF entity, and the TDF entity determine a charging identifier assigned to the reflow data, and the charging identifier is used to identify the reflow data. After the PCEF entity performs SDF granularity-based charging on the data packet, when the data packet arrives at the TDF entity, the TDF entity determines the reflow data, and re-sends the reflow data to the PCEF entity, so that the PCEF entity is based on the The fee identifier determines the reflow data, and adjusts the SDF granularity based charging result according to the reflow data to achieve accurate charging. The reflow data refers to data that affects the charging result of the PCEF entity based on the SDF granularity.
基于第三种计费方法的主要思路, 下面分别从 TDF实体、 PCEF实体以及 PCRF实体的角度详细说明第二种计费方法的流程。  Based on the main idea of the third charging method, the following describes the flow of the second charging method from the perspective of the TDF entity, the PCEF entity, and the PCRF entity.
从 TDF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the TDF entity includes:
TDF实体接收到 PCEF实体发送的上行数据包后, 确定回流数据, 并为所 述回流数据添加计费标识, 所述回流数据是指所述上行数据包中影响所述 PCEF实体对所述上行数据包基于 SDF粒度的计费结果的数据包;  After receiving the uplink data packet sent by the PCEF entity, the TDF entity determines the reflow data, and adds a charging identifier to the reflow data, where the reflow data refers to affecting the uplink data by the PCEF entity in the uplink data packet. a packet based on the SDF granularity of the charging result;
TDF 实体将携带所述计费标识的回流数据发送给 PCEF 实体, 以使所述 The TDF entity sends the reflow data carrying the charging identifier to the PCEF entity to enable the
PCEF实体根据携带所述计费标识的回流数据, 对所述上行数据包基于 SDF粒 度的计费结果进行调整。 The PCEF entity adjusts the charging result of the uplink data packet based on the SDF granularity according to the reflow data carrying the charging identifier.
在一可选实施方式中, TDF 实体接收到上行数据包后, 确定回流数据, 并为所述回流数据添加计费标识之前, 还包括:  In an optional implementation, after the TDF entity receives the uplink data packet, determines the reflow data, and adds the charging identifier to the reflow data, the method further includes:
TDF实体接收 PCRF实体发送的所述 PCRF实体为所述回流数据分配的所 述计费标识。  The TDF entity receives the charging identifier allocated by the PCRF entity sent by the PCRF entity for the reflow data.
进一步可选的, TDF实体接收 PCRF实体发送的所述 PCRF实体为所述回 流数据分配的所述计费标识, 包括:  Further, optionally, the TDF entity receives the charging identifier that is sent by the PCRF entity to the loopback data, and includes:
TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会 话建立请求消息包括所述计费标识。 基于上述, TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息之 后, 还包括: The TDF entity receives a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier. After the TDF entity receives the TDF session establishment request message sent by the PCRF entity, the method further includes:
TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。  The TDF entity sends a TDF Session Setup Response message to the PCRF entity.
从 PCEF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the PCEF entity includes:
PCEF实体在对上行数据包进行基于 SDF粒度的计费之后, 接收 TDF实体 发送的携带有计费标识的回流数据, 所述回流数据是所述 TDF实体确定的所 述上行数据包中影响所述 PCEF实体对所述上行数据包的基于 SDF粒度的计费 结果的数据包;  After performing the SDF granularity-based charging on the uplink data packet, the PCEF entity receives the reflow data carried by the TDF entity and carries the charging identifier, where the reflow data is in the uplink data packet determined by the TDF entity. a data packet of the SDF granularity based charging result of the uplink data packet by the PCEF entity;
PCEF实体根据所述计费标识确定接收到的是回流数据, 确定所述回流数 据所属的 SDF, 对所述确定的 SDF的计费结果进行调整。  The PCEF entity determines, according to the charging identifier, that the received data is reflow data, determines an SDF to which the reflow data belongs, and adjusts the charging result of the determined SDF.
在一可选实施方式中, PCEF实体接收 TDF实体发送的携带有计费标识的 回流数据之前, 还包括:  In an optional implementation, before receiving the reflow data carried by the TDF entity and carrying the charging identifier, the PCEF entity further includes:
PCEF实体接收 PCRF实体发送的所述 PCRF实体为所述回流数据分配的所 述计费标识。  The PCEF entity receives the charging identifier allocated by the PCRF entity sent by the PCRF entity for the reflow data.
进一步可选的, PCEF实体接收 PCRF实体发送的所述 PCRF实体为所述回 流数据分配的所述计费标识, 包括:  Further, optionally, the PCEF entity receives the charging identifier that is sent by the PCRF entity and is sent by the PCRF entity to the backflow data, and includes:
PCEF实体接收 PCRF实体发送的 IP-CAN会话建立响应消息,所述 IP-CAN 会话建立响应消息包括所述计费标识。  The PCEF entity receives an IP-CAN session setup response message sent by the PCRF entity, and the IP-CAN session setup response message includes the charging identifier.
基于上述, PCEF实体接收 PCRF实体发送的 IP-CAN会话建立响应消息之 前, 还包括:  Based on the foregoing, before the PCEF entity receives the IP-CAN session establishment response message sent by the PCRF entity, the method further includes:
PCEF实体向 PCRF实体发送 IP-CAN会话建立请求消息。  The PCEF entity sends an IP-CAN Session Setup Request message to the PCRF entity.
从 PCRF实体的角度进行描述的方法流程包括:  The method flow described from the perspective of the PCRF entity includes:
PCRF实体确定需要分配给回流数据包的计费标识, 所述回流数据是指上 行数据包中影响 PCEF实体对所述上行数据包的基于 SDF粒度的计费结果的数 据包;  The PCRF entity determines a charging identifier that needs to be allocated to the reflow packet, and the reflow data refers to a packet in the uplink packet that affects the SDF granularity-based charging result of the PCEF entity to the uplink packet;
PCRF实体将所述计费标识发送给 TDF实体和所述 PCEF实体, 以供所述 TDF实体从来自 PCEF实体的所述上行数据包中确定出所述回流数据后在所述 回流数据中添加所述计费标识后向所述 PCEF实体发送, 使所述 PCEF实体根 据所述计费标识确定所述回流数据并基于所述回流数据对所述上行数据包的 基于 SDF粒度的计费结果进行调整。 在一可选实施方式中, PCRF实体将所述计费标识发送给 TDF实体,包括: PCRF实体向 TDF实体发送 TDF会话建立请求消息, 所述 TDF会话建立请 求消息包括所述计费标识。 Sending, by the PCRF entity, the charging identifier to the TDF entity and the PCEF entity, where the TDF entity adds the reflow data to the reflow data after determining the reflow data from the uplink data packet from the PCEF entity After the charging identifier is sent to the PCEF entity, the PCEF entity determines the reflow data according to the charging identifier, and adjusts the SDF granularity-based charging result of the uplink data packet based on the reflow data. . In an optional implementation manner, the PCRF entity sends the charging identifier to the TDF entity, including: the PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the charging identifier.
基于上述, PCRF实体向 TDF实体发送 TDF会话建立请求消息之后, 还包 括: PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。  After the PCRF entity sends the TDF session establishment request message to the TDF entity, the method further includes: the PCRF entity receiving the TDF session establishment response message sent by the TDF entity.
在一可选实施方式中, PCRF实体将所述计费标识发送给 PCEF实体, 包 括:  In an optional implementation, the PCRF entity sends the charging identifier to the PCEF entity, including:
PCRF实体向 PCEF实体发送 IP-CAN会话建立响应消息, 所述 IP-CAN会 话建立响应消息包括所述计费标识。  The PCRF entity sends an IP-CAN session setup response message to the PCEF entity, and the IP-CAN session setup response message includes the charging identifier.
基于上述, PCRF实体向 PCEF实体发送 IP-CAN会话建立响应消息之前, 还包括: PCRF实体接收 PCEF实体发送的 IP-CAN会话建立请求消息。  Based on the foregoing, before the PCRF entity sends the IP-CAN session establishment response message to the PCEF entity, the method further includes: the PCRF entity receiving the IP-CAN session establishment request message sent by the PCEF entity.
下面从多网元交互的角度, 进一步对本发明提供的第三种计费方法的流 程进行详细描述。  The flow of the third charging method provided by the present invention is further described in detail from the perspective of multi-network element interaction.
图 6为本发明实施例提供的又一种计费方法的流程图。 如图 6所示, 所 述方法包括:  FIG. 6 is a flowchart of still another charging method according to an embodiment of the present invention. As shown in Figure 6, the method includes:
61、 PCEF实体接收服务网关设备发送的 IP-CAN承载建立请求消息。 61. The PCEF entity receives an IP-CAN bearer setup request message sent by the serving gateway device.
62、 PCEF实体向 PCRF实体发送 IP-CAN会话建立请求消息。 62. The PCEF entity sends an IP-CAN session establishment request message to the PCRF entity.
63、 PCRF实体确定需要分配给回流数据的计费标识。  63. The PCRF entity determines a charging identifier that needs to be assigned to the reflow data.
在此说明, 本实施例中的回流数据是指影响计费准确性, 用于供 PCEF实 体对基于 SDF粒度的计费结果进行调整的数据,是由 TDF实体返回给 PCEF实 体的, 例如可以是 TDF实体基于应用数据流进行计费后的数据, 或者是 TDF 实体执行流控而丢弃的数据。  It is noted that the reflow data in this embodiment refers to the data that affects the charging accuracy, and is used by the PCEF entity to adjust the SDF granularity-based charging result, which is returned by the TDF entity to the PCEF entity, for example, The TDF entity performs charging based on the application data stream, or data that is discarded by the TDF entity to perform flow control.
其中, PCRF实体为回流数据分配计费标识, 目的一是供 TDF实体标识回 流数据,二是使 PCEF实体基于计费标识从接收到的下行数据中识别出回流数 据。 PCRF实体分配给回流数据的计费标识可以是 DSCP值, 以便于在数据包 的 IP头中的 DSCP位采用相应的值标识该回流数据。  The PCRF entity allocates a charging identifier for the reflow data, and the purpose is to enable the TDF entity to identify the reflow data, and the second is to enable the PCEF entity to identify the reflow data from the received downlink data based on the charging identifier. The charging identifier assigned by the PCRF entity to the reflow data may be a DSCP value so that the DSCP bit in the IP header of the packet identifies the reflow data with a corresponding value.
64、 PCRF实体向 TDF实体发送 TDF会话建立请求消息, 该 TDF会话建立 请求消息包括分配给回流数据的计费标识, 例如 DSCP值。  64. The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes a charging identifier assigned to the reflow data, such as a DSCP value.
65、 TDF实体向 PCRF实体发送 TDF会话建立响应消息。  65. The TDF entity sends a TDF session setup response message to the PCRF entity.
66、 PCRF实体向 PCEF实体发送 IP-CAN会话建立响应消息, 该 IP-CAN 会话建立响应消息包括分配给回流数据的计费标识,例如 DSCP值。至此, PCRF 实体与 TDF实体和 PCEF实体相配合, 为回流数据分配了计费标识, 并分别提 供给了 TDF实体和 PCEF实体, 以便于后续 TDF实体和 PCEF实体基于该回流 数据的计费标识, 进行更加准确的计费操作。 66. The PCRF entity sends an IP-CAN session establishment response message to the PCEF entity, the IP-CAN The session setup response message includes a charging identifier assigned to the reflow data, such as a DSCP value. At this point, the PCRF entity cooperates with the TDF entity and the PCEF entity to allocate a charging identifier for the reflow data, and provides the TDF entity and the PCEF entity respectively, so that the subsequent TDF entity and the PCEF entity are based on the charging identifier of the reflow data. Perform more accurate billing operations.
67、 TDF实体接收到上行数据包后, 确定回流数据, 例如 TDF实体可以 执行流控策略, 确定需要丢弃的上行数据包作为回流数据, 或者 TDF实体将 基于应用数据流计费的应用的上行数据包作为回流数据。  67. After receiving the uplink data packet, the TDF entity determines the reflow data. For example, the TDF entity may perform a flow control policy, determine the uplink data packet to be discarded as the reflow data, or the uplink data of the application that the TDF entity will charge based on the application data flow. The package acts as reflux data.
68、 TDF实体将所确定的回流数据转发给 PCEF实体, 并在回流数据中包 含分配给回流数据的计费标识, 例如 DSCP值等, 以便于 PCEF实体接收到回 流数据时, 能够识别出接收到的是回流数据, 即是 TDF实体丢弃的上行数据 包或 TDF实体基于应用数据流进行计费的上行数据包。  68. The TDF entity forwards the determined reflow data to the PCEF entity, and includes a charging identifier, such as a DSCP value, allocated to the reflow data in the reflow data, so that the PCEF entity can recognize the received data when receiving the reflow data. The reflow data is the uplink data packet discarded by the TDF entity or the uplink data packet that the TDF entity performs charging based on the application data flow.
具体的, TDF实体可以将回流数据的外层 IP头的 IP地址等信息进行反 转, 然后转发给 PCEF实体。  Specifically, the TDF entity may reverse information such as the IP address of the outer IP header of the reflow data, and then forward the information to the PCEF entity.
69、 PCEF实体收到回流数据后, 根据回流数据中的计费标识, 确定接收 到的是回流数据, 则根据回流数据包内层的 IP信息, 例如 IP地址等确定该 回流数据所属的 SDF, 并调整对该 SDF的计费结果, 以便于准确计费。  69. After receiving the reflow data, the PCEF entity determines, according to the charging identifier in the reflow data, that the reflow data is received, determining the SDF to which the reflow data belongs according to the IP information of the inner layer of the reflow packet, such as an IP address. And adjust the billing result for the SDF to facilitate accurate billing.
具体的, PPCEF实体可以统计回流数据的流量, 并从回流数据所属的 SDF 的计费结果中扣除因该回流数据的流量产生的费用, 以达到准确计费的目的。  Specifically, the PPCEF entity can count the traffic of the reflow data, and deduct the fee generated by the traffic of the reflow data from the charging result of the SDF to which the reflow data belongs, so as to achieve accurate charging.
在本实施例中, 预先协商回流数据对应的计费标识, 并定义该计费标识 用于指示 PCEF实体对基于 SDF粒度的计费结果进行调整, 则在 PCEF实体基 于 SDF粒度计费完成后, 数据包到达 TDF实体, TDF实体执行基于应用的流 控或基于应用数据流的计费等操作后, 确定操作的数据包作为回流数据并在 其中携带计费标识, 然后转发给 PCEF实体, 以便于 PCEF实体基于回流数据 中的计费标识确定回流数据, 然后根据回流数据所属的 SDF并调整该 SDF的 计费结果, 达到准确计费的目的。  In this embodiment, the charging identifier corresponding to the reflow data is pre-negotiated, and the charging identifier is used to indicate that the PCEF entity adjusts the SDF granularity-based charging result, after the PCEF entity completes the SDF granularity charging, The data packet arrives at the TDF entity. After the TDF entity performs application-based flow control or application data flow-based charging, the data packet of the operation is determined as the reflow data and carries the charging identifier therein, and then forwarded to the PCEF entity, so as to facilitate The PCEF entity determines the reflow data based on the charging identifier in the reflow data, and then adjusts the charging result of the SDF according to the SDF to which the reflow data belongs, so as to achieve accurate charging.
在此说明, 在图 6所示实施例中, 以上行数据包为例进行了说明, 对于 下行数据包可以采用类似图 6所示实施例的方式进行处理。  Here, in the embodiment shown in Fig. 6, the above data packet is described as an example, and the downlink data packet can be processed in a manner similar to the embodiment shown in Fig. 6.
图 7为本发明实施例提供的一种 PCRF实体的结构示意图。 如图 7所示, 所述 PCRF实体包括: 确定模块 71、 分配模块 72和发送模块 73。  FIG. 7 is a schematic structural diagram of a PCRF entity according to an embodiment of the present invention. As shown in FIG. 7, the PCRF entity includes: a determining module 71, an allocating module 72, and a sending module 73.
确定模块 71, 用于确定需要计费的第一应用。 分配模块 72, 与确定模块 71连接, 用于为确定模块 71确定的所述第一 应用分配计费标识, 所述计费标识用于标识需要对所述第一应用进行单独计 费。 The determining module 71 is configured to determine a first application that needs to be charged. The allocating module 72 is connected to the determining module 71, and configured to allocate a charging identifier to the first application determined by the determining module 71, where the charging identifier is used to identify that the first application needs to be separately charged.
发送模块 73, 与确定模块 71和分配模块 72连接, 用于将确定模块 71 确定的所述第一应用的标识和分配模块 72 为所述第一应用分配的计费标识 分别发送给 UE、 PCEF实体和 TDF实体, 以使所述 UE和所述 TDF实体在所述 第一应用的数据包中添加所述计费标识后发送给所述 PCEF实体,使所述 PCEF 实体基于所述第一应用的标识和为所述第一应用分配的计费标识分别对来自 所述 UE和所述 TDF实体的携带有所述计费标识的数据包进行单独计费。  The sending module 73 is connected to the determining module 71 and the assigning module 72, and is configured to send the identifier of the first application determined by the determining module 71 and the charging identifier allocated by the allocating module 72 to the first application to the UE and the PCEF respectively. An entity and a TDF entity, so that the UE and the TDF entity add the charging identifier to a data packet of the first application, and then send the charging identifier to the PCEF entity, so that the PCEF entity is based on the first application. The identifier and the charging identifier allocated for the first application separately charge the data packet carrying the charging identifier from the UE and the TDF entity separately.
在一可选实施方式中,发送模块 73用于将所述第一应用的标识和为所述 第一应用分配的计费标识分别发送给 UE和 PCEF实体, 包括:  In an optional implementation, the sending module 73 is configured to send the identifier of the first application and the charging identifier allocated to the first application to the UE and the PCEF entity, respectively, including:
发送模块 73具体用于向所述 PCEF实体发送 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述第一应用的标识和为所述第一应用 的分配的计费标识, 以使所述 PCEF实体通过服务网关设备将所述第一应用的 标识和为所述第一应用分配的计费标识发送给所述 UE。  The sending module 73 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application. And sending, by the serving gateway device, the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
在一可选实施方式中,发送模块 73将所述第一应用的标识和为所述第一 应用分配的计费标识 TDF实体, 包括:  In an optional implementation, the sending module 73 adds the identifier of the first application and the charging identifier TDF entity allocated for the first application, including:
发送模块 73具体用于向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用分配的计 费标识。  The sending module 73 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes an identifier of the first application and a subscription identifier allocated for the first application.
在一可选实施方式中,确定模块 71具体用于接收所述 TDF实体发送的业 务流探测事件, 所述业务流探测事件是所述 TDF实体探测到需要计费的所述 第一应用的数据包后发送的, 且所述业务流探测事件包括所述第一应用的标 识; 根据所述第一应用的标识确定所述第一应用。  In an optional implementation, the determining module 71 is specifically configured to receive a service flow detection event sent by the TDF entity, where the service flow detection event is that the TDF entity detects data of the first application that needs to be charged. After the packet is sent, the service flow detection event includes an identifier of the first application; and the first application is determined according to the identifier of the first application.
在上述业务流探测事件的基础上,发送模块 73用于将所述第一应用的标 识和为所述第一应用分配的计费标识分别发送给 UE和 PCEF实体, 包括: 发送模块 73具体用于向所述 PCEF实体发送策略与计费规则消息, 所述 策略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费 标识, 以使所述 PCEF实体通过服务网关设备将所述第一应用的标识和为所述 第一应用分配的计费标识发送给所述 UE。 在上述业务流探测事件的基础上,发送模块 73用于将所述第一应用的标 识和为所述第一应用分配的计费标识 TDF实体, 包括: On the basis of the service flow detection event, the sending module 73 is configured to send the identifier of the first application and the charging identifier allocated to the first application to the UE and the PCEF entity, respectively. Sending a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, so that the PCEF entity passes The serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE. On the basis of the service flow detection event, the sending module 73 is configured to: use the identifier of the first application and the charging identifier TDF entity allocated to the first application, including:
发送模块 73具体用于向所述 TDF实体发送修改 ADC规则消息,所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配的计费标识。  The sending module 73 is specifically configured to send a modified ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
进一步可选的, 所述 PCEF实体还可以包括: 接收模块。 该接收模块可用 于在发送模块 73向所述 PCEF实体发送 IP-CAN会话建立响应消息之前,接收 所述 PCEF实体发送 IP-CAN会话建立请求消息。 或者, 接收模块还用于在发 送模块 73向所述 TDF实体发送 TDF会话建立请求消息之后,接收所述 TDF实 体发送的 TDF会话建立响应消息。  Further optionally, the PCEF entity may further include: a receiving module. The receiving module can be configured to receive the IP-CAN session establishment request message by the PCEF entity before the sending module 73 sends an IP-CAN session establishment response message to the PCEF entity. Alternatively, the receiving module is further configured to: after the sending module 73 sends a TDF session establishment request message to the TDF entity, receive a TDF session establishment response message sent by the TDF entity.
本实施例提供的 PCRF 实体的各功能模块可用于执行上述方法实施例中 第一种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The functional modules of the PCRF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiments. The specific working principle is not described here. For details, refer to the description of the method embodiments.
本实施例提供的 PCRF实体, 确定需要计费的第一应用, 并为第一应用分 配计费标识, 通过所述计费标识标识需要对第一应用进行单独计费, 然后将 第一应用的标识和为第一应用分配的计费标识分别发送给 TDF实体、 PCEF实 体和 UE, 使得 UE和 TDF实体在发送给 PCEF实体的第一应用的数据包中添加 所述计费标识,而 PCEF实体就可以对接收到的携带有所述计费标识的数据包 进行单独计费, 实现在上行方向对第一应用的单独计费。 另外, 本实施例提 供的 PCRF 实体通过为第一应用分配计费标识因为可以标识第一应用的数据 包, 因此不存在重复计费的问题。  The PCRF entity provided in this embodiment determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier needs to separately charge the first application, and then the first application is And the charging identifier assigned to the first application is sent to the TDF entity, the PCEF entity, and the UE, respectively, so that the UE and the TDF entity add the charging identifier to the data packet of the first application sent to the PCEF entity, and the PCEF entity The received data packet carrying the charging identifier can be separately charged to implement separate charging for the first application in the uplink direction. In addition, the PCRF entity provided in this embodiment does not have the problem of repeated charging by assigning a charging identifier to the first application because the data packet of the first application can be identified.
图 8为本发明实施例提供的另一种 PCRF实体的结构示意图。如图 8所示, 所述 PCRF实体包括: 处理器 81、 发射器 82和存储器 83。  FIG. 8 is a schematic structural diagram of another PCRF entity according to an embodiment of the present invention. As shown in FIG. 8, the PCRF entity includes: a processor 81, a transmitter 82, and a memory 83.
存储器 83可以包括只读存储器和随机存取存储器, 并向处理器 81提供 指令和数据。 存储器 83 的一部分还可以包括非易失性随机存取存储器 (NVRAM)  Memory 83 can include read only memory and random access memory and provides instructions and data to processor 81. A portion of the memory 83 may also include non-volatile random access memory (NVRAM)
存储器 83存储了如下的元素, 可执行模块或者数据结构, 或者它们的子 集, 或者它们的扩展集:  Memory 83 stores the following elements, executable modules or data structures, or a subset thereof, or their extended set:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 81通过调用存储器 83存储的操作指令 (该 操作指令可存储在操作***中) , 执行如下操作: In the embodiment of the present invention, the processor 81 calls the operation instruction stored in the memory 83 (the The operation instructions can be stored in the operating system), and the following operations are performed:
确定需要计费的第一应用, 并为所述第一应用分配计费标识, 所述计费 标识用于标识需要对所述第一应用进行单独计费。  Determining a first application that needs to be charged, and assigning a charging identifier to the first application, where the charging identifier is used to identify that the first application needs to be separately charged.
发射器 82, 用于将处理器 81确定的所述第一应用的标识和处理器 81为 所述第一应用分配的计费标识分别发送给 UE、 PCEF实体和 TDF实体, 以使所 述 UE和所述 TDF实体在所述第一应用的数据包中添加所述计费标识后发送给 所述 PCEF实体, 使所述 PCEF实体基于所述第一应用的标识和为所述第一应 用分配的计费标识分别对来自所述 UE和所述 TDF实体的携带有所述计费标识 的数据包进行单独计费。  The transmitter 82 is configured to send the identifier of the first application determined by the processor 81 and the charging identifier allocated by the processor 81 to the first application to the UE, the PCEF entity, and the TDF entity, respectively, to enable the UE And the TDF entity adds the charging identifier to the data packet of the first application, and sends the charging identifier to the PCEF entity, so that the PCEF entity allocates the first application according to the identifier of the first application. The charging identifier separately charges the data packet carrying the charging identifier from the UE and the TDF entity.
进一步, 如图 8所示, 所述 PCRF实体还可以包括: 接收器 84。  Further, as shown in FIG. 8, the PCRF entity may further include: a receiver 84.
处理器 81控制 PCRF实体的操作, 处理器 81还可以称为中央处理单元 (Central Processing Unit , 简称为 CPU) 。 存储器 83可以包括只读存储 器和随机存取存储器, 并向处理器 81提供指令和数据。 存储器 83的一部分 还可以包括非易失性随机存取存储器 (NVRAM) 。 具体的应用中, PCRF 实体 的各个组件通过总线*** 85耦合在一起, 其中总线*** 85除包括数据总线 之外, 还可以包括电源总线、 控制总线和状态信号总线等。 但是为了清楚说 明起见, 在图中将各种总线都标为总线*** 85。  The processor 81 controls the operation of the PCRF entity, and the processor 81 may also be referred to as a Central Processing Unit (CPU). Memory 83 can include read only memory and random access memory and provides instructions and data to processor 81. A portion of the memory 83 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the PCRF entity are coupled together by a bus system 85. The bus system 85 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 85 in the figure.
上述本发明实施例揭示的方法可以应用于处理器 81 中, 或者由处理器 81 实现。 处理器 81可能是一种集成电路芯片, 具有信号的处理能力。 在实 现过程中,上述方法的各步骤可以通过处理器 81中的硬件的集成逻辑电路或 者软件形式的指令完成。上述的处理器 81可以是通用处理器、数字信号处理 器 (DSP) 、 专用集成电路 (ASIC) 、 现成可编程门阵列 (FPGA) 或者其他可 编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用处理器可 以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本发明实施 例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译 码处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储器、 寄存器 等本领域成熟的存储介质中。 该存储介质位于存储器 83, 处理器 81读取存 储器 83中的信息, 结合其硬件完成上述方法的步骤。  The method disclosed in the foregoing embodiments of the present invention may be applied to the processor 81 or implemented by the processor 81. Processor 81 may be an integrated circuit chip with signal processing capabilities. In the implementation process, the steps of the above method may be completed by an integrated logic circuit of hardware in the processor 81 or an instruction in the form of software. The processor 81 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by the hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 83, and the processor 81 reads the information in the memory 83 and combines the hardware to perform the steps of the above method.
在一可选实施方式中,发射器 82用于将所述第一应用的标识和为所述第 一应用分配的计费标识分别发送给 UE和 PCEF实体, 包括: In an optional implementation, the transmitter 82 is configured to identify the identifier of the first application as the first The charging identifiers allocated by the application are respectively sent to the UE and the PCEF entity, including:
发射器 82具体用于向所述 PCEF实体发送 IP-CAN会话建立响应消息,所 述 IP-CAN会话建立响应消息包括所述第一应用的标识和为所述第一应用的 分配的计费标识, 以使所述 PCEF实体通过服务网关设备将所述第一应用的标 识和为所述第一应用分配的计费标识发送给所述 UE。  The transmitter 82 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application. And sending, by the serving gateway device, the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
在一可选实施方式中,发射器 82将所述第一应用的标识和为所述第一应 用分配的计费标识 TDF实体, 包括:  In an optional implementation, the transmitter 82 identifies the identifier of the first application and the charging identifier TDF entity allocated for the first application, including:
发射器 82具体用于向所述 TDF实体发送 TDF会话建立请求消息, 所述 The transmitter 82 is specifically configured to send a TDF session establishment request message to the TDF entity, where
TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用分配的计 费标识。 The TDF session establishment request message includes an identifier of the first application and a subscription identifier assigned to the first application.
在一可选实施方式中, 处理器 81具体用于通过接收器 84接收所述 TDF 实体发送的业务流探测事件, 所述业务流探测事件是所述 TDF实体探测到需 要计费的所述第一应用的数据包后发送的, 且所述业务流探测事件包括所述 第一应用的标识;然后根据接收器 84接收的所述第一应用的标识确定所述第 一应用。  In an optional implementation, the processor 81 is specifically configured to receive, by the receiver 84, a service flow detection event sent by the TDF entity, where the service flow detection event is that the TDF entity detects that the charging is required. And transmitting, after the data packet of the application, the service flow detection event includes an identifier of the first application; and determining the first application according to the identifier of the first application received by the receiver 84.
在上述业务流探测事件的基础上,发射器 82用于将所述第一应用的标识 和为所述第一应用分配的计费标识分别发送给 UE和 PCEF实体, 包括:  On the basis of the service flow detection event, the transmitter 82 is configured to send the identifier of the first application and the charging identifier allocated to the first application to the UE and the PCEF entity, respectively, including:
发射器 82具体用于向所述 PCEF实体发送策略与计费规则消息, 所述策 略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费标 识, 以使所述 PCEF实体通过服务网关设备将所述第一应用的标识和为所述第 一应用分配的计费标识发送给所述 UE。  The transmitter 82 is specifically configured to send a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated to the first application, so that The PCEF entity sends the identifier of the first application and the charging identifier allocated for the first application to the UE by using a serving gateway device.
在上述业务流探测事件的基础上,发射器 82用于将所述第一应用的标识 和为所述第一应用分配的计费标识 TDF实体, 包括:  Based on the foregoing service flow detection event, the transmitter 82 is configured to: use the identifier of the first application and the charging identifier TDF entity allocated for the first application, including:
发射器 82具体用于向所述 TDF实体发送修改 ADC规则消息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配的计费标识。  The transmitter 82 is specifically configured to send a modified ADC rule message to the TDF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
进一步可选的, 接收器 84 可用于在发射器 82 向所述 PCEF 实体发送 IP-CAN会话建立响应消息之前, 接收所述 PCEF实体发送 IP-CAN会话建立请 求消息。 或者, 接收器 84还用于在发射器 82向所述 TDF实体发送 TDF会话 建立请求消息之后, 接收所述 TDF实体发送的 TDF会话建立响应消息。  Further optionally, the receiver 84 is configured to receive the IP-CAN session establishment request message by the PCEF entity before the transmitter 82 sends the IP-CAN session establishment response message to the PCEF entity. Alternatively, the receiver 84 is further configured to: after the transmitter 82 sends a TDF session establishment request message to the TDF entity, receive a TDF session establishment response message sent by the TDF entity.
本实施例提供的 PCRF 实体可用于执行上述方法实施例中第一种计费方 法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。 The PCRF entity provided in this embodiment may be used to perform the first charging party in the foregoing method embodiment. The specific working principle of the method of the method will not be described again. For details, refer to the description of the method embodiment.
本实施例提供的 PCRF实体, 确定需要计费的第一应用, 并为第一应用分 配计费标识, 通过所述计费标识标识需要对第一应用进行单独计费, 然后将 第一应用的标识和为第一应用分配的计费标识分别发送给 TDF实体、 PCEF实 体和 UE, 使得 UE和 TDF实体在发送给 PCEF实体的第一应用的数据包中添加 所述计费标识,而 PCEF实体就可以对接收到的携带有所述计费标识的数据包 进行单独计费, 实现在上行方向对第一应用的单独计费。 另外, 本实施例提 供的 PCRF 实体通过为第一应用分配计费标识因为可以标识第一应用的数据 包, 因此不存在重复计费的问题。  The PCRF entity provided in this embodiment determines a first application that needs to be charged, and allocates a charging identifier to the first application, where the charging identifier needs to separately charge the first application, and then the first application is And the charging identifier assigned to the first application is sent to the TDF entity, the PCEF entity, and the UE, respectively, so that the UE and the TDF entity add the charging identifier to the data packet of the first application sent to the PCEF entity, and the PCEF entity The received data packet carrying the charging identifier can be separately charged to implement separate charging for the first application in the uplink direction. In addition, the PCRF entity provided in this embodiment does not have the problem of repeated charging by assigning a charging identifier to the first application because the data packet of the first application can be identified.
图 9为本发明实施例提供的一种 PCEF实体的结构示意图。 如图 9所示, 所述 PCEF实体包括: 接收模块 91、 发送模块 92和计费模块 93。  FIG. 9 is a schematic structural diagram of a PCEF entity according to an embodiment of the present invention. As shown in FIG. 9, the PCEF entity includes: a receiving module 91, a sending module 92, and a billing module 93.
接收模块 91, 用于接收 PCRF实体发送的所述 PCRF实体确定的需要单独 计费的第一应用的标识和为所述第一应用分配的计费标识。  The receiving module 91 is configured to receive, by the PCRF entity, an identifier of the first application that needs to be separately charged, and a charging identifier that is allocated to the first application.
发送模块 92, 与接收模块 91连接, 用于将接收模块 91接收的所述第一 应用的标识和为所述第一应用分配的计费标识通过服务网关设备发送给 UE , 以使所述 UE 在所述第一应用的上行数据包中添加所述计费标识后向所述 PCEF实体发送。  The sending module 92 is connected to the receiving module 91, and configured to send, by the serving gateway device, the identifier of the first application received by the receiving module 91 and the charging identifier allocated to the first application to the UE, so that the UE And adding the charging identifier to the uplink data packet of the first application, and sending the identifier to the PCEF entity.
接收模块 91, 还用于接收所述 UE发送的携带有所述计费标识的上行数 据包。  The receiving module 91 is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier.
计费模块 93, 与接收模块 91连接, 用于根据接收模块 91接收的所述计 费标识对接收模块 91 接收的携带有所述计费标识的上行数据包进行单独计 费。  The charging module 93 is connected to the receiving module 91, and is configured to separately charge the uplink data packet that is received by the receiving module 91 and that carries the charging identifier according to the charging identifier received by the receiving module 91.
在一可选实施方式中,接收模块 91还用于接收 TDF实体发送的携带有所 述计费标识的下行数据包。  In an optional implementation, the receiving module 91 is further configured to receive a downlink data packet that is sent by the TDF entity and that carries the charging identifier.
相应的, 计费模块 93, 还用于根据接收模块 91接收的所述计费标识对 接收模块 91接收的携带有所述计费标识的下行数据包进行单独计费。  Correspondingly, the charging module 93 is further configured to separately charge the downlink data packet that is received by the receiving module 91 and that carries the charging identifier according to the charging identifier received by the receiving module 91.
在一可选实施方式中, 接收模块 91用于接收 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识, 包括:  In an optional implementation, the receiving module 91 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
接收模块 91具体用于接收所述 PCRF实体发送的 IP-CAN会话建立响应消 息,所述 IP-CAN会话建立响应消息包括所述第一应用的标识和为所述第一应 用的分配的计费标识; 或者 The receiving module 91 is specifically configured to receive an IP-CAN session establishment response sent by the PCRF entity. The IP-CAN session establishment response message includes an identifier of the first application and an allocated charging identifier for the first application; or
接收模块 91具体用于接收所述 PCRF实体发送的策略与计费规则消息, 所述策略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的 计费标识。  The receiving module 91 is specifically configured to receive the policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
可选的, 发送模块 92还用于在接收模块 91接收所述 PCRF实体发送的 IP-CAN会话建立响应消息之前, 向所述 PCRF实体发送 IP-CAN会话建立请求 消息。  Optionally, the sending module 92 is further configured to send an IP-CAN session establishment request message to the PCRF entity before the receiving module 91 receives the IP-CAN session setup response message sent by the PCRF entity.
在一可选实施方式中,发送模块 92用于将所述第一应用的标识和为所述 第一应用分配的计费标识通过服务网关设备发送给 UE, 包括:  In an optional implementation, the sending module 92 is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
发送模块 92具体用于向所述服务网关设备发送 IP-CAN承载建立响应消 息,所述 IP-CAN承载建立响应消息包括所述第一应用的标识和为所述第一应 用分配的计费标识, 以使所述服务网关设备将所述第一应用的标识和为所述 第一应用分配的计费标识发送给所述 UE。  The sending module 92 is specifically configured to send an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier allocated to the first application. So that the serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE.
可选的, 接收模块 91 还用于在发送模块 92 向所述服务网关设备发送 Optionally, the receiving module 91 is further configured to send, at the sending module 92, the serving gateway device.
IP-CAN承载建立响应消息之前, 接收所述服务网关设备发送的 IP-CAN承载 建立请求消息。 Before the IP-CAN bearer setup response message, the IP-CAN bearer setup request message sent by the serving gateway device is received.
本实施例提供的 PCEF 实体的各功能模块可用于执行上述方法实施例中 第一种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The function modules of the PCEF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiments. The specific working principle is not described here. For details, refer to the description of the method embodiments.
本实施例提供的 PCEF实体, 接收由 PCRF实体确定的需要单独计费的第 一应用的标识和为第一应用分配的计费标识, 根据第一应用的标识和为第一 应用分配的计费标识,对来自于 UE或 TDF实体的携带有所述计费标识的第一 应用的数据包进行单独计费, 并且由于通过所述计费标识可以标识第一应用 的数据包, 不会出现重复计费的问题。  The PCEF entity provided in this embodiment receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, according to the identifier of the first application and the accounting allocated for the first application. Identifying, separately charging, for the data packet of the first application that carries the charging identifier from the UE or the TDF entity, and because the data packet of the first application can be identified by using the charging identifier, there is no repetition Billing issue.
图 10为本发明实施例提供的另一种 PCEF实体的结构示意图。如图 10所 述, 所述 PCEF实体包括: 接收器 1001、 发射器 1002、 处理器 1003和存储器 1004。  FIG. 10 is a schematic structural diagram of another PCEF entity according to an embodiment of the present invention. As shown in FIG. 10, the PCEF entity includes: a receiver 1001, a transmitter 1002, a processor 1003, and a memory 1004.
接收器 1001, 用于接收 PCRF实体发送的所述 PCRF实体确定的需要单独 计费的第一应用的标识和为所述第一应用分配的计费标识。  The receiver 1001 is configured to receive, by the PCRF entity, an identifier of the first application that needs to be separately charged, and a charging identifier that is allocated to the first application.
发射器 1002, 用于将接收器 1001接收的所述第一应用的标识和为所述 第一应用分配的计费标识通过服务网关设备发送给 UE, 以使所述 UE在所述 第一应用的上行数据包中添加所述计费标识后向所述 PCEF实体发送。 a transmitter 1002, configured to use the identifier of the first application received by the receiver 1001 as The charging identifier of the first application is sent to the UE by the serving gateway device, so that the UE sends the charging identifier to the PCEF entity after adding the charging identifier to the uplink data packet of the first application.
接收器 1001, 还用于接收所述 UE发送的携带有所述计费标识的上行数 据包。  The receiver 1001 is further configured to receive an uplink data packet that is sent by the UE and that carries the charging identifier.
存储器 1004可以包括只读存储器和随机存取存储器, 并向处理器 1003 提供指令和数据。存储器 1004的一部分还可以包括非易失性随机存取存储器 (NVRAM) o  Memory 1004 can include read only memory and random access memory and provides instructions and data to processor 1003. A portion of memory 1004 may also include non-volatile random access memory (NVRAM) o
存储器 1004存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  Memory 1004 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 1003通过调用存储器 1004存储的操作指令 (该操作指令可存储在操作***中) , 执行如下操作:  In the embodiment of the present invention, the processor 1003 performs the following operations by calling an operation instruction stored in the memory 1004 (the operation instruction can be stored in the operating system):
根据接收器 1001接收的所述计费标识对接收器 1001接收的携带有所述 计费标识的上行数据包进行单独计费。  The uplink data packet that is received by the receiver 1001 and carries the charging identifier is separately charged according to the charging identifier received by the receiver 1001.
处理器 1003控制 PCEF实体的操作, 处理器 1003还可以称为 CPU。 存储 器 1004可以包括只读存储器和随机存取存储器, 并向处理器 1003提供指令 和数据。存储器 1004的一部分还可以包括非易失性随机存取存储器(NVRAM)。 具体的应用中, PCEF实体的各个组件通过总线*** 1005耦合在一起, 其中 总线*** 1005除包括数据总线之外, 还可以包括电源总线、控制总线和状态 信号总线等。 但是为了清楚说明起见, 在图中将各种总线都标为总线*** 上述本发明实施例揭示的方法可以应用于处理器 1003中,或者由处理器 1003实现。 处理器 1003可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 1003中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 1003可以是通用处理器、数字 信号处理器 (DSP) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 1004, 处理 器 1003读取存储器 1004中的信息, 结合其硬件完成上述方法的步骤。 The processor 1003 controls the operation of the PCEF entity, which may also be referred to as a CPU. The memory 1004 can include read only memory and random access memory and provides instructions and data to the processor 1003. A portion of the memory 1004 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the PCEF entity are coupled together by a bus system 1005. The bus system 1005 may include a power bus, a control bus, a status signal bus, and the like in addition to the data bus. However, for clarity of description, various buses are labeled as a bus system in the figure. The method disclosed in the above embodiments of the present invention may be applied to the processor 1003 or implemented by the processor 1003. The processor 1003 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 1003 or an instruction in a form of software. The processor 1003 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. Combined with this The steps of the method disclosed in the embodiments of the present invention may be directly implemented by the hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 1004. The processor 1003 reads the information in the memory 1004 and completes the steps of the above method in combination with the hardware.
在一可选实施方式中,接收器 1001还用于接收 TDF实体发送的携带有所 述计费标识的下行数据包。  In an optional implementation, the receiver 1001 is further configured to receive a downlink data packet that is sent by the TDF entity and that carries the charging identifier.
相应的, 处理器 1003, 还用于根据接收器 1001接收的所述计费标识对 接收器 1001接收的携带有所述计费标识的下行数据包进行单独计费。  Correspondingly, the processor 1003 is further configured to separately charge the downlink data packet that is received by the receiver 1001 and that carries the charging identifier according to the charging identifier received by the receiver 1001.
在一可选实施方式中, 接收器 1001用于接收 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识, 包括:  In an optional implementation, the receiver 1001 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
接收器 1001具体用于接收所述 PCRF实体发送的 IP-CAN会话建立响应消 息,所述 IP-CAN会话建立响应消息包括所述第一应用的标识和为所述第一应 用的分配的计费标识; 或者  The receiver 1001 is specifically configured to receive an IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes an identifier of the first application and an allocated charging for the first application. Identification; or
接收器 1001具体用于接收所述 PCRF实体发送的策略与计费规则消息, 所述策略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的 计费标识。  The receiver 1001 is specifically configured to receive a policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes an identifier of the first application and a charging identifier allocated for the first application.
可选的, 发射器 1002还用于在接收器 1001接收所述 PCRF实体发送的 IP-CAN会话建立响应消息之前, 向所述 PCRF实体发送 IP-CAN会话建立请求 消息。  Optionally, the transmitter 1002 is further configured to send an IP-CAN session establishment request message to the PCRF entity before the receiver 1001 receives the IP-CAN session establishment response message sent by the PCRF entity.
在一可选实施方式中,发射器 1002用于将所述第一应用的标识和为所述 第一应用分配的计费标识通过服务网关设备发送给 UE, 包括:  In an optional implementation, the transmitter 1002 is configured to send the identifier of the first application and the charging identifier that is allocated to the first application to the UE by using the serving gateway device, including:
发射器 1002具体用于向所述服务网关设备发送 IP-CAN承载建立响应消 息,所述 IP-CAN承载建立响应消息包括所述第一应用的标识和为所述第一应 用分配的计费标识, 以使所述服务网关设备将所述第一应用的标识和为所述 第一应用分配的计费标识发送给所述 UE。  The transmitter 1002 is specifically configured to send an IP-CAN bearer setup response message to the serving gateway device, where the IP-CAN bearer setup response message includes an identifier of the first application and a charging identifier assigned to the first application. So that the serving gateway device sends the identifier of the first application and the charging identifier allocated for the first application to the UE.
可选的, 接收器 1001 还用于在发射器 1002 向所述服务网关设备发送 IP-CAN承载建立响应消息之前, 接收所述服务网关设备发送的 IP-CAN承载 建立请求消息。 本实施例提供的 PCEF 实体可用于执行上述方法实施例中第一种计费方 法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。 Optionally, the receiver 1001 is further configured to receive an IP-CAN bearer setup request message sent by the serving gateway device before the transmitter 1002 sends an IP-CAN bearer setup response message to the serving gateway device. The PCEF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 PCEF实体, 接收由 PCRF实体确定的需要单独计费的第 一应用的标识和为第一应用分配的计费标识, 根据第一应用的标识和为第一 应用分配的计费标识,对来自于 UE或 TDF实体的携带有所述计费标识的第一 应用的数据包进行单独计费, 并且由于通过所述计费标识可以标识第一应用 的数据包, 不会出现重复计费的问题。  The PCEF entity provided in this embodiment receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated to the first application, according to the identifier of the first application and the accounting allocated for the first application. Identifying, separately charging, for the data packet of the first application that carries the charging identifier from the UE or the TDF entity, and because the data packet of the first application can be identified by using the charging identifier, there is no repetition Billing issue.
图 1 1为本发明实施例提供的一种 TDF实体的结构示意图。如图 11所示, 所述 TDF实体包括: 接收模块 1101、 确定添加模块 1102和发送模块 1 103。  FIG. 1 is a schematic structural diagram of a TDF entity according to an embodiment of the present invention. As shown in FIG. 11, the TDF entity includes: a receiving module 1101, a determining adding module 1102, and a sending module 1103.
接收模块 1101, 用于接收 PCRF实体发送的所述 PCRF实体确定的需要单 独计费的第一应用的标识和为所述第一应用分配的计费标识。  The receiving module 1101 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and a charging identifier that is allocated to the first application.
确定添加模块 1102, 与接收模块 1101连接, 用于根据接收模块 1101接 收的所述第一应用的标识确定所述第一应用的下行数据包, 在所述第一应用 的下行数据包中添加接收模块 1101接收的所述计费标识。  The determining module 1102 is configured to be connected to the receiving module 1101, configured to determine, according to the identifier of the first application received by the receiving module 1101, the downlink data packet of the first application, and add and receive the downlink data packet of the first application. The charging identifier received by the module 1101.
发送模块 1 103, 与确定添加模块 1102连接, 用于将添加所述计费标识 的下行数据包发送给 PCEF实体, 以使所述 PCEF实体基于所述计费标识对所 述第一应用的下行数据包进行单独计费。  The sending module 1103 is connected to the determining adding module 1102, and configured to send the downlink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity downlinks the first application based on the charging identifier. Packets are billed separately.
在一可选实施方式中,接收模块 1101用于接收 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识, 包括:  In an optional implementation, the receiving module 1101 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
接收模块 1101具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用 分配的计费标识。  The receiving module 1101 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes an identifier of the first application and a charging identifier allocated for the first application.
可选的,发送模块 1103还用于在接收模块 1101接收所述 PCRF实体发送 的 TDF会话建立请求消息之后, 向 PCRF实体发送 TDF会话建立响应消息。  Optionally, the sending module 1103 is further configured to send a TDF session establishment response message to the PCRF entity after the receiving module 1101 receives the TDF session establishment request message sent by the PCRF entity.
在一可选实施方式中, 所述 PCEF实体还包括: 探测模块, 用于探测需要 单独计费的所述第一应用的数据包。  In an optional implementation manner, the PCEF entity further includes: a detecting module, configured to detect a data packet of the first application that needs to be separately charged.
基于上述探测模块, 发送模块 1103, 还用于在探测模块探测到所述第一 应用的数据包后, 向所述 PCRF实体发送业务流探测事件, 所述业务流探测事 件包括所述第一应用的标识, 以使所述 PCRF实体根据所述第一应用的标识确 定需要对所述第一应用进行单独计费。 The sending module 1103 is further configured to: after the detecting module detects the data packet of the first application, send a service flow detecting event to the PCRF entity, where the service flow detecting event includes the first application The identifier, so that the PCRF entity is determined according to the identifier of the first application. It is necessary to separately charge the first application.
基于上述探测模块,在一可选实施方式中,接收模块 1101用于接收 PCRF 实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述 第一应用分配的计费标识, 包括:  Based on the foregoing detection module, in an optional implementation, the receiving module 1101 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and a charging that is allocated to the first application. Identification, including:
接收模块 1101具体用于接收所述 PCRF实体发送的修改 ADC规则消息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配的计 费标识。  The receiving module 1101 is specifically configured to receive a modified ADC rule message sent by the PCRF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
本实施例提供的 TDF实体的各功能模块可用于执行上述方法实施例中第 一种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The function modules of the TDF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 TDF实体,接收由 PCRF实体确定的需要单独计费的第一 应用的标识和为第一应用分配的计费标识, 根据第一应用的标识和为第一应 用分配的计费标识, 在第一应用的下行数据包中添加所述计费标识后发送给 PCEF实体, 使得 PCEF实体可以根据 PCRF实体发送的第一应用的标识和为第 一应用分配的计费标识, 对来自 TDF实体的携带有所述计费标识的下行数据 包进行单独计费, 实现对第一应用的单独计费, 并且不会出现重复计费的问 题。  The TDF entity provided in this embodiment receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated for the first application, according to the identifier of the first application and the accounting allocated for the first application. The identifier is sent to the PCEF entity in the downlink data packet of the first application, and is sent to the PCEF entity, so that the PCEF entity can be based on the identifier of the first application sent by the PCRF entity and the charging identifier allocated for the first application. The downlink data packet carrying the charging identifier of the TDF entity is separately charged, and the individual charging for the first application is implemented, and the problem of repeated charging does not occur.
图 12为本发明实施例提供的另一种 TDF实体的结构示意图。 如图 12所 示, 所述 TDF实体包括: 接收器 1201、 处理器 1202、 发射器 1203和存储器 1204。  FIG. 12 is a schematic structural diagram of another TDF entity according to an embodiment of the present invention. As shown in FIG. 12, the TDF entity includes: a receiver 1201, a processor 1202, a transmitter 1203, and a memory 1204.
接收器 1201, 用于接收 PCRF实体发送的所述 PCRF实体确定的需要单独 计费的第一应用的标识和为所述第一应用分配的计费标识。  The receiver 1201 is configured to receive, by the PCRF entity, an identifier of the first application that needs to be separately charged, and a charging identifier that is allocated to the first application.
存储器 1204可以包括只读存储器和随机存取存储器, 并向处理器 1202 提供指令和数据。存储器 1204的一部分还可以包括非易失性随机存取存储器 (NVRAM)  Memory 1204 can include read only memory and random access memory and provides instructions and data to processor 1202. A portion of memory 1204 may also include non-volatile random access memory (NVRAM)
存储器 1204存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  Memory 1204 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 1202通过调用存储器 1204存储的操作指令 (该操作指令可存储在操作***中) , 执行如下操作: In the embodiment of the present invention, the processor 1202 calls the operation instruction stored in the memory 1204. (The operation instruction can be stored in the operating system), do the following:
根据接收器 1201 接收的所述第一应用的标识确定所述第一应用的下行 数据包, 在所述第一应用的下行数据包中添加所述接收器接收的所述计费标 识。  Determining a downlink data packet of the first application according to the identifier of the first application received by the receiver 1201, and adding the charging identifier received by the receiver to a downlink data packet of the first application.
发射器 1203, 用于将添加所述计费标识的下行数据包发送给 PCEF实体, 以使所述 PCEF 实体基于所述计费标识对所述第一应用的下行数据包进行单 独计费。  The transmitter 1203 is configured to send the downlink data packet that adds the charging identifier to the PCEF entity, so that the PCEF entity separately charges the downlink data packet of the first application based on the charging identifier.
处理器 1202控制 TDF实体的操作, 处理器 1202还可以称为 CPU。 存储 器 1204可以包括只读存储器和随机存取存储器, 并向处理器 1202提供指令 和数据。存储器 1204的一部分还可以包括非易失性随机存取存储器(NVRAM)。 具体的应用中, TDF实体的各个组件通过总线*** 1205耦合在一起, 其中总 线*** 1205除包括数据总线之外, 还可以包括电源总线、控制总线和状态信 号总线等。但是为了清楚说明起见,在图中将各种总线都标为总线*** 1205。  The processor 1202 controls the operation of the TDF entity, and the processor 1202 may also be referred to as a CPU. Memory 1204 can include read only memory and random access memory and provides instructions and data to processor 1202. A portion of memory 1204 may also include non-volatile random access memory (NVRAM). In a specific application, the various components of the TDF entity are coupled together by a bus system 1205, wherein the bus system 1205 can include, in addition to the data bus, a power bus, a control bus, and a status signal bus. However, for clarity of description, various buses are labeled as bus system 1205 in the figure.
上述本发明实施例揭示的方法可以应用于处理器 1202中,或者由处理器 1202实现。 处理器 1202可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 1202中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 1202可以是通用处理器、数字 信号处理器 (DSP ) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 1204, 处理 器 1202读取存储器 1204中的信息, 结合其硬件完成上述方法的步骤。  The method disclosed in the foregoing embodiments of the present invention may be applied to the processor 1202 or implemented by the processor 1202. Processor 1202 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method may be completed by an integrated logic circuit of hardware in the processor 1202 or an instruction in the form of software. The processor 1202 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in conventional memory, such as random memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 1204, and the processor 1202 reads the information in the memory 1204 and combines the hardware to perform the steps of the above method.
在一可选实施方式中, 接收器 1201用于接收 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识, 包括:  In an optional implementation, the receiver 1201 is configured to receive, by the PCRF entity, an identifier of the first application that is determined by the PCRF entity and that needs to be separately charged, and an accounting identifier that is allocated to the first application, where:
接收器 1201具体用于接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用分配 的计费标识。 The receiver 1201 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes an identifier of the first application and is allocated for the first application. Billing ID.
可选的, 发射器 1203还用于在接收器 1201接收所述 PCRF实体发送的 TDF会话建立请求消息之后, 向 PCRF实体发送 TDF会话建立响应消息。  Optionally, the transmitter 1203 is further configured to send a TDF session establishment response message to the PCRF entity after the receiver 1201 receives the TDF session establishment request message sent by the PCRF entity.
在一可选实施方式中,处理器 1202还用于探测需要单独计费的所述第一 应用的数据包。  In an optional implementation, the processor 1202 is further configured to detect a data packet of the first application that needs to be separately charged.
基于上述, 发射器 1203, 还用于在处理器 1202探测到所述第一应用的 数据包后, 向所述 PCRF实体发送业务流探测事件, 所述业务流探测事件包括 所述第一应用的标识, 以使所述 PCRF实体根据所述第一应用的标识确定需要 对所述第一应用进行单独计费。  Based on the above, the transmitter 1203 is further configured to: after the processor 1202 detects the data packet of the first application, send a service flow detection event to the PCRF entity, where the service flow detection event includes the first application And determining, by the PCRF entity, determining, according to the identifier of the first application, that the first application needs to be separately charged.
基于上述, 在一可选实施方式中, 接收器 1201用于接收 PCRF实体发送 的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用 分配的计费标识, 包括:  Based on the foregoing, in an optional implementation, the receiver 1201 is configured to receive, by the PCRF entity, an identifier of a first application that is separately billed by the PCRF entity and a charging identifier that is allocated to the first application, where Includes:
接收器 1201具体用于接收所述 PCRF实体发送的修改 ADC规则消息, 所 述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配的计费 标识。  The receiver 1201 is specifically configured to receive a modified ADC rule message sent by the PCRF entity, where the modified ADC rule message includes an identifier of the first application and a charging identifier allocated for the first application.
本实施例提供的 TDF实体可用于执行上述方法实施例中第一种计费方法 的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The TDF entity provided in this embodiment may be used to perform the process of the first charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 TDF实体,接收由 PCRF实体确定的需要单独计费的第一 应用的标识和为第一应用分配的计费标识, 根据第一应用的标识和为第一应 用分配的计费标识, 在第一应用的下行数据包中添加所述计费标识后发送给 PCEF实体, 使得 PCEF实体可以根据 PCRF实体发送的第一应用的标识和为第 一应用分配的计费标识, 对来自 TDF实体的携带有所述计费标识的下行数据 包进行单独计费, 实现对第一应用的单独计费, 并且不会出现重复计费的问 题。  The TDF entity provided in this embodiment receives the identifier of the first application that is determined by the PCRF entity and needs to be separately charged, and the charging identifier that is allocated for the first application, according to the identifier of the first application and the accounting allocated for the first application. The identifier is sent to the PCEF entity in the downlink data packet of the first application, and is sent to the PCEF entity, so that the PCEF entity can be based on the identifier of the first application sent by the PCRF entity and the charging identifier allocated for the first application. The downlink data packet carrying the charging identifier of the TDF entity is separately charged, and the individual charging for the first application is implemented, and the problem of repeated charging does not occur.
图 13为本发明实施例提供的又一种 PCRF实体的结构示意图。如图 13所 示, 所述 PCRF实体包括: 发送模块 1301和接收模块 1302。  FIG. 13 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention. As shown in FIG. 13, the PCRF entity includes: a sending module 1301 and a receiving module 1302.
发送模块 1301, 用于向 TDF实体发送的 PCC规则标识和 /或 SDF模板, 以供所述 TDF实体确定影响 PCEF实体基于 SDF粒度的计费结果的第一应用所 属的 SDF的标识和第一应用的数据包的流量。  The sending module 1301 is configured to send the PCC rule identifier and/or the SDF template to the TDF entity, where the TDF entity determines the identifier and the first application of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result belongs The traffic of the packet.
接收模块 1302, 用于接收所述 TDF实体发送的根据所述 PCC规则标识和 /或 SDF模板确定的所述第一应用所属的 SDF的标识和所述第一应用的数据包 的流量。 The receiving module 1302 is configured to receive, according to the PCC rule identifier, sent by the TDF entity, And the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application determined by the SDF template.
发送模块 1301, 与接收模块 1302连接, 还用于将接收模块 1302接收的 所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应用所属的 SDF的标识和所述 第一应用的数据包的流量对来自 UE的上行数据包基于 SDF粒度的计费结果进 行调整; 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。  The sending module 1301 is connected to the receiving module 1302, and is further configured to send, by the receiving module 1302, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that The PCEF entity adjusts the uplink data packet from the UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, where the first application is The data packet belongs to an upstream data packet from the UE.
在一可选实施方式中,发送模块 1301用于向 TDF实体发送的 PCC规则标 识和 /或 SDF模板, 包括:  In an optional implementation, the sending module 1301 is configured to send the PCC rule identifier and/or the SDF template to the TDF entity, including:
发送模块 1301具体用于向所述 TDF实体发送 TDF会话建立请求消息,所 述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。  The sending module 1301 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
可选的,接收模块 1302还用于在发送模块 1301向所述 TDF实体发送 TDF 会话建立请求消息之后, 接收 TDF实体发送的 TDF会话建立响应消息。  Optionally, the receiving module 1302 is further configured to: after the sending module 1301 sends a TDF session establishment request message to the TDF entity, receive a TDF session establishment response message sent by the TDF entity.
在一可选实施方式中,发送模块 1301用于将所述第一应用所属的 SDF的 标识和所述第一应用的数据包的流量发送给所述 PCEF实体, 包括:  In an optional implementation, the sending module 1301 is configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, including:
发送模块 1301具体用于向所述 PCEF实体发送 IP-CAN会话修改请求消 息,所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的标识和所 述第一应用的数据包的流量。  The sending module 1301 is specifically configured to send an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. flow.
本实施例提供的 PCRF 实体的各功能模块可用于执行上述方法实施例中 第二种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The function modules of the PCRF entity provided in this embodiment may be used to perform the process of the second charging method in the foregoing method embodiments. The specific working principle is not described here. For details, refer to the description of the method embodiments.
本实施例提供的 PCRF实体, 向 TDF实体发送 PCC规则标识和 /或 SDF模 板, 使得 TDF实体确定需要单独计费的第一应用的标识和第一应用的数据包 的流量并返回给本实施例的 PCRF实体, 本实施例的 PCRF实体将第一应用的 标识和第一应用的数据包的流量发送给 PCEF实体, 使 PCEF实体根据第一应 用的标识和第一应用的数据包的流量重新对基于 SDF粒度的计费结果进行调 整, 从而实现准确计费。  The PCRF entity provided in this embodiment sends a PCC rule identifier and/or an SDF template to the TDF entity, so that the TDF entity determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and returns the data to the embodiment. The PCRF entity, the PCRF entity of the embodiment sends the identifier of the first application and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity re-pairs according to the identifier of the first application and the traffic of the data packet of the first application. The billing result based on the SDF granularity is adjusted to achieve accurate billing.
图 14为本发明实施例提供的又一种 PCRF实体的结构示意图。如图 14所 示, 所述 PCRF实体包括: 发射器 1401、 接收器 1402、 处理器 1403和存储器 1404。  FIG. 14 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention. As shown in FIG. 14, the PCRF entity includes: a transmitter 1401, a receiver 1402, a processor 1403, and a memory 1404.
发射器 1401, 用于向 TDF实体发送的 PCC规则标识和 /或 SDF模板, 以 供所述 TDF实体确定影响 PCEF实体基于 SDF粒度的计费结果的第一应用所属 的 SDF的标识和第一应用的数据包的流量。 a transmitter 1401, configured to send a PCC rule identifier and/or an SDF template to the TDF entity, And determining, by the TDF entity, an identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result and a traffic of the data packet of the first application.
接收器 1402, 用于接收所述 TDF实体发送的根据所述 PCC规则标识和 / 或 SDF模板确定的所述第一应用所属的 SDF的标识和所述第一应用的数据包 的流量。  The receiver 1402 is configured to receive, by the TDF entity, the identifier of the SDF to which the first application belongs according to the PCC rule identifier and/or the SDF template, and the traffic of the data packet of the first application.
发射器 1401, 还用于将所述第一应用所属的 SDF的标识和所述第一应用 的数据包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应 用所属的 SDF的标识和所述第一应用的数据包的流量对来自 UE的上行数据包 基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包属于来自 所述 UE的上行数据包。  The transmitter 1401 is further configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity is based on the first application belongs to The identifier of the SDF and the traffic of the data packet of the first application are adjusted according to the SDF granularity charging result of the uplink data packet from the UE, where the data packet of the first application belongs to the uplink data packet from the UE .
在本实施例中, 存储器 1404可以包括只读存储器和随机存取存储器, 并 向处理器 1403提供指令和数据。 存储器 1404的一部分还可以包括非易失性 随机存取存储器 (NVRAM) 。  In the present embodiment, the memory 1404 can include read only memory and random access memory, and provides instructions and data to the processor 1403. A portion of memory 1404 may also include non-volatile random access memory (NVRAM).
存储器 1404存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  Memory 1404 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 1403通过调用存储器 1404存储的操作指令 (该操作指令可存储在操作***中) , 执行相应操作, 从而控制 PCRF实体的 操作。  In the embodiment of the present invention, the processor 1403 performs a corresponding operation by calling an operation instruction stored in the memory 1404 (which can be stored in the operating system), thereby controlling the operation of the PCRF entity.
处理器 1403控制 PCRF实体的操作, 处理器 1403还可以称为 CPU。 存储 器 1404可以包括只读存储器和随机存取存储器, 并向处理器 1403提供指令 和数据。存储器 1404的一部分还可以包括非易失性随机存取存储器(NVRAM)。 具体的应用中, PCRF实体的各个组件通过总线*** 1405耦合在一起, 其中 总线*** 1405除包括数据总线之外, 还可以包括电源总线、控制总线和状态 信号总线等。 但是为了清楚说明起见, 在图中将各种总线都标为总线*** 1405 ο  The processor 1403 controls the operation of the PCRF entity, and the processor 1403 may also be referred to as a CPU. Memory 1404 can include read only memory and random access memory and provides instructions and data to processor 1403. A portion of memory 1404 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the PCRF entity are coupled together by a bus system 1405. The bus system 1405 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 1405 in the figure.
上述本发明实施例揭示的方法可以应用于处理器 1403中,或者由处理器 1403实现。 处理器 1403可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 1403中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 1403可以是通用处理器、数字 信号处理器 (DSP ) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 1404, 处理 器 1403读取存储器 1404中的信息, 结合其硬件完成上述方法的步骤。 The method disclosed in the foregoing embodiment of the present invention may be applied to the processor 1403 or implemented by the processor 1403. The processor 1403 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 1403 or an instruction in a form of software. The processor 1403 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 1404. The processor 1403 reads the information in the memory 1404 and completes the steps of the above method in combination with hardware.
在一可选实施方式中,发射器 1401用于向 TDF实体发送的 PCC规则标识 和 /或 SDF模板, 包括:  In an alternative embodiment, the transmitter 1401 is configured to send the PCC rule identifier and/or the SDF template to the TDF entity, including:
发射器 1401具体用于向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。  The transmitter 1401 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
可选的, 接收器 1402还用于在发射器 1401向所述 TDF实体发送 TDF会 话建立请求消息之后, 接收 TDF实体发送的 TDF会话建立响应消息。  Optionally, the receiver 1402 is further configured to: after the transmitter 1401 sends a TDF session setup request message to the TDF entity, receive a TDF session setup response message sent by the TDF entity.
在一可选实施方式中,发射器 1401用于将所述第一应用所属的 SDF的标 识和所述第一应用的数据包的流量发送给所述 PCEF实体, 包括:  In an optional implementation, the transmitter 1401 is configured to send the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, including:
发射器 1401具体用于向所述 PCEF实体发送 IP-CAN会话修改请求消息, 所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的标识和所述第 一应用的数据包的流量。  The transmitter 1401 is specifically configured to send an IP-CAN session modification request message to the PCEF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. flow.
本实施例提供的 PCRF 实体可用于执行上述方法实施例中第二种计费方 法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The PCRF entity provided in this embodiment can be used to perform the process of the second charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 PCRF实体, 向 TDF实体发送 PCC规则标识和 /或 SDF模 板, 使得 TDF实体确定需要单独计费的第一应用的标识和第一应用的数据包 的流量并返回给本实施例的 PCRF实体, 本实施例的 PCRF实体将第一应用的 标识和第一应用的数据包的流量发送给 PCEF实体, 使 PCEF实体根据第一应 用的标识和第一应用的数据包的流量重新对基于 SDF粒度的计费结果进行调 整, 从而实现准确计费。  The PCRF entity provided in this embodiment sends a PCC rule identifier and/or an SDF template to the TDF entity, so that the TDF entity determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and returns the data to the embodiment. The PCRF entity, the PCRF entity of the embodiment sends the identifier of the first application and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity re-pairs according to the identifier of the first application and the traffic of the data packet of the first application. The billing result based on the SDF granularity is adjusted to achieve accurate billing.
图 15为本发明实施例提供的又一种 PCEF实体的结构示意图。如图 15所 示, 所述 PCEF实体包括: 接收模块 1501和计费调整模块 1502。 FIG. 15 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention. As shown in Figure 15 The PCEF entity includes: a receiving module 1501 and a charging adjustment module 1502.
接收模块 1501, 用于接收 PCRF实体发送的影响所述 PCEF实体基于 SDF 粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用的数据包的流 量; 其中, 所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量 是 TDF实体根据所述 PCRF实体发送的 PCC规则标识和 /或 SDF模板确定并发 送给所述 PCRF实体的。  The receiving module 1501 is configured to receive, by the PCRF entity, an identifier of the SDF that is affected by the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application, where the first The identifier of the SDF to which the application belongs and the traffic of the data packet of the first application are determined by the TDF entity according to the PCC rule identifier and/or the SDF template sent by the PCRF entity, and sent to the PCRF entity.
计费调整模块 1502, 与接收模块 1501连接, 用于根据接收模块 1501接 收的所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量, 对来 自 UE的上行数据包基于 SDF粒度的计费结果进行调整, 其中, 所述第一应用 的数据包属于来自所述 UE的上行数据包。  The charging adjustment module 1502 is configured to be connected to the receiving module 1501, configured to determine, according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application received by the receiving module 1501, the uplink data packet from the UE is based on The charging result of the SDF granularity is adjusted, wherein the data packet of the first application belongs to an uplink data packet from the UE.
在一可选实施方式中, 所述 PCEF实体还包括: 计费模块, 用于在接收模 块 1501接收第一应用所属的 SDF的标识和所述第一应用的数据包的流量之 前, 对来自所述 UE的上行数据包进行基于 SDF粒度的计费。  In an optional implementation, the PCEF entity further includes: a charging module, configured to: before the receiving module 1501 receives the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, The uplink data packet of the UE performs charging based on SDF granularity.
在一可选实施方式中, 接收模块 1501用于接收 PCRF实体发送的影响所 述 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第 一应用的数据包的流量, 包括:  In an optional implementation, the receiving module 1501 is configured to receive, by the PCRF entity, an identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application. , including:
接收模块 1501具体用于接收所述 PCRF实体发送的 IP-CAN会话修改请求 消息,所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的标识和 所述第一应用的数据包的流量。  The receiving module 1501 is specifically configured to receive an IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. Traffic.
可选的, 本实施例的 PCEF实体还可以包括: 发送模块, 用于在接收模块 Optionally, the PCEF entity in this embodiment may further include: a sending module, configured to receive the module
1501接收所述 PCRF实体发送的 IP-CAN会话修改请求消息之后, 向所述 PCRF 实体发送 IP-CAN会话修改响应消息。 After receiving the IP-CAN session modification request message sent by the PCRF entity, the 1501 sends an IP-CAN session modification response message to the PCRF entity.
本实施例提供的 PCEF 实体的各功能模块可用于执行上述方法实施例中 第二种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The function modules of the PCEF entity provided in this embodiment may be used to perform the process of the second charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 PCEF实体, 接收 PCRF实体发送的由 TDF实体确定出的 需要单独计费的第一应用的标识和第一应用的数据包的流量, 根据第一应用 的标识和第一应用的数据包的流量, 重新调整基于 SDF粒度的计费结果, 实 现准确计费。  The PCEF entity provided in this embodiment receives the identifier of the first application that needs to be separately charged and the data packet of the first application that is determined by the TDF entity and is sent by the PCRF entity, according to the identifier of the first application and the first application. The traffic of the data packet is re-adjusted based on the SDF granularity charging result to achieve accurate charging.
图 16为本发明实施例提供的又一种 PCEF实体的结构示意图。如图 16所 示, 所述 PCEF实体包括: 接收器 1601、 处理器 1602和存储器 1603。 接收器 1601, 用于接收 PCRF实体发送的影响所述 PCEF实体基于 SDF粒 度的计费结果的第一应用所属的 SDF 的标识和所述第一应用的数据包的流 量; 其中, 所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量 是 TDF实体根据所述 PCRF实体发送的 PCC规则标识和 /或 SDF模板确定并发 送给所述 PCRF实体的。 FIG. 16 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention. As shown in FIG. 16, the PCEF entity includes: a receiver 1601, a processor 1602, and a memory 1603. The receiver 1601 is configured to receive, by the PCRF entity, an identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application, where the first The identifier of the SDF to which the application belongs and the traffic of the data packet of the first application are determined by the TDF entity according to the PCC rule identifier and/or the SDF template sent by the PCRF entity, and sent to the PCRF entity.
存储器 1603可以包括只读存储器和随机存取存储器, 并向处理器 1602 提供指令和数据。存储器 1603的一部分还可以包括非易失性随机存取存储器 (NVRAM) o  Memory 1603 can include read only memory and random access memory and provides instructions and data to processor 1602. A portion of memory 1603 may also include non-volatile random access memory (NVRAM) o
存储器 1603存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  Memory 1603 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 1602通过调用存储器 1603存储的操作指令 (该操作指令可存储在操作***中) , 执行如下操作:  In the embodiment of the present invention, the processor 1602 performs the following operations by calling an operation instruction stored in the memory 1603 (the operation instruction can be stored in the operating system):
根据接收器 1601接收的所述第一应用所属的 SDF的标识和所述第一应用 的数据包的流量,对来自 UE的上行数据包基于 SDF粒度的计费结果进行调整, 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。  Adjusting the uplink data packet from the UE based on the SDF granularity charging result according to the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application received by the receiver 1601, where the An application's data packet belongs to an upstream data packet from the UE.
进一步可选的, 所述 PCEF实体还可以包括: 发射器 1604。  Further optionally, the PCEF entity may further include: a transmitter 1604.
处理器 1602控制 PCEF实体的操作, 处理器 1602还可以称为 CPU。 存储 器 1603可以包括只读存储器和随机存取存储器, 并向处理器 1602提供指令 和数据。存储器 1603的一部分还可以包括非易失性随机存取存储器(NVRAM)。 具体的应用中, PCEF实体的各个组件通过总线*** 1605耦合在一起, 其中 总线*** 1605除包括数据总线之外, 还可以包括电源总线、控制总线和状态 信号总线等。 但是为了清楚说明起见, 在图中将各种总线都标为总线*** 1605 ο  The processor 1602 controls the operation of the PCEF entity, which may also be referred to as a CPU. Memory 1603 can include read only memory and random access memory and provides instructions and data to processor 1602. A portion of memory 1603 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the PCEF entity are coupled together by a bus system 1605. The bus system 1605 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 1605 in the figure.
上述本发明实施例揭示的方法可以应用于处理器 1602中,或者由处理器 1602实现。 处理器 1602可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 1602中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 1602可以是通用处理器、数字 信号处理器 (DSP ) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 1603, 处理 器 1602读取存储器 1603中的信息, 结合其硬件完成上述方法的步骤。 The method disclosed in the foregoing embodiments of the present invention may be applied to the processor 1602 or implemented by the processor 1602. The processor 1602 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method may be completed by an integrated logic circuit of hardware in the processor 1602 or an instruction in a form of software. The processor 1602 described above may be a general purpose processor, a digital Signal processor (DSP), application specific integrated circuit (ASIC), off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 1603, and the processor 1602 reads the information in the memory 1603, and completes the steps of the above method in combination with the hardware thereof.
在一可选实施方式中, 处理器 1602, 还用于在接收器 1601接收第一应 用所属的 SDF的标识和所述第一应用的数据包的流量之前,对来自所述 UE的 上行数据包进行基于 SDF粒度的计费。  In an optional implementation, the processor 1602 is further configured to: after receiving, by the receiver 1601, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application, the uplink data packet from the UE Perform SDF granularity based charging.
在一可选实施方式中, 接收器 1601用于接收 PCRF实体发送的影响所述 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一 应用的数据包的流量, 包括:  In an optional implementation manner, the receiver 1601 is configured to receive, by the PCRF entity, an identifier of the SDF that belongs to the first application that affects the SDF granularity-based charging result of the PCEF entity, and a traffic of the data packet of the first application. , including:
接收器 1601具体用于接收所述 PCRF实体发送的 IP-CAN会话修改请求消 息,所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的标识和所 述第一应用的数据包的流量。  The receiver 1601 is specifically configured to receive an IP-CAN session modification request message sent by the PCRF entity, where the IP-CAN session modification request message includes an identifier of the SDF to which the first application belongs and a data packet of the first application. Traffic.
可选的, 发射器 1604可用于在接收器 1601接收所述 PCRF实体发送的 IP-CAN会话修改请求消息之后, 向所述 PCRF实体发送 IP-CAN会话修改响应 消息。  Optionally, the transmitter 1604 is configured to send an IP-CAN session modification response message to the PCRF entity after the receiver 1601 receives the IP-CAN session modification request message sent by the PCRF entity.
本实施例提供的 PCEF 实体可用于执行上述方法实施例中第二种计费方 法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The PCEF entity provided in this embodiment may be used to perform the process of the second charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 PCEF实体, 接收 PCRF实体发送的由 TDF实体确定出的 需要单独计费的第一应用的标识和第一应用的数据包的流量, 根据第一应用 的标识和第一应用的数据包的流量, 重新调整基于 SDF粒度的计费结果, 实 现准确计费。  The PCEF entity provided in this embodiment receives the identifier of the first application that needs to be separately charged and the data packet of the first application that is determined by the TDF entity and is sent by the PCRF entity, according to the identifier of the first application and the first application. The traffic of the data packet is re-adjusted based on the SDF granularity charging result to achieve accurate charging.
图 17为本发明实施例提供的又一种 TDF实体的结构示意图。 如图 17所 示, 所述 TDF实体包括: 接收模块 1701、 确定模块 1702和发送模块 1703。  FIG. 17 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention. As shown in FIG. 17, the TDF entity includes: a receiving module 1701, a determining module 1702, and a sending module 1703.
接收模块 1701,用于接收 PCRF实体发送的 PCC规则标识和 /或 SDF模板。 确定模块 1702, 与接收模块 1701连接, 用于根据接收模块 1701接收的 所述 PCC规则标识和 /或 SDF模板, 确定影响 PCEF实体基于 SDF粒度的计费 结果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量。 The receiving module 1701 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity. The determining module 1702 is connected to the receiving module 1701 for receiving according to the receiving module 1701. The PCC rule identifier and/or the SDF template determines an identifier of the SDF to which the first application that affects the PCEF entity based on the SDF granularity charging result and a traffic of the data packet of the first application.
发送模块 1703, 与确定模块 1702连接, 用于将确定模块 1702确定的所 述第一应用所属的 SDF的标识和所述第一应用的数据包的流量通过所述 PCRF 实体发送给所述 PCEF实体,以使所述 PCEF实体基于所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流量对来自 UE的上行数据包基于 SDF粒度 的计费结果进行调整; 其中, 所述第一应用的数据包属于来自所述 UE的上行 数据包。  The sending module 1703 is connected to the determining module 1702, and configured to send, by the PCRF entity, the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application determined by the determining module 1702 to the PCEF entity. And adjusting, by the PCEF entity, the SDL granularity-based charging result of the uplink data packet from the UE, based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application; The data packet of the first application belongs to an uplink data packet from the UE.
在一可选实施方式中, 接收模块 1701用于接收 PCRF实体发送的 PCC规 则标识和 /或 SDF模板, 包括:  In an optional implementation, the receiving module 1701 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity, including:
接收模块 1701具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。  The receiving module 1701 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
可选的,发送模块 1703还可用于在接收模块 1701接收所述 PCRF实体发 送的 TDF会话建立请求消息之后, 向 PCRF实体发送 TDF会话建立响应消息。  Optionally, the sending module 1703 is further configured to send a TDF session establishment response message to the PCRF entity after the receiving module 1701 receives the TDF session establishment request message sent by the PCRF entity.
在一可选实施方式中, 确定模块 1702用于根据接收模块 1701接收的所 述 PCC规则标识和 /或 SDF模板, 确定影响 PCEF实体基于 SDF粒度的计费结 果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量, 包括: 确定模块 1702具体用于根据接收模块 1701接收的所述 PCC规则标识指 示的 PCC规则, 确定因执行基于应用的流控而被丢弃的数据包所属的应用作 为所述第一应用, 确定所述被丢弃的数据包的流量作为所述第一应用的数据 包的流量, 并确定所述第一应用所属的 SDF; 或者  In an optional implementation, the determining module 1702 is configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiving module 1701, an identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result belongs. And the traffic of the data packet of the first application, where: the determining module 1702 is specifically configured to determine, according to the PCC rule indicated by the PCC rule identifier received by the receiving module 1701, a data packet that is discarded due to performing application-based flow control. As the first application, the associated application determines the traffic of the discarded data packet as the traffic of the data packet of the first application, and determines the SDF to which the first application belongs; or
确定模块 1702具体用于根据接收模块 1701接收的所述 SDF模板探测到 不需要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进 行计费时, 从具有相同 IP地址信息的所有数据包中, 确定实际需要计费的数 据包所属的应用作为所述第一应用, 确定实际需要计费的数据包的流量作为 所述第一应用的数据包的流量, 并确定所述第一应用所属的 SDF; 或者, 确定模块 1702具体用于根据接收模块 1701接收的所述 SDF模板探测到 不需要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进 行计费时, 从具有相同 IP地址信息的所有数据包, 确定出不需要计费的数据 包所属的应用作为所述第一应用, 确定不需要计费的数据包的流量作为所述 第一应用的数据包的流量, 并确定所述第一应用所属的 SDF。 The determining module 1702 is specifically configured to: when the SDF template received by the receiving module 1701 detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the same IP address information is obtained. In all the data packets, the application to which the data packet actually required to be charged belongs is determined as the first application, and the traffic of the data packet actually required to be charged is determined as the traffic of the data packet of the first application, and the The SDF to which the first application belongs; or the determining module 1702 is specifically configured to detect, according to the SDF template received by the receiving module 1701, that all data packets having the same IP address information in the uplink data packet from the UE are not required to be counted. Time-consuming, determining, from all the data packets having the same IP address information, an application to which the data packet that does not need to be charged belongs is used as the first application, and determining the traffic of the data packet that does not need to be charged as the The traffic of the first application's data packet, and determining the SDF to which the first application belongs.
本实施例提供的 TDF实体的各功能模块可用于执行上述方法实施例中第 二种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The function modules of the TDF entity provided in this embodiment can be used to perform the process of the second charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 TDF实体,接收 PCRF实体发送的 PCC规则标识和 /或 SDF 模板, 并据此确定出需要单独计费的第一应用的标识和第一应用的数据包的 流量, 然后通过 PCRF实体发送给 PCEF实体, 使得 PCEF实体可以根据第一应 用的标识和第一应用的数据包的流量, 重新调整基于 SDF粒度的计费结果, 实现准确计费。  The TDF entity provided in this embodiment receives the PCC rule identifier and/or the SDF template sent by the PCRF entity, and determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and then passes the PCRF. The entity sends the entity to the PCEF entity, so that the PCEF entity can re-adjust the charging result based on the SDF granularity according to the identifier of the first application and the traffic of the data packet of the first application, so as to implement accurate charging.
图 18为本发明实施例提供的又一种 TDF实体的结构示意图。 如图 18所 示, 所述 TDF实体包括: 接收器 1801、 处理器 1802、 发射器 1803和存储器 1804。  FIG. 18 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention. As shown in FIG. 18, the TDF entity includes: a receiver 1801, a processor 1802, a transmitter 1803, and a memory 1804.
接收器 1801, 用于接收 PCRF实体发送的 PCC规则标识和 /或 SDF模板。 存储器 1804可以包括只读存储器和随机存取存储器,并向处理器 602提 供指令和数据。 存储器 1804 的一部分还可以包括非易失性随机存取存储器 (NVRAM) 。  The receiver 1801 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity. Memory 1804 can include read only memory and random access memory and provides instructions and data to processor 602. A portion of memory 1804 may also include non-volatile random access memory (NVRAM).
存储器 1804存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  Memory 1804 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 1802通过调用存储器 1804存储的操作指令 (该操作指令可存储在操作***中) , 执行如下操作:  In the embodiment of the present invention, the processor 1802 performs the following operations by calling an operation instruction stored in the memory 1804 (which can be stored in the operating system):
根据接收器 1801接收的所述 PCC规则标识和 /或 SDF模板,确定影响 PCEF 实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用 的数据包的流量。  And determining, according to the PCC rule identifier and/or the SDF template received by the receiver 1801, an identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result and a traffic of the data packet of the first application.
发射器 1803, 用于将处理器 1802确定的所述第一应用所属的 SDF的标 识和所述第一应用的数据包的流量通过所述 PCRF实体发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量对来自 UE的上行数据包基于 SDF粒度的计费结果进行调整;其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。 其中, 处理器 1802控制 TDF实体的操作, 处理器 1802还可以称为 CPU。 存储器 1804可以包括只读存储器和随机存取存储器, 并向处理器 1802提供 指令和数据。 存储器 1804 的一部分还可以包括非易失性随机存取存储器 (NVRAM) 。 具体的应用中, TDF实体的各个组件通过总线*** 1805耦合在 一起, 其中总线*** 1805除包括数据总线之外, 还可以包括电源总线、 控制 总线和状态信号总线等。 但是为了清楚说明起见, 在图中将各种总线都标为 总线*** 1805。 a transmitter 1803, configured to send, by the processor 1802, an identifier of an SDF to which the first application belongs and a traffic of a data packet of the first application to the PCEF entity by using the PCRF entity, to enable the PCEF The entity adjusts the uplink data packet from the UE based on the SDF granularity charging result based on the identifier of the SDF to which the first application belongs and the traffic of the data packet of the first application; where the data packet of the first application is It belongs to the uplink data packet from the UE. The processor 1802 controls the operation of the TDF entity, and the processor 1802 may also be referred to as a CPU. Memory 1804 can include read only memory and random access memory and provides instructions and data to processor 1802. A portion of the memory 1804 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the TDF entity are coupled together by a bus system 1805. The bus system 1805 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for clarity of description, various buses are labeled as bus system 1805 in the figure.
上述本发明实施例揭示的方法可以应用于处理器 1802中,或者由处理器 1802实现。 处理器 1802可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 1802中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 1802可以是通用处理器、数字 信号处理器 (DSP ) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 1804, 处理 器 1802读取存储器 1804中的信息, 结合其硬件完成上述方法的步骤。  The method disclosed in the foregoing embodiments of the present invention may be applied to the processor 1802 or implemented by the processor 1802. Processor 1802 may be an integrated circuit chip with signal processing capabilities. In an implementation process, the steps of the above method may be performed by an integrated logic circuit of hardware in the processor 1802 or an instruction in the form of software. The processor 1802 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in conventional memory, such as random memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in memory 1804, and processor 1802 reads the information in memory 1804 and, in conjunction with its hardware, performs the steps of the above method.
在一可选实施方式中, 接收器 1801用于接收 PCRF实体发送的 PCC规则 标识和 /或 SDF模板, 包括:  In an optional implementation, the receiver 1801 is configured to receive a PCC rule identifier and/or an SDF template sent by the PCRF entity, including:
接收器 1801具体用于接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。  The receiver 1801 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identifier and/or an SDF template.
可选的,发射器 1803还可用于在接收器 1801接收所述 PCRF实体发送的 TDF会话建立请求消息之后, 向 PCRF实体发送 TDF会话建立响应消息。  Optionally, the transmitter 1803 is further configured to send a TDF session establishment response message to the PCRF entity after the receiver 1801 receives the TDF session establishment request message sent by the PCRF entity.
在一可选实施方式中,处理器 1802用于根据接收器 1801接收的所述 PCC 规则标识和 /或 SDF模板, 确定影响 PCEF实体基于 SDF粒度的计费结果的第 一应用所属的 SDF的标识和所述第一应用的数据包的流量, 包括:  In an optional implementation, the processor 1802 is configured to determine, according to the PCC rule identifier and/or the SDF template received by the receiver 1801, an identifier of the SDF to which the first application that affects the PCDF entity based on the SDF granularity charging result belongs. And the traffic of the data packet of the first application, including:
处理器 1802具体用于根据接收器 1801接收的所述 PCC规则标识指示的 PCC 规则, 确定因执行基于应用的流控而被丢弃的数据包所属的应用作为所 述第一应用, 确定所述被丢弃的数据包的流量作为所述第一应用的数据包的 流量, 并确定所述第一应用所属的 SDF; 或者 The processor 1802 is specifically configured to determine, according to the PCC rule indicated by the PCC rule identifier received by the receiver 1801, an application to which the data packet discarded by performing application-based flow control belongs Determining, by the first application, the traffic of the discarded data packet as the traffic of the data packet of the first application, and determining the SDF to which the first application belongs; or
处理器 1802具体用于根据接收器 1801接收的所述 SDF模板探测到不需 要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进行计 费时, 从具有相同 IP地址信息的所有数据包中, 确定实际需要计费的数据包 所属的应用作为所述第一应用, 确定实际需要计费的数据包的流量作为所述 第一应用的数据包的流量, 并确定所述第一应用所属的 SDF; 或者,  The processor 1802 is specifically configured to: when the SDF template received by the receiver 1801 detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the slave device has the same IP address information. In all the data packets, the application to which the data packet actually required to be charged belongs is determined as the first application, and the traffic of the data packet actually required to be charged is determined as the traffic of the data packet of the first application, and the The SDF to which the first application belongs; or,
处理器 1802具体用于根据接收器 1801接收的所述 SDF模板探测到不需 要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进行计 费时, 从具有相同 IP地址信息的所有数据包, 确定出不需要计费的数据包所 属的应用作为所述第一应用, 确定不需要计费的数据包的流量作为所述第一 应用的数据包的流量, 并确定所述第一应用所属的 SDF。  The processor 1802 is specifically configured to: when the SDF template received by the receiver 1801 detects that all data packets having the same IP address information in the uplink data packet from the UE are not required to be charged, the slave device has the same IP address information. Determining, by the application, the application to which the data packet that does not need to be charged belongs, as the first application, determining the traffic of the data packet that does not need to be charged as the traffic of the data packet of the first application, and determining the The SDF to which the first application belongs.
本实施例提供的 TDF实体可用于执行上述方法实施例中第二种计费方法 的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The TDF entity provided in this embodiment can be used to perform the process of the second charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 TDF实体,接收 PCRF实体发送的 PCC规则标识和 /或 SDF 模板, 并据此确定出需要单独计费的第一应用的标识和第一应用的数据包的 流量, 然后通过 PCRF实体发送给 PCEF实体, 使得 PCEF实体可以根据第一应 用的标识和第一应用的数据包的流量, 重新调整基于 SDF粒度的计费结果, 实现准确计费。  The TDF entity provided in this embodiment receives the PCC rule identifier and/or the SDF template sent by the PCRF entity, and determines the identifier of the first application that needs to be separately charged and the traffic of the data packet of the first application, and then passes the PCRF. The entity sends the entity to the PCEF entity, so that the PCEF entity can re-adjust the charging result based on the SDF granularity according to the identifier of the first application and the traffic of the data packet of the first application, so as to implement accurate charging.
图 19为本发明实施例提供的又一种 TDF实体的结构示意图。 如图 19所 示,所述 TDF实体包括:接收模块 1901、确定添加模块 1902和发送模块 1903。  FIG. 19 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention. As shown in FIG. 19, the TDF entity includes: a receiving module 1901, a determining adding module 1902, and a sending module 1903.
接收模块 1901, 用于接收 PCEF实体发送的上行数据包。  The receiving module 1901 is configured to receive an uplink data packet sent by the PCEF entity.
确定添加模块 1902, 与接收模块 1901连接, 用于在接收模块 1901接收 到所述上行数据包之后, 确定回流数据, 并为所述回流数据添加计费标识, 所述回流数据是指所述上行数据包中影响所述 PCEF 实体对所述上行数据包 基于 SDF粒度的计费结果的数据包。  The determining module 1902 is connected to the receiving module 1901, and configured to: after the receiving module 1901 receives the uplink data packet, determine reflow data, and add a charging identifier to the reflow data, where the reflow data refers to the uplink A data packet in the data packet that affects the charging result of the SDF granularity of the uplink data packet by the PCEF entity.
发送模块 1903, 与确定添加模块 1902连接, 用于将确定添加模块 1902 确定的携带所述计费标识的回流数据发送给所述 PCEF实体, 以使所述 PCEF 实体根据携带所述计费标识的回流数据, 对所述上行数据包基于 SDF粒度的 计费结果进行调整。 在一可选实施方式中, 接收模块 1901还用于在确定添加模块 1902为所 述回流数据添加计费标识之前, 接收 PCRF实体发送的所述 PCRF实体为所述 回流数据分配的所述计费标识。 可选的, 接收模块 1901 还与确定添加模块 1902连接, 用于向确定添加模块 1902提供所述计费标识。 The sending module 1903 is connected to the determining adding module 1902, and configured to send, by the determining the adding module 1902, the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity is configured to carry the charging identifier. The data is reflowed, and the uplink data packet is adjusted based on the SDF granularity charging result. In an optional implementation, the receiving module 1901 is further configured to: before determining that the adding module 1902 adds a charging identifier to the reflow data, receiving, by the PCRF entity, the charging that is allocated by the PCRF entity for the reflow data. Logo. Optionally, the receiving module 1901 is further connected to the determining adding module 1902, and configured to provide the charging identifier to the determining adding module 1902.
在一可选实施方式中,接收模块 1901用于接收 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识, 包括:  In an optional implementation, the receiving module 1901 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes:
接收模块 1901具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述计费标识。  The receiving module 1901 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
可选的,发送模块 1903还用于在接收模块 1901接收所述 PCRF实体发送 的 TDF会话建立请求消息之后,向所述 PCRF实体发送 TDF会话建立响应消息。  Optionally, the sending module 1903 is further configured to send a TDF session establishment response message to the PCRF entity after the receiving module 1901 receives the TDF session establishment request message sent by the PCRF entity.
本实施例提供的 TDF实体的各功能模块可用于执行上述方法实施例中第 三种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The functional modules of the TDF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiments. The specific working principle is not described here. For details, refer to the description of the method embodiments.
本实施例提供的 TDF实体,确定来自于 PCEF实体的上行数据包中的回流 数据, 并将回流数据添加计费标识后返回给 PCEF实体, 使得 PCEF实体可以 根据计费标识确定 TDF实体发送的是回流数据, 并基于该回流数据的流量重 新调整基于 SDF粒度的计费结果, 实现准确计费。  The TDF entity provided in this embodiment determines the reflow data in the uplink data packet from the PCEF entity, and adds the recurring data to the PCEF entity after adding the charging identifier, so that the PCEF entity can determine, according to the charging identifier, that the TDF entity sends the The data is reflowed, and the SDF granularity based charging result is readjusted based on the flow of the reflow data to achieve accurate charging.
图 20为本发明实施例提供的又一种 TDF实体的结构示意图。 如图 20所 示, 所述 TDF实体包括: 接收器 2001、 处理器 2002、 发射器 2003和存储器 其中, 接收器 2001, 用于接收 PCEF实体发送的上行数据包。  FIG. 20 is a schematic structural diagram of still another TDF entity according to an embodiment of the present invention. As shown in FIG. 20, the TDF entity includes: a receiver 2001, a processor 2002, a transmitter 2003, and a memory. The receiver 2001 is configured to receive an uplink data packet sent by a PCEF entity.
存储器 2004可以包括只读存储器和随机存取存储器, 并向处理器 2002 提供指令和数据。存储器 2004的一部分还可以包括非易失性随机存取存储器 (NVRAM) o  Memory 2004 can include read only memory and random access memory and provides instructions and data to processor 2002. A portion of the memory 2004 may also include non-volatile random access memory (NVRAM) o
存储器 2004存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  Memory 2004 stores the following elements, executable modules or data structures, or a subset of them, or their extended set:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 2002通过调用存储器 2004存储的操作指令 (该操作指令可存储在操作***中) , 执行如下操作: 在接收器 2001接收到所述上行数据包之后, 确定回流数据, 并为所述回 流数据添加计费标识,所述回流数据是指所述上行数据包中影响所述 PCEF实 体对所述上行数据包基于 SDF粒度的计费结果的数据包。 In the embodiment of the present invention, the processor 2002 performs the following operations by calling an operation instruction stored in the memory 2004 (the operation instruction can be stored in the operating system): After receiving the uplink data packet, the receiver 2001 determines the reflow data, and adds a charging identifier to the reflow data, where the reflow data refers to the uplink data packet affecting the PCEF entity to the uplink data. A packet based on the SDF granularity of the charging result.
发射器 2003, 用于将携带所述计费标识的回流数据发送给所述 PCEF实 体, 以使所述 PCEF实体根据携带所述计费标识的回流数据, 对所述上行数据 包基于 SDF粒度的计费结果进行调整。  The transmitter 2003 is configured to send the reflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity performs the SDF granularity on the uplink data packet according to the reflow data carrying the charging identifier. The billing result is adjusted.
其中, 处理器 2002控制 TDF实体的操作, 处理器 2002还可以称为 CPU。 存储器 2004可以包括只读存储器和随机存取存储器, 并向处理器 2002提供 指令和数据。 存储器 2004 的一部分还可以包括非易失性随机存取存储器 (NVRAM) 。 具体的应用中, TDF实体的各个组件通过总线*** 2005耦合在 一起, 其中总线*** 2005除包括数据总线之外, 还可以包括电源总线、 控制 总线和状态信号总线等。 但是为了清楚说明起见, 在图中将各种总线都标为 总线*** 2005。  The processor 2002 controls the operation of the TDF entity, and the processor 2002 may also be referred to as a CPU. Memory 2004 can include read only memory and random access memory and provides instructions and data to processor 2002. A portion of the memory 2004 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the TDF entity are coupled together by a bus system 2005, which may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for clarity of description, various buses are labeled as bus system 2005 in the figure.
上述本发明实施例揭示的方法可以应用于处理器 2002中,或者由处理器 2002实现。 处理器 2002可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 2002中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 2002可以是通用处理器、数字 信号处理器 (DSP ) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 2004, 处理 器 2002读取存储器 2004中的信息, 结合其硬件完成上述方法的步骤。  The method disclosed in the foregoing embodiments of the present invention may be applied to the processor 2002 or implemented by the processor 2002. The processor 2002 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method may be completed by an integrated logic circuit of hardware in the processor 2002 or an instruction in the form of software. The processor 2002 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in conventional memory, such as random memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 2004, and the processor 2002 reads the information in the memory 2004 and combines the hardware to perform the steps of the above method.
在一可选实施方式中, 接收器 2001还用于在处理器 2002为所述回流数 据添加计费标识之前, 接收 PCRF实体发送的所述 PCRF实体为所述回流数据 分配的所述计费标识, 以向处理器 2002提供所述计费标识。  In an optional implementation, the receiver 2001 is further configured to: before the processor 2002 adds the charging identifier to the reflow data, receive, by the PCRF entity, the charging identifier that is sent by the PCRF entity to the reflow data. And providing the charging identifier to the processor 2002.
在一可选实施方式中, 接收器 2001用于接收 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识, 包括: 接收器 2001具体用于接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述计费标识。 In an optional implementation, the receiver 2001 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes: The receiver 2001 is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
可选的, 发射器 2003还用于在接收器 2001接收所述 PCRF实体发送的 TDF会话建立请求消息之后, 向所述 PCRF实体发送 TDF会话建立响应消息。  Optionally, the transmitter 2003 is further configured to send a TDF session establishment response message to the PCRF entity after the receiver 2001 receives the TDF session establishment request message sent by the PCRF entity.
本实施例提供的 TDF实体可用于执行上述方法实施例中第三种计费方法 的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The TDF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 TDF实体,确定来自于 PCEF实体的上行数据包中的回流 数据, 并将回流数据添加计费标识后返回给 PCEF实体, 使得 PCEF实体可以 根据计费标识确定 TDF实体发送的是回流数据, 并基于该回流数据的流量重 新调整基于 SDF粒度的计费结果, 实现准确计费。  The TDF entity provided in this embodiment determines the reflow data in the uplink data packet from the PCEF entity, and adds the recurring data to the PCEF entity after adding the charging identifier, so that the PCEF entity can determine, according to the charging identifier, that the TDF entity sends the The data is reflowed, and the SDF granularity based charging result is readjusted based on the flow of the reflow data to achieve accurate charging.
图 21为本发明实施例提供的又一种 PCEF实体的结构示意图。如图 21所 示, 所述 PCEF实体包括: 接收模块 2101和计费调整模块 2102。  FIG. 21 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention. As shown in FIG. 21, the PCEF entity includes: a receiving module 2101 and a charging adjustment module 2102.
接收模块 2101, 用于在对上行数据包进行基于 SDF粒度的计费之后, 接 收 TDF实体发送的携带有计费标识的回流数据, 所述回流数据是所述 TDF实 体确定的所述上行数据包中影响所述 PCEF实体对所述上行数据包的基于 SDF 粒度的计费结果的数据包。  The receiving module 2101 is configured to: after performing the SDF granularity-based charging on the uplink data packet, receive the reflow data that is sent by the TDF entity and that carries the charging identifier, where the reflow data is the uplink data packet that is determined by the TDF entity. a data packet affecting the SDF granularity based charging result of the uplink data packet by the PCEF entity.
计费调整模块 2102, 与接收模块 2101连接, 用于根据所述计费标识确 定接收模块 2101 接收到的数据是所述回流数据, 确定所述回流数据所属的 SDF, 对所述确定的 SDF的计费结果进行调整。  The billing adjustment module 2102 is connected to the receiving module 2101, and configured to determine, according to the billing identifier, that the data received by the receiving module 2101 is the reflow data, determine an SDF to which the reflow data belongs, and determine the SDF of the reflow data. The billing result is adjusted.
在一可选实施方式中,接收模块 2101还用于在接收所述 TDF实体发送的 携带有计费标识的回流数据之前, 接收 PCRF实体发送的所述 PCRF实体为所 述回流数据分配的所述计费标识。  In an optional implementation, the receiving module 2101 is further configured to: before receiving the reflow data carrying the charging identifier sent by the TDF entity, receiving, by the PCRF entity, the PCRF entity to allocate the reflow data Billing ID.
在一可选实施方式中,接收模块 2101用于接收 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识, 包括:  In an optional implementation, the receiving module 2101 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes:
接收模块 2101具体用于接收所述 PCRF实体发送的 IP-CAN会话建立响应 消息, 所述 IP-CAN会话建立响应消息包括所述计费标识。  The receiving module 2101 is specifically configured to receive an IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier.
可选的, 本实施例的 PCEF实体还可以包括: 发送模块, 用于在接收模块 Optionally, the PCEF entity in this embodiment may further include: a sending module, configured to receive the module
2101接收所述 PCRF实体发送的 IP-CAN会话建立响应消息之前, 向所述 PCEF 实体发送 IP-CAN会话建立请求消息。 2101: Before receiving the IP-CAN session establishment response message sent by the PCRF entity, send an IP-CAN session establishment request message to the PCEF entity.
本实施例提供的 PCEF 实体的各功能模块可用于执行上述方法实施例中 第三种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。 本实施例提供的 PCEF实体,接收 TDF实体发送的携带有计费标识的回流 数据, 在根据所述计费标识确定接收到的数据是回流数据之后, 确定回流数 据所属的 SDF, 然后对所确定的 SDF的计费结果进行调整, 实现准确计费。 The functional modules of the PCEF entity provided in this embodiment may be used to execute the foregoing method embodiment. For the flow of the third charging method, the specific working principle is not described again. For details, refer to the description of the method embodiment. The PCEF entity provided in this embodiment receives the reflow data carried by the TDF entity and carries the charging identifier. After determining that the received data is reflow data according to the charging identifier, determining the SDF to which the reflow data belongs, and then determining the SDF. The SDF billing result is adjusted to achieve accurate billing.
图 22为本发明实施例提供的又一种 PCEF实体的结构示意图。如图 22所 示, 所述 PCEF实体包括: 接收器 2201、 处理器 2202和存储器 2203。  FIG. 22 is a schematic structural diagram of still another PCEF entity according to an embodiment of the present invention. As shown in FIG. 22, the PCEF entity includes: a receiver 2201, a processor 2202, and a memory 2203.
接收器 2201, 用于在对上行数据包进行基于 SDF粒度的计费之后, 接收 TDF实体发送的携带有计费标识的回流数据, 所述回流数据是所述 TDF实体 确定的所述上行数据包中影响所述 PCEF实体对所述上行数据包的基于 SDF粒 度的计费结果的数据包。  The receiver 2201 is configured to receive, after the SDF granularity-based charging of the uplink data packet, the reflow data that is sent by the TDF entity and that carries the charging identifier, where the reflow data is the uplink data packet that is determined by the TDF entity. And a data packet affecting the SDF granularity-based charging result of the uplink data packet by the PCEF entity.
存储器 2203可以包括只读存储器和随机存取存储器, 并向处理器 2202 提供指令和数据。存储器 2203的一部分还可以包括非易失性随机存取存储器 (NVRAM) o  Memory 2203 can include read only memory and random access memory and provides instructions and data to processor 2202. A portion of memory 2203 may also include non-volatile random access memory (NVRAM) o
存储器 2203存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  The memory 2203 stores the following elements, executable modules or data structures, or a subset thereof, or their extended set:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 2202通过调用存储器 2203存储的操作指令 (该操作指令可存储在操作***中) , 执行如下操作:  In the embodiment of the present invention, the processor 2202 performs the following operations by calling an operation instruction stored in the memory 2203 (which can be stored in the operating system):
根据所述计费标识确定接收器 2201接收到的数据是所述回流数据,确定 所述回流数据所属的 SDF, 对所述确定的 SDF的计费结果进行调整。  Determining, according to the charging identifier, that the data received by the receiver 2201 is the reflow data, determining an SDF to which the reflow data belongs, and adjusting the charging result of the determined SDF.
可选的, 本实施例的 PCEF实体还包括: 发射器 2204。  Optionally, the PCEF entity in this embodiment further includes: a transmitter 2204.
处理器 2202控制 PCEF实体的操作, 处理器 2202还可以称为 CPU。 存储 器 2203可以包括只读存储器和随机存取存储器, 并向处理器 2202提供指令 和数据。存储器 2203的一部分还可以包括非易失性随机存取存储器(NVRAM)。 具体的应用中, PCEF实体的各个组件通过总线*** 2205耦合在一起, 其中 总线*** 2205除包括数据总线之外, 还可以包括电源总线、控制总线和状态 信号总线等。 但是为了清楚说明起见, 在图中将各种总线都标为总线*** 2205 ο 上述本发明实施例揭示的方法可以应用于处理器 2202中,或者由处理器 2202实现。 处理器 2202可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 2202中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 2202可以是通用处理器、数字 信号处理器 (DSP ) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 2203, 处理 器 2202读取存储器 2203中的信息, 结合其硬件完成上述方法的步骤。 The processor 2202 controls the operation of the PCEF entity, which may also be referred to as a CPU. Memory 2203 can include read only memory and random access memory and provides instructions and data to processor 2202. A portion of the memory 2203 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the PCEF entity are coupled together by a bus system 2205. The bus system 2205 may include a power bus, a control bus, a status signal bus, and the like in addition to the data bus. However, for clarity of description, various buses are labeled as bus system 2205 in the figure. The method disclosed in the foregoing embodiment of the present invention may be applied to the processor 2202 or implemented by the processor 2202. Processor 2202 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 2202 or an instruction in a form of software. The processor 2202 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware. Component. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 2203. The processor 2202 reads the information in the memory 2203 and completes the steps of the above method in combination with the hardware.
在一可选实施方式中,接收器 2201还用于在接收所述 TDF实体发送的携 带有计费标识的回流数据之前, 接收 PCRF实体发送的所述 PCRF实体为所述 回流数据分配的所述计费标识。  In an optional implementation, the receiver 2201 is further configured to: before receiving the reflow data carrying the charging identifier sent by the TDF entity, receiving, by the PCRF entity, the PCRF entity to allocate the reflow data Billing ID.
在一可选实施方式中, 接收器 2201用于接收 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识, 包括:  In an optional implementation, the receiver 2201 is configured to receive, by the PCRF entity, the charging identifier that is allocated by the PCRF entity for the reflow data, and includes:
接收器 2201具体用于接收所述 PCRF实体发送的 IP-CAN会话建立响应消 息, 所述 IP-CAN会话建立响应消息包括所述计费标识。  The receiver 2201 is specifically configured to receive an IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identifier.
可选的, 发射器 2204可用于在接收器 2201接收所述 PCRF实体发送的 Optionally, the transmitter 2204 is configured to receive, by the receiver 2201, the sent by the PCRF entity.
IP-CAN会话建立响应消息之前, 向所述 PCEF实体发送 IP-CAN会话建立请求 消息。 An IP-CAN Session Establishment Request message is sent to the PCEF entity prior to the IP-CAN Session Setup Response message.
本实施例提供的 PCEF 实体可用于执行上述方法实施例中第三种计费方 法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The PCEF entity provided in this embodiment can be used to perform the process of the third charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 PCEF实体,接收 TDF实体发送的携带有计费标识的回流 数据, 在根据所述计费标识确定接收到的数据是回流数据之后, 确定回流数 据所属的 SDF, 然后对所确定的 SDF的计费结果进行调整, 实现准确计费。  The PCEF entity provided in this embodiment receives the reflow data carried by the TDF entity and carries the charging identifier. After determining that the received data is reflow data according to the charging identifier, determining the SDF to which the reflow data belongs, and then determining the SDF. The SDF billing result is adjusted to achieve accurate billing.
图 23为本发明实施例提供的又一种 PCRF实体的结构示意图。如图 23所 示, 所述 PCRF实体包括: 确定模块 2301和发送模块 2302。  FIG. 23 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention. As shown in FIG. 23, the PCRF entity includes: a determining module 2301 and a sending module 2302.
确定模块 2301, 用于确定需要分配给回流数据包的计费标识, 所述回流 数据是指上行数据包中影响 PCEF实体对所述上行数据包的基于 SDF粒度的计 费结果的数据包。 a determining module 2301, configured to determine a charging identifier that needs to be allocated to a reflow packet, the reflow The data refers to a data packet in the uplink data packet that affects the SDF granularity-based charging result of the uplink data packet by the PCEF entity.
发送模块 2302, 与确定模块 2301连接, 用于将确定模块 2301确定的所 述计费标识发送给 TDF实体和所述 PCEF实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确定出所述回流数据后在所述回流数据中添加 所述计费标识后向所述 PCEF实体发送, 使所述 PCEF实体根据所述计费标识 确定所述回流数据并基于所述回流数据对所述上行数据包的基于 SDF粒度的 计费结果进行调整。  The sending module 2302 is connected to the determining module 2301, and configured to send the charging identifier determined by the determining module 2301 to the TDF entity and the PCEF entity, where the TDF entity sends the uplink data from the PCEF entity. After the reflow data is determined in the packet, the charging identifier is added to the reflow data, and then sent to the PCEF entity, so that the PCEF entity determines the reflow data according to the charging identifier and is based on the reflow. The data adjusts the SDF granularity based charging result of the uplink data packet.
在一可选实施方式中,发送模块 2302用于将所述计费标识发送给 TDF实 体, 包括:  In an optional implementation, the sending module 2302 is configured to send the charging identifier to the TDF entity, including:
发送模块 2302具体用于向所述 TDF实体发送 TDF会话建立请求消息,所 述 TDF会话建立请求消息包括所述计费标识。  The sending module 2302 is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the charging identifier.
可选的, 所述 PCRF实体还可以包括: 接收模块, 用于在发送模块 2302 向所述 TDF实体发送 TDF会话建立请求消息之后,接收所述 TDF实体发送 TDF 会话建立响应消息。  Optionally, the PCRF entity may further include: a receiving module, configured to: after the sending module 2302 sends a TDF session establishment request message to the TDF entity, receive the TDF entity to send a TDF session establishment response message.
在一可选实施方式中, 发送模块 2302 用于将所述计费标识发送给所述 PCEF实体, 包括:  In an optional implementation, the sending module 2302 is configured to send the charging identifier to the PCEF entity, including:
发送模块 2302具体用于向所述 PCEF实体发送 IP-CAN会话建立响应消 息, 所述 IP-CAN会话建立响应消息包括所述计费标识。  The sending module 2302 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes the charging identifier.
所述接收模块还用于在发送模块 2302向所述 PCEF实体发送 IP-CAN会话 建立响应消息之前, 接收所述 PCEF实体发送的 IP-CAN会话建立请求消息。  The receiving module is further configured to receive an IP-CAN session establishment request message sent by the PCEF entity before the sending module 2302 sends an IP-CAN session establishment response message to the PCEF entity.
本实施例提供的 PCRF 实体的各功能模块可用于执行上述方法实施例中 第三种计费方法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The function modules of the PCRF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiments. The specific working principle is not described here. For details, refer to the description of the method embodiments.
本实施例提供的 PCRF实体, 确定分配给回流数据的计费标识, 并分别发 送给 TDF实体和 PCEF实体,使得 TDF实体在确定出的回流数据中添加所述计 费标识后发送给 PCEF实体, 而 PCEF实体基于所述计费标识确定来自于 TDF 实体的数据是回流数据, 进而确定回流数据所属的 SDF, 对所确定出的 SDF 的计费结果进行调整, 实现准确计费。  The PCRF entity provided in this embodiment determines the charging identifiers that are allocated to the reflow data, and sends them to the TDF entity and the PCEF entity, respectively, so that the TDF entity adds the charging identifier to the determined reflow data and sends the charging identifier to the PCEF entity. The PCEF entity determines that the data from the TDF entity is the reflow data based on the charging identifier, and then determines the SDF to which the reflow data belongs, and adjusts the determined SDF charging result to implement accurate charging.
图 24为本发明实施例提供的又一种 PCRF实体的结构示意图。如图 24所 示, 所述 PCRF实体包括: 处理器 2401、 发射器 2402和存储器 2403。 存储器 2403可以包括只读存储器和随机存取存储器, 并向处理器 2401 提供指令和数据。存储器 2403的一部分还可以包括非易失性随机存取存储器 (NVRAM) o FIG. 24 is a schematic structural diagram of still another PCRF entity according to an embodiment of the present invention. As shown in FIG. 24, the PCRF entity includes: a processor 2401, a transmitter 2402, and a memory 2403. Memory 2403 can include read only memory and random access memory and provides instructions and data to processor 2401. A portion of the memory 2403 may also include non-volatile random access memory (NVRAM) o
存储器 2403存储了如下的元素, 可执行模块或者数据结构, 或者它们的 子集, 或者它们的扩展集:  Memory 2403 stores the following elements, executable modules or data structures, or subsets thereof, or their extended sets:
操作指令: 包括各种操作指令, 用于实现各种操作。  Operation instructions: Includes various operation instructions for implementing various operations.
操作***: 包括各种***程序, 用于实现各种基础业务以及处理基于硬 件的任务。  Operating System: Includes a variety of system programs for implementing basic services and handling hardware-based tasks.
在本发明实施例中, 处理器 2401通过调用存储器 2403存储的操作指令 (该操作指令可存储在操作***中) , 执行如下操作:  In the embodiment of the present invention, the processor 2401 performs the following operations by calling an operation instruction stored in the memory 2403 (the operation instruction can be stored in the operating system):
确定需要分配给回流数据包的计费标识, 所述回流数据是指上行数据包 中影响 PCEF实体对所述上行数据包的基于 SDF粒度的计费结果的数据包。  A charging identifier that needs to be allocated to the reflow packet is determined, and the reflow data refers to a packet in the uplink packet that affects the SDF granularity-based charging result of the uplink packet by the PCEF entity.
发射器 2402, 用于将所述计费标识发送给 TDF实体和所述 PCEF实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确定出所述回流 数据后在所述回流数据中添加所述计费标识后向所述 PCEF实体发送,使所述 PCEF实体根据所述计费标识确定所述回流数据并基于所述回流数据对所述上 行数据包的基于 SDF粒度的计费结果进行调整。  a transmitter 2402, configured to send the charging identifier to a TDF entity and the PCEF entity, where the TDF entity determines the reflow data from the uplink data packet from the PCEF entity Adding the charging identifier to the PCEF entity, and then sending, by the PCEF entity, the reflow data according to the charging identifier, and based on the reflow data, based on the SDF granularity of the uplink data packet. The billing results are adjusted.
可选的, 如图 24所示, 所述 PCRF实体还可以包括: 接收器 2404。  Optionally, as shown in FIG. 24, the PCRF entity may further include: a receiver 2404.
处理器 2401控制 PCRF实体的操作, 处理器 2401还可以称为 CPU。 存储 器 2403可以包括只读存储器和随机存取存储器, 并向处理器 2401提供指令 和数据。存储器 2403的一部分还可以包括非易失性随机存取存储器(NVRAM)。 具体的应用中, PCRF实体的各个组件通过总线*** 2405耦合在一起, 其中 总线*** 2405除包括数据总线之外, 还可以包括电源总线、控制总线和状态 信号总线等。 但是为了清楚说明起见, 在图中将各种总线都标为总线*** 2405 ο  The processor 2401 controls the operation of the PCRF entity, which may also be referred to as a CPU. The memory 2403 can include read only memory and random access memory and provides instructions and data to the processor 2401. A portion of the memory 2403 may also include non-volatile random access memory (NVRAM). In a specific application, the components of the PCRF entity are coupled together by a bus system 2405. The bus system 2405 may include a power bus, a control bus, and a status signal bus in addition to the data bus. However, for the sake of clarity, various buses are labeled as bus system 2405 in the figure.
上述本发明实施例揭示的方法可以应用于处理器 2401中,或者由处理器 2401实现。 处理器 2401可能是一种集成电路芯片, 具有信号的处理能力。 在实现过程中,上述方法的各步骤可以通过处理器 2401中的硬件的集成逻辑 电路或者软件形式的指令完成。上述的处理器 2401可以是通用处理器、数字 信号处理器 (DSP ) 、 专用集成电路 (ASIC ) 、 现成可编程门阵列 (FPGA) 或 者其他可编程逻辑器件、 分立门或者晶体管逻辑器件、 分立硬件组件。 通用 处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。 结合本 发明实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成, 或者用译码处理器中的硬件及软件模块组合执行完成。 软件模块可以位于随 机存储器, 闪存、 只读存储器, 可编程只读存储器或者电可擦写可编程存储 器、 寄存器等本领域成熟的存储介质中。 该存储介质位于存储器 2403, 处理 器 2401读取存储器 2403中的信息, 结合其硬件完成上述方法的步骤。 The method disclosed in the foregoing embodiments of the present invention may be applied to the processor 2401 or implemented by the processor 2401. The processor 2401 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the foregoing method may be completed by an integrated logic circuit of hardware in the processor 2401 or an instruction in a form of software. The processor 2401 described above may be a general purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), an off-the-shelf programmable gate array (FPGA), or Other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The general purpose processor may be a microprocessor or the processor or any conventional processor or the like. The steps of the method disclosed in the embodiments of the present invention may be directly implemented as a hardware decoding processor, or may be performed by a combination of hardware and software modules in the decoding processor. The software modules can be located in a conventional storage medium such as random access memory, flash memory, read only memory, programmable read only memory or electrically erasable programmable memory, registers, and the like. The storage medium is located in the memory 2403, and the processor 2401 reads the information in the memory 2403 and completes the steps of the above method in combination with the hardware thereof.
在一可选实施方式中,发射器 2402用于将所述计费标识发送给 TDF实体, 包括:  In an optional implementation, the transmitter 2402 is configured to send the charging identifier to the TDF entity, including:
发射器 2402具体用于向所述 TDF实体发送 TDF会话建立请求消息,所述 The transmitter 2402 is specifically configured to send a TDF session establishment request message to the TDF entity, where
TDF会话建立请求消息包括所述计费标识。 The TDF session establishment request message includes the charging identifier.
可选的, 接收器 2404可用于在发射器 2402向所述 TDF实体发送 TDF会 话建立请求消息之后, 接收所述 TDF实体发送 TDF会话建立响应消息。  Optionally, the receiver 2404 is configured to: after the transmitter 2402 sends a TDF session setup request message to the TDF entity, receive the TDF entity to send a TDF session setup response message.
在一可选实施方式中,发射器 2402用于将所述计费标识发送给所述 PCEF 实体, 包括:  In an optional implementation, the transmitter 2402 is configured to send the charging identifier to the PCEF entity, including:
发射器 2402具体用于向所述 PCEF实体发送 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标识。  The transmitter 2402 is specifically configured to send an IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes the charging identifier.
接收器 2404还用于在发射器 2402向所述 PCEF实体发送 IP-CAN会话建 立响应消息之前, 接收所述 PCEF实体发送的 IP-CAN会话建立请求消息。  The receiver 2404 is further configured to receive an IP-CAN session establishment request message sent by the PCEF entity before the transmitter 2402 sends an IP-CAN session establishment response message to the PCEF entity.
本实施例提供的 PCRF 实体可用于执行上述方法实施例中第三种计费方 法的流程, 其具体工作原理不再赘述, 详见方法实施例的描述。  The PCRF entity provided in this embodiment may be used to perform the process of the third charging method in the foregoing method embodiment. The specific working principle is not described here. For details, refer to the description of the method embodiment.
本实施例提供的 PCRF实体, 确定分配给回流数据的计费标识, 并分别发 送给 TDF实体和 PCEF实体,使得 TDF实体在确定出的回流数据中添加所述计 费标识后发送给 PCEF实体, 而 PCEF实体基于所述计费标识确定来自于 TDF 实体的数据是回流数据, 进而确定回流数据所属的 SDF, 对所确定出的 SDF 的计费结果进行调整, 实现准确计费。  The PCRF entity provided in this embodiment determines the charging identifiers that are allocated to the reflow data, and sends them to the TDF entity and the PCEF entity, respectively, so that the TDF entity adds the charging identifier to the determined reflow data and sends the charging identifier to the PCEF entity. The PCEF entity determines that the data from the TDF entity is the reflow data based on the charging identifier, and then determines the SDF to which the reflow data belongs, and adjusts the determined SDF charging result to implement accurate charging.
本领域普通技术人员可以理解: 实现上述方法实施例的全部或部分步骤 可以通过程序指令相关的硬件来完成, 前述的程序可以存储于一计算机可读 取存储介质中, 该程序在执行时, 执行包括上述方法实施例的步骤; 而前述 的存储介质包括: R0M、 RAM, 磁碟或者光盘等各种可以存储程序代码的介质。 最后应说明的是: 以上各实施例仅用以说明本发明的技术方案, 而非对 其限制; 尽管参照前述各实施例对本发明进行了详细的说明, 本领域的普通 技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改, 或者对其中部分或者全部技术特征进行等同替换; 而这些修改或者替换, 并 不使相应技术方案的本质脱离本发明各实施例技术方案的范围。 A person skilled in the art can understand that all or part of the steps of implementing the above method embodiments may be completed by using hardware related to program instructions, and the foregoing program may be stored in a computer readable storage medium, and the program is executed when executed. The steps of the foregoing method embodiments are included; and the foregoing storage medium includes: a medium that can store program codes, such as a ROM, a RAM, a magnetic disk, or an optical disk. Finally, it should be noted that the above embodiments are only for explaining the technical solutions of the present invention, and are not intended to be limiting thereof; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art will understand that The technical solutions described in the foregoing embodiments may be modified, or some or all of the technical features may be equivalently replaced; and the modifications or substitutions do not deviate from the technical solutions of the embodiments of the present invention. range.

Claims

权利 要 求书 claims
1、 一种计费方法, 其特征在于, 包括: 1. A billing method, characterized by including:
策略控制和计费规则功能 PCRF实体确定需要计费的第一应用,并为所述 第一应用分配计费标识, 所述计费标识用于标识需要对所述第一应用进行单 独计费; The policy control and charging rule function PCRF entity determines the first application that requires charging, and allocates a charging identifier to the first application, where the charging identifier is used to identify that separate charging is required for the first application;
所述 PCRF 实体将所述第一应用的标识和为所述第一应用分配的计费标 识分别发送给用户设备 UE、 策略和计费执行 PCEF实体和业务检测功能 TDF 实体, 以使所述 UE和所述 TDF实体在所述第一应用的数据包中添加所述计费 标识后发送给所述 PCEF实体, 使所述 PCEF实体基于所述第一应用的标识和 为所述第一应用分配的计费标识分别对来自所述 UE和所述 TDF实体的携带有 所述计费标识的数据包进行单独计费。 The PCRF entity sends the identity of the first application and the charging identity assigned to the first application to the user equipment UE, the policy and charging execution PCEF entity and the service detection function TDF entity respectively, so that the UE and the TDF entity adds the charging identifier to the data packet of the first application and sends it to the PCEF entity, so that the PCEF entity allocates the information to the first application based on the identifier of the first application and The charging identifier separately charges the data packets carrying the charging identifier from the UE and the TDF entity.
2、 根据权利要求 1所述的方法, 其特征在于, 所述 PCRF实体将所述第 一应用的标识和为所述第一应用分配的计费标识分别发送给 UE和 PCEF实体, 包括: 2. The method according to claim 1, wherein the PCRF entity sends the identity of the first application and the charging identity assigned to the first application to the UE and the PCEF entity respectively, including:
所述 PCRF实体向所述 PCEF实体发送互联网连接访问网络 IP-CAN会话建 立响应消息,所述 IP-CAN会话建立响应消息包括所述第一应用的标识和为所 述第一应用的分配的计费标识, 以使所述 PCEF实体通过服务网关设备将所述 第一应用的标识和为所述第一应用分配的计费标识发送给所述 UE。 The PCRF entity sends an Internet connection access network IP-CAN session establishment response message to the PCEF entity. The IP-CAN session establishment response message includes the identification of the first application and the allocated calculation for the first application. The PCEF entity sends the identity of the first application and the charging identity assigned to the first application to the UE through the service gateway device.
3、根据权利要求 2所述的方法,其特征在于,所述 PCRF实体向所述 PCEF 实体发送 IP-CAN会话建立响应消息之前, 还包括: 3. The method according to claim 2, characterized in that before the PCRF entity sends the IP-CAN session establishment response message to the PCEF entity, it further includes:
所述 PCRF实体接收所述 PCEF实体发送的 IP-CAN会话建立请求消息。 The PCRF entity receives the IP-CAN session establishment request message sent by the PCEF entity.
4、 根据权利要求 1-3任一项所述的方法, 其特征在于, 所述 PCRF实体 将所述第一应用的标识和为所述第一应用分配的计费标识 TDF实体, 包括: 所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会 话建立请求消息包括所述第一应用的标识和为所述第一应用分配的计费标 识。 4. The method according to any one of claims 1 to 3, characterized in that, the PCRF entity combines the identity of the first application and the charging identity TDF entity allocated for the first application, including: The PCRF entity sends a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the identity of the first application and the charging identity assigned to the first application.
5、根据权利要求 4所述的方法, 其特征在于, 所述 PCRF实体向所述 TDF 实体发送 TDF会话建立请求消息之后, 还包括: 5. The method according to claim 4, characterized in that, after the PCRF entity sends a TDF session establishment request message to the TDF entity, it further includes:
所述 PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。 The PCRF entity receives the TDF session establishment response message sent by the TDF entity.
6、 根据权利要求 1所述的方法, 其特征在于, 所述 PCRF实体确定需要 计费的第一应用, 包括: 6. The method according to claim 1, characterized in that the PCRF entity determines the need The first application for billing, including:
所述 PCRF实体接收所述 TDF实体发送的业务流探测事件,所述业务流探 测事件是所述 TDF实体探测到需要计费的所述第一应用的数据包后发送的, 且所述业务流探测事件包括所述第一应用的标识; The PCRF entity receives a business flow detection event sent by the TDF entity. The business flow detection event is sent after the TDF entity detects the data packet of the first application that needs to be charged, and the business flow detection event The detection event includes the identification of the first application;
所述 PCRF实体根据所述第一应用的标识确定所述第一应用。 The PCRF entity determines the first application according to the identification of the first application.
7、 根据权利要求 6所述的方法, 其特征在于, 所述 PCRF实体将所述第 一应用的标识和为所述第一应用分配的计费标识分别发送给 UE和 PCEF实体, 包括: 7. The method according to claim 6, wherein the PCRF entity sends the identity of the first application and the charging identity assigned to the first application to the UE and the PCEF entity respectively, including:
所述 PCRF实体向所述 PCEF实体发送策略与计费规则消息, 所述策略与 计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费标识, 以使所述 PCEF 实体通过服务网关设备将所述第一应用的标识和为所述第一 应用分配的计费标识发送给所述 UE。 The PCRF entity sends a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes the identity of the first application and the charging identity assigned to the first application, so that the The PCEF entity sends the identity of the first application and the charging identity assigned to the first application to the UE through the service gateway device.
8、 根据权利要求 6或 7所述的方法, 其特征在于, 所述 PCRF实体将所 述第一应用的标识和为所述第一应用分配的计费标识 TDF实体, 包括: 8. The method according to claim 6 or 7, characterized in that the PCRF entity combines the identity of the first application and the charging identity assigned to the first application to the TDF entity, including:
所述 PCRF实体向所述 TDF实体发送修改应用探测控制 ADC规则消息,所 述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配的计费 标识。 The PCRF entity sends a modified application detection control ADC rule message to the TDF entity, where the modified ADC rule message includes the identifier of the first application and the charging identifier assigned to the first application.
9、 一种计费方法, 其特征在于, 包括: 9. A billing method, characterized by including:
策略和计费执行 PCEF实体接收策略控制和计费规则功能 PCRF实体发送 的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用 分配的计费标识; Policy and charging execution The PCEF entity receives the identity of the first application that requires separate charging determined by the PCRF entity and the charging identity assigned to the first application sent by the policy control and charging rule function PCRF entity;
所述 PCEF 实体将所述第一应用的标识和为所述第一应用分配的计费标 识通过服务网关设备发送给用户设备 UE, 以使所述 UE在所述第一应用的上 行数据包中添加所述计费标识后向所述 PCEF实体发送; The PCEF entity sends the identity of the first application and the charging identity assigned to the first application to the user equipment UE through the serving gateway device, so that the UE can be included in the uplink data packet of the first application. Add the charging identifier and send it to the PCEF entity;
所述 PCEF实体接收所述 UE发送的携带有所述计费标识的上行数据包, 并根据所述计费标识对携带有所述计费标识的上行数据包进行单独计费。 The PCEF entity receives the uplink data packet carrying the charging identification sent by the UE, and performs separate charging on the uplink data packet carrying the charging identification according to the charging identification.
10、 根据权利要求 9所述的方法, 其特征在于, 还包括: 10. The method according to claim 9, further comprising:
所述 PCEF实体接收业务检测功能 TDF实体发送的携带有所述计费标识的 下行数据包, 并根据所述计费标识对携带有所述计费标识的下行数据包进行 单独计费。 The PCEF entity receives the downlink data packet carrying the charging identification sent by the service detection function TDF entity, and performs separate charging on the downlink data packet carrying the charging identification according to the charging identification.
11、 根据权利要求 9或 10所述的方法, 其特征在于, 所述 PCEF实体接 收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第一应用的标识和 为所述第一应用分配的计费标识, 包括: 11. The method according to claim 9 or 10, characterized in that, the PCEF entity receives the identifier of the first application that requires separate charging and is determined by the PCRF entity and is sent by the PCRF entity and allocates the information to the first application. The billing identifier includes:
所述 PCEF实体接收所述 PCRF实体发送的互联网连接访问网络 IP-CAN会 话建立响应消息,所述 IP-CAN会话建立响应消息包括所述第一应用的标识和 为所述第一应用的分配的计费标识; 或者 The PCEF entity receives the Internet connection access network IP-CAN session establishment response message sent by the PCRF entity. The IP-CAN session establishment response message includes the identification of the first application and the allocation of the first application. Billing ID; or
所述 PCEF实体接收所述 PCRF实体发送的策略与计费规则消息, 所述策 略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费标 识。 The PCEF entity receives the policy and charging rule message sent by the PCRF entity, and the policy and charging rule message includes the identifier of the first application and the charging identifier assigned to the first application.
12、 根据权利要求 11所述的方法, 其特征在于, 所述 PCEF实体接收所 述 PCRF实体发送的 IP-CAN会话建立响应消息之前, 还包括: 12. The method according to claim 11, wherein before the PCEF entity receives the IP-CAN session establishment response message sent by the PCRF entity, it further includes:
所述 PCEF实体向所述 PCRF实体发送 IP-CAN会话建立请求消息。 The PCEF entity sends an IP-CAN session establishment request message to the PCRF entity.
13、 根据权利要求 9-12任一项所述的方法, 其特征在于, 所述 PCEF实 体将所述第一应用的标识和为所述第一应用分配的计费标识通过服务网关设 备发送给 UE, 包括: 13. The method according to any one of claims 9 to 12, characterized in that, the PCEF entity sends the identity of the first application and the charging identity assigned to the first application through the service gateway device. UE, including:
所述 PCEF实体向所述服务网关设备发送 IP-CAN承载建立响应消息, 所 述 IP-CAN承载建立响应消息包括所述第一应用的标识和为所述第一应用分 配的计费标识, 以使所述服务网关设备将所述第一应用的标识和为所述第一 应用分配的计费标识发送给所述 UE。 The PCEF entity sends an IP-CAN bearer establishment response message to the serving gateway device, where the IP-CAN bearer establishment response message includes the identification of the first application and the charging identification assigned to the first application, so as to The serving gateway device is caused to send the identity of the first application and the charging identity assigned to the first application to the UE.
14、 根据权利要求 13所述的方法, 其特征在于, 所述 PCEF实体向所述 服务网关设备发送 IP-CAN承载建立响应消息之前, 还包括: 14. The method according to claim 13, wherein before the PCEF entity sends the IP-CAN bearer establishment response message to the serving gateway device, it further includes:
所述 PCEF实体接收所述服务网关设备发送的 IP-CAN承载建立请求消息, 所述 IP-CAN承载建立请求消息包括所述 UE的标识。 The PCEF entity receives the IP-CAN bearer establishment request message sent by the serving gateway device, and the IP-CAN bearer establishment request message includes the identity of the UE.
15、 一种计费方法, 其特征在于, 包括: 15. A billing method, characterized by including:
业务检测功能 TDF实体接收策略控制和计费规则功能 PCRF实体发送的所 述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配 的计费标识; The service detection function TDF entity receives the policy control and charging rule function The identification of the first application that requires separate charging and the charging identification assigned to the first application determined by the PCRF entity and sent by the PCRF entity;
所述 TDF 实体根据所述第一应用的标识确定所述第一应用的下行数据 包, 在所述第一应用的下行数据包中添加所述计费标识; The TDF entity determines the downlink data packet of the first application based on the identifier of the first application, and adds the charging identifier to the downlink data packet of the first application;
所述 TDF实体将添加所述计费标识的下行数据包发送给策略和计费执行 PCEF实体, 以使所述 PCEF实体基于所述计费标识对所述第一应用的下行数 据包进行单独计费。 The TDF entity sends the downlink data packet with the charging identifier added to the policy and charging execution PCEF entity, so that the PCEF entity separately charges the downlink data packet of the first application based on the charging identifier.
16、根据权利要求 15所述的方法, 其特征在于, 所述 TDF实体接收 PCRF 实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述 第一应用分配的计费标识, 包括: 16. The method according to claim 15, characterized in that, the TDF entity receives, sent by the PCRF entity, the identification of the first application that requires separate charging determined by the PCRF entity and the accounting information allocated for the first application. Fee identification, including:
所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用分配的计 费标识。 The TDF entity receives the TDF session establishment request message sent by the PCRF entity, and the TDF session establishment request message includes the identification of the first application and the charging identification assigned to the first application.
17、 根据权利要求 16所述的方法, 其特征在于, 所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息之后, 还包括: 17. The method according to claim 16, characterized in that, after the TDF entity receives the TDF session establishment request message sent by the PCRF entity, it further includes:
所述 TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。 The TDF entity sends a TDF session establishment response message to the PCRF entity.
18、根据权利要求 15所述的方法, 其特征在于, 所述 TDF实体接收 PCRF 实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述 第一应用分配的计费标识之前, 还包括: 18. The method according to claim 15, characterized in that, the TDF entity receives, sent by the PCRF entity, the identification of the first application that requires separate charging determined by the PCRF entity and the accounting information allocated for the first application. Before the fee logo, also include:
所述 TDF实体探测需要单独计费的所述第一应用的数据包, 并在探测到 所述第一应用的数据包后, 向所述 PCRF实体发送业务流探测事件, 所述业务 流探测事件包括所述第一应用的标识, 以使所述 PCRF实体根据所述第一应用 的标识确定需要对所述第一应用进行单独计费。 The TDF entity detects the data packet of the first application that requires separate charging, and after detecting the data packet of the first application, sends a business flow detection event to the PCRF entity, the business flow detection event The identifier of the first application is included, so that the PCRF entity determines that the first application needs to be charged separately according to the identifier of the first application.
19、根据权利要求 18所述的方法, 其特征在于, 所述 TDF实体接收 PCRF 实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述 第一应用分配的计费标识, 包括: 19. The method according to claim 18, characterized in that, the TDF entity receives, sent by the PCRF entity, the identification of the first application that requires separate charging determined by the PCRF entity and the accounting information allocated for the first application. Fee identification, including:
所述 TDF实体接收所述 PCRF实体发送的修改应用探测控制 ADC规则消 息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分配 的计费标识。 The TDF entity receives the modified application detection control ADC rule message sent by the PCRF entity, and the modified ADC rule message includes the identifier of the first application and the charging identifier assigned to the first application.
20、 一种计费方法, 其特征在于, 包括: 20. A billing method, characterized by including:
策略控制和计费规则功能 PCRF实体向业务检测功能 TDF实体发送的策略 与计费控制 PCC规则标识和 /或服务数据流 SDF模板, 以供所述 TDF实体确定 影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和第一应用的数据包的流量; The policy control and charging rule function PCRF entity sends the policy and charging control PCC rule identification and/or service data flow SDF template to the service detection function TDF entity, so that the TDF entity determines the impact policy and charging execution based on the PCEF entity The SDF granular charging result includes the identification of the SDF to which the first application belongs and the traffic volume of the data packet of the first application;
所述 PCRF实体接收所述 TDF实体发送的根据所述 PCC规则标识和 /或 SDF 模板确定的所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流 所述 PCRF实体将所述第一应用所属的 SDF的标识和所述第一应用的数据 包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应用所属 的 SDF的标识和所述第一应用的数据包的流量对来自用户设备 UE的上行数据 包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包属于来 自所述 UE的上行数据包。 The PCRF entity receives the identity and/or SDF sent by the TDF entity according to the PCC rule. The template determines the identity of the SDF to which the first application belongs and the flow of data packets of the first application. The PCRF entity determines the identity of the SDF to which the first application belongs and the flow of data packets of the first application. Sent to the PCEF entity, so that the PCEF entity charges the uplink data packets from the user equipment UE based on the SDF granularity based on the identity of the SDF to which the first application belongs and the traffic of the data packets of the first application. The result is adjusted; wherein, the data packet of the first application belongs to the uplink data packet from the UE.
21、 根据权利要求 20所述的方法, 其特征在于, 所述 PCRF实体向 TDF 实体发送的 PCC规则标识和 /或 SDF模板, 包括: 21. The method according to claim 20, characterized in that the PCC rule identification and/or SDF template sent by the PCRF entity to the TDF entity includes:
所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会 话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。 The PCRF entity sends a TDF session establishment request message to the TDF entity, and the TDF session establishment request message includes the PCC rule identification and/or SDF template.
22、 根据权利要求 21所述的方法, 其特征在于, 所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息之后, 还包括: 22. The method according to claim 21, characterized in that, after the PCRF entity sends the TDF session establishment request message to the TDF entity, it further includes:
所述 PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。 The PCRF entity receives the TDF session establishment response message sent by the TDF entity.
23、 根据权利要求 20-22任一项所述的方法, 其特征在于, 所述 PCRF实 体将所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量发送给 所述 PCEF实体, 包括: 23. The method according to any one of claims 20 to 22, characterized in that, the PCRF entity sends the identification of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entities, including:
所述 PCRF实体向所述 PCEF实体发送互联网连接访问网络 IP-CAN会话修 改请求消息,所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的 标识和所述第一应用的数据包的流量。 The PCRF entity sends an Internet connection access network IP-CAN session modification request message to the PCEF entity. The IP-CAN session modification request message includes the identification of the SDF to which the first application belongs and the data of the first application. Packet traffic.
24、 一种计费方法, 其特征在于, 包括: 24. A billing method, characterized by including:
策略和计费执行 PCEF实体接收策略控制和计费规则功能 PCRF实体发送 的影响所述 PCEF实体基于服务数据流 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量; 其中, 所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流量是业务检测功能 TDF 实体根据所述 PCRF实体发送的策略与计费控制 PCC规则标识和 /或 SDF模板确定并发送给 所述 PCRF实体的; The policy and charging execution PCEF entity receives the identity of the SDF to which the first application belongs and the SDF of the first application that affects the charging result of the PCEF entity based on the service data flow SDF granularity sent by the policy control and charging rule function PCRF entity. The traffic of the data packet; wherein, the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application are the identity of the policy and charging control PCC rules sent by the service detection function TDF entity according to the PCRF entity and /or the SDF template is determined and sent to the PCRF entity;
所述 PCEF实体根据所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量,对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行 调整, 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。 The PCEF entity adjusts the SDF granularity-based charging result of the uplink data packet from the user equipment UE according to the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application, wherein, The data packet of the first application belongs to the uplink data packet from the UE.
25、根据权利要求 24所述的方法,其特征在于,所述 PCEF实体接收 PCRF 实体发送的影响所述 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量之前, 还包括: 25. The method according to claim 24, characterized in that the PCEF entity receives the identifier of the SDF to which the first application that affects the PCEF entity's charging result based on SDF granularity and the first application is sent by the PCRF entity. Before applying the packet traffic, also include:
所述 PCEF实体对来自所述 UE的上行数据包进行基于 SDF粒度的计费。 The PCEF entity performs SDF granularity-based charging on uplink data packets from the UE.
26、 根据权利要求 24或 25所述的方法, 其特征在于, 所述 PCEF实体接 收 PCRF实体发送的影响所述 PCEF实体基于 SDF粒度的计费结果的第一应用 所属的 SDF的标识和所述第一应用的数据包的流量, 包括: 26. The method according to claim 24 or 25, characterized in that, the PCEF entity receives the identification of the SDF to which the first application that affects the PCEF entity's charging result based on SDF granularity and the said The traffic of the first application packet, including:
所述 PCEF实体接收所述 PCRF实体发送的互联网连接访问网络 IP-CAN会 话修改请求消息, 所述 IP-CAN会话修改请求消息包括所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量。 The PCEF entity receives the Internet connection access network IP-CAN session modification request message sent by the PCRF entity. The IP-CAN session modification request message includes the identification of the SDF to which the first application belongs and the ID of the first application. Packet traffic.
27、 一种计费方法, 其特征在于, 包括: 27. A billing method, characterized by including:
业务检测功能 TDF实体接收策略控制和计费规则功能 PCRF实体发送的策 略与计费控制 PCC规则标识和 /或服务数据流 SDF模板; Business detection function TDF entity receives policy control and charging rule function Policy and charging control sent by PCRF entity PCC rule identification and/or service data flow SDF template;
所述 TDF实体根据所述 PCC规则标识和 /或 SDF模板,确定影响策略和计 费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所 述第一应用的数据包的流量; The TDF entity determines, according to the PCC rule identifier and/or SDF template, the identity of the SDF to which the first application belongs and the data packet of the first application that affects the policy and charging execution based on the SDF granularity charging result of the PCEF entity. flow;
所述 TDF实体将所述第一应用所属的 SDF的标识和所述第一应用的数据 包的流量通过所述 PCRF实体发送给所述 PCEF实体, 以使所述 PCEF实体基于 所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量对来自用户 设备 UE的上行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应 用的数据包属于来自所述 UE的上行数据包。 The TDF entity sends the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity through the PCRF entity, so that the PCEF entity is based on the first application. The identification of the SDF to which it belongs and the traffic volume of the data packet of the first application adjust the charging result of the uplink data packet from the user equipment UE based on the SDF granularity; wherein, the data packet of the first application belongs to the UE. of upstream data packets.
28、根据权利要求 27所述的方法, 其特征在于, 所述 TDF实体接收 PCRF 实体发送的 PCC规则标识和 /或 SDF模板, 包括: 28. The method according to claim 27, characterized in that the TDF entity receives the PCC rule identification and/or SDF template sent by the PCRF entity, including:
所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。 The TDF entity receives the TDF session establishment request message sent by the PCRF entity, and the TDF session establishment request message includes the PCC rule identification and/or SDF template.
29、 根据权利要求 28所述的方法, 其特征在于, 所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息之后, 还包括: 29. The method according to claim 28, wherein after the TDF entity receives the TDF session establishment request message sent by the PCRF entity, it further includes:
所述 TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。 The TDF entity sends a TDF session establishment response message to the PCRF entity.
30、 根据权利要求 27-29任一项所述的方法, 其特征在于, 所述 TDF实 体根据所述 PCC规则标识和 /或 SDF模板, 确定影响 PCEF实体基于 SDF粒度 的计费结果的第一应用所属的 SDF的标识和所述第一应用的数据包的流量, 包括: 30. The method according to any one of claims 27 to 29, characterized in that, the TDF entity determines the influencing PCEF entity based on the PCC rule identifier and/or SDF template based on SDF granularity The identification of the SDF to which the first application belongs and the traffic volume of the data packet of the first application include:
所述 TDF实体根据所述 PCC规则标识指示的 PCC规则, 确定因执行基于 应用的流控而被丢弃的数据包所属的应用作为所述第一应用, 确定所述被丢 弃的数据包的流量作为所述第一应用的数据包的流量, 并确定所述第一应用 所属的 SDF; 或者 The TDF entity determines, according to the PCC rule indicated by the PCC rule identifier, the application to which the discarded data packet belongs due to execution of application-based flow control as the first application, and determines the flow of the discarded data packet as The traffic of data packets of the first application, and determine the SDF to which the first application belongs; or
所述 TDF实体根据所述 SDF模板探测到不需要对来自所述 UE的上行数据 包中具有相同 IP地址信息的所有数据包进行计费时, 从具有相同 IP地址信 息的所有数据包中, 确定实际需要计费的数据包所属的应用作为所述第一应 用, 确定实际需要计费的数据包的流量作为所述第一应用的数据包的流量, 并确定所述第一应用所属的 SDF; 或者, When the TDF entity detects that it is not necessary to charge all data packets with the same IP address information in the uplink data packets from the UE according to the SDF template, determine from all data packets with the same IP address information The application to which the data packets that actually need to be charged belongs is used as the first application, the traffic of the data packets that actually need to be charged is determined as the traffic of the data packets of the first application, and the SDF to which the first application belongs is determined; or,
TDF实体根据所述 SDF模板探测到不需要对来自所述 UE的上行数据包中 具有相同 IP地址信息的所有数据包进行计费时, 从具有相同 IP地址信息的 所有数据包, 确定出不需要计费的数据包所属的应用作为所述第一应用, 确 定不需要计费的数据包的流量作为所述第一应用的数据包的流量, 并确定所 述第一应用所属的 SDF。 When the TDF entity detects that it is not necessary to charge all data packets with the same IP address information in the uplink data packets from the UE according to the SDF template, it determines from all data packets with the same IP address information that it is not necessary. The application to which the charged data packets belong is used as the first application, the traffic of the data packets that do not need to be charged is determined as the traffic of the data packets of the first application, and the SDF to which the first application belongs is determined.
31、 一种计费方法, 其特征在于, 包括: 31. A billing method, characterized by including:
业务检测功能 TDF实体接收到策略和计费执行 PCEF实体发送的上行数据 包后, 确定回流数据, 并为所述回流数据添加计费标识, 所述回流数据是指 所述上行数据包中影响所述 PCEF实体对所述上行数据包基于服务数据流 SDF 粒度的计费结果的数据包; After the service detection function TDF entity receives the uplink data packet sent by the policy and charging execution PCEF entity, it determines the backflow data and adds a charging identifier to the backflow data. The backflow data refers to the affected data in the uplink data packet. The PCEF entity charges the uplink data packet based on the service data flow SDF granularity of the data packet;
所述 TDF实体将携带所述计费标识的回流数据发送给所述 PCEF实体, 以 使所述 PCEF实体根据携带所述计费标识的回流数据,对所述上行数据包基于 SDF粒度的计费结果进行调整。 The TDF entity sends the backflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity charges the uplink data packet based on SDF granularity based on the backflow data carrying the charging identifier. The results are adjusted.
32、 根据权利要求 31 所述的方法, 其特征在于, 所述 TDF实体接收到 32. The method according to claim 31, characterized in that the TDF entity receives
PCEF实体发送的上行数据包后, 确定回流数据, 并为所述回流数据添加计费 标识之前, 还包括: After the PCEF entity sends the uplink data packet, it determines the return data, and before adding the charging identifier to the return data, it also includes:
所述 TDF实体接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识。 The TDF entity receives the charging identifier sent by the policy control and charging rule function PCRF entity and allocated by the PCRF entity for the reflow data.
33、根据权利要求 32所述的方法, 其特征在于, 所述 TDF实体接收 PCRF 实体发送的所述 PCRF实体为所述回流数据分配的所述计费标识, 包括: 所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息, 所述 TDF会话建立请求消息包括所述计费标识。 33. The method according to claim 32, characterized in that, the TDF entity receives PCRF The charging identifier sent by the PCRF entity for the backflow data includes: the TDF entity receives the TDF session establishment request message sent by the PCRF entity, and the TDF session establishment request message includes the accounting fee logo.
34、 根据权利要求 33所述的方法, 其特征在于, 所述 TDF实体接收所述 PCRF实体发送的 TDF会话建立请求消息之后, 还包括: 34. The method according to claim 33, characterized in that, after the TDF entity receives the TDF session establishment request message sent by the PCRF entity, it further includes:
所述 TDF实体向所述 PCRF实体发送 TDF会话建立响应消息。 The TDF entity sends a TDF session establishment response message to the PCRF entity.
35、 一种计费方法, 其特征在于, 包括: 35. A billing method, characterized by including:
策略和计费执行 PCEF实体在对上行数据包进行基于服务数据流 SDF粒度 的计费之后,接收业务检测功能 TDF实体发送的携带有计费标识的回流数据, 所述回流数据是所述 TDF实体确定的所述上行数据包中影响所述 PCEF实体对 所述上行数据包的基于 SDF粒度的计费结果的数据包; After the policy and charging execution PCEF entity performs charging on the uplink data packet based on the service data flow SDF granularity, it receives the return data carrying the charging identifier sent by the service detection function TDF entity, and the return data is the TDF entity The determined data packets in the uplink data packets affect the SDF granularity-based charging result of the PCEF entity for the uplink data packets;
所述 PCEF实体根据所述计费标识确定接收到的数据是所述回流数据,确 定所述回流数据所属的 SDF, 对所述确定的 SDF的计费结果进行调整。 The PCEF entity determines that the received data is the reflow data according to the charging identifier, determines the SDF to which the reflow data belongs, and adjusts the charging result of the determined SDF.
36、根据权利要求 35所述的方法, 其特征在于, 所述 PCEF实体接收 TDF 实体发送的携带有计费标识的回流数据之前, 包括: 36. The method according to claim 35, characterized in that, before the PCEF entity receives the reflow data carrying the charging identifier sent by the TDF entity, it includes:
所述 PCEF实体接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体为所述回流数据分配的所述计费标识。 The PCEF entity receives the charging identifier sent by the policy control and charging rule function PCRF entity and allocated by the PCRF entity for the reflow data.
37、根据权利要求 36所述的方法,其特征在于,所述 PCEF实体接收 PCRF 实体发送的所述 PCRF实体为所述回流数据分配的所述计费标识, 包括: 37. The method according to claim 36, wherein the PCEF entity receives the charging identifier sent by the PCRF entity and allocated by the PCRF entity for the reflow data, including:
所述 PCEF实体接收所述 PCRF实体发送的互联网连接访问网络 IP-CAN会 话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标识。 The PCEF entity receives the Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, and the IP-CAN session establishment response message includes the charging identifier.
38、 根据权利要求 37所述的方法, 其特征在于, 所述 PCEF实体接收所 述 PCRF实体发送的 IP-CAN会话建立响应消息之前, 还包括: 38. The method according to claim 37, wherein before the PCEF entity receives the IP-CAN session establishment response message sent by the PCRF entity, it further includes:
所述 PCEF实体向所述 PCRF实体发送 IP-CAN会话建立请求消息。 The PCEF entity sends an IP-CAN session establishment request message to the PCRF entity.
39、 一种计费方法, 其特征在于, 包括: 39. A billing method, characterized by including:
策略控制和计费规则功能 PCRF 实体确定需要分配给回流数据包的计费 标识,所述回流数据是指上行数据包中影响策略和计费执行 PCEF实体对所述 上行数据包的基于服务数据流 SDF粒度的计费结果的数据包; The policy control and charging rules function PCRF entity determines the charging identifier that needs to be allocated to the backflow data packet. The backflow data refers to the service data flow in the uplink data packet that affects the policy and charging execution PCEF entity on the uplink data packet. Data packets of accounting results at SDF granularity;
所述 PCRF实体将所述计费标识发送给业务检测功能 TDF实体和所述 PCEF 实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确定出所 述回流数据后在所述回流数据中添加所述计费标识后向所述 PCEF实体发送, 使所述 PCEF 实体根据所述计费标识确定所述回流数据并基于所述回流数据 对所述上行数据包的基于 SDF粒度的计费结果进行调整。 The PCRF entity sends the charging identification to the service detection function TDF entity and the PCEF entity, so that the TDF entity determines the uplink data packet from the PCEF entity. After the backflow data is added to the backflow data, the charging identifier is sent to the PCEF entity, so that the PCEF entity determines the backflow data based on the charging identifier and performs the uplink processing based on the backflow data. The accounting results of data packets based on SDF granularity are adjusted.
40、 根据权利要求 39所述的方法, 其特征在于, 所述 PCRF实体将所述 计费标识发送给 TDF实体, 包括: 40. The method according to claim 39, characterized in that the PCRF entity sends the charging identification to the TDF entity, including:
所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息,所述 TDF会 话建立请求消息包括所述计费标识。 The PCRF entity sends a TDF session establishment request message to the TDF entity, and the TDF session establishment request message includes the charging identifier.
41、 根据权利要求 40所述的方法, 其特征在于, 所述 PCRF实体向所述 TDF实体发送 TDF会话建立请求消息之后, 还包括: 41. The method according to claim 40, characterized in that, after the PCRF entity sends the TDF session establishment request message to the TDF entity, it further includes:
所述 PCRF实体接收所述 TDF实体发送的 TDF会话建立响应消息。 The PCRF entity receives the TDF session establishment response message sent by the TDF entity.
42、 根据权利要求 39-41任一项所述的方法, 其特征在于, 所述 PCRF实 体将所述计费标识发送给所述 PCEF实体, 包括: 42. The method according to any one of claims 39-41, characterized in that the PCRF entity sends the charging identifier to the PCEF entity, including:
所述 PCRF实体向所述 PCEF实体发送互联网连接访问网络 IP-CAN会话建 立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标识。 The PCRF entity sends an Internet connection access network IP-CAN session establishment response message to the PCEF entity, and the IP-CAN session establishment response message includes the charging identifier.
43、 根据权利要求 42所述的方法, 其特征在于, 所述 PCRF实体向所述 43. The method according to claim 42, characterized in that the PCRF entity sends a message to the
PCEF实体发送 IP-CAN会话建立响应消息之前, 还包括: Before the PCEF entity sends the IP-CAN session establishment response message, it also includes:
所述 PCRF实体接收所述 PCEF实体发送的 IP-CAN会话建立请求消息。 The PCRF entity receives the IP-CAN session establishment request message sent by the PCEF entity.
44、 一种策略控制和计费规则功能 PCRF实体, 其特征在于, 包括: 确定模块, 用于确定需要计费的第一应用; 44. A policy control and charging rule function PCRF entity, characterized in that it includes: a determination module, used to determine the first application that requires charging;
分配模块, 用于为所述第一应用分配计费标识, 所述计费标识用于标识 需要对所述第一应用进行单独计费; An allocation module, configured to allocate a charging identifier to the first application, where the charging identifier is used to identify the need for separate charging of the first application;
发送模块, 用于将所述确定模块确定的所述第一应用的标识和所述分配 模块为所述第一应用分配的计费标识分别发送给用户设备 UE、 策略和计费执 行 PCEF实体和业务检测功能 TDF实体, 以使所述 UE和所述 TDF实体在所述 第一应用的数据包中添加所述计费标识后发送给所述 PCEF实体,使所述 PCEF 实体基于所述第一应用的标识和为所述第一应用分配的计费标识分别对来自 所述 UE和所述 TDF实体的携带有所述计费标识的数据包进行单独计费。 A sending module, configured to send the identification of the first application determined by the determination module and the charging identification allocated by the allocation module to the user equipment UE, the policy and charging execution PCEF entity and The service detection function TDF entity is configured to enable the UE and the TDF entity to add the charging identifier to the data packet of the first application and then send it to the PCEF entity, so that the PCEF entity can The application identifier and the charging identifier assigned to the first application perform separate charging on the data packets carrying the charging identifier from the UE and the TDF entity.
45、 根据权利要求 44所述的 PCRF实体, 其特征在于, 所述发送模块用 于将所述第一应用的标识和为所述第一应用分配的计费标识分别发送给 UE 和 PCEF实体, 包括: 所述发送模块具体用于向所述 PCEF 实体发送互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述第一应 用的标识和为所述第一应用的分配的计费标识, 以使所述 PCEF实体通过服务 网关设备将所述第一应用的标识和为所述第一应用分配的计费标识发送给所 述 UE。 45. The PCRF entity according to claim 44, wherein the sending module is configured to send the identity of the first application and the charging identity assigned to the first application to the UE and the PCEF entity respectively, include: The sending module is specifically configured to send an Internet connection access network IP-CAN session establishment response message to the PCEF entity. The IP-CAN session establishment response message includes the identification of the first application and the ID of the first application. The assigned charging identity is so that the PCEF entity sends the identity of the first application and the charging identity assigned to the first application to the UE through the serving gateway device.
46、 根据权利要求 44或 45所述的 PCRF实体, 其特征在于, 所述发送模 块将所述第一应用的标识和为所述第一应用分配的计费标识 TDF实体,包括: 所述发送模块具体用于向所述 TDF实体发送 TDF会话建立请求消息, 所 述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用分配的 计费标识。 46. The PCRF entity according to claim 44 or 45, characterized in that the sending module combines the identity of the first application and the charging identity TDF entity allocated for the first application, including: the sending The module is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the identity of the first application and the charging identity assigned to the first application.
47、 根据权利要求 44所述的 PCRF实体, 其特征在于, 所述确定模块具 体用于接收所述 TDF实体发送的业务流探测事件, 所述业务流探测事件是所 述 TDF实体探测到需要计费的所述第一应用的数据包后发送的, 且所述业务 流探测事件包括所述第一应用的标识; 根据所述第一应用的标识确定所述第 一应用。 47. The PCRF entity according to claim 44, wherein the determining module is specifically configured to receive a service flow detection event sent by the TDF entity, and the service flow detection event is when the TDF entity detects a need to calculate The first application is sent after paying the data packet of the first application, and the business flow detection event includes the identifier of the first application; and the first application is determined according to the identifier of the first application.
48、 根据权利要求 47所述的 PCRF实体, 其特征在于, 所述发送模块用 于将所述第一应用的标识和为所述第一应用分配的计费标识分别发送给 UE 和 PCEF实体, 包括: 48. The PCRF entity according to claim 47, wherein the sending module is configured to send the identity of the first application and the charging identity assigned to the first application to the UE and the PCEF entity respectively, include:
所述发送模块具体用于向所述 PCEF实体发送策略与计费规则消息,所述 策略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的计费 标识, 以使所述 PCEF实体通过服务网关设备将所述第一应用的标识和为所述 第一应用分配的计费标识发送给所述 UE。 The sending module is specifically configured to send a policy and charging rule message to the PCEF entity, where the policy and charging rule message includes the identity of the first application and the charging identity assigned to the first application, to The PCEF entity is caused to send the identity of the first application and the charging identity assigned to the first application to the UE through the serving gateway device.
49、 根据权利要求 47或 48所述的 PCRF实体, 其特征在于, 所述发送模 块用于将所述第一应用的标识和为所述第一应用分配的计费标识 TDF实体, 包括: 49. The PCRF entity according to claim 47 or 48, characterized in that the sending module is configured to combine the identity of the first application and the charging identity allocated for the first application to the TDF entity, including:
所述发送模块具体用于向所述 TDF实体发送修改应用探测控制 ADC规则 消息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应用分 配的计费标识。 The sending module is specifically configured to send a modified application detection control ADC rule message to the TDF entity, where the modified ADC rule message includes the identifier of the first application and the charging identifier assigned to the first application.
50、 一种策略和计费执行 PCEF实体, 其特征在于, 包括: 50. A policy and charging execution PCEF entity, characterized by including:
接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识; A receiving module, configured to receive the PCRF sent by the policy control and charging rule function PCRF entity The identity of the first application that requires separate charging determined by the entity and the charging identity assigned to the first application;
发送模块, 用于将所述接收模块接收的所述第一应用的标识和为所述第 一应用分配的计费标识通过服务网关设备发送给用户设备 UE, 以使所述 UE 在所述第一应用的上行数据包中添加所述计费标识后向所述 PCEF实体发送; 所述接收模块,还用于接收所述 UE发送的携带有所述计费标识的上行数 据包; A sending module, configured to send the identification of the first application and the charging identification assigned to the first application received by the receiving module to the user equipment UE through the service gateway device, so that the UE can be used in the first application. Add the charging identifier to the uplink data packet of an application and send it to the PCEF entity; The receiving module is also used to receive the uplink data packet sent by the UE and carrying the charging identifier;
计费模块, 用于根据所述计费标识对所述接收模块接收的携带有所述计 费标识的上行数据包进行单独计费。 A charging module, configured to separately charge the uplink data packets carrying the charging identifier received by the receiving module according to the charging identifier.
51、 根据权利要求 50所述的 PCEF实体, 其特征在于, 所述接收模块还 用于接收业务检测功能 TDF实体发送的携带有所述计费标识的下行数据包; 所述计费模块, 还用于根据所述计费标识对所述接收模块接收的携带有 所述计费标识的下行数据包进行单独计费。 51. The PCEF entity according to claim 50, wherein the receiving module is further configured to receive a downlink data packet carrying the charging identifier sent by the service detection function TDF entity; the charging module is further It is used for separately charging the downlink data packet carrying the charging identifier received by the receiving module according to the charging identifier.
52、 根据权利要求 50或 51所述的 PCEF实体, 其特征在于, 所述接收模 块用于接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第一应用 的标识和为所述第一应用分配的计费标识, 包括: 52. The PCEF entity according to claim 50 or 51, wherein the receiving module is configured to receive the identifier of the first application that the PCRF entity determines needs to be separately charged and the identification number for the first application sent by the PCRF entity. An application-assigned billing identifier, including:
所述接收模块具体用于接收所述 PCRF 实体发送的互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述第一应 用的标识和为所述第一应用的分配的计费标识; 或者 The receiving module is specifically configured to receive an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity. The IP-CAN session establishment response message includes the identification of the first application and the identifier for the first application. assigned billing ID; or
所述接收模块具体用于接收所述 PCRF实体发送的策略与计费规则消息, 所述策略与计费规则消息包括所述第一应用的标识和为所述第一应用分配的 计费标识。 The receiving module is specifically configured to receive a policy and charging rule message sent by the PCRF entity, where the policy and charging rule message includes the identifier of the first application and the charging identifier assigned to the first application.
53、 根据权利要求 50-52任一项所述的 PCEF实体, 其特征在于, 所述发 送模块用于将所述第一应用的标识和为所述第一应用分配的计费标识通过服 务网关设备发送给 UE, 包括: 53. The PCEF entity according to any one of claims 50 to 52, characterized in that the sending module is configured to send the identity of the first application and the charging identity allocated to the first application through the service gateway. The device sends to the UE, including:
所述发送模块具体用于向所述服务网关设备发送 IP-CAN承载建立响应 消息,所述 IP-CAN承载建立响应消息包括所述第一应用的标识和为所述第一 应用分配的计费标识, 以使所述服务网关设备将所述第一应用的标识和为所 述第一应用分配的计费标识发送给所述 UE。 The sending module is specifically configured to send an IP-CAN bearer establishment response message to the service gateway device. The IP-CAN bearer establishment response message includes the identification of the first application and the charging allocated for the first application. Identity, so that the service gateway device sends the identification of the first application and the charging identification assigned to the first application to the UE.
54、 一种业务检测功能 TDF实体, 其特征在于, 包括: 接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识; 54. A service detection function TDF entity, which is characterized by including: A receiving module, configured to receive the identification of the first application that requires separate charging determined by the PCRF entity and the charging identification assigned to the first application sent by the policy control and charging rule function PCRF entity;
确定添加模块, 用于根据所述接收模块接收的所述第一应用的标识确定 所述第一应用的下行数据包, 在所述第一应用的下行数据包中添加所述接收 模块接收的所述计费标识; Determine and add a module, configured to determine the downlink data packet of the first application according to the identification of the first application received by the receiving module, and add all the downlink data packets received by the receiving module to the downlink data packet of the first application. The above billing identification;
发送模块, 用于将添加所述计费标识的下行数据包发送给策略和计费执 行 PCEF实体, 以使所述 PCEF实体基于所述计费标识对所述第一应用的下行 数据包进行单独计费。 A sending module, configured to send the downlink data packet with the charging identifier added to the policy and charging execution PCEF entity, so that the PCEF entity performs separate processing on the downlink data packet of the first application based on the charging identifier. Billing.
55、 根据权利要求 54所述的 TDF实体, 其特征在于, 所述接收模块用于 接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第一应用的标识 和为所述第一应用分配的计费标识, 包括: 55. The TDF entity according to claim 54, characterized in that, the receiving module is configured to receive the identifier of the first application that the PCRF entity determines needs to be separately charged and the identification number for the first application sent by the PCRF entity. Assigned billing IDs, including:
所述接收模块具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述第一应用的标识和为所述第一应用 分配的计费标识。 The receiving module is specifically configured to receive a TDF session establishment request message sent by the PCRF entity. The TDF session establishment request message includes the identification of the first application and the charging identification assigned to the first application.
56、 根据权利要求 54所述的 TDF实体, 其特征在于, 还包括: 56. The TDF entity according to claim 54, further comprising:
探测模块, 用于探测需要单独计费的所述第一应用的数据包; A detection module, configured to detect data packets of the first application that require separate charging;
所述发送模块,还用于在所述探测模块探测到所述第一应用的数据包后, 向所述 PCRF实体发送业务流探测事件,所述业务流探测事件包括所述第一应 用的标识, 以使所述 PCRF实体根据所述第一应用的标识确定需要对所述第一 应用进行单独计费。 The sending module is also configured to send a business flow detection event to the PCRF entity after the detection module detects the data packet of the first application, where the business flow detection event includes the identification of the first application. , so that the PCRF entity determines that the first application needs to be charged separately according to the identification of the first application.
57、 根据权利要求 56所述的 TDF实体, 其特征在于, 所述接收模块用于 接收 PCRF实体发送的所述 PCRF实体确定的需要单独计费的第一应用的标识 和为所述第一应用分配的计费标识, 包括: 57. The TDF entity according to claim 56, characterized in that, the receiving module is configured to receive the identifier of the first application that requires separate charging and is determined by the PCRF entity and is sent by the PCRF entity. Assigned billing IDs, including:
所述接收模块具体用于接收所述 PCRF实体发送的修改应用探测控制 ADC 规则消息, 所述修改 ADC规则消息包括所述第一应用的标识和为所述第一应 用分配的计费标识。 The receiving module is specifically configured to receive a modified application detection control ADC rule message sent by the PCRF entity, where the modified ADC rule message includes the identifier of the first application and the charging identifier assigned to the first application.
58、 一种策略控制和计费规则功能 PCRF实体, 其特征在于, 包括: 处理器, 用于确定需要计费的第一应用, 并为所述第一应用分配计费标 识, 所述计费标识用于标识需要对所述第一应用进行单独计费; 发射器, 用于将所述处理器确定的所述第一应用的标识和所述处理器为 所述第一应用分配的计费标识分别发送给用户设备 UE、策略和计费执行 PCEF 实体和业务检测功能 TDF实体, 以使所述 UE和所述 TDF实体在所述第一应用 的数据包中添加所述计费标识后发送给所述 PCEF实体, 使所述 PCEF实体基 于所述第一应用的标识和为所述第一应用分配的计费标识分别对来自所述 UE 和所述 TDF实体的携带有所述计费标识的数据包进行单独计费。 58. A policy control and charging rule function PCRF entity, characterized in that it includes: a processor, configured to determine the first application that requires charging, and allocate a charging identifier to the first application, and the charging The identifier is used to identify that the first application needs to be charged separately; A transmitter, configured to send the identity of the first application determined by the processor and the charging identity assigned by the processor to the user equipment UE, the policy and charging execution PCEF entity and The service detection function TDF entity is configured to enable the UE and the TDF entity to add the charging identifier to the data packet of the first application and then send it to the PCEF entity, so that the PCEF entity performs the operation based on the first application. The application identifier and the charging identifier assigned to the first application perform separate charging on the data packets carrying the charging identifier from the UE and the TDF entity.
59、 一种策略和计费执行 PCEF实体, 其特征在于, 包括: 59. A policy and charging execution PCEF entity, characterized by including:
接收器, 用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识; Receiver, configured to receive the identification of the first application that requires separate charging determined by the PCRF entity and the charging identification assigned to the first application sent by the policy control and charging rule function PCRF entity;
发射器, 用于将所述接收器接收的所述第一应用的标识和为所述第一应 用分配的计费标识通过服务网关设备发送给用户设备 UE, 以使所述 UE在所 述第一应用的上行数据包中添加所述计费标识后向所述 PCEF实体发送; A transmitter, configured to send the identity of the first application received by the receiver and the charging identity assigned to the first application to the user equipment UE through the serving gateway device, so that the UE can Add the charging identifier to the uplink data packet of an application and send it to the PCEF entity;
所述接收器,还用于接收所述 UE发送的携带有所述计费标识的上行数据 包; The receiver is also configured to receive an uplink data packet carrying the charging identifier sent by the UE;
处理器, 用于根据所述计费标识对所述接收器接收的携带有所述计费标 识的上行数据包进行单独计费。 A processor, configured to separately charge the uplink data packet carrying the charging identifier received by the receiver according to the charging identifier.
60、 一种业务检测功能 TDF实体, 其特征在于, 包括: 60. A business detection function TDF entity, which is characterized by including:
接收器, 用于接收策略控制和计费规则功能 PCRF实体发送的所述 PCRF 实体确定的需要单独计费的第一应用的标识和为所述第一应用分配的计费标 识; Receiver, configured to receive the identification of the first application that requires separate charging determined by the PCRF entity and the charging identification assigned to the first application sent by the policy control and charging rule function PCRF entity;
处理器, 用于根据所述接收器接收的所述第一应用的标识确定所述第一 应用的下行数据包, 在所述第一应用的下行数据包中添加所述接收器接收的 所述计费标识; A processor, configured to determine the downlink data packet of the first application according to the identification of the first application received by the receiver, and add the downlink data packet received by the receiver to the downlink data packet of the first application. billing identification;
发射器, 用于将添加所述计费标识的下行数据包发送给策略和计费执行 Transmitter, used to send the downlink data packet with the charging identifier added to the policy and charging execution
PCEF实体, 以使所述 PCEF实体基于所述计费标识对所述第一应用的下行数 据包进行单独计费。 PCEF entity, so that the PCEF entity separately charges the downlink data packet of the first application based on the charging identifier.
61、 一种策略控制和计费规则功能 PCRF实体, 其特征在于, 包括: 发送模块, 用于向业务检测功能 TDF实体发送的策略与计费控制 PCC规 则标识和 /或服务数据流 SDF模板, 以供所述 TDF实体确定影响策略和计费执 行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和第一应 用的数据包的流量; 61. A policy control and charging rule function PCRF entity, characterized in that it includes: a sending module, used to send the policy and charging control PCC rule identification and/or service data flow SDF template to the service detection function TDF entity, for the TDF entity to determine the impact policy and billing implementation The PCEF entity determines the identity of the SDF to which the first application belongs and the traffic volume of the data packet of the first application based on the SDF granular charging result;
接收模块, 用于接收所述 TDF实体发送的根据所述 PCC规则标识和 /或 SDF模板确定的所述第一应用所属的 SDF的标识和所述第一应用的数据包的 流量; A receiving module, configured to receive the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application sent by the TDF entity and determined according to the PCC rule identity and/or the SDF template;
所述发送模块, 还用于将所述第一应用所属的 SDF的标识和所述第一应 用的数据包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一 应用所属的 SDF的标识和所述第一应用的数据包的流量对来自用户设备 UE的 上行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据 包属于来自所述 UE的上行数据包。 The sending module is also configured to send the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity can The SDF identifier and the traffic of the data packet of the first application are used to adjust the charging result of the uplink data packet from the user equipment UE based on the SDF granularity; wherein, the data packet of the first application belongs to the SDF granularity. Upstream data packet.
62、 根据权利要求 61所述的 PCRF实体, 其特征在于, 所述发送模块用 于向 TDF实体发送的 PCC规则标识和 /或 SDF模板, 包括: 62. The PCRF entity according to claim 61, characterized in that the PCC rule identifier and/or SDF template sent by the sending module to the TDF entity includes:
所述发送模块具体用于向所述 TDF实体发送 TDF会话建立请求消息, 所 述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。 The sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the PCC rule identification and/or SDF template.
63、 根据权利要求 61或 62所述的 PCRF实体, 其特征在于, 所述发送模 块用于将所述第一应用所属的 SDF的标识和所述第一应用的数据包的流量发 送给所述 PCEF实体, 包括: 63. The PCRF entity according to claim 61 or 62, characterized in that the sending module is configured to send the identification of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entities, including:
所述发送模块具体用于向所述 PCEF 实体发送互联网连接访问网络 IP-CAN会话修改请求消息, 所述 IP-CAN会话修改请求消息包括所述第一应 用所属的 SDF的标识和所述第一应用的数据包的流量。 The sending module is specifically configured to send an Internet connection access network IP-CAN session modification request message to the PCEF entity. The IP-CAN session modification request message includes the identification of the SDF to which the first application belongs and the first The traffic of application packets.
64、 一种策略和计费执行 PCEF实体, 其特征在于, 包括: 64. A policy and charging execution PCEF entity, characterized by including:
接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的影响所述 PCEF实体基于服务数据流 SDF粒度的计费结果的第一应用所属的 SDF的标识 和所述第一应用的数据包的流量; 其中, 所述第一应用所属的 SDF的标识和 所述第一应用的数据包的流量是业务检测功能 TDF实体根据所述 PCRF实体发 送的策略与计费控制 PCC规则标识和 /或 SDF模板确定并发送给所述 PCRF实 体的; A receiving module, configured to receive the identification of the SDF to which the first application belongs and the data packet of the first application sent by the policy control and charging rule function PCRF entity that affects the charging result of the PCEF entity based on the service data flow SDF granularity. The traffic; wherein, the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application are the policy and charging control PCC rule identification and/or sent by the service detection function TDF entity according to the PCRF entity The SDF template is determined and sent to the PCRF entity;
计费调整模块, 用于根据所述第一应用所属的 SDF的标识和所述第一应 用的数据包的流量,对来自用户设备 UE的上行数据包基于 SDF粒度的计费结 果进行调整, 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。 A charging adjustment module, configured to adjust the SDF granularity-based charging result of the uplink data packet from the user equipment UE according to the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application, where , the data packet of the first application belongs to the uplink data packet from the UE.
65、 根据权利要求 64所述的 PCEF实体, 其特征在于, 还包括: 计费模块, 用于在所述接收模块接收第一应用所属的 SDF的标识和所述 第一应用的数据包的流量之前,对来自所述 UE的上行数据包进行基于 SDF粒 度的计费。 65. The PCEF entity according to claim 64, further comprising: a charging module, configured to receive, in the receiving module, the identity of the SDF to which the first application belongs and the traffic volume of the data packet of the first application. Previously, uplink data packets from the UE were charged based on SDF granularity.
66、 根据权利要求 64或 65所述的 PCEF实体, 其特征在于, 所述接收模 块用于接收 PCRF实体发送的影响所述 PCEF实体基于 SDF粒度的计费结果的 第一应用所属的 SDF的标识和所述第一应用的数据包的流量, 包括: 66. The PCEF entity according to claim 64 or 65, wherein the receiving module is configured to receive the identification of the SDF to which the first application that affects the charging result of the PCEF entity based on SDF granularity is sent by the PCRF entity. and the traffic of data packets of the first application, including:
所述接收模块具体用于接收所述 PCRF 实体发送的互联网连接访问网络 IP-CAN会话修改请求消息, 所述 IP-CAN会话修改请求消息包括所述第一应 用所属的 SDF的标识和所述第一应用的数据包的流量。 The receiving module is specifically configured to receive an Internet connection access network IP-CAN session modification request message sent by the PCRF entity. The IP-CAN session modification request message includes the identification of the SDF to which the first application belongs and the first application. The flow of packets for an application.
67、 一种业务检测功能 TDF实体, 其特征在于, 包括: 67. A business detection function TDF entity, which is characterized by including:
接收模块,用于接收策略控制和计费规则功能 PCRF实体发送的策略与计 费控制 PCC规则标识和 /或服务数据流 SDF模板; The receiving module is used to receive the policy control and charging rule function, policy and charging control PCC rule identification and/or service data flow SDF template sent by the PCRF entity;
确定模块,用于根据所述接收模块接收的所述 PCC规则标识和 /或 SDF模 板,确定影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用 所属的 SDF的标识和所述第一应用的数据包的流量; Determining module, configured to determine, according to the PCC rule identification and/or SDF template received by the receiving module, the identification and identification of the SDF to which the first application that affects the policy and charging execution PCEF entity's charging results based on SDF granularity belongs. The traffic of data packets of the first application;
发送模块, 用于将所述确定模块确定的所述第一应用所属的 SDF的标识 和所述第一应用的数据包的流量通过所述 PCRF实体发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行调 整; 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。 A sending module, configured to send the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application determined by the determination module to the PCEF entity through the PCRF entity, so that the PCEF The entity adjusts the charging result of the uplink data packet from the user equipment UE based on the SDF granularity based on the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application; wherein, the first application's The data packet belongs to the uplink data packet from the UE.
68、 根据权利要求 67所述的 TDF实体, 其特征在于, 所述接收模块用于 接收 PCRF实体发送的 PCC规则标识和 /或 SDF模板, 包括: 68. The TDF entity according to claim 67, wherein the receiving module is configured to receive the PCC rule identification and/or SDF template sent by the PCRF entity, including:
所述接收模块具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述 PCC规则标识和 /或 SDF模板。 The receiving module is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the PCC rule identification and/or SDF template.
69、 根据权利要求 67或 68所述的 TDF实体, 其特征在于, 所述确定模 块用于根据所述接收模块接收的所述 PCC规则标识和 /或 SDF模板,确定影响 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和所述第一 应用的数据包的流量, 包括: 69. The TDF entity according to claim 67 or 68, wherein the determining module is configured to determine, based on the PCC rule identifier and/or SDF template received by the receiving module, the factors affecting the PCEF entity based on the SDF granularity. The identification of the SDF to which the first application of the charging result belongs and the traffic volume of the data packet of the first application include:
所述确定模块具体用于根据所述接收模块接收的所述 PCC规则标识指示 的 PCC规则, 确定因执行基于应用的流控而被丢弃的数据包所属的应用作为 所述第一应用, 确定所述被丢弃的数据包的流量作为所述第一应用的数据包 的流量, 并确定所述第一应用所属的 SDF; 或者 The determining module is specifically configured to identify the PCC rule according to the indication received by the receiving module. PCC rules, determine the application to which the discarded data packets belong due to execution of application-based flow control as the first application, determine the flow of the discarded data packets as the flow of the data packets of the first application, and determine the SDF to which the first application belongs; or
所述确定模块具体用于根据所述接收模块接收的所述 SDF模板探测到不 需要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进行 计费时, 从具有相同 IP地址信息的所有数据包中, 确定实际需要计费的数据 包所属的应用作为所述第一应用, 确定实际需要计费的数据包的流量作为所 述第一应用的数据包的流量, 并确定所述第一应用所属的 SDF; 或者, The determining module is specifically configured to detect, based on the SDF template received by the receiving module, that it is not necessary to charge all data packets with the same IP address information in the uplink data packets from the UE, from the Among all the data packets of the address information, determine the application to which the data packets that actually need to be charged belong as the first application, determine the traffic of the data packets that actually need to be charged as the traffic of the data packets of the first application, and determine The SDF to which the first application belongs; or,
所述确定模块具体用于根据所述接收模块接收的所述 SDF模板探测到不 需要对来自所述 UE的上行数据包中具有相同 IP地址信息的所有数据包进行 计费时, 从具有相同 IP地址信息的所有数据包, 确定出不需要计费的数据包 所属的应用作为所述第一应用, 确定不需要计费的数据包的流量作为所述第 一应用的数据包的流量, 并确定所述第一应用所属的 SDF。 The determining module is specifically configured to detect, based on the SDF template received by the receiving module, that it is not necessary to charge all data packets with the same IP address information in the uplink data packets from the UE, from the All data packets of the address information, determine the application to which the data packets that do not need to be charged belong as the first application, determine the traffic of the data packets that do not need to be charged as the traffic of the data packets of the first application, and determine The SDF to which the first application belongs.
70、 一种策略控制和计费规则功能 PCRF实体, 其特征在于, 包括: 发射器, 用于向业务检测功能 TDF实体发送的策略与计费控制 PCC规则 标识和 /或服务数据流 SDF模板, 以供所述 TDF实体确定影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属的 SDF的标识和第一应用 的数据包的流量; 70. A policy control and charging rule function PCRF entity, characterized in that it includes: a transmitter, used to send the policy and charging control PCC rule identification and/or service data flow SDF template to the service detection function TDF entity, For the TDF entity to determine the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application based on the charging result of the SDF granularity that affects the policy and charging execution of the PCEF entity;
接收器, 用于接收所述 TDF实体发送的根据所述 PCC规则标识和 /或 SDF 模板确定的所述第一应用所属的 SDF 的标识和所述第一应用的数据包的流 所述发射器, 还用于将所述第一应用所属的 SDF的标识和所述第一应用 的数据包的流量发送给所述 PCEF实体, 以使所述 PCEF实体基于所述第一应 用所属的 SDF的标识和所述第一应用的数据包的流量对来自用户设备 UE的上 行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包 属于来自所述 UE的上行数据包。 Receiver, configured to receive the identifier of the SDF to which the first application belongs and the stream of data packets of the first application sent by the TDF entity and determined according to the PCC rule identifier and/or the SDF template; the transmitter , and is also used to send the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application to the PCEF entity, so that the PCEF entity is based on the identity of the SDF to which the first application belongs. The charging result of the uplink data packet from the user equipment UE is adjusted based on the SDF granularity based on the traffic of the data packet of the first application; wherein, the data packet of the first application belongs to the uplink data packet from the UE.
71、 一种策略和计费执行 PCEF实体, 其特征在于, 包括: 71. A policy and charging execution PCEF entity, characterized by including:
接收器, 用于接收策略控制和计费规则功能 PCRF 实体发送的影响所述 PCEF实体基于服务数据流 SDF粒度的计费结果的第一应用所属的 SDF的标识 和所述第一应用的数据包的流量; 其中, 所述第一应用所属的 SDF的标识和 所述第一应用的数据包的流量是业务检测功能 TDF实体根据所述 PCRF实体发 送的策略与计费控制 PCC规则标识和 /或 SDF模板确定并发送给所述 PCRF实 体的; Receiver, configured to receive the identification of the SDF to which the first application belongs and the data packet of the first application that affects the charging result of the PCEF entity based on the service data flow SDF granularity sent by the policy control and charging rule function PCRF entity. traffic; wherein, the identity of the SDF to which the first application belongs and The traffic of the data packet of the first application is determined by the service detection function TDF entity according to the policy and charging control PCC rule identification and/or SDF template sent by the PCRF entity and sent to the PCRF entity;
处理器, 用于根据所述第一应用所属的 SDF的标识和所述第一应用的数 据包的流量,对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行 调整, 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。 The processor is configured to adjust the SDF granularity-based charging result of the uplink data packet from the user equipment UE according to the identification of the SDF to which the first application belongs and the traffic of the data packet of the first application, wherein, The data packet of the first application belongs to the uplink data packet from the UE.
72、 一种业务检测功能 TDF实体, 其特征在于, 包括: 72. A business detection function TDF entity, which is characterized by including:
接收器,用于接收策略控制和计费规则功能 PCRF实体发送的策略与计费 控制 PCC规则标识和 /或服务数据流 SDF模板; Receiver, used to receive the policy control and charging rule function PCRF entity sent policy and charging control PCC rule identification and/or service data flow SDF template;
处理器, 用于根据所述接收器接收的所述 PCC规则标识和 /或 SDF模板, 确定影响策略和计费执行 PCEF实体基于 SDF粒度的计费结果的第一应用所属 的 SDF的标识和所述第一应用的数据包的流量; A processor configured to determine, according to the PCC rule identification and/or SDF template received by the receiver, the identification and identity of the SDF to which the first application that affects the policy and charging execution PCEF entity's charging results based on SDF granularity belongs. The traffic of data packets of the first application;
发射器, 用于将所述处理器确定的所述第一应用所属的 SDF的标识和所 述第一应用的数据包的流量通过所述 PCRF实体发送给所述 PCEF实体, 以使 所述 PCEF实体基于所述第一应用所属的 SDF的标识和所述第一应用的数据包 的流量对来自用户设备 UE的上行数据包基于 SDF粒度的计费结果进行调整; 其中, 所述第一应用的数据包属于来自所述 UE的上行数据包。 A transmitter, configured to send the identity of the SDF to which the first application determines and the traffic of the data packet of the first application determined by the processor to the PCEF entity through the PCRF entity, so that the PCEF The entity adjusts the charging result of the uplink data packet from the user equipment UE based on the SDF granularity based on the identity of the SDF to which the first application belongs and the traffic of the data packet of the first application; wherein, the first application's The data packet belongs to the uplink data packet from the UE.
73、 一种业务检测功能 TDF实体, 其特征在于, 包括: 73. A business detection function TDF entity, which is characterized by including:
接收模块, 用于接收策略和计费执行 PCEF实体发送的上行数据包; 确定添加模块, 用于在所述接收模块接收到所述上行数据包之后, 确定 回流数据, 并为所述回流数据添加计费标识, 所述回流数据是指所述上行数 据包中影响所述 PCEF实体对所述上行数据包基于服务数据流 SDF粒度的计费 结果的数据包; A receiving module, configured to receive the uplink data packet sent by the policy and charging execution PCEF entity; and a determining and adding module, configured to determine the return data after the receiving module receives the uplink data packet, and add the return data to the return data packet. Charging identifier, the backflow data refers to the data packet in the uplink data packet that affects the charging result of the PCEF entity for the uplink data packet based on the service data flow SDF granularity;
发送模块, 用于将携带所述计费标识的回流数据发送给所述 PCEF实体, 以使所述 PCEF实体根据携带所述计费标识的回流数据,对所述上行数据包基 于 SDF粒度的计费结果进行调整。 A sending module, configured to send the backflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity calculates the uplink data packet based on SDF granularity according to the backflow data carrying the charging identifier. Fee results are adjusted.
74、 根据权利要求 73所述的 TDF实体, 其特征在于, 所述接收模块还用 于在所述确定添加模块为所述回流数据添加计费标识之前, 接收策略控制和 计费规则功能 PCRF实体发送的所述 PCRF实体为所述回流数据分配的所述计 费标识。 74. The TDF entity according to claim 73, wherein the receiving module is further configured to receive a policy control and charging rule function PCRF entity before the determining and adding module adds a charging identifier to the reflow data. The sending PCRF entity assigns the charging identifier for the reflow data.
75、 根据权利要求 74所述的 TDF实体, 其特征在于, 所述接收模块用于 接收 PCRF实体发送的所述 PCRF实体为所述回流数据分配的所述计费标识, 包括: 75. The TDF entity according to claim 74, wherein the receiving module is configured to receive the charging identifier sent by the PCRF entity and allocated by the PCRF entity for the reflow data, including:
所述接收模块具体用于接收所述 PCRF实体发送的 TDF会话建立请求消 息, 所述 TDF会话建立请求消息包括所述计费标识。 The receiving module is specifically configured to receive a TDF session establishment request message sent by the PCRF entity, where the TDF session establishment request message includes the charging identifier.
76、 一种策略和计费执行 PCEF实体, 其特征在于, 包括: 76. A policy and charging execution PCEF entity, characterized by including:
接收模块, 用于在对上行数据包进行基于服务数据流 SDF粒度的计费之 后, 接收业务检测功能 TDF实体发送的携带有计费标识的回流数据, 所述回 流数据是所述 TDF实体确定的所述上行数据包中影响所述 PCEF实体对所述上 行数据包的基于 SDF粒度的计费结果的数据包; The receiving module is configured to receive the return data carrying the charging identifier sent by the service detection function TDF entity after charging the uplink data packet based on the service data flow SDF granularity. The return data is determined by the TDF entity. Data packets in the uplink data packet that affect the SDF granularity-based charging result of the PCEF entity for the uplink data packet;
计费调整模块, 用于根据所述计费标识确定所述接收模块接收到的数据 是所述回流数据, 确定所述回流数据所属的 SDF, 对所述确定的 SDF的计费 结果进行调整。 A charging adjustment module, configured to determine that the data received by the receiving module is the reflow data according to the charging identification, determine the SDF to which the reflow data belongs, and adjust the charging results of the determined SDF.
77、 根据权利要求 76所述的 PCEF实体, 其特征在于, 所述接收模块还 用于在接收所述 TDF实体发送的携带有计费标识的回流数据之前, 接收策略 控制和计费规则功能 PCRF实体发送的所述 PCRF实体为所述回流数据分配的 所述计费标识。 77. The PCEF entity according to claim 76, wherein the receiving module is further configured to receive the policy control and charging rule function PCRF before receiving the backflow data carrying the charging identifier sent by the TDF entity. The charging identifier assigned by the PCRF entity to the backflow data is sent by the entity.
78、 根据权利要求 77所述的 PCEF实体, 其特征在于, 所述接收模块用 于接收 PCRF实体发送的所述 PCRF实体为所述回流数据分配的所述计费标识, 包括: 78. The PCEF entity according to claim 77, wherein the receiving module is configured to receive the charging identifier sent by the PCRF entity and allocated by the PCRF entity for the reflow data, including:
所述接收模块具体用于接收所述 PCRF 实体发送的互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标 识。 The receiving module is specifically configured to receive an Internet connection access network IP-CAN session establishment response message sent by the PCRF entity, where the IP-CAN session establishment response message includes the charging identification.
79、 一种策略控制和计费规则功能 PCRF实体, 其特征在于, 包括: 确定模块, 用于确定需要分配给回流数据包的计费标识, 所述回流数据 是指上行数据包中影响策略和计费执行 PCEF 实体对所述上行数据包的基于 服务数据流 SDF粒度的计费结果的数据包; 79. A policy control and charging rule function PCRF entity, characterized in that it includes: a determination module, used to determine the charging identifier that needs to be allocated to the backflow data packet, and the backflow data refers to the impact policy and in the uplink data packet The charging execution PCEF entity performs the charging result of the uplink data packet based on the service data flow SDF granularity for the data packet;
发送模块, 用于将所述计费标识发送给业务检测功能 TDF 实体和所述 PCEF实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确 定出所述回流数据后在所述回流数据中添加所述计费标识后向所述 PCEF 实 体发送,使所述 PCEF实体根据所述计费标识确定所述回流数据并基于所述回 流数据对所述上行数据包的基于 SDF粒度的计费结果进行调整。 A sending module, configured to send the charging identifier to the service detection function TDF entity and the PCEF entity, so that the TDF entity determines the return data from the uplink data packet from the PCEF entity. After adding the charging identifier to the reflow data, the PCEF implements The PCEF entity determines the backflow data according to the charging identifier and adjusts the SDF granularity-based charging result of the uplink data packet based on the backflow data.
80、 根据权利要求 79所述的 PCRF实体, 其特征在于, 所述发送模块用 于将所述计费标识发送给 TDF实体, 包括: 80. The PCRF entity according to claim 79, characterized in that the sending module is used to send the charging identification to the TDF entity, including:
所述发送模块具体用于向所述 TDF实体发送 TDF会话建立请求消息, 所 述 TDF会话建立请求消息包括所述计费标识。 The sending module is specifically configured to send a TDF session establishment request message to the TDF entity, where the TDF session establishment request message includes the charging identifier.
81、 根据权利要求 79或 80所述的 PCRF实体, 其特征在于, 所述发送模 块用于将所述计费标识发送给所述 PCEF实体, 包括: 81. The PCRF entity according to claim 79 or 80, characterized in that the sending module is used to send the charging identification to the PCEF entity, including:
所述发送模块具体用于向所述 PCEF 实体发送互联网连接访问网络 IP-CAN会话建立响应消息, 所述 IP-CAN会话建立响应消息包括所述计费标 识。 The sending module is specifically configured to send an Internet connection access network IP-CAN session establishment response message to the PCEF entity, where the IP-CAN session establishment response message includes the charging identification.
82、 一种业务检测功能 TDF实体, 其特征在于, 包括: 82. A business detection function TDF entity, which is characterized by including:
接收器, 用于接收策略和计费执行 PCEF实体发送的上行数据包; 处理器, 用于在所述接收器接收到所述上行数据包之后, 确定回流数据, 并为所述回流数据添加计费标识, 所述回流数据是指所述上行数据包中影响 所述 PCEF实体对所述上行数据包基于服务数据流 SDF粒度的计费结果的数据 包; A receiver, configured to receive the uplink data packet sent by the policy and charging execution PCEF entity; a processor, configured to determine the backflow data after the receiver receives the uplink data packet, and add calculations to the backflow data Charge identifier, the backflow data refers to the data packet in the uplink data packet that affects the charging result of the PCEF entity for the uplink data packet based on the service data flow SDF granularity;
发射器, 用于将携带所述计费标识的回流数据发送给所述 PCEF实体, 以 使所述 PCEF实体根据携带所述计费标识的回流数据,对所述上行数据包基于 SDF粒度的计费结果进行调整。 A transmitter configured to send the backflow data carrying the charging identifier to the PCEF entity, so that the PCEF entity calculates the uplink data packet based on SDF granularity based on the backflow data carrying the charging identifier. Fee results are adjusted.
83、 一种策略和计费执行 PCEF实体, 其特征在于, 包括: 83. A policy and charging execution PCEF entity, characterized by including:
接收器,用于在对上行数据包进行基于服务数据流 SDF粒度的计费之后, 接收业务检测功能 TDF实体发送的携带有计费标识的回流数据, 所述回流数 据是所述 TDF实体确定的所述上行数据包中影响所述 PCEF实体对所述上行数 据包的基于 SDF粒度的计费结果的数据包; A receiver configured to receive backflow data carrying a charging identifier sent by the service detection function TDF entity after charging uplink data packets based on the service data flow SDF granularity. The backflow data is determined by the TDF entity. Data packets in the uplink data packet that affect the SDF granularity-based charging result of the PCEF entity for the uplink data packet;
处理器, 用于根据所述计费标识确定所述接收器接收到的数据是所述回 流数据, 确定所述回流数据所属的 SDF, 对所述确定的 SDF的计费结果进行 调整。 A processor, configured to determine that the data received by the receiver is the reflow data according to the charging identification, determine the SDF to which the reflow data belongs, and adjust the charging result of the determined SDF.
84、 一种策略控制和计费规则功能 PCRF实体, 其特征在于, 包括: 处理器, 用于确定需要分配给回流数据包的计费标识, 所述回流数据是 指上行数据包中影响策略和计费执行 PCEF 实体对所述上行数据包的基于服 务数据流 SDF粒度的计费结果的数据包; 84. A policy control and charging rule function PCRF entity, characterized in that it includes: a processor, configured to determine the charging identifier that needs to be allocated to the return data packet, and the return data is Refers to the data packets in the uplink data packet that affect the policy and charging execution PCEF entity’s charging results based on the service data flow SDF granularity of the uplink data packet;
发射器, 用于将所述计费标识发送给业务检测功能 TDF实体和所述 PCEF 实体, 以供所述 TDF实体从来自所述 PCEF实体的所述上行数据包中确定出所 述回流数据后在所述回流数据中添加所述计费标识后向所述 PCEF实体发送, 使所述 PCEF 实体根据所述计费标识确定所述回流数据并基于所述回流数据 对所述上行数据包的基于 SDF粒度的计费结果进行调整。 Transmitter, configured to send the charging identifier to the service detection function TDF entity and the PCEF entity, so that the TDF entity determines the return data from the uplink data packet from the PCEF entity. The charging identifier is added to the return data and then sent to the PCEF entity, so that the PCEF entity determines the return data according to the charging identifier and performs the calculation of the uplink data packet based on the return data. The accounting results of SDF granularity are adjusted.
PCT/CN2013/083780 2013-09-18 2013-09-18 Charging method and device WO2015039307A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
PCT/CN2013/083780 WO2015039307A1 (en) 2013-09-18 2013-09-18 Charging method and device
CN201380004532.6A CN104769978B (en) 2013-09-18 2013-09-18 Charging method and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2013/083780 WO2015039307A1 (en) 2013-09-18 2013-09-18 Charging method and device

Publications (1)

Publication Number Publication Date
WO2015039307A1 true WO2015039307A1 (en) 2015-03-26

Family

ID=52688100

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2013/083780 WO2015039307A1 (en) 2013-09-18 2013-09-18 Charging method and device

Country Status (2)

Country Link
CN (1) CN104769978B (en)
WO (1) WO2015039307A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024031389A1 (en) * 2022-08-09 2024-02-15 北京小米移动软件有限公司 Billing processing method and apparatus, communication device, and storage medium

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108696363B (en) * 2017-02-25 2022-03-08 华为技术有限公司 Charging method and device
CN110620748B (en) * 2018-06-20 2021-12-21 中国电信股份有限公司 Data packet identification method, device, system and computer readable storage medium
CN117859295A (en) * 2022-08-09 2024-04-09 北京小米移动软件有限公司 Charging correction method, device, communication equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102131172A (en) * 2010-01-18 2011-07-20 中兴通讯股份有限公司 Traffic processing method and system
CN102625272A (en) * 2011-01-31 2012-08-01 中兴通讯股份有限公司 Usage monitoring method supporting traffic detection function and usage monitoring system
CN103220651A (en) * 2012-01-21 2013-07-24 阿尔卡特朗讯 Method and equipment for carrying out charging control on application layer data

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102137367B (en) * 2010-01-26 2016-03-30 中兴通讯股份有限公司 Method and system, PCC system that the strategy strengthened and charging control

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102131172A (en) * 2010-01-18 2011-07-20 中兴通讯股份有限公司 Traffic processing method and system
CN102625272A (en) * 2011-01-31 2012-08-01 中兴通讯股份有限公司 Usage monitoring method supporting traffic detection function and usage monitoring system
CN103220651A (en) * 2012-01-21 2013-07-24 阿尔卡特朗讯 Method and equipment for carrying out charging control on application layer data

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024031389A1 (en) * 2022-08-09 2024-02-15 北京小米移动软件有限公司 Billing processing method and apparatus, communication device, and storage medium

Also Published As

Publication number Publication date
CN104769978A (en) 2015-07-08
CN104769978B (en) 2019-02-19

Similar Documents

Publication Publication Date Title
US20130021916A1 (en) Method and System for Obtaining Network Loads
JP6025926B2 (en) Method, apparatus and system for controlling services
JP7040772B2 (en) How to perform policing of non-IP data through the service exposure feature
US9479917B1 (en) Rating group-specific actions for mobile networks
US8605655B1 (en) Policy and charging control rule precedence mapping in wireless connectivity access networks
US9621444B2 (en) Method and device for handling dropped data packets
WO2017143915A1 (en) Method and device for throttling bandwidth of access point
US9602675B1 (en) Usage monitoring control for mobile networks
KR102046323B1 (en) Method and apparatus for controlling traffic of radio access network in a wireless communication system
US9565586B1 (en) Usage monitoring control for mobile networks
WO2010072107A1 (en) User service flow charge deducting method and device
US20160164752A1 (en) Node and method for service usage reporting and quota establishment
US20140254356A1 (en) Method and apparatus for controlling traffic of radio access network in a wireless communication system
WO2015039307A1 (en) Charging method and device
KR20140077095A (en) Method and apparatus for forwarding of data traffic
US9571663B1 (en) Usage monitoring control for mobile networks
WO2017054199A1 (en) Strategy determination method and apparatus
WO2011134319A1 (en) Policy control method for packet service and packet service system
EP3510726B1 (en) Methods and nodes for managing charging of a user equipment by enabling management of traffic steering policy
WO2015048992A1 (en) Handling overload of a network node
EP3170283B1 (en) Method for enhanced policy and charging control in telecommunications networks
WO2014110923A1 (en) Network information processing method, apparatus and system
WO2014110966A1 (en) Method, apparatus and system for processing traffic data
WO2018040073A1 (en) Method, apparatus and system for charging multi-access network
KR101775058B1 (en) System for mixing heterogeneous mobile communication, sgsn of wcdma network and method for processing data call thereof, mme of epc network and method for processing data call thereof

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 13893824

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 13893824

Country of ref document: EP

Kind code of ref document: A1