vendor-id Manipulation

You can manipulate the Vendor ID value in the AVP header by configuring the header-type parameter to avp-vendor-id. This performs the DMR manipulation on the 4-byte vendor-id in the AVP header. AVP vendor id is present in the AVP header only when the ‘V’ bit is set in the flags. This is important because the DMR application relies upon the bit being set to determine where the data payload begins.

The avp-vendor-id search invokes an unsigned integer comparison between the received value and the match-value. If the match-value is empty, the configured action is performed without doing any match.

For the case where match-value is non-empty, as in the following example, the DMR engine checks whether the ‘V’ bit is set in the received header. If not, then the vendor id is not present either and the comparison is unsuccessful. If the ‘V’ bit is set, and the match succeeds, the match is successful. (An unsuccessful match has the DMR proceed to the next header-rule.)

avp-header-rules
   name         replaceAvpFlags
   header-type  avp-vendor-id
   action       add
   match-value  9148
   new-value    10415

When the match is successful (or if the match value is left empty), the configured action is performed. Consider all following actions:

  • none—no action will be performed
  • add—a configured vendor-id value in the new-value parameter is added to the AVP header and the ‘V’ bit set to indicate it’s presence. If you prefer to set the ‘V’ bit in an AVP, it is better to do an avp-vendor-id action first and then manipulate the rest of the flags.

    If the new-value is empty, the add operation is not performed.

    If a vendor-id already exists in the AVP header, then it is replaced by new-value.

  • replace—the existing vendor-id value is replaced with the new-value.

    If the new-value is empty, the replace operation is not performed.

    If the vendor-id does not exist in the header, then one will be added with the new-value and the ‘V’ bit is set to indicate its presence.

  • delete—the vendor-id will be removed from the AVP header and ‘V’ bit will be reset to indicate its absence.

    If the new-value is empty, then the delete operation will not be performed.

    If the vendor-id does not exist, then the delete operation is not performed.