ECS Regular Expression

Feature Summary and Revision History

Summary Data

Table 1. Summary Data

Applicable Product(s) or Functional Area

5G-UPF

Applicable Platform(s)

VPC-SI

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

First introduced.

2022.01.2

Feature Description

The ECS Regular Expression feature supports the implementation of regex engine in the User Plane Function (UPF). Furthermore, this feature allows you to configure the regex rule through RCM.

The UPF supports the following protocols as part of regex engine rebuild and rule matching.

  • HTTP

    • URL

    • URI

    • HOST

  • WWW

    • URL

    • URI

  • RTSP

    • URL

    • URI

How It Works

The following table lists the special characters that you can use in regex rule expressions.

Convention Description
* Zero or more characters.
+ Zero or more repeated instances of the token preceding the +.
? Zero or one character.
\character Escaped character.
\? Match on a question mark (\<ctrl-v>?)
\+ Match on a plus sign
\* Match on an asterisk
\a Alert (ASCII 7)
\b Backspace (ASCII 8)
\f Form-feed (ASCII 12)
\n New line (ASCII 10)
\r Carriage return (ASCII 13)
\t Tab (ASCII 9)
\v Vertical tab (ASCII 11)
\0 Null (ASCII 0)
\\ Back slash
Bracketed range [0-9] Matching any single character from the range.
A leading ^ in a range No match in the range. All other characters represent themselves.
.\x## Any ASCII character as specified in two-digit hex notation. For example, \x5A yields a ā€˜Zā€™.

The following diagram illustrates the regex rule configuration through RCM:

Configuring Regex Rule

Configure the regex rule through RCM using UPF CLI instance or directly on the UPF through CLI.

configure 
   require rcm-configmgr 
   end 

Sample Configuration

Following is a sample configuration for configuring the Regex Rule.

configure
   active-charging service <service_name>
      ruledef <ruledef_name>
         http url regex <regex_url>
         rtsp uri regex <regex_uri>
         www url regex <regex_url>
         end

Monitoring and Troubleshooting

This section provides information on CLI commands that are available for monitoring and troubleshooting the feature.

Show Commands and Outputs

This section provides information about show CLI commands that are available in support of ECS Regex feature in UPF.

Show Commands

Description

show user-plane-service regex status

Use this command to display the engine status for the SessMgr instance.

show user-plane-service regex statistics memory

Use this command to display the memory statistics for the SessMgr instance.

show user-plane-service regex statistics memory summary

Use this command to display the combined memory summary for the SessMgr.

show user-plane-service regex statistics ruledef

Use this command to display the regex ruledef statistics for the SessMgr.

show user-plane-service regex statistics ruledef summary

Use this command to display the combined regex ruledef statistics summary for the SessMgr.