Configuration Guide for Subscription and Policies
Ericsson Service-Aware Policy Controller

Contents

1Configuration and Provisioning Overview
1.1Other Conventions

2

Configuration Prerequisites

3

Subscription and Policies Data Overview

4

Provision Subscribers
4.1Provision Subscriber Groups
4.1.1Provision Global Subscriber Group
4.2Provision Subscribers
4.2.1Subscriber Identifiers
4.3Handling of Multiple Service Offerings
4.4Configure Dynamic Group Selection
4.5Handling of Unknown Subscribers
4.5.1Autoprovisioning
4.5.2Unknown Subscriber
4.5.3Unknown Subscriber EDSources pointing to the SAPC internal database
4.5.4Unknown and Autoprovisioning Precedence

5

Provision Policies
5.1Policies Basic Concepts
5.1.1Rule Combining Algorithm in a Policy
5.1.2Combining Algorithm in a Policy Locator
5.1.3Combining Algorithm for the Subscriber Policies
5.2Provisioning Policies
5.2.1Subscriber Extension Data to Be Used in Policies
5.3Policy Types
5.4Policy Tags

6

Appendix A. Condition Policy Language
6.1Condition Formula Examples
6.1.1Reuse of Complex Expressions
6.2Condition Formula Language
6.2.1Condition Formula Operators
6.2.2Condition Formula Expressions

Reference List

1   Configuration and Provisioning Overview

Figure 1 shows the main parts related to configuration and provisioning in the SAPC.

Figure 1   Configuration and Provisioning Overview

The purpose of this document is to provide a guideline for subscription and policies in the SAPC by providing some configuration and provisioning examples.

This document does not intend to be an exhaustive guide for all possibilities related to subscription and policies in the SAPC.

Furthermore, for each particular function of the SAPC (for example, Access and Charging Control, Bearer QoS Control or Fair Usage Control), specific subscription and policy data could be needed. This particular subscription and policy data can be found in the corresponding SAPC Configuration Guides document.

The complete parameter list and details of all configured options of the SAPC are included in separate documents. For more information, refer to Managed Object Model (MOM) and Provisioning REST API.

Examples in this document cover the case of data configured in the SAPC internal repository. If an external repository is used, refer to Database Access.

1.1   Other Conventions

This document refers to some configuration and provisioning data.

To clarify which detailed data is managed by COM or by the REST API, this document uses the following conventions:

2   Configuration Prerequisites

Before configuring the SAPC in an operational network, make sure that:

3   Subscription and Policies Data Overview

The main elements in the SAPC data model are Subscribers, Subscriber Groups, and Policies, which are applicable to all the SAPC functions.

Provision each subscriber or group with the desired attributes for the applicable functions that the SAPC controls, such as Access and Charging Control, Bearer QoS Control, and Fair Usage Control.

Characterizing Subscribers or Groups can be done in the following ways:

4   Provision Subscribers

4.1   Provision Subscriber Groups

Subscribers sharing similar data (service offering) can be grouped. The services and policies defined for a group apply to the subscribers belonging to that group.

To provision subscribers groups, use the dataplan URI in the provisioning REST API.

Example 1 provisions some subscriber groups:

Example 1   Configuration of Subscriber Groups

PUT /dataplans/Bronze
{
	"dataplanName" : "Bronze",
	"subscribedContents" : 
	[
		
		{
			"contentName" : "Chat",
			"redirect" : false
		}
	]
}

PUT /dataplans/Gold
{
	"dataplanName" : "Gold",
	"subscribedContents" : 
	[
		
		{
			"contentName" : "Streaming",
			"redirect" : false
		},
		
		{
			"contentName" : "Video",
			"redirect" : false
		},
		
		{
			"contentName" : "Chat",
			"redirect" : false
		}
	]
}
 

Gold subscribers are enabled to execute Streaming, Video, and Chat services.

Bronze subscribers are enabled to execute only Chat services.

Gold, Bronze, and all subscribers are also enabled to execute internet service, coming from global group (see Example 2).

4.1.1   Provision Global Subscriber Group

A special subscriber group with identifier "global" and lowest group priority can be provisioned with the default values to apply for all the subscribers. All the subscribers implicitly belong to this "global" group (without the need of setting "global" value in their attribute dataplans).

Example 2 is an example for the provisioning of the global subscriber group:

Example 2   Configuration of Global Subscriber Group

PUT /dataplans/global
{
	"dataplanName" : "global",
	"subscribedContents" : 
	[
		
		{
			"contentName" : "Internet",
			"redirect" : false
		}
	]
}
 

"global" group subscribers are enabled to execute the internet service. No services are globally blacklisted. Thus, all the subscribers provisioned in the SAPC have Internet as a subscribed service. This is why in Example 1 the groups do not contain Internet as a subscribed service.

4.2   Provision Subscribers

To provision subscribers, use the subscriber URI in the provisioning REST API.

Example 3 provisions a subscriber:

Example 3   Provisioning of Subscriber

PUT /subscribers/34600000001
{
	"dataplans" : 
	[
		
		{
			"dataplanName" : "Gold"
		}
	],
	"deniedContents" : [ "Chat" ],
	"subscriberId" : "34600000001"
}
 

Example 3 provisions subscriber "34600000001" belonging to group "Gold" but is not authorized to execute Chat service, overriding the group specifications.

Temporary Subscriptions

It is possible to apply for a subscriber certain profile data (coming from a service offering) only during a particular period. To do that, use dataplanName, startDate, and stopDate JSON attributes inside dataplans in the subscriber URI in the provisioning REST API.

Subscriber Dates With Daylight Saving Time (DST)

For ambiguous time representations, the SAPC considers the non DST time.

An ambiguous time is a time that maps to more than one Coordinated Universal Time (UTC). It occurs when the clock time is adjusted back in time, such as during the transition from a time zone's daylight saving time to its standard time.

To avoid misleading Time of Day behaviors, do not configure times in this range.

Example 4 provisions a subscriber in Europe/Stockholm time zone with silver group which starts on the last Sunday of October 2017, 02:30 CET (non DST). This dataplan has no effect for that subscriber, on summer time, 02:30 CEST.

Example 4   Provision a Subscriber dataplan which applies on non DST time

PUT /subscribers/34600000002
{
	"dataplans" : 
	[
		
		{
			"dataplanName" : "Silver",
			"startDate" : "29-10-2017T02:30"
		}
	],
	"deniedContents" : [ "Skype" ],
	"subscriberId" : "34600000002"
}
 

4.2.1   Subscriber Identifiers

It is possible in the SAPC to use an administrative subscriber identifier to locate the subscriber profile and applicable subscriber policies different from the subscriber traffic identity received in the protocol requests.

To provision the mapping between the traffic identities and the administrative identifier, do the following steps:

  1. Create an instance of EDSourceMOC with eDSourceId = SubscriberIdentity, containing exactly the content of Example 5.
  2. Set administrative and traffic identifiers in subscriberId and trafficIds JSON attributes in the subscriber URI in the provisioning REST API.

Here is the exact configuration for SubscriberIdentity EDSource:

Example 5   Subscriber Identity

<edit-config>
    <target>
    <running />
    </target>
    <config>
   <ManagedElement xmlns="urn:com:ericsson:ecim:ComTop">
    <managedElementId>1</managedElementId>
    <dnPrefix>dc=ManagedElement</dnPrefix>
    <networkManagedElementId>1</networkManagedElementId>
    <userLabel>Managed Element</userLabel>
    <PolicyControlFunction xmlns="urn:com:ericsson:ecim:sapcmom">
      <policyControlFunctionId>1</policyControlFunctionId>
         <EntityData xmlns="urn:com:ericsson:ecim:entitydatamom">
            <entityDataId>1</entityDataId>
            <EDSources xmlns="urn:com:ericsson:ecim:edsourcesmom">
               <eDSourcesId>1</eDSourcesId>
                  <EDSource xmlns="urn:com:ericsson:ecim:edsourcemom" xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" nc:operation="merge">
                     <eDSourceId>SubscriberIdentity</eDSourceId>
                        <definition>
def SubscriberIdentity (subsId)
{
  dataSource = 
  {
    url = "internaldb:";
    query = "SubscriberTrafficIdPot:{subsId}";
  }
  fieldDef =
  {
    trafficId = arg(subsId);
    adminId = dataSourceField("subscriberId");
  }
}
                 </definition>
               </EDSource>
            </EDSources>
         </EntityData>
   </PolicyControlFunction>
   </ManagedElement>
   </config>
</edit-config>

Warning!

If the content of SubscriberIdentity EDSource is not exactly as shown in Example 5, the SAPC does not handle properly the mapping between traffic and administrative subscriber identifiers.

Example 6 is an example for provisioning of subscriber identities:

Example 6   Subscriber identities mapping

PUT /subscribers/Joe
{
	"subscriberId" : "Joe",
	"trafficIds" : [ "778373000", "joe@operator1.com" ]
}
 

Example 6 shows how to provision "Joe" Subscriber profile as the administrative identifier for this subscriber (Joe has to be used to locate his corresponding policies), with two traffic identifiers: "778373000" MSISDN and " joe@operator1.com" NAI.

When the SAPC receives several subscriber identities (several instances of Subscription-Id AVP) in the incoming Gx request, use the configurable attribute enum subsIdType to decide which one to use as traffic identifier.

4.3   Handling of Multiple Service Offerings

A Subscriber can be associated with several subscriptions, having each subscription different set of applicable profile data. Each subscription can have data corresponding to different functions, or to the same function, in which case it is recommended to apply a precedence or priority to resolve conflicts.

The priority of a dataplan for a subscriber can be statically provisioned:

4.4   Configure Dynamic Group Selection

In addition to the static association of a Subscriber to a Group, it is possible to determine it dynamically, using Group Selection policies.

The SAPC evaluates these policies for the list of groups statically associated with the subscriber. General concepts about provisioning of policies are recommended in this point, see Section 5.

To use Group Selection policies, follow next steps:

  1. Provision at least one rule (condition) and policy associated with:
    1. global policy locator: use

      <base_URI>/locators/resources/<dataplanName>/contexts/subscription

    2. or to a subscriber locator: use

      <base_URI>/subscribers/<subscriberId>/locators/resources/<dataplanName>/contexts/subscription

    Note:  
    In Group Selection policies, it makes no sense to use the subscriber group locator.

Example 7 is an example of Dynamic Group Selection policy is the following:

Example 7   Configuration of Dynamic Group Selection

PUT /rules/rDynamicGroupSelection
{
	"condition" : "((now.time < \"18:00\") && (now.time > \"20:00\"))",
	"ruleName" : "rDynamicGroupSelection"
}

PUT /policies/pDynamicGroupSelection
{
	"policyName" : "pDynamicGroupSelection",
	"ruleCombiningAlgorithm" : "permit-overrides",
	"rules" : [ "rDynamicGroupSelection" ]
}

PUT /subscribers/Joe/locators/resources/Gold/contexts/subscription
{
	"policies" : [ "pDynamicGroupSelection" ]
}

PUT /subscribers/Joe
{
	"dataplans" : 
	[
		
		{
			"dataplanName" : "Basic"
		},
		
		{
			"dataplanName" : "Gold",
			"priority" : 1
		}
	],
	"subscriberId" : "Joe"
}

In Example 7, the subscriber "Joe" is statically associated with "Basic" and "Gold" groups. However, "Gold" group is only selected from 18:00 until 20:00.

Example 8 is an example of a Group Selection global policy, applicable to all Subscribers:

Example 8   Configuration of Dynamic Group Selection

PUT /rules/rCityCells
{
	"condition" : "not( inRange(AccessData.subscriber.locationInfo.cellIdentity, \"1000,2000\" ))",
	"ruleName" : "rCityCells"
}

PUT /policies/pCityCells
{
	"policyName" : "pCityCells",
	"ruleCombiningAlgorithm" : "permit-overrides",
	"rules" : [ "rCityCells" ]
}

PUT /locators/resources/CityGroup/contexts/subscription
{
	"policies" : [ "pCityCells" ]
}

PUT /subscribers/562500100200
{
	"dataplans" : 
	[
		
		{
			"dataplanName" : "RusticGroup"
		},
		
		{
			"dataplanName" : "CitiGroup"
		}
	],
	"subscriberId" : "562500100200"
}

In Example 8, the subscriber is statically associated with "RusticGroup" and "CityGroup". However, "CityGroup" is only selected for the subscriber in case their location does not belong to the cell identifiers (1000,2000) belonging to the rustic area.

4.5   Handling of Unknown Subscribers

The SAPC can process traffic request for subscribers that are not provisioned in internal database, in the following exclusive ways:

  1. Autoprovisioning: The SAPC automatically provisions the subscriber when it receives the first traffic request (IP Session establishment). Afterward, the automatically provisioned subscriber works as a normal subscriber.
    Note:  
    Using this autoprovisioning function, the subscribers are only automatically created in the SAPC.

    To activate autoprovisioning behavior, see Section 4.5.1.

  2. Or, use a shared profile, see Section 4.5.2

4.5.1   Autoprovisioning

To use autoprovisioning, do the following:

  1. If the SAPC receives several subscriber identities (several instances of Subscription-Id AVP) in the incoming Gx request, to decide which subscriber identity is used for the autoprovisioned subscriber use the attribute enum subsIdType.
  2.  
    1. If needed to select the subscriber group associated with the subscriber, depending on dynamic conditions, use autoprovisioning policies, see Section 4.5.1.1.
    2. Or, if not needed dynamic conditions (or for the cases when the condition evaluates to false), create "auto" subscriber group.
  3. If it is needed to differentiate (personalize) the subscriber data of the autoprovisioned subscriber once it is autoprovisioned, provision data in the corresponding subscriber (after the first CCR message for the subscriber automatically creates it).

4.5.1.1   Provision Autoprovisioning Policies

Some previous general concepts about provisioning of policies are recommended in this point, see Section 5.

To configure autoprovisioning scenario by policies, do the following:

  1. Add one or more groups to be used as groups for automatically created subscribers.
  2. Add Autoprovision policies at global policy locator.

Example 9 shows the configuration using an autoprovisioning policy.

Example 9   Autoprovisioning policies

PUT /rules/rAutoprovisioning
{
	"condition" : "(AccessData.bearer.accessType == 1004)",
	"outputAttributes" : 
	[
		
		{
			"attrName" : "dataplan",
			"attrValue" : "\"4g-group\"",
			"result" : "permit"
		}
	],
	"ruleName" : "rAutoprovisioning"
}

PUT /policies/pAutoprovisioning
{
	"policyName" : "pAutoprovisioning",
	"ruleCombiningAlgorithm" : "permit-overrides",
	"rules" : [ "rAutoprovisioning" ]
}

PUT /locators/resources/any/contexts/autoprovisioning
{
	"policies" : [ "pAutoprovisioning" ]
}

PUT /dataplans/4g-group
{
	"dataplanName" : "4g-group"
}

PUT /dataplans/AutoProvFixed
{
	"dataplanName" : "AutoProvFixed",
	"usageLimits" : 
	[
		
		{
			"absoluteLimits" : 
			{
				"dlVolume" : 1048576,
				"resetPeriod" : 
				{
					"volume" : "monthly"
				}
			},
			"description" : "Total traffic"
		}
	]
}

In Example 9, the SAPC associates the group "4g-group" to autoprovisioned subscribers when the access type is E-UTRAN (rule condition (AccessData.bearer.accessType == 1004) ). It also provisions usage limits for the "4g-group" dataplan.

4.5.1.2   Subscriber Group for Autoprovisioning

If there is no need of a dynamic condition to select the group for the autoprovisioned subscribers, it is possible to assign statically the special auto subscriber group.

To do so, create a dataplan called "auto".

Example 10 shows how for autoprovisioned subscribers following data apply: 1 GB data volume per month for total traffic.

Example 10   Autoprovisioning Configuration

PUT /dataplans/auto
{
	"dataplanName" : "auto",
	"usageLimits" : 
	[
		
		{
			"absoluteLimits" : 
			{
				"dlVolume" : 1048576,
				"resetPeriod" : 
				{
					"volume" : "monthly"
				}
			},
			"description" : "Total traffic"
		}
	]
}

4.5.1.3   Autoprovisioning and Dynamic Group Selection

The SAPC can assign, statically or dynamically, autoprovisioned subscribers to a group. In both cases, the subscriber only belongs to one group, and therefore, the dynamic Group Selection (Section 4.4) does not apply.

4.5.2   Unknown Subscriber

For scenarios where it is not needed subscriber differentiation, it is possible to share the same profile (called "unknown"): the SAPC can process requests for a subscriber identifier that it is not found.

If the "unknown" Subscriber is not provisioned, and the SAPC receives a request containing a subscriber identifier not found, the SAPC rejects the request specifying that the subscriber identity is unknown.

To share the common profile for unknown subscribers, do the following:

  1. Provision a subscriber called "unknown" (administrative identifier), and the desired services and data to apply for all the unknown subscribers.
  2. Configure the subscriber unknown related Entity Data Sources: create in COM an instance of the following EDSources:
    • eDSourceId = SubscriberUnknown
    • eDSourceId = GroupsToSubscriberUnknown
    Note:  
    If some data are not needed for the "unknown" subscriber, it is possible to simplify previous EDSources, see Not Needed Data in Database Access.

    Example:

    def SubscriberUnknown ( argId )
      {
        dataSource =
        {
          url = "internaldb:";
          query = ...;
        }
        fieldDef =
        {
          ...
          usageLimits = "";
          sms = "";
          sharedDataplan = dataSourceField("sharedDataplanId");
        }
      }

    The example above shows the configuration for SubscriberUnknown EDSource, where it does not use Fair Usage, neither end-user notifications.


4.5.3   Unknown Subscriber EDSources pointing to the SAPC internal database

And next, the exact configuration for SubscriberUnknown EDSources pointing to the SAPC internal database:

Example 11   Subscriber Unknown EDSources

<edit-config>
 <target>
  <running/>
 </target>
 <config>
  <ManagedElement xmlns="urn:com:ericsson:ecim:ComTop">
  <managedElementId>1</managedElementId>
  <dnPrefix>dc=ManagedElement</dnPrefix>
  <networkManagedElementId>1</networkManagedElementId>
  <userLabel>Managed Element</userLabel>
  <PolicyControlFunction xmlns="urn:com:ericsson:ecim:sapcmom">
   <policyControlFunctionId>1</policyControlFunctionId>
   <EntityData xmlns="urn:com:ericsson:ecim:entitydatamom">
   <entityDataId>1</entityDataId>
   <EDSources xmlns="urn:com:ericsson:ecim:edsourcesmom">
    <eDSourcesId>1</eDSourcesId>
    <EDSource xmlns="urn:com:ericsson:ecim:edsourcemom" xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" nc:operation="merge">
    <eDSourceId>SubscriberUnknown</eDSourceId>
      <definition>
def SubscriberUnknown ( argId )
{
 dataSource =
 {
   url = "internaldb:";
   query = "SubscriberPot:{argId}";
 }
 fieldDef =
 {
   id = dataSourceField("id");
   groups = dataSourceField("dataplans");
   trafficIds = dataSourceField("trafficIds");
   sharedDataplan = dataSourceField("sharedDataplanId");
   subscribedServices = dataSourceField("subscribedContents");
   blacklistServices = dataSourceField("deniedContents");
   contentFilteringProfileId = dataSourceField("contentFiltering");
   chargingProfile = SubsChargingProfile(dataSourceField("subscriberChargingProfile"));
   chargingSystem = OnlineChargingSystemProfile(dataSourceField("onlineChargingSystemProfile"));
   customerId = dataSourceField("customerId");
   maxBearerQosProfile = BearerQosProfile(dataSourceField("maxBearerQosProfile"));
   minBearerQosProfile = BearerQosProfile(dataSourceField("minBearerQosProfile"));
   servicesToRedirect =  dataSourceField("redirectContents");
   presenceReportingAreaNames = dataSourceField("presenceReportingAreaNames");
   usageLimits = dataSourceField("usageLimits");
   sms = dataSourceField("smsDestinations");
   eventTriggers = dataSourceField("eventTriggers");
   pdnGwListName = PdnGwListProfile(dataSourceField("pdnGwListName"));
   spid = dataSourceField("spid");
 }
}
      </definition>
     </EDSource>
     <EDSource xmlns="urn:com:ericsson:ecim:edsourcemom" xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" nc:operation="merge">
     <eDSourceId>GroupsToSubscriberUnknown</eDSourceId>
      <definition>
def GroupsToSubscriberUnknown( subsId, groupId )
{
  dataSource =
  {
    url = "internaldb:";
    query = "SubscriberPot:{subsId}";
  }
  fieldDef =
  {
    priority = dataSourceField("dataplans:{groupId}:prio");
    startDate = dataSourceField("dataplans:{groupId}:start_date");
    endDate = dataSourceField("dataplans:{groupId}:end_date");
  }
}
      </definition>
     </EDSource>
    </EDSources>
  </EntityData>
</PolicyControlFunction>
</ManagedElement>
</config>
</edit-config>

4.5.4   Unknown and Autoprovisioning Precedence

The use of "unknown" subscriber and autoprovisioned subscribers (static assignation of autoprovisioned subscriber group) are mutually exclusive. If the provisioning includes "auto" subscriber group, unknown subscriber does not apply.

To autoprovision some subscribers but apply the unknown for some others, use autoprovisioning policies: when the condition of such autoprovisioning policies is not fulfilled, but the subscriber with identifier "unknown" is provisioned, the SAPC uses this default profile for not provisioned subscribers.

5   Provision Policies

5.1   Policies Basic Concepts

The following video shows the basic concepts of policies.

Figure 2   Policies Basic Concepts Video

The main policies data are:

Next video shows how the SAPC evaluates rules and policies.

Figure 3   Policies Evaluation

5.1.1   Rule Combining Algorithm in a Policy

Indicates how to select the result of the rules associated to one policy.

The output attributes returned are the ones associated to the rule that determined the result.

Algorithms for decision:

Algorithms for classification: a policy is considered fulfilled:

And the SAPC provides the following options:

5.1.2   Combining Algorithm in a Policy Locator

The algorithm to solve conflicts among the list of policies inside a policy locator is fixed (not configured):

The next video shows how the SAPC selects the policies applicable to a subscriber.

Figure 4   Selection of Data for a Subscriber

5.1.3   Combining Algorithm for the Subscriber Policies

For a Subscriber the SAPC evaluates in order the set of policies belonging to several Policy Locators (different subjects).

The algorithm to solve conflicts among the different locator policies is fixed (not configured):

The next video explains how policies and time of day conditions work.

Figure 5   Policies and Time of Day

5.2   Provisioning Policies

To provision a policy, create at least:

Caution!

The SAPC does not consider immediately changes done in these parameters, but refreshes their values every 5 minutes.

5.2.1   Subscriber Extension Data to Be Used in Policies

Operators can want to use their own extra data (not known in advance by the SAPC) to be evaluated in the SAPC policy conditions. So, from the SAPC point of view, it is possible to extend Subscriber entry with extra attributes to the ones considered in Table 13.

Follow next steps for each additional attribute in the subscriber profile (example attribute: "age"):

  1. Reconfigure Subscriber EDSource to add as a new fieldDef the new attribute.
    Note:  
    Do not remove any of the rest of fieldDefs set at installation time.

  2. Provision the name and value for the new attribute in operatorSpecificInfos of the subscriber REST URI.

Example 12 is an example to reconfigure Subscriber EDSource:

Example 12   Subscriber Entity Data Source

<edit-config>
  <target>
  <running />
  </target>
  <config>
  <ManagedElement xmlns="urn:com:ericsson:ecim:ComTop">
  <managedElementId>1</managedElementId>
  <dnPrefix>dc=ManagedElement</dnPrefix>
  <networkManagedElementId>1</networkManagedElementId>
  <userLabel>Managed Element</userLabel>
    <PolicyControlFunction xmlns="urn:com:ericsson:ecim:sapcmom">
        <policyControlFunctionId>1</policyControlFunctionId>
            <EntityData xmlns="urn:com:ericsson:ecim:entitydatamom">
                <entityDataId>1</entityDataId>
                <EDSources xmlns="urn:com:ericsson:ecim:edsourcesmom">
                    <eDSourcesId>1</eDSourcesId>
                    <EDSource xmlns="urn:com:ericsson:ecim:edsourcemom" 
			xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" nc:operation="merge">
                        <eDSourceId>Subscriber</eDSourceId>
                        <definition>
def Subscriber( argId ) {
   dataSource = { 
      url = "internaldb:"; 
      query = "SubscriberPot:{argId}"; 
   } 
   fieldDef = { 
      ...
      age = dataSourceField("name:age");
   } 
}
                        </definition>
                    </EDSource>
                </EDSources>
            </EntityData>
    </PolicyControlFunction>
    </ManagedElement>
    </config>
</edit-config>

Example 13 shows the provision of the attribute age for the subscriber 34600000011 with the value 20.

Example 13   Operator Specific Info Provisioning

PUT /subscribers/34600000011
{
	"operatorSpecificInfos" : 
	[
		
		{
			"attributeName" : "age",
			"attributeValue" : "20"
		}
	],
	"subscriberId" : "34600000011"
}

Subscriber.age is ready to be used within policy conditions.

5.3   Policy Types

This section includes as summary, the complete list of the SAPC policy types that can be used for the various functions that the SAPC provides.

The particular use and details of each policy type is covered in the corresponding SAPC Configuration Guides document.

Table 1    Subscription Related Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Autoprovisioning

autoprovisioning

any

-

permit


dataplan


"<dataplanId>"

Only has sense to use Global Policy Locator

Dynamic Group Selection

subscription

<dataplanId>

<subscriberId>

-

No sense to use Policy Locator using as Subject = the Dataplan

Charging System

charging-system

any

-

permit


charging-system


"<chargingSystemName>"

Only has sense to use Global Policy Locator

Table 2    Accumulation Related Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Conditional Accumulation

accumulation

reporting-group


<reporting-group-id>

<subscriberId>


<dataplanId>

-

Type I = Only policies, no qualification


Used to accumulate or not depending on flexible policy conditions

Dynamic Group Selection

subscription

reporting-group.<counterId>


<reporting-group-id>.<counter-Id>

<subscriberId>


<dataplanId>

-

Type I = Only policies, no qualification


Used to accumulate on different counters.

Table 3    Access Related Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Access Control (Service Authorization)


Autoprovisioning

autoprovisioning

any

-

permit


dataplan


"<dataplanId>"

Only has sense to use Global Policy Locator

Dynamic Group Selection

subscription

<dataplanId>

<subscriberId>

-

No sense to use Policy Locator using as Subject = the Dataplan

Charging System

charging-system

any

-

permit


charging-system


"<chargingSystemName>"

Only has sense to use Global Policy Locator

Table 4    Access Related Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Access Control (Service Authorization)


Access

access

<contentId>

<subscriberId>


<dataplanId>

 

Type I = Only policies, qualification


Gx


Conditions:


Subscriber Data


Access Data


ToD

Access Control (Static service qualification)


Static Access

static-access

<contentId>

<subscriberId>


<dataplanId>

permit


pcc-rule-id


" <pccRuleName>"

Type I = Only policies, qualification


Gx


Conditions:


Subscriber Data


Access Data


ToD

Rule Space selection


Service Domain

access

sevice-domain

<subscriberId>


<dataplanId>

permit


rule-space


" <ruleSpaceName>"

Ericsson Gx+

IP-CAN Session


Access

access

ip-can-session

<subscriberId>


<dataplanId>

-

Type I = Only policies, qualification


Gx


Conditions:


Subscriber Data


Access Data


ToD

Table 5    Charging and Content Filtering Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Service Charging

charging

<contentId>

<subscriberId>


<dataplanId>

permit


charging


ServiceChargingProfile


[" <chargingProfileName>"]

Type II = Mixing policies and qualification


Gx


Conditions:


Access Data


Subscriber


ToD

Subscriber Charging

charging

any

<subscriber-id>


<dataplan-id>

permit


subs-charging


ServiceChargingProfile


[" <chargingProfileName>"]

Type II = Mixing policies and qualification


Gx


Conditions:


Access Data


Subscriber


Time conditions (but no ToD reauthorization

Content Filtering

content-filtering

sevice-domain

<subscriberId>


<dataplanId>

permit


content-filtering-id


" <contentFilteringValues>"

Type II = Mixing policies and qualification


Used to return Content-Filtering in Ericsson Gx+

Table 6    QoS Related Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Bearer QoS Control


QoS for Service

qos

<contentId>

<subscriberId>


<dataplanId>

permit


qos


ServiceQosProfile


["<qosProfileName>"]

Type II = Mixing policies and qualification


Gx


Conditions:


Subscriber Data


Access Data


ToD

Bearer QoS Control


QoS for Service

qos

ip-can-session

<subscriberId>


<dataplanId>

permit


max-qos


BearerQosProfile


["<qosProfileName>"] or qos_prof_expression


permit


min-qos


BearerQosProfile


["<qosProfileName>"] or qos_prof_expression

Type II = Mixing policies and qualification


Gx


Conditions:


Subscriber Data


Access Data


ToD

Table 7    Dynamic Policy Control (Rx) Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Dynamic Service Classification

service-classification

application

-

service


<contentId>

Only policies, no qualification


Gx - Rx binding


Algorithms: single match, multiple match


Conditions:


- AfData

Access Control (Dynamic Service Authorization)


Access

access

<contentId>

<subscriberId>


<dataplanId>

-

Mixing policies and qualification


Conditions:


Access Data


Subscriber


ToD

Bearer QoS Control (Dynamic Service Qualification


QoS for Service

qos

<contentId>

<subscriberId>


<dataplanId>

permit


qos


ServiceQosProfile


["<qosProfileName>"]

Mixing policies and qualification


Conditions:


media components (AfData)


Access Data


Subscriber


ToD

(Dynamic Service Qalification)


Service Charging

charging

<contentId>

<subscriberId>


<dataplanId>

permit


charging


ServiceChargingProfile


["<chargingProfileName>"]

Mixing policies and qualification


Conditions:


media components (AfData)


Access Data


Subscriber


ToD

Bearer QoS Control


QoS for Service

qos

ip-can-session

<subscriberId>


<dataplanId>

permit


max-qos


BearerQosProfile


["<qosProfileName>"] or qos_prof_expression


permit


min-qos


BearerQosProfile


["<qosProfileName>"] or qos_prof_expression

Mixing policies and qualification


Conditions:


media components (AfData)


Access Data


Subscriber


ToD

Table 8    Mobility Based Policy Control (Smp) Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Smp Session control

access

sx-session

<subscriberId>


<dataplanId>

-

Type I = Only policies, no qualification


Smp


Conditions:


Access Data


Subscriber

PDN GW Selection

pdn-gw

any

<subscriberId>


<dataplanId>

permit


pdn-gw-list


"<pdnGwList name value>"

Type II = Mixing policies and qualification


Smp


Conditions:


Access Data


Subscriber

SPID Selection

spid

any

<subscriberId>


<dataplanId>

permit


spid


value

Type II = Mixing policies and qualification


Smp


Conditions:


Access Data


Subscriber

Table 9    Notification Related Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Notifications

notification

any

<subscriberId>


<dataplanId>

permit


notification


"<Notification message>"


permit


notification


NotifReceiver"<Notification message>"

Type III = All Permit


_Used to send Subscriber notifications


Algorithms: all permit

Table 10    Presence Reporting Area in Gx Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Notifications

notification

any

<subscriberId>


<dataplanId>

permit


notification


"<Notification message>"


permit


notification


NotifReceiver"<Notification message>"

Type III = All Permit


_Used to send Subscriber notifications


Algorithms: all permit

Table 11    Presence Reporting Area in Gx Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Presence Reporting Area Selection

location

any

<subscriberId>


<dataplanId>

permit


presence-area


PraProfile


[" <presenceAreaName>"]

Type II = Mixing policies and qualification


Gx


Conditions:


Access Data


Subscriber


Time conditions (but no ToD reauthorization

Table 12    Event Triggers Selection Policies

Policy Type

Policy Locator

Output Attributes

Comments

Context

Resource

Subject

Event Triggers Selection

event-triggers

any

<subscriberId>


<dataplanId>

permit


event-triggers


" <list of event trigger values>"

Type IV= Mixing AllPermit policies and qualification


Gx


Conditions:


Access Data


Subscriber


Media component (AfData)


ToD


Algorithms:all permit


List of event triggers in CSV format

5.4   Policy Tags

The conditions that the SAPC evaluates in policies are set in condition attribute of a rule. It is possible to use the following data (policy tags):

Subscription Related Policy Tags

Tags related to the subscriber profile can be used in the condition formula of rules. The data makes reference to data provisioned for the subscriber to which the rule to be evaluated applies.

Table 13    Subscription Related Tags

Tag

Return Type

Possible Values

Comments

Subscriber.x

Any

Any

x is any of the fieldDefs defined in Subscriber EDSource (see Section 5.2.1)

Subscriber.groups

String

 

List of group identifiers (dataplans) statically provisioned in the Subscriber profile.

Subscription.group["groupName"].isActive


(1)

Boolean

true


false

Indicates if the group (dataplan) is active for the subscriber, as result of subscription information (Subscription.group["groupName"].isSubscribed equal to true) and Dynamic Group Selection policies (see Section 4.4.

Subscription.group["groupName"].isSubscribed

Boolean

true


false

Indicates if the group (dataplan) is statically associated with the subscriber and current date is between start and end subscription date.

(1)  Because Subscription.group["groupName"].isActive itself depends on the result of Dynamic Group Selection, avoid using it as a condition of Dynamic Group Selection policies. That could cause uncertain results.


6   Appendix A. Condition Policy Language

6.1   Condition Formula Examples

This chapter contains examples of possible expressions that can be used within a condition formula. They are just examples, and their correctness (syntactically and semantically) depends on for which functionality is used the condition.

6.1.1   Reuse of Complex Expressions

A condition formula can be composed of several logical expressions. If needed to reuse the same complex expression in different condition formulas, it is possible to use Entity Data Source mechanism. This makes easier to read and maintain future changes in the complex expression. For details, refer to Database Access.

To do so, perform the following configuration steps:

  1. Create an auxiliary Entity Data Source (whose dataSource points to internal database).
  2. Include the logical expression to be reused as default argument of the Entity Data Source.
  3. Assign the argument to a fieldDef of the Entity Data Source.
  4. Include the fieldDef in the condition formulas that want to reuse the logical expression.
Note:  
Ericsson discourages the reuse of expressions containing boolean time conditions.

For example, an operator wants to define different operation modes called Full, Restricted and Default and that only one of them is applied (for example to authorize a service, or any other policy control managed by the SAPC).

Example 14 is an example to reuse of the Restricted mode expression:

Example 14   Definition of an Entity Data Source for reusable expression.

<edit-config>
    <target>
    <running />
    </target>
    <config>
   <ManagedElement xmlns="urn:com:ericsson:ecim:ComTop">
    <managedElementId>1</managedElementId>
    <dnPrefix>dc=ManagedElement</dnPrefix>
    <networkManagedElementId>1</networkManagedElementId>
    <userLabel>Managed Element</userLabel>
    <PolicyControlFunction xmlns="urn:com:ericsson:ecim:sapcmom">
      <policyControlFunctionId>1</policyControlFunctionId>
         <EntityData xmlns="urn:com:ericsson:ecim:entitydatamom">
            <entityDataId>1</entityDataId>
            <EDSources xmlns="urn:com:ericsson:ecim:edsourcesmom">
               <eDSourcesId>1</eDSourcesId>
                  <EDSource xmlns="urn:com:ericsson:ecim:edsourcemom" xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" nc:operation="merge">
                     <eDSourceId>RestrictedMode</eDSourceId>
                     <definition>
 def RestrictedMode
( 
 expression = '( 
 inRange(AccessData.subscriber.locationInfo.sgsnAddress,
        "10.16.120.0/32,10.16.130.0/32")
 )'
)
{
  dataSource = 
  { 
   url = "internaldb;"; 
   query = ""; 
  }
  fieldDef = 
  {
   isActive = dataSourceField("expression");
  }
 }
                     </definition>
                 </EDSource>
           </EDSources>
         </EntityData>
   </PolicyControlFunction>
   </ManagedElement>
   </config>
</edit-config>

Example 15 shows how to define the reuse of Full:

Example 15   Definition of an Entity Data Source for reusable expression.

<edit-config>
    <target>
    <running />
    </target>
    <config>
   <ManagedElement xmlns="urn:com:ericsson:ecim:ComTop">
    <managedElementId>1</managedElementId>
    <dnPrefix>dc=ManagedElement</dnPrefix>
    <networkManagedElementId>1</networkManagedElementId>
    <userLabel>Managed Element</userLabel>
    <PolicyControlFunction xmlns="urn:com:ericsson:ecim:sapcmom">
      <policyControlFunctionId>1</policyControlFunctionId>
         <EntityData xmlns="urn:com:ericsson:ecim:entitydatamom">
            <entityDataId>1</entityDataId>
            <EDSources xmlns="urn:com:ericsson:ecim:edsourcesmom">
               <eDSourcesId>1</eDSourcesId>
                  <EDSource xmlns="urn:com:ericsson:ecim:edsourcemom" xmlns:nc="urn:ietf:params:xml:ns:netconf:base:1.0" nc:operation="merge">
                     <eDSourceId>FullMode</eDSourceId>
                     <definition>
 def FullMode
 ( complexExpression = '
     ( inRange(AccessData.subscriber.locationInfo.networkCode, "12-14, 16-25")
      || ( (AccessData.subscriber.locationInfo.networkCode == 15)
          && inRange(AccessData.subscriber.locationInfo.sgsnAddress, "10.16.120.0/24,10.16.130.0/24")
         )
     )&&((inRange( AccessData.userEquipmentInfo.model, "10-11") && AccessData.userEquipmentInfo.version > 5)
          || (( AccessData.userEquipmentInfo.model == 12 ) && AccessData.userEquipmentInfo.version > 7)
          || (( AccessData.userEquipmentInfo.model == 14 ) && AccessData.userEquipmentInfo.version > 4)
     )'
 )
 {
  dataSource = 
  { 
    url = "internaldb;"; 
    query = ""; 
  }
  fieldDef = 
  {
      isActive = arg( "complexExpression");
  }
 }
                     </definition>
                 </EDSource>
           </EDSources>
         </EntityData>
   </PolicyControlFunction>
   </ManagedElement>
   </config>
</edit-config>

Example 16 is the example of different condition formulas for full, restricted and default modes, showing the reuse:

Example 16   Condition formulas reusing expressions defined in Entity Data Source.

PUT /rules/defaultMode
{
	"condition" : "not(FullMode.isActive)&& not(RestrictedMode.isActive)",
	"ruleName" : "defaultMode"
}

PUT /rules/fullMode
{
	"condition" : "FullMode.isActive",
	"ruleName" : "fullMode"
}

PUT /rules/restrictedMode
{
	"condition" : "not(FullMode.isActive)&& RestrictedMode.isActive",
	"ruleName" : "restrictedMode"
}

6.2   Condition Formula Language

A condition formula is composed of expressions related to operators whose evaluation result is a boolean value.

The language of the condition formula according to Backus-Naur Form (BNF) specification (refer to Backus Naur Form - RFC 2234) has the following format:

<ConditionFormulaExpression> ::=
     <Expression> binOp <Expression> |
     <Expression>

<Expression> ::=
     keyword <AccessToStructure> |
     keyword "(" <FunctionParams> ")" |
     "(" <Expression> ")" |
     resource-id

<AccessToStructure> ::=
     "." keyword <AccessToStructure> |
     "[" <Expression> "]" <AccessToStructure>
     
<FunctionParams> ::=
     <Expression> |
     <Expression> "," <FunctionParams>

binOp: "+" | "-"  | "*" | "==" | "!=" | "&" | "|" | "&&" | 
       "||" | "<" | ">"
resource-id: double quoted string | positive integer
keyword: string

The meaning of the condition formula language elements is the following:

The parenthesis are used to perform the nesting between different expressions and to control the precedence between these expressions. The precedence in the evaluation is from left to right.

6.2.1   Condition Formula Operators

The formula operators are used to combine different expressions within the condition that the SAPC evaluates.

Warning!

To avoid unexpected evaluation results, Ericsson recommends to explicitly use parenthesis.

If parenthesis are not explicitly used, there is no precedence in the operators, and the SAPC evaluates the condition from left to right.

The following example shows how the SAPC evaluates operators if no parenthesis are used:

Subscriber.id == "12345678" && AccessData.bearer.accessType == 1001

The previous condition formula is evaluated as:

Subscriber.id == ("12345678" && (AccessData.bearer.accessType == 1001))

Table 14 shows the operators for the condition formula :

Table 14    Condition Formula Operators

Operators

Operation Meaning

+

Adds the integer values of 2 expressions. (1)

-

Subtracts the integer values of 2 expressions.

*

Multiplies the integer values of 2 expressions. (2)

==

Checks the equality of its operands.

!=

Checks the inequality of its operands.

&&

Logical AND operation between 2 expressions.

||

Logical OR operation between 2 expressions.

&

Bitwise AND operation between 2 expressions.

|

Bitwise OR operation between 2 expressions.

<

Expression lower than other expression.

>

Expression higher than other expression.

(1)  Logical addition of 2 logical expressions is also supported: op1 + op2 returns op1 when op2 is false.

(2)  Logical multiplication of 2 logical expressions is also supported: op1*op2 returns op1 when op2 is true.


6.2.2   Condition Formula Expressions

According to the condition formula language specification, an Expression can be composed of a set of tags, functions, and fixed values.

6.2.2.1   Tags

A tag is a name representing a concept and is used to construct an expression of the condition formula.

There are tags that can be used for taking decisions related to any the SAPC function (for example time and date). Other tags are only allowed depending on the SAPC node functionality (for such cases, refer to the appropriate Configuration Guide document).

6.2.2.2   ToD Tags

Time and date tags can be used in the SAPC to take decisions based on flexible time of date conditions.

Table 15    Time and Date Tags

Tag

Return Type


Possible Return Values

Comments

now.offset

Integer

any

Number of seconds elapsed since 00:00:00 January 1, 1970.

now.time

String

any

Time of the day, expressed in following way:


“hh:mm[:ss]”


Where


hh = 2 digits for hour, 00 - 23 (am/pm NOT allowed)


mm = 2 digits for minutes, 00-59


ss = 2 digits for seconds, 00-59. Optional, when not included, default seconds are 00.

now.day

Integer

1–31

Day of month

now.dayOfWeek

Integer

1–7

Day of week:


1: Monday


2: Tuesday


3: Wednesday


4: Thursday


5: Friday


6: Saturday


7: Sunday

now.month

Integer

1–12

Month

now.year

Integer

any (all digits of the year must be specified)

Year

These tags refer to the SAPC local date and time. In mobile scenarios, if the SAPC receives the 3GPP-MS-TimeZone AVP and the SAPC is configured to consider it (enableMsTimeZone = true), its value is applied to the tags.

When the SAPC evaluates conditions including these tags, it also calculates an internal validity (number of seconds) for which the boolean result condition keeps its boolean result (considering the applied combining algorithm, see Section 5.1.1).

Warning!

"00:00:00" is the first second of a day, so, now.time < "00:00" results always in false. To refer to midnight (that is, last instant of a day), use "23:59:59".

Some examples for using time and date tags in the condition formula are provided next:

6.2.2.3   Functions

The arguments of the functions can be an allowed combination of tags, a fixed value or an invocation to other function, considering that the type of these data is equal to the argument type defined for the function.

Warning!

When using a list of elements, do not use "," within any element of the list because the elements are separated by ",". Otherwise, the policy evaluation leads to an unexpected result.

Table 16 shows the supported functions:

Table 16    Condition Functions

Function

Return Type

Arguments

Comments

contains(array list, string elem)

Boolean

list: a list of elements (elements are separated by ",").


elem: the element to find inside the list.

Returns true if the passed element is included in the past list. False otherwise.

firstCharsOf( string st, integer n)

String

st: the input string.


n: the number of characters to be selected from the input string.

Returns the first n characters starting to count from the left of the string passed as the first argument.

inPeriod( integer time, string periods)

Boolean

time:
now.offset
See Table 15


periods: list of date and time periods.

Returns true if at least one period contains the passed time. False otherwise. This
function also returns a validity (Section 6.2.2.2) with the number of seconds for the next change.


For the format of the periods definition, see Section 6.2.2.3.1.

inRange(string elem, array ranges)

Boolean

elem: the input element.(1)


ranges: a list of ranges.

Returns true if the passed "elem" is included in any of the specified "range"s. In case the "elem" is a range, it returns true if the range is included in any of the specified "range"s. In case the "elem" is a list or a list of ranges, the function returns true if all the list elements are included in any of the specified "range"s.


False otherwise.


To specify ranges use "-" separator, for example: 1-5. To specify lists use "," separator, for example: 1,5 or 1-5, 7-10.


IPv4 addresses in dot format (either using mask or range notation) and IPv6 prefixes in colon notation (preferred format) are also accepted. For example:
192.168.0.0/24
192.168.0.1-192.168.0.254

lastCharsOf( string st, integer n)

String

st: the input string.


n: the number of characters to be selected from the input string.

Returns the last n characters starting to count from the right of the string passed as the first argument.

not(boolean bool)

Boolean

bool: the condition to negate.

Applies the not boolean operation on the boolean condition passed.

strcat(string str1, string str2)

String

str1, str2 input strings

Returns the string resulting of joining the strings passed as input.

substr(string str, int index, int length)

String

str: input string


index: index position, starting from zero


length: number of characters to be selected from the input string

Returns the substring extracted from the input string, from the specified index position (included) until the number of characters indicated by length, or until the end of the input string if length <=0.

StrDLeft(string st, string delimiter)

String

st: the input string.


delimiter: the delimiter to find inside the input string.

Tries to find the delimiter passed in the second argument inside the string in the first argument. If found, it returns the string composed of the characters to the left of the delimiter in the input string.

StrDRight(string st, string delimiter)

String

st: the input string.


delimiter: the delimiter to find inside the input string.

Tries to find the delimiter passed in the second argument inside the string in the first argument. If found, it returns the string composed of the characters to the right of the delimiter in the input string.

toString(integer int, string format)

String

int: the input integer.


format: indicates the type of format for the resulting string.

Returns a string formatted according to format argument.


format possible values:


  • "MB": Mbytes, using 2 decimals digits precision. Indicate int argument in kilobytes.

  • "GB": Gbytes, using 2 decimals digits precision. Indicate int argument in kilobytes.

(1)  elem can be a numeric value, an IPv4 or IPv6 address or prefix, or a list or a range of integers or IP addresses values.


6.2.2.3.1   Format for Periods in Function inPeriod

The second parameter of the inPeriod function is composed of expressions referring to date and time periods.

Examples:

The language of the periods according to Backus-Naur Form (BNF) specification (refer to Backus Naur Form - RFC 2234) has the following format:

<periods> ::= <period> [";"<periods>]

<period> ::= 
     <subperiodDate>["/"<subperiodWeek>]["/"<subperiodTime>] | 
     <subperiodWeek>["/"<subperiodTime>] |
     <subperiodTime>
 
<subperiodDate> ::= <subperiodDateItem>["|"<subperiodDate>] 
<subperiodWeek> ::= <subperiodWeekItem>["|"<subperiodWeek>] 
<subperiodTime> ::= <subperiodTimeItem>["|"<subperiodTime>]

<subperiodDateItem> ::= <startInDate> ["," <endInDate>]
<subperiodWeekItem> ::= <startInWeek> ["," <endInWeek>]
<subperiodTimeItem> ::= <startInTime> ["," <endInTime>]

<startInDate> ::= <dd>"-"<mm>"-"<yyyy>["T"<hh>[":"<mm>[":"<ss>]]]
<endInDate> ::= <dd>"-"<mm>"-"<yyyy>["T"<hh>[":"<mm>[":"<ss>]]]

<startInWeek> ::= "MO" | "TU" | "WE" | "TH" | "FR" | "SA" | "SU"
<endInWeek> ::= "MO" | "TU" | "WE" | "TH" | "FR" | "SA" | "SU"

<startInTime> ::= <hh>[":"<mm>[":"<ss>]]
<endInTime> ::= <hh>[":"<mm>[":"<ss>]]

The meaning of the period elements is the following:

6.2.2.3.2   Examples of Function in Range
inRange(AccessData.host.version, "4000-6000, 8000-9000")
inRange(AccessData.subscriber.locationInfo.sgsnAddress,"160.50.40.0/24,160.50.40.50-160.50.40.60")
inRange(AccessData.subscriber.locationInfo.sgsnAddress,"2001:0DB8:0::1428:57AB/32")
inRange(AccessData.subscriber.locationInfo.sgsnAddress,"2001:0DB8:0000:0000:0000:0000:1428:57AB-2001:0DB8::FFFF:FFFF")
inRange(TdfData.serverIp,"160.50.1.1-160.50.255.255")
inRange(TdfData.serverPort,"5000-5100,9500-9999")

Reference List

Standards
[1] Backus Naur Form - RFC 2234.