Content Filtering, Event Detail Records, and X-Header Enrichment Support

Feature Summary and Revision History

Summary Data

Table 1. Summary Data

Applicable Product(s) or Functional Area

SMF

Applicable Platform(s)

SMI

Feature Default Setting

Disabled - Configuration Required

Related Changes in this Release

Not Applicable

Related Documentation

Not Applicable

Revision History

Table 2. Revision History

Revision Details

Release

Custom EDR Generation

2021.01.0

First introduced.

Pre-2020.02.0

Feature Description

The SMF supports the following functionality:

  • Content Filtering

  • Event Detail Record (EDR)

  • X-header Enrichment

Converged Core Refactoring Changes

This section describes the changes related to converged core refactoring in this chapter.

The edr-format edr_format_name CLI command in the Active Charging Service configuration mode is deprecated in 2021.01 and later releases.

Content Filtering Support

Feature Description

The Content Filtering (CF) service prevents subscribers from inadvertently getting exposed to universally unacceptable content, or content that is inappropriate as per subscriber preferences. Based on the URLs in the subscriber requests, the CF service filters HTTP and WAP requests from mobile subscribers. Operators can filter and control the content for an individual subscriber to access.

The CF service provides the following solutions:

  • URL Blacklisting—In this solution, all HTTP or WAP URLs in subscriber requests must match against a database of "blacklisted" URLs. If there is a match, it discards the flow, redirects, or terminates as per the configuration. In case of no match, subscribers view the content as usual.

    URL Blacklisting may not be a subscriber opt-in service. Operators can enable URL Blacklisting either for all subscribers or for a subset of subscribers. Typical cases include applying a blacklisted database of child porn URLs to all subscribers so that they are inadvertently not exposed to the universally unacceptable content.

  • Category-based Static Content Filtering—In this solution, all HTTP or WAP URLs in subscriber requests must match against a static URL categorization database. Action initiates based on the URL's category and as per the configuration in the subscriber CF policy. Possible actions include:

    • Permitting

    • Blocking

    • Redirecting

    • Inserting content

Configuring Content Filtering

This section describes how to configure the following:

  • Content Filtering

Configuring Content Filtering Support

This section describes how to configure CF support.


Note

Apart from the following configurations, all other configurations are used only in the UPF, and are only sent from the SMF to the UPF via RCM. The SMF does not use these configurations.


Configuring Content Filtering under Active Charging Service

To configure CF support under the active charging service, use the following configuration:

configure 
   active-charging service service_name 
      content-filtering category policy-id cf_policy_id 
         analyze priority priority { all | category category 
          | x-category xcategory } action { allow | 
          content-insert content_string | discard | redirect-url url | 
          terminate-flow | www-reply-code-and-terminate-flow reply_code  
          } [ edr edr_format] failure-action { allow |  
          content-insert content_string | discard | redirect-url url 
          | terminate-flow | www-reply-code-and-terminate-flow reply_code} 
          [ edr edr_format] 
          end 
Configuring Content Filtering under Rulebase

To configure CF under the rulebase, use the following configuration:


configure 
   active-charging service service_name 
      content-filtering category policy-id cf_policy_id 
      content-filtering mode category static-only 
      end 
Configuring Content Filtering under APN

To configure CF under the APN, use the following configuration:


configure 
   context context_name 
      apn apn_name 
         content-filtering category policy-id cf_policy_id 
         end 
Content Filtering Policy ID on N7 Interface

The CF categories are configured under the active charging service under specific policy IDs. The rulebase and APN also have an associated policy ID. For any session, one policy ID can be associated with the session at anytime. The categories configured under that CF policy ID are applicable for the session on the UPF.

The PCF can override the CF policy ID by sending this value on the N7 interface. For this purpose, a proprietary IE is available in the YAML definition for the N7 interface. The hierarchy for the CF policy ID is as follows:


smPolicyDecision 
   ciscoAvpSet: 
      cfPolicyId: uint32 value 

When the PCF does not send a CF policy ID, the existing CF policy ID in the rulebase configuration or the policy ID configured in the APN configuration is selected, in the order of precedence. This CF policy ID value is sent to the UPF in PFCP Session Establishment Request message in the "Subscriber Parameters" attribute. During PDU Session Modification, if the PCF changes the CF policy ID, the ID is sent to the UPF in PFCP Session Modification Request message.

Event Data Record Logging Support

Feature Description

Event Data Records (EDRs) collect information that you can use to charge subscribers for specific events that they consume. The EDRs catch whatever bytes get transmitted over the flow.

When a flow ends, the SMF generates EDRs with detail information of the terminated flow. The SMF supports logging of EDRs for both 4G and 5G subscriber sessions.

The SMF uses the event reports to generate EDR files comprised of logged information in comma-separated value (CSV) format. The SMF sends one CSV record per line. The CSV records are stored in a file and are optionally compressed before sending to an external server.

These CSV files can be downloaded and used offline to—

  • Debug or understand the application behaviour.

  • Diagnose the call flow for the specific subscribers.

The SMF supports EDR file generation for transaction and transaction-collision level details for subscriber sessions. By default, the EDR generation is disabled.

EDR Format

In addition to the existing Transaction EDR fields, the application appends procedure-id and event-id along with their field values. Application registers the procedure-id, event-id, and field-id along with their corresponding names. This mapping is used to format the CSV event entry. Each event entry consists of comma-separated procedure-id, event-id, and field-value. These registered mappings can also be used in CLI commands to disable EDRs at procedure, event, or field level. You can enable or disable the EDRs dynamically during runtime. The existing EDR records remain the same and the runtime changes get reflected only in the newly generated EDR records.

Transaction EDR Format

Transaction-EDR-Fields, list of Event-Entries []

Event Entries

Procedure-id1, Event-id1, list of field-id1-values[]

The following is a sample transaction entry along with a list of events in the CSV format.

Transaction-id-value, Start-Time, Elapsed-Time, ……, 
Procedure-id1, event-id1, field-id1-value, field-id2-value……, 
Procedure-id1, event-id2, field-id1-value, field-id2-value……, 
        Procedure-id1, event-id1, field-id1-value, field-id2-value……

Note

There might be different set of fields for a combination of procedure-id and event-id. You can enable or disable the EDRs dynamically during runtime by using a CLI command. For configuration details, see the Configure EDR Files for Generation section in this guide.


The CSV file is generated in each SMF service pod where the subscriber sessions and events are processed. The location of the EDR files inside pod is as follows:

/tmp/edr/smf-service/<pod-instance>/transactions.csv

/tmp/edr/smf-service/<pod-instance>/transaction_collisions.csv

Example:

/tmp/edr/smf-service/1/transactions.csv

/tmp/edr/smf-service/1/transaction_collisions.csv

EDR Transaction File

The EDR transaction file dumps the transaction information at the end of the transaction. By default, the file generation is disabled.

The following table provides the information that is stored in the file.

Table 3. EDR Transaction File Fields

Field Number

Field Name

Field Description

1

Transaction ID

Transaction ID

2

Start Time

The transaction start time in yyyy/MM/dd HH:mm:ss.SSS format.

3

Elapsed Ms

The time taken for transaction to end in milliseconds.

4

Subscriber ID

The subscriber ID. For example, imsi-123456789012345

5

Transaction Type

The transaction type (integer) which is defined internally in the application.

6

Transaction Description

The transaction description in string format.

7

Session Primary Key

The primary key of the session.

8

Session Unique Keys

The unique keys for the session separated by |.

9

Session Non Unique Keys

The non-unique keys for the session separated by |.

10

Status

The transaction status (success or error).

11

Status Code

The transaction status code to indicate the failure reason.

12

Procedure Name

The procedure name for which the transaction was submitted.

13

Sub Procedure Name

The sub procedure name for which the transaction was submitted.

14

State

The transaction state. It can be:

  • Started

  • New

  • Ready

  • Active

  • Pending

  • Suspend

  • SuspendWaitingForResponse

  • SuspendWaitingForLock

  • Abort

  • Finished

  • Timeout

  • Unknown

15

Execution stages

The list of stages the transaction went through its lifecycle separated by |

NOTES:

  • Each field is separated by comma (,).

  • Fields session_uks, session_nuks, execution_stages are a list. These fields are separated by pipe (|). For example, session_uks can be denoted as uk1|uk2|uk3.

CSV Format Examples:

1,2020/10/06 16:56:09.276,161,imsi-123456789012345,7,N11SmContextCreateReq,
imsi-123456789012345:5,,supi:imsi-123456789012345|gpsi:msisdn-9999988888|pei:
imei-123456786666660|udm:10.1.5.52|dnn:intershat|rat:nr|access:3gpp access|
connectivity:5g|policy:1,success,success,PDU Session Establishment,N11SmContextCreateReq,
Active,init_done|SETUP: Idle|SETUP: Await UDM Registration|SETUP: Await UDM Subscription Fetch|
SETUP: Await UDM Subscribe for Notification|finished
2,2020/10/06 16:56:09.432,659,imsi-123456789012345,106,NIntSelfTxnPduSetup,
imsi-123456789012345:5,33554442,supi:imsi-123456789012345|gpsi:msisdn-9999988888|pei:
imei-123456786666660|udm:10.1.5.52|dnn:intershat|rat:nr|access:3gpp access|connectivity:
5g|pcfGroupId:PCF-dnn=intershat;|pcf:10.1.5.52|policy:2|upf:10.1.5.52|upfEpKey:10.1.5.52:
10.1.5.54|ipv4-addr:poolv4/12.0.0.1|ipv4-pool:poolv4|ipv4-range:poolv4/12.0.0.1|ipv4-startrange:
poolv4/12.0.0.1|amf:10.1.5.52,success,success,unknown,unknown,Active,init_done|SETUP: 
Await PCF Internal|SETUP: Await PCF Create|SETUP: Await Address Allocation|SETUP: 
Await PCF Update|SETUP: Await Charging Create|SETUP: Await UPF Setup|SETUP: 
Await Assign Ebi Response|SETUP: Await N1 N2|finished
3,2020/10/06 16:56:10.151,167,imsi-123456789012345,10,N11SmContextUpdateReq,
imsi-123456789012345:5,33554442,supi:imsi-123456789012345|gpsi:msisdn-9999988888|pei:
imei-123456786666660|udm:10.1.5.52|dnn:intershat|rat:nr|access:3gpp access|connectivity:
5g|pcfGroupId:PCF-dnn=intershat;|pcf:10.1.5.52|policy:2|upf:10.1.5.52|
upfEpKey:10.1.5.52:10.1.5.54|ipv4-addr:poolv4/12.0.0.1|ipv4-pool:poolv4|
ipv4-range:poolv4/12.0.0.1|ipv4-startrange:poolv4/12.0.0.1|amf:10.1.5.52,success,success,
PDU Session Establishment,N11SmContextUpdateReq,Active,init_done|SETUP: Await AMF Update|
SETUP: Await UPF Modify|finished
4,2020/10/06 16:56:12.404,159,imsi-123456789012345,24,N11SmContextReleaseReq,
imsi-123456789012345:5,33554442,supi:imsi-123456789012345|gpsi:msisdn-9999988888|pei:
imei-123456786666660|udm:10.1.5.52|dnn:intershat|rat:nr|access:3gpp access|connectivity:
5g|pcfGroupId:PCF-dnn=intershat;|pcf:10.1.5.52|policy:2|upf:10.1.5.52|upfEpKey:10.1.5.52:
10.1.5.54|amf:10.1.5.52,success,success,unknown,unknown,Active,init_done|RELEASE: Idle|
RELEASE: Await UPF Release|RELEASE: Await Resource Release|finished
5,2020/10/06 16:56:12.563,158,imsi-123456789012345,123,NIntPduReleaseComplete,
imsi-123456789012345:5,,,success,success,PDU Session Release - AMF initiated,
NIntPduReleaseComplete,Active,init_done|RELEASE: Await Internal Charging Terminate|
RELEASE: Await Charging Terminate|RELEASE: Await PCF Delete|finished|finished
Procedure-level EDR Generation

The Event Logging feature captures procedure-level information per subscriber. Upon completing a procedure, either successfully or unsuccessfully, the SMF generates a procedure summary or event report logging the event.

The EDR generation per procedure is configurable. For configuration details, see the Configure EDR Files for Generation section in this guide.

The following table lists the supported procedures and the corresponding IDs.

Table 4. Procedure List
Procedure Procedure-ID
PDN-SESSION-CREATE or PDU-SESSION-CREATE 3
PDN-SESSION-DELETE or PDU-SESSION-DELETE 4

Further, the SMF captures event-level information per procedure. The following table provides details on the subscriber events and the respective event IDs.

The events captured per procedure are configurable. For configuration details, see the Configure EDR Files for Generation section in this guide.

Table 5. Event ID
EVENT EVENT-ID
N11SmContextCreateReq 1287
N11SmContextUpdateReq 1290
N11N1N2MessageTransferReq 1299
N11SmContextUpdateModifyReq 1293
N11EbiAssignmentReq 1302
N11SmContextReleaseReq 1304
N11SmContextStatusNotifyReq 1310
N11N1N2MessageTransferFailNotificationReq 1339
N4SessionModificationReq 527
N4SessionReleaseReq 530
N4SessionEstablishmentReq 524
N7SmPolicyCreateReq 3329
N7SmPolicyDeleteReq 3335
N7SmPolicyUpdateReq 3332
N7SmPolicyTerminateNotifyReq 3341
N10UnsubscribeForNotificationReq 1432
N10SubscribeForNotificationReq 1319
N10RegistrationRequest 1313
N10SubscriptionFetchReq 1316
N10DeregistrationRequest 1325
N10UnsubscribeForNotificationReq 1432
N10UpdateNotifyReq 1322
N40ChargingDataReq 3585
N40ChargingDataReq 3585
N40ChargingNotificationReq 3588
SecondaryAuthenReq 2307
S5S8CreateSessReq 2051
S5S8DeleteBearerReq 2057
S5S8DeleteSessReq 2055
metadata 1000

The following tables list the detailed event record for the PDU Session Create and Delete procedures.

Table 6. PDU Session Create Procedure
Attributes Event ID Field Name Presence Type Description
TXN EDR fields M

PROCEDURE

ID

EVENT-ID VERSION M String N11SmContext CreateReq
SUPI M String
IMEI/PEI M String
IMSI M String
MSISDN M String
GPSI M String
STATUS M String
STATUS-CODE O Number
PDU(PDN)- SESSION-TYPE O Number
SSC-MODE O Number
CAUSE O String
PCO O PCO
N1MSGREQ TYPE O N1N2MSGREQ CONTENT PDU-SESSION -ESTB-REQUEST
N2MSGREQ TYPE O N1N2MSGREQ CONTENT
N1MSGRESP TYPE O N1N2MSGRSP CONTENT PDU-SESSION- ESTB-REJECT
N2MSGRESP TYPE O N1N2MSGRSP CONTENT
MAX-SUPP- FILTERS O Number
ALWAYS-ON O Boolean
BACKOFF-TIME O NA NA
RAT-TYPE M String

PROCEDURE

ID

EVENT-ID2 VERSION M String N11SmContext UpdateReq
STATUS M String
STATUS-CODE O Number
PCO O PCO
N1MSGREQ TYPE O N1N2MSGREQ CONTENT
N2MSGREQ TYPE O N1N2MSGREQ CONTENT
N1MSGRESP TYPE O N1N2MSGRSP CONTENT
N2MSGRESP TYPE O N1N2MSGRSP CONTENT
CAUSE O
BACKOFF-TIME O NA NA

PROCEDURE

ID

EVENT-ID3 VERSION M String N11N1N2Message TransferReq
STATUS M String
STATUS-CODE O Number
N1MSGREQ TYPE O N1N2MSGREQ CONTENT

PDU-SESSION -ESTB-ACCEPT,

PDU-SESSION -ESTB-REJECT, and so on

N2MSGREQ TYPE O N1N2MSGREQ CONTENT
N1MSGRESP TYPE O N1N2MSGRSP CONTENT
N2MSGRESP TYPE O N1N2MSGRSP CONTENT
PCO O PCO
PDU-SESSION- TYPE O Number
SSC-MODE O Number
DNN O String
QOS-RULE O QOS-RULE
QOS-DESC O QOS-DESC
SESSION-AMBR O SESS-AMBR
CAUSE O String
PAA O PAA
S-NSSAI O NSSAI
ALWAYS-ON O Boolean

PROCEDURE

ID

EVENT-ID VERSION M String

N7SmPolicy CreateReq

SUPI M String
IMEI/PEI M String
GPSI M String
STATUS M String
STATUS-CODE O Number
PDU(PDN)- SESSION-TYPE O Number
QOS-DESC O QOS-DESC
SESSION-AMBR O SESS-AMBR
CAUSE O String
PROCEDURE- ID=3 EVENT-ID= <event_id> VERSION M

String

EVENT= N4Session ModificationReq,

N10Deregistration Request

N7SmPolicy UpdateReq,

N10Subscription FetchReq,

N10Unsubscribe ForNotification Req,

SecondaryAuthen Req,

N10SubscribeFor NotificationReq

N40Charging DataReq,

N7SmPolicy DeleteReq,

N11Ebi AssignmentReq,

N4Session EstablishmentReq,

N4Session ReleaseReq,

N10Registration Request

STATUS M String
STATUS-CODE O Number
PDU-SESSION- TYPE M Number
CAUSE O String

PROCEDURE

ID

EVENT-ID VERSION M String S5S8Create SessReq
SUPI M String
IMEI/PEI M String
IMSI M String
MSISDN M String
GPSI M String
STATUS M String
STATUS-CODE O Number
PCO O PCO
PDU-SESSION- TYPE O Number
SSC-MODE O Number
DNN/APN O String
QOS-RULE O QOS-RULE
QOS-DESC O QOS-DESC
SESSION-AMBR O SESS-AMBR
CAUSE O String
PAA O PAA
S-NSSAI O NSSAI
RAT-TYPE M String
EVENT-ID1=1000 VERSION M Number META DATA
SUPI M
IMEI/PEI M
IMSI M
MSISDN M
GPSI
SERVING-PLMN M
UE-LOCATION M UE-LOCATION
START-TIME M String
END-TIME M String
TRIGGER-NF M
TRIGGER- EVENT M
USERPLANE- STATUS M
CAUSE M
SGW-ID O
DISCONNECT- REASON O
STATUS M
STATUS-CODE O
DNN M
RAT-TYPE M
UE-TIMEZONE M
PDU-SESSION- TYPE M
UE-PLMN M
SUBSCRIBED- SESS-AMBR- UPLINK M
SUBSCRIBED- SESS-AMBR- DOWNLINK M
SUBSCRIBED- 5QI M
SUBSCRIBED- ARP M
PAA M
LOCAL-SEID M
REMOTE-SEID M
ROAMING- STATUS M
CONNECTION- TIME M NA NA
PDU-SESSION- ID O
ALWAYS-ON O
EPS-IWK O
S-NSSAI O
MAX-SUPP- FILTERS O
SSC-MODE O
UE-TYPE O
LOCAL-CFTEID- TEID O
LOCAL-CFTEID- IP O
REMOTE-CFTEID- TEID O
REMOTE-CFTEID- IP O
VIRTUAL-DNN/ APN O

For details on the listed attributes, see the table in the EDR Transaction File section.

Table 7. PDN Delete Event
Attributes Event ID Name Presence Description
TXN EDR fields M
PROCEDURE-ID=3 EVENT-ID= <event_id> VERSION M

EVENT= N11SmContext ReleaseReq,

N40Charging DataReq,

N7SmPolicy DeleteReq,

N10UnsubscribeFor NotificationReq,

N10Deregistration Request,

N7SmPolicy TerminateNotifyReq,

N40Charging NotificationReq,

RadiusCoa DisconnectReq,

N7SmPolicy TerminateNotifyReq,

N40Charging NotificationReq,

N10Update NotifyReq,

N11SmContext StatusNotifyReq,

N11N1N2Message TransferFail NotificationReq

STATUS M
STATUS-CODE M
CAUSE O
EVENT-ID= <event_id> VERSION M

N1N2Message TransferReq,

N11SmContext UpdateReq

STATUS M
STATUS-CODE O
N1MSGREQTYPE O

PduSession ReleaseCommand,

PduSession ReleaseRequest,

PduSession ReleaseComplete

N2MSGREQTYPE O PduSessionResource ReleaseCommand
N1MSGRESPTYPE O PduSession ReleaseReject
N2MSGRESPTYPE O
BACKOFF-TIME O NA
PCO O
CAUSE O
EVENT-ID1=1000 VERSION M META-DATA
SUPI M
IMSI M
IMEI M
MSISDN M
GPSI
SERVING-PLMN M
UE-LOCATION M
START-TIME M
END-TIME M
TRIGGER-NF M
TRIGGER-EVENT M
USERPLANE- STATUS M
CAUSE M
SGW-ID O
DISCONNECT- REASON O
STATUS M
UPDATE-TIME M NA

NOTES:

  • Userplane-status is of type number. The number can be one of the following:

    • UpStateNone = 0

    • UpStateEstablishing = 1 // UPF Session is being established or setup

    • UpStateActivating = 2 // UPF Session is being modified to Activate Access Tunnel

    • UpStateActivated = 3 // UPF Session Active for Access & Core Tunnel

    • UpStateDeactivating = 4 // UPF Session is being modified to Deactivate Access Tunnel

    • UpStateDeactivated = 5 // UPF Session Deactivated for Access, valid Core Tunnel Only

    • UpStateModifying = 6 // UPF Session is being modified for QoS/flow parameters

    • UpStateDeleting = 7 // UPF Session is being Released

    • UpStateDeleted = 8 // UPF Session is Released

  • PduSessionType is of type number. The number can be one of the following:

    • UnknownSessionType = 0

    • Ipv4PduSession = 1

    • Ipv6PduSession = 2

    • Ipv4V6PduSession = 3

      Unstrutured = 4

      Ethernet = 5

      FutureUsePduSessionType = 7

  • SSC mode is of type number. The number can be one of the following:

    • UnknownSscMode = 0

    • SscMode1 = 1

    • SscMode2 = 2

    • SscMode3 = 3

    • DupSscMode1 = 4

    • DupSscMode2 = 5

    • DupSscMode3 = 6

    • FutureUseSscMode = 7

  • Eps Iwk (Type: Number)

    • EpsInterworkingIndication_DummyEnum = 0

    • EpsInterworkingIndication_NONE = 1

    • EpsInterworkingIndication_WITH_N26 = 2

    • EpsInterworkingIndication_WITHOUT_N26 = 3

  • Roaming status (Type: Number)

    • ROAMING_STATUS_NONE = 0

    • ROAMING_STATUS_HOMER =1 //HOMER

    • ROAMING_STATUS_VISITOR_LBO =2 //LBO

    • ROAMING_STATUS_VISITOR_HR = 3 //IN-HR

    • ROAMING_STATUS_ROMER = 4 //OUT-HR

  • PreemptionCapability (type: Number)

    5G:

    • 0: "PreemptionCapability_DummyEnum",

    • 1: "NOT_PREEMPT",

    • 2: "MAY_PREEMPT",

    Others:

    • 0: Disabled

    • 1: Enabled

  • PreemptionVulnerability (type: Number)

    5G:

    • 0: "PreemptionVulnerability_DummyEnum",

    • 1: "NOT_PREEMPTABLE",

    • 2: "PREEMPTABLE",

  • Disconnect-Reason (type: String)

    Disconnect-Reason contains a self-explanatory string. If it holds a number, then the string interpretation is as follows:

    • PduRelReason_Error = 1

    • PduRelReason_SessIdleTimeout = 2

    • PduRelReason_SessCpIdleTimeout = 3

    • PduRelReason_SessAbsoluteTimeout = 4

Procedure EDR Example:

1,2021/03/18 13:43:40.892,1448,imsi-123456789012345,1287,N11SmContextCreateReq,
.
.
.
3,1313,V1,Success,201,1,,3,1316,V1,Success,200,1,,3,1319,V1,Success,201,1,,3,1287,V1,
imsi-123456789012345,imei-123456786666660,123456789012345,9999988888,msisdn-9999988888,
Success,,1,0,,,193|,,,,,,,NR,3,3329,V1,imsi-123456789012345,imei-123456786666660,msisdn-9999988888,
Success,201,1,3|1;2;7|3000 mbps|4000 mbps|1000 mbps|2000 mbps,20 kbps|20 kbps,,3,3332,V1,Success,
204,1,,3,3585,V1,Success,201,1,,3,524,V1,Success,,1,Request_Accepted,3,1299,V1,Success,200,194|,
77|,,,,1,1,intershat,2|1|0|2|128|1|filters:0;3;1;;|3|1|0|2|192|1|filters:0;3;1;;|1|1|1|1|255|1|
filters:0;3;1;;,5||0 kbps|0 kbps|0 kbps|0 kbps|3||6000 mbps|8000 mbps|2000 mbps|4000 mbps,20 kbps|
20 kbps,N1_N2_TRANSFER_INITIATED,12.0.4.0|,2|Abf123||,0

In the preceding example, the initial entries represent the transaction EDRs and last part provided here represents the procedure-level EDRs.

EDR Transaction Collision

This EDR file dumps the transaction collision information whenever the collision occurs. It is useful to debug collision scenarios.

Table 8. EDR Transaction Collision File Fields

Field No.

Field Name

Field Description

1

Subscriber ID

The subscriber ID. For example, imsi-123456789012345

2

Collision Time

Collision time in yyyy/MM/dd HH:mm:ss.SSS format.

3

Force Resolution

Indicates whether the resolution is forced (true/false).

4

Collision Cause

The cause of collision.

5

New Transactions Before Collision

Transactions in the new state before collision handling separated by |.

6

Pending Transactions Before Collision

Transactions in the pending state before collision handling separated by |.

7

Active Transactions Before Collision

Transactions in the active state before collision handling separated by |.

8

New Transactions After Collision

Transactions in the new state after collision handling separated by |.

9

Pending Transactions After Collision

Transactions in the pending state after collision handling separated by |.

10

Active Transactions After Collision

Transactions in the active state after collision handling separated by |.

11

Suspended Transactions After Collision

Transactions in the suspended state after collision handling separated by |.

12

Aborted Transactions After Collision

Transactions in the aborted state after collision handling separated by |.

CSV Format Examples:

supi:imsi-123456789012345,2020/10/06 16:15:11.801,true,SessionLockSamePriority,17,,,,,,|17,,
supi:imsi-123456789012345,2020/10/06 16:15:11.824,true,SessionLockSamePriority,18,,,,,,|18,,
supi:imsi-123456789012345,2020/10/06 16:15:11.857,true,SessionLockSamePriority,19,,,,,,|19,,
supi:imsi-123456789012345,2020/10/06 16:15:11.883,true,SessionLockSamePriority,20,,,,,,|20,,
supi:imsi-123456789012345,2020/10/06 16:15:11.888,true,SessionLockRelease,,,,,,,,,x

EDR Attributes

This section provides details of the EDR attributes and its sub attributes.

Table 9. QOS-RULE
QOS-RULE-LIST qr-id|qr-opcode| qr-dqr|qr-qfi| qr-prededence|num-filters| filters:flter-id;flter-dir; fltr-cmp-type;ip;port
Field Sub field Sub-sub field Presence

QOS-RULE

QOS-RULE-ID M
QOS-RULE-OPCODE M
QOS-RULE-DQR M
QOS-RULE-QFI M
QOS-RULE- PRECEDENCE M
NO-PKT-FILTERS
PKT-FILTER-LIST M
PKT-FILTER-ID M
PKT-FILTER- DIRECTION M
PKT-FILTER-CMP-TYPE M
PKT-FILTER-IP- ADDRESS O
PKT-FILTER-PORT O

Note

Delimiters subject to change based on the position of QOS-RULE in the attribute.


Table 10. QOS-DESC
QOS-DESC [5qi|preEmpCap;preEmpVul;Prior| mbr-ul|mbr-dl|gbr-ul|gbr-dl]
Sub field Type Presence
5QI M
ARP ARP M
MBR-UPLINK O
MBR-DOWNLINK O
GBR-UPLINK O
GBR-DOWNLINK O

Note

Delimiters subject to change based on the position of QOS-DESC in the attribute.


Table 11. PCO
PCO [TYPE|PCSCF-ADDR-LIST|DNS-ADDR-LIST| PDU-SESSION-ID| QOS-RULE-LIST|SESSION-AMBR| QOS-DESC|S-NSSAI| MS-SUPPORT-NW_ADDR-TFT| NW-SUPPORT-NW_ADDR-TFT| PCSCF-ADDR-REQ|DNS-ADDR-REQ|MTU-REQ| MTU-SIZE]
Sub field Type Presence
TYPE String M EPCO or PCO or APCO
PCSCF-ADDR-LIST PCSCF-ADDR O CSR Response sent from SMF
DNS-ADDR-LIST DNS-ADDR O CSR Response sent from SMF
PDU-SESSION-ID O CSR Response sent from SMF
QOS-RULE-LIST QOS-RULE O CSR Response sent from SMF
SESSION-AMBR SESS-AMBR O CSR Response sent from SMF
QOS-DESC QOS-DESC O CSR Response sent from SMF
S-NSSAI NSSAI O CSR Response sent from SMF
MS-SUPPORT-NW_ ADDR-TFT Boolean O CSR Response sent from SMF
NW-SUPPORT-NW_ ADDR-TFT Boolean O CSR Response sent from SMF
PCSCF-ADDR-REQ PCSCF-ADDR-REQ O CSR Response sent from SMF
DNS-ADDR-REQ DNS-ADDR-REQ O CSR Response sent from SMF
IPV4-MTU-REQUEST Boolean O CSR Response sent from SMF
IPV4-MTU-SIZE String O CSR Response sent from SMF

Note

In the preceding table, CSR Request and CSR Response messages refer to 4G and Wi-Fi call flows. N11 SM Context Create Request and Response messages refer to 5G call flows.


Table 12. PCSCF-ADDR-REQ
PCSCF-ADDR-REQ [PCO-PCSF-ADDR-IPV4-REQ ; PCO-PCSF-ADDR-IPV6-REQ]
Sub field Presence Type
PCO-PCSF-ADDR-IPV4-REQ M Boolean
PCO-PCSF-ADDR-IPV6-REQ M Boolean
Table 13. PCSCF-ADDR
PCSCF-ADDR [ipv4-Primary; ipv4-secondary; ipv4-tertiary; ipv6-Primary; ipv6-secondary; ipv6-tertiary]
Sub field Presence Type
PCSF-ADDR-IPV4-LIST O List
PCSF-ADDR-IPV6-LIST O List
Table 14. DNS-ADDR
DNS-ADDR [ipv4-Primary; ipv4-secondary; ipv4-tertiary; ipv6-Primary; ipv6-secondary; ipv6-tertiary]
Sub field Presence Type
DNS-ADDR-IPV4-LIST O List
DNS-ADDR-IPV6-LIST O List
Table 15. DNS-ADDR-REQ
DNS-ADDR-REQ [PCO-PCSF-ADDR-IPV4-REQ; PCO-PCSF-ADDR-IPV6-REQ]
Sub field Presence Type
PCO-PCSF-ADDR-IPV4-REQ M Boolean
PCO-PCSF-ADDR-IPV6-REQ M Boolean
Table 16. NSSAI
NSSAI [sst|sd|hplmnsst|hplmnsd]
Sub field Presence Type
SST M Number
SD O String
HPLMN-SST O Number
HPLMN-SD O String

Note

Delimiters subject to change based on the position of S-NSSAI in the attribute.


Table 17. PAA
PAA [ipv4-addr|ipv6-addr]
Sub field Presence Type
ADDR-IPV4 O String
ADDR-IPV6 O String
Table 18. N1N2MSGREQCONTENT
N1-Msg-Req-Content [msg-type|cause]
Sub field Presence Type
MSG-TYPE M SMF N1N2MsgType
Cause O String
Table 19. PLMN-ID
PLMN-ID mcc|mnc
Sub field Presence
MCC M
MNC M

Note

Delimiters subject to change based on the position of PLMN-ID in the parent attribute.


Table 20. GUAMI
GUAMI amf-id|plmn-id
Sub field Presence
AMF-ID M
PLMN-ID M
Table 21. SESS-AMBR
SESS-AMBR [ambr-dl| ambr-ul]
Sub field Presence Type
mbr-dl O Number
ambr-ul O Number
Table 22. UE-LOCATION
UE-LOCATION

[locationType|Ecgi: ECGI|Tai:TAI] or

[locationType|Ncgi: NCGI|Tai:TAI]

Sub field Presence Type
locationType M String “Eutra” or “NR”
ECGI or NCGI O ECGI/NCGI
Tai O TAI
Table 23. ECGI or NCGI
ECGI /NCGI [plmn-id;cellId]
Sub field Presence Type
Plmn-id M PLMN-ID
Cell-id M String
Table 24. TAI
TAI [plmn-id;tac]
Sub field Presence Type
Plmn-id M PLMN-ID
tac M String

The SMF generates detailed records with field-level details per event. The following table lists the different N1 N2 messages and the associated IDs.

Table 25. N1 N2 Message Types
Message Message ID
PDU-SESSION-ESTB-REQUEST 193
PDU-SESSION-ESTB-ACCEPT 194
PDU-SESSION-ESTB-REJECT 195
PDU-SESSION-MOD-REQ 201
PDU-SESSION-MOD-CMD 203
PDU-SESSION-MOD-CMD-REJ 202
PDU-SESSION-MOD-CMD-COMP 204
PDU-SESSION-REL-REQ 209
PDU-SESSION-REL-CMD 211
PDU-SESSION-REL-REJ 210
PDU-SESSION-REL-COMP 212
N2_PDU_SESSION_RESOURCE_RELEASE_COMMAND 85
N2_PDU_SESSION_RESOURCE_RELEASE_RESPONSE 130
N2_PDU_SESSION_RESOURCE_SETUP_REQUEST 77
SM-CONTEXT-CREATE 2500
SM-CONTEXT-CREATE-RESP 2501
SM-CONTEXT-UPDATE 2502
SM-CONTEXT-UPDATE-RESP 2503
PDU-RES-SETUP-REQ 3000

Limitations

The EDR Logging feature has the following limitations:

  • Event record generation does not work for the following procedures:

    • PDU Session Modify

    • Handover

    • Idle-Active transition

    • Active-Idle transition

  • The SMF supports only IMSI (SUPI)-based EDR reporting.

  • The SMF currently supports EDR generation in CSV format. The EDR file storage format is not configurable.

  • This feature is not applicable to a procedure that does not send a response explicitly to an incoming request.

Configuring EDRs

This section describes how to configure the EDR Logging feature.

Enable EDR Reporting


Note

Currently, the EDR file generation works for only specific subscribers. EDR generation occurs after configuring the subscriber ID.


Use the following sample configuration to enable or disable the EDR generation for particular subscribers.

config 
    edr reporting enable 
    edr subscribers subscriber_id  
    end  

NOTES:

  • edr reporting enable : Specify this keyword to enable the EDR reporting on SMF. Use the edr reporting disable command to disable the EDR reporting functionality. By default, the EDR reporting is disabled.

  • edr subscribers subscriber_id : Specify the ID of subscribers for which the EDR reporting must be enabled. subscriber_id must be an alphanumeric string. The default value is empty.


    Note

    Be sure to specify the exact subscriber key in this command. The SMF supports only IMSI (SUPI)-based EDR reporting.


  • Configure a minimum of one subscriber upon enabling the EDR reporting.

  • You can configure up to a maximum of 10 subscribers for EDR generation.

Configure EDR Files for Generation

Use the following sample configuration to generate the EDR events at transaction level.

config 
   edr file { transaction | transaction-collision } 
      disable procedure-id procedure_id_value  
      procedure-id procedure_id_value  
         disable event-id event_id_value  
         event-id event_id_value  
            disable field-id field_id_value 
            end 
  • edr file { transaction | transaction-collision } : Specify to generate EDR files with transaction or transaction-collision level details for subscriber sessions.

  • procedure-id procedure_id_value : Specify the procedure ID or procedure name for which the event reporting must be enabled.

  • event-id event_id_value : Specify the event ID or event name for which the event reporting must be enabled.

  • field-id field_id_value : Specify the field ID or field name for which the event reporting must be enabled.

  • All procedure IDs, event IDs, and field IDs registered by application, are enabled by default.

  • If a procedure-id is disabled, no event start, add field, or event-end will be honored for the procedure-id.

  • If an event-id is disabled within a procedure id, then event-start, event-end, or add field will not be honored for the procedure-id and event-id combination.

  • If a field-id is disabled for an event-id, then add-field will not be honored, and a blank entry will be present instead of value in CSV entry.

Example configuration:

edr file transaction
  disable procedure-id 24 32
  procedure-id 25
    disable event-id 5 7 8   
    event-id 5
      disable field-id 10 12 14 

In the preceding example, disable event-id 5 7 8 means disable the event-id 5, 7, and 8 for procedure-id 25. The disable field-id 10 12 14 means disable the field-id 10, 12, and 14 for procedure-id 25 and event-id 5.

Configure EDR Parameters

Use the following sample configuration to configure the EDR parameters.

config 
   edr file transaction  
      limit size file_size count file_count 
      flush interval file_flush_interval 
      end 

NOTES:

  • limit size file_size count file_count : Specify the maximum size of one EDR file, after which the EDR file is compressed and new CSV file is created. The default file size is 100 MB.

    count file_count : Specify the maximum number of EDR files to be preserved. The default file count is 10.

  • flush interval file_flush_interval : Specify the time interval, in milliseconds, to flush the EDR files. The default value is 1000 ms.

Verifying EDR Transactions

Use the following show commands to display the currently registered procedures, events, and fields for the application along with their respective IDs.

show edr transaction-procedure procedure_id event event_id 
show edr event event_id 

You can provide all the procedures and events. Otherwise, you can provide a particular procedure name and event name or procedure-id and event-id.


Note

The show command output is based on the mapping registered by the application.


The following is an example of the show command output.

Procedure-id 20, Procedure-Name: xyz
    Event-id 1, Event-Name: abc
         1 – Field1-Name
         2 – Field2-Name
         …
         …
         …
     Event-id 2, Event-Name: efgh
          1 – Field1-Name
          2 – Field2-Name
          …
          …
          …
    …
    …
    …
Procedure-id 21, Procedure-Name: bbbb
     Event-id 1, Event-Name: cccc
          1 – Field1-Name
          2 – Field2-Name
          …
          …
          …
     Event-id 2, Event-Name: dddd
          1 – Field1-Name
          2 – Field2-Name
          …
          …
          …

This output helps the operator to know current CSV format of a particular procedure-id and event-id pair.

OAM Support for EDR Logging

This section describes operations, administration, and maintenance information for this feature.

Bulk Statistics Support

The SMF maintains the following bulk statistics as part of this feature.

  • edr_error_total

    Labels:

    • error_code – The EDR writing error code

This metric is pegged whenever an error occurs during EDR writing. This metric displays "EdrQueueFull" as the error_code when the writing queue is full and the EDR is dropped.

Metadata Provided by SMF for EDR

The SMF provides the following metadata to the User Plane Function (UPF), which includes the data in the generated EDRs:

  • Called-Station-ID: Specifies the DNN for the session

  • Calling-Station-ID: Specifies the MSISDN of the UE

  • RAT Type: RAT type for the current session (NR or EUTRAN)

  • ULI: User location for the current session

The UPF receives the above data in the "Subscriber Parameters" IE in the PFCP Session Establishment Request message. The RAT type and ULI can change during the lifetime of session (for events, such as 5G to 4G handover). The UPF receives the changed values of these parameters in the PFCP Session Modification Request message.


Note

  • All the parameters are always sent from the SMF to the UPF irrespective of EDR configuration being available. These parameters ensure that any change in configuration after the session creation is immediately applied on the UPF.

  • The SMF supports EDR-related configurations. However, the SMF does not require these configurations for its functionality. These configurations are sent to the UPF through RCM.


X-Header Insertion Support

With the X-Header Insertion and X-Header Encryption features, collectively known as Header Enrichment, you can append headers to HTTP or WSP GET and POST request packets, and HTTP response packets for use by end applications. For example, mobile advertisement insertion (MSISDN, IMSI, IP address, user-customizable, and so on.

Supported X-Header Information

Out of all the configurable X-header information, some information requires control plane (SMF) to send the corresponding values to the user plane (UPF). The following table lists the information that is sent from the SMF to the UPF for X-header Insertion support.

Xheader Field Description Present in Session Establishment Modified in Session Modification
String Constant Inserts the configured string in xheader N/A N/A
Charging ID Per Flow/Bearer Charging Id Yes N/A
IMEI IMEI for the call Yes N/A
IMSI IMSI for the call Yes N/A
Rat-Type RAT type for the UE session Yes Yes
s-mcc-mnc MCC/MNC of the SGW/AMF Yes N/A
Sgsn-address AMF/SGW address Yes Yes
ULI User Location Info Yes Yes
GGSN-Address N4/S5 endpoint of SMF Yes Yes
Radius-station-ID MSISDN of the UE N/A N/A
Sn-rulebase Rulebase for a call Yes Yes
Subscriber-ip-address IP address allocated to UE N/A N/A
Msisdn-no-cc Obtained from MSISDN Yes No

The subscriber-specific fields—IMSI, MSIDN, and IMEI—are encoded in the "User ID" standard IE. See, 3GPP 29.244, Section 8.2.101 for more information.

Rest of the fields are sent in the "Subscriber Parameters" proprietary AVP. Some fields, such as the "Rulebase" and "UE IP address", are sent as a part of the created PDRs.


Note

  • All the parameters are always sent from the SMF to the UPF irrespective of whether X-header configuration is available. These parameters ensure that any change in configuration after session creation is immediately applied on the UPF.

  • The SMF supports X-header Insertion-related configurations. The SMF does not require these configurations for its functionality. These configurations are sent to the UPF through the RCM.


Bearer QCI Support

Feature Description

The User Plane function (UPF) requires the Bearer level information (BLI) for each QoS flow like QFI for 5G and Bearer Id for 4G, 5G QoS Identifier (5QI) allocation and retention priority (ARP), and Charging ID, to support inline services. The Bearer QCI Support feature facilitates this requirement with the SMF.


Note

The Bearer QCI Support feature also includes support for Bli_ID and QFI values in the “Create PDR” message.

The SMF sends the Bearer QoS Class Identifier (QCI) Information Element (IE), which is cisco proprietary IE, in the PFCP session establishment request and PFCP session modification request. The UPF implicitly derives the deletion indication. If a BLI ID is no longer associated with any PDR, the UPF removes it from the PFCP session context. The UPF adds the 5QI or QCI value in the EDR. Currently, the Bearer QCI field is used for 5G to add the 5QI.

The BLI is reported to the UPF as shown in the following table. The formats and encoding and decoding of these IEs are the same as other 3GPP IEs as described in TS 29.244.

Information

Elements

Mandatory

/Optional

Data Type Description

valid

guint8

Validity of the Bearer level information IE

bli_id

Mandatory

PfcpBliId

QoS flow identifier (QFI) of 5G or Bearer ID (4G)

qci

Optional

PfcpQci

Used by PGW-C, not relevant for SMF

_5qi

Optional

Pfcp5qi

5QI associated with the QoS flow

arp

Mandatory

PfcpArp

ARP comprises of pre-emption capability, Pre-emption vulnerability, and priority level.

charging_id

Optional

PfcpChargingId

Charging ID associated with the QoS flow or Bearer (or both).

Bearer Level Information ID

The unique ID for each Bearer level information sent from SMF. The recommended value of this IE is QFI (in 5G) or Bearer-id (in 4G). The format of IE is as below:

Bits

Octets

8

7

6

5

4

3

2

1

1 to 2

Type = 232 (decimal)

3 to 4

Length = 1

5

BLI_ID value

6 to n+4

These octets are present only if explicitly specified

QCI : This is not applicable for 5G. It is used in CUPS, if required.

Bits

Octets

8

7

6

5

4

3

2

1

1 to 2

Type = 233 (decimal)

3 to 4

Length = 1

5

QCI value

6 to n+4

These octets are present only if explicitly specified

5QI: The SMF uses this this IE to send the 5QI value.

Bits

Octets

8

7

6

5

4

3

2

1

1 to 2

Type = 234 (decimal)

3 to 4

Length = 1

5

5QI value

6 to n+4

These octets are present only if explicitly specified

ARP: The ARP value is sent with this IE.


Note

From SMF, the ARP value is encoded as arp->pci)<<4) | arp->pl)<<2)| arp->pvi)

Bits

Octets

8

7

6

5

4

3

2

1

1 to 2

Type = 235 (decimal)

3 to 4

Length = 1

5

ARP value

6 to n+4

These octets are present only if explicitly specified

Charging ID: The Charging IE is sent with this IE.

Bits

Octets

8

7

6

5

4

3

2

1

1 to 2

Type = 236 (decimal)

3 to 4

Length = 1

5

Charging Id value

6 to n+4

These octets are present only if explicitly specified

Triggers for Bearer Level Information IE

The following are the triggers for sending the BLI IE in PFCP messages:

PFCP Session Establishment Message

The Bearer level information IE is sent for each new QoS flow with the unique QFI ID. This IE is added in the policy decision in the N7 Policy Control Create Response message from the PCF. Therefore, SMF sends multiple instances of this IE, in a single PFCP message.

PFCP Session Modification Message:

Any new QoS flow addition or new PCC rule referring to an existing QoS flow that results in a new QER or PDR IE that has a new Bearer level information IE for each unique QFI ID.

The BLI IE is not included in the PFCP Session Modification Message if the modification is for IDFT tunnels.