RFC 2924

Accounting Attributes and Record Formats

πŸ“… published September 2000, from ietf

1. Introduction ✨

Okay bestie, this is RFC 2924 πŸ¦‹, titled Accounting Attributes and Record Formats. It came out in September 2000 from the Network Working Group, written by N. Brownlee from The University of Auckland and A. Blount from MetraTech Corp. πŸŽ€ It's Informational, which means it shares info with the Internet community and doesn't specify an Internet standard. The title block doesn't list anything it obsoletes or updates, so there's no drama there πŸ’…

The Status of this Memo says the same thing: it's just info, not a standard, and it can be shared freely 🌸

The Copyright Notice is from The Internet Society (2000), all rights reserved πŸ’œ


Abstract

This document basically rounds up the accounting stuff from both the IETF and the ITU-T 🧚 It explains a way to classify the Accounting Attributes in those documents ✨ It also talks about how accounting data records get exchanged, and the pros and cons of putting everything in one record format and transport protocol versus keeping them separate πŸ‘‘ On top of that, it covers service definition independence, extensibility, and versioning, plus the compound service definition stuff 🫢


Table of Contents

Here's the whole table of contents, copied exactly so you can see the full layout πŸ“

1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . .   2
2. Terminology and Notation . . . . . . . . . . . . . . . . . . .   3
3. Architecture Model . . . . . . . . . . . . . . . . . . . . . .   4
4. IETF Documents . . . . . . . . . . . . . . . . . . . . . . . .   4
4.1. RADIUS . . . . . . . . . . . . . . . . . . . . . . . . . . .   4
4.1.1. RADIUS Attributes  . . . . . . . . . . . . . . . . . . . .   5
4.2. DIAMETER . . . . . . . . . . . . . . . . . . . . . . . . . .   6
4.2.1. DIAMETER Attributes  . . . . . . . . . . . . . . . . . . .   7
4.3. ROAMOPS  . . . . . . . . . . . . . . . . . . . . . . . . . .   8
4.4. RTFM . . . . . . . . . . . . . . . . . . . . . . . . . . . .   8
4.4.1. RTFM Attributes  . . . . . . . . . . . . . . . . . . . . .   9
4.5. ISDN MIB . . . . . . . . . . . . . . . . . . . . . . . . . .  10
4.5.1. ISDN Attributes  . . . . . . . . . . . . . . . . . . . . .  10
4.6. AToMMIB  . . . . . . . . . . . . . . . . . . . . . . . . . .  11
4.6.1. AToMMIB Attributes . . . . . . . . . . . . . . . . . . . .  11
4.7. QoS: RSVP and DIFFSERV . . . . . . . . . . . . . . . . . . .  12
4.7.1. QoS: RSVP and DIFFSERV Attributes  . . . . . . . . . . . .  13
5. ITU-T Documents  . . . . . . . . . . . . . . . . . . . . . . .  13
5.1. Q.825: Call Detail Recording . . . . . . . . . . . . . . . .  13
5.2. Q.825 Attributes . . . . . . . . . . . . . . . . . . . . . .  14
6. Other Documents  . . . . . . . . . . . . . . . . . . . . . . .  18
6.1. TIPHON: ETSI TS 101 321  . . . . . . . . . . . . . . . . . .  18
6.2. MSIX . . . . . . . . . . . . . . . . . . . . . . . . . . . .  19
7. Accounting File and Record Formats . . . . . . . . . . . . . .  19
7.1. ASN.1 Records  . . . . . . . . . . . . . . . . . . . . . . .  19
7.1.1. RTFM and AToMMIB . . . . . . . . . . . . . . . . . . . . .  19
7.1.2. Q.825  . . . . . . . . . . . . . . . . . . . . . . . . . .  20
7.2. Binary Records . . . . . . . . . . . . . . . . . . . . . . .  20
7.2.1. RADIUS . . . . . . . . . . . . . . . . . . . . . . . . . .  20
7.2.2. DIAMETER . . . . . . . . . . . . . . . . . . . . . . . . .  20
7.3. Text Records . . . . . . . . . . . . . . . . . . . . . . . .  21
7.3.1. ROAMOPS  . . . . . . . . . . . . . . . . . . . . . . . . .  21
8. AAA Requirements . . . . . . . . . . . . . . . . . . . . . . .  22
8.1. A Well-defined Set of Attributes . . . . . . . . . . . . . .  22
8.2. A Simple Interchange Format  . . . . . . . . . . . . . . . .  23
9. Issues . . . . . . . . . . . . . . . . . . . . . . . . . . . .  23
9.1. Record Format vs. Protocol . . . . . . . . . . . . . . . . .  24
9.2. Tagged, Typed Data . . . . . . . . . . . . . . . . . . . . .  24
9.2.1. Standard Type Definitions  . . . . . . . . . . . . . . . .  25
9.3. Transaction Identifiers  . . . . . . . . . . . . . . . . . .  26
9.4. Service Definitions  . . . . . . . . . . . . . . . . . . . .  26
9.4.1. Service Independence . . . . . . . . . . . . . . . . . . .  27
9.4.2. Versioned Service Definitions  . . . . . . . . . . . . . .  29
9.4.3. Relationships Among Usage Events . . . . . . . . . . . . .  29
9.4.4. Service Namespace Management . . . . . . . . . . . . . . .  30
10. Encodings . . . . . . . . . . . . . . . . . . . . . . . . . .  30
11. Security Considerations . . . . . . . . . . . . . . . . . . .  31
12. References  . . . . . . . . . . . . . . . . . . . . . . . . .  31
13. Authors' Addresses  . . . . . . . . . . . . . . . . . . . . .  35
14. Full Copyright Statement  . . . . . . . . . . . . . . . . . .  36

1. Introduction 🌈

This document gives you the highlights of the IETF and ITU-T accounting docs πŸ“š For the ones that describe Accounting Attributes (basically, quantities you can measure and report) πŸ“Š there's an Attribute Summary. Lots of these docs describe attributes that look alike, but the document doesn't try to figure out which ones are actually the same across docs πŸ™ˆ The big move here is an extensible classification scheme for AAA Accounting Attributes, and it's a superset of every attribute in all the docs it summarises πŸ’–

Here's the tea: a lot of existing accounting record formats and protocols [RAD-ACT] [TIPHON] aren't super useful, because they only describe one service at a time and they can't really be extended 😭 Some of them do support extensible attributes [RAD-ACT], but none of them offer identification, type checking, or versioning for defined groupings of attributes (service definitions) πŸ’€ So this document makes the case for well-defined services ✨

It also talks about the advantages and disadvantages of integrated versus separate record formats and transport protocols πŸ”₯ Plus service definition independence, extensibility, and versioning, and compound service definition capabilities πŸŽ€


2. Terminology and Notation πŸ’…

These terms show up all over the document, so get comfy with them πŸ“

Accounting Server β€” A network element that accepts Usage Events from Service Elements. It's the interface to the back-end rating, billing, and operations support systems πŸ’Ό

Attribute-Value Pair (AVP) β€” A representation for a Usage Attribute, made of the name of the Attribute and a value 🧁

Property β€” A component of a Usage Event. For example, a Usage Event describing a phone call might have a "duration" Property ⏱️

Service β€” A type of task that a Service Element performs for a Service Consumer πŸ›ŽοΈ

Service Consumer β€” The client of a Service Element, aka the end-user of a network service πŸ™‹β€β™€οΈ

Service Definition β€” A specification for a particular service. It's made up of a name or other identifier, versioning information, and a collection of Properties πŸ“

Service Element β€” A network element that provides a service to Service Consumers. Examples are RAS devices, voice and fax gateways, and conference bridges πŸŒ‰

Usage Attribute β€” A component of a Usage Event that describes some metric of service usage πŸ“ˆ

Usage Event β€” The description of one instance of service usage πŸ¦‹


3. Architecture Model 🧚

Service Elements give Services to Service Consumers 🫢 Before, during, and/or after those services happen, the Service Element reports Usage Events to an Accounting Server πŸ“€ Or, the other way around: the Accounting Server can query the Service Element for Usage Events πŸ”„ Usage events get sent either one at a time or in bulk πŸ“¦

Here's the picture, exactly as drawn:

   +------------+       +-----------+              +------------+
   |  Service   |<----->|  Service  | Usage Events | Accounting |
   |  Consumer  |   +-->|  Element  |------------->|   Server   |
   +------------+   |   +-----------+              +------------+
                    |
   +------------+   |
   |  Service   |<--+
   |  Consumer  |
   +------------+

Accounting Servers can forward Usage Events to other systems, and those systems might live in other administrative domains 🌍 This document doesn't cover those transfers πŸ™…β€β™€οΈ


4. IETF Documents πŸŽ€

In March 1999 there were at least 19 Internet Drafts and 8 RFCs about Accounting πŸ“š The next sections sum them up, grouped by working group πŸ‘―β€β™€οΈ

4.1. RADIUS πŸ”

The RADIUS protocol [RAD-PROT] carries authentication, authorization, and configuration info between a Network Access Server (NAS) and an authentication server 🀝 The requests and responses in the protocol are written in terms of RADIUS attributes, like User-Name, Service-Type, and so on ✨ Those attributes give a RADIUS server what it needs to authenticate users and set up their authorized network service πŸ‘‘

The protocol was later extended to carry accounting info between a NAS and a shared accounting server πŸ“Š That got done by defining a set of RADIUS accounting attributes [RAD-ACT] πŸ’œ

Quick packet tea β˜• RADIUS packets start with a short header that holds the RADIUS packet type, the authenticator (sixteen octets), and the length 🧾 After that comes a sequence of (Type, Length, Value) triples, one for each attribute 🍬

RADIUS is seriously popular, and people have proposed a bunch of big new extensions 🌸 For example, [RAD-EXT] talks about extensions to implement the Extensible Authentication Protocol (EAP) and the Apple Remote Access Protocol (ARAP) πŸ¦‹ And [RAD-TACC] covers extensions so RADIUS can work well with tunnels using protocols like PPTP and L2TP 🌈

4.1.1. RADIUS Attributes ✨

okay so every RADIUS attribute gets its own 8-bit number, called the RADIUS Type field πŸŽ€. The up-to-date values live in the most recent Assigned Numbers RFC [ASG-NBR], but here's the current lineup πŸ’…

   RADIUS Attributes [RAD-PROT]             36  Login-LAT-Group
                                            37  Framed-AppleTalk-Link
       1  User-Name                         38  Framed-AppleTalk-Network
       2  User-Password                     39  Framed-AppleTalk-Zone
       3  CHAP-Password
       4  NAS-IP-Address                    60  CHAP-Challenge
       5  NAS-Port                          61  NAS-Port-Type
       6  Service-Type                      62  Port-Limit
       7  Framed-Protocol                   63  Login-LAT-Port
       8  Framed-IP-Address
       9  Framed-IP-Netmask              RADIUS Accounting Attributes
      10  Framed-Routing                 [RAD-ACT]
      11  Filter-Id
      12  Framed-MTU                        40  Acct-Status-Type
      13  Framed-Compression                41  Acct-Delay-Time
      14  Login-IP-Host                     42  Acct-Input-Octets
      15  Login-Service                     43  Acct-Output-Octets
      16  Login-TCP-Port                    44  Acct-Session-Id
      17  (unassigned)                      45  Acct-Authentic
      18  Reply-Message                     46  Acct-Session-Time
      19  Callback-Number                   47  Acct-Input-Packets
      20  Callback-Id                       48  Acct-Output-Packets
      21  (unassigned)                      49  Acct-Terminate-Cause
      22  Framed-Route                      50  Acct-Multi-Session-Id
      23  Framed-IPX-Network                51  Acct-Link-Count
      24  State
      25  Class                          RADIUS Extension Attributes
      26  Vendor-Specific                [RAD-EXT]
      27  Session-Timeout
      28  Idle-Timeout                      52  Acct-Input-Gigawords
      29  Termination-Action                53  Acct-Output-Gigawords
      30  Called-Station-Id                 54  Unused
      31  Calling-Station-Id                55  Event-Timestamp
      32  NAS-Identifier
      33  Proxy-State                       70  ARAP-Password
      34  Login-LAT-Service                 71  ARAP-Features
      35  Login-LAT-Node                    72  ARAP-Zone-Access
      73  ARAP-Security
      74  ARAP-Security-Data
      75  Password-Retry
      76  Prompt
      77  Connect-Info
      78  Configuration-Token
      79  EAP-Message
      80  Message-Authenticator

      84  ARAP-Challenge-Response
      85  Acct-Interim-Interval
      87  NAS-Port-Id
      88  Framed-Pool

   RADIUS Tunneling Attributes
   [RAD-TACC]

      64  Tunnel-Type
      65  Tunnel-Medium-Type
      66  Tunnel-Client-Endpoint
      67  Tunnel-Server-Endpoint
      68  Acct-Tunnel-Connection
      69  Tunnel-Password

      81  Tunnel-Private-Group-ID
      82  Tunnel-Assignment-ID
      83  Tunnel-Preference

      90  Tunnel-Client-Auth-ID
      91  Tunnel-Server-Auth-ID

4.2. DIAMETER πŸ¦‹

The DIAMETER framework [DIAM-FRAM] is a policy protocol that clients use to do Policy, AAA and Resource Control πŸ”₯. The best part is that one server can handle policies for loads of different services. The DIAMETER protocol is a header followed by objects, and each object gets wrapped in a header called an Attribute-Value Pair (AVP) πŸ’œ

The base protocol is the foundation 🧚. It covers the header formats, security extensions and requirements, plus a small number of mandatory commands and AVPs. A brand-new service can level up DIAMETER by extending that base protocol to support whatever new functionality it needs ✨

What really sets DIAMETER apart is its built-in support for Inter-Server communication πŸ‘‘. There are lots of ways to do this, but the standout feature is being able to "proxy" messages across a group of DIAMETER servers, which is called a proxy chain 🫢

The DIAMETER Accounting Extension document [DIAM-ACT] adds a way to securely transfer accounting records over the DIAMETER base protocol πŸ’…. That includes records that might pass through one or more intermediate proxies, following the 'referral broker' model 🌈

The DIAMETER accounting protocol [DIAM-ACT] defines DIAMETER records for moving an ADIF record (see below) around πŸ“. It introduces five new attributes (480..485) that specify how accounting information gets delivered between DIAMETER servers πŸŽ€

4.2.1. DIAMETER Attributes

okay so DIAMETER AVPs are identified by a 16-bit number defined in [DIAM-AUTH] πŸ¦‹. Most of the AVPs in that document were copied from the RADIUS protocol [RAD-PROT], which means RADIUS and DIAMETER servers can read the same dictionary and users files. iykyk πŸ™ˆ

DIAMETER's backward compatibility is there to make deployment easier πŸ’–. DIAMETER inherits the RADIUS attributes and only adds a few of its own ✨

Below, attribute numbers that are used for RADIUS attributes but not for DIAMETER are marked with a star (*). RADIUS attributes that DIAMETER already uses aren't listed again πŸ’œ

The DIAMETER attributes are:

    4      (unassigned, *)
   17      (unassigned)
   21      (unassigned)
   24      (unassigned, *)
   25      (unassigned, *)
   27      (unassigned, *)
   32      (unassigned, *)
   33      (unassigned, *)
  280      Filter-Rule
  281      Framed-Password-Policy
  480      Accounting-Record-Type
  481      ADIF-Record
  482      Accounting-Interim-Interval
  483      Accounting-Delivery-Max-Batch
  484      Accounting-Delivery-Max-Delay
  485      Accounting-Record-Number

  600      SIP-Sequence
  601      SIP-Call-ID
  602      SIP-To
  603      SIP-From

4.3. ROAMOPS 🌸

[ROAM-IMPL] takes a close look at the design and functionality of existing roaming implementations πŸ‘€. "Roaming capability" is loosely the ability to use any one of several Internet service providers (ISPs), while keeping a formal customer-vendor relationship with only one of them πŸ’…. One requirement for roaming to work well is effective accounting ✨

[ROAM-ADIF] proposes a standard accounting record format called the Accounting Data Interchange Format (ADIF) πŸŽ€. It's designed to represent accounting data compactly and in a protocol-independent way, so ADIF can represent accounting data from any protocol that uses attribute value pairs (AVPs) or variable bindings πŸ¦‹

ADIF doesn't define accounting attributes of its own πŸ™ˆ. Instead, it gives examples of accounting records that use the RADIUS accounting attributes πŸ’œ


4.4. RTFM 🧚

The RTFM Architecture [RTFM-ARC] gives us a general method for measuring network traffic flows between "metered traffic groups" πŸ”₯. Each RTFM flow has a set of "address" attributes, which define the traffic groups at each of the flow's end-points πŸ’–

Flows also have traffic-related attributes, like the times of the first and last packets, and counts for packets and bytes in each direction πŸ“

RTFM flow measurements are made by RTFM meters [RTFM-MIB] and collected by RTFM meter readers using SNMP 🫢. The MIB uses a "DataPackage" convention, which specifies the attribute values to read from a flow table row. The meter returns the values for each required attribute inside a BER-encoded sequence. That means there's only one object identifier for the whole sequence, which greatly reduces the number of bytes needed to retrieve the data 🌈

4.4.1. RTFM Attributes

RTFM attributes are identified by a 16-bit attribute number πŸŽ€

The RTFM Attributes are:

 0  Null
 1  Flow Subscript                Integer    Flow table info

 4  Source Interface              Integer    Source Address
 5  Source Adjacent Type          Integer
 6  Source Adjacent Address       String
 7  Source Adjacent Mask          String
 8  Source Peer Type              Integer
 9  Source Peer Address           String
10  Source Peer Mask              String
11  Source Trans Type             Integer
12  Source Trans Address          String
13  Source Trans Mask             String

14  Destination Interface         Integer    Destination Address
15  Destination Adjacent Type     Integer
16  Destination Adjacent Address  String
17  Destination AdjacentMask      String
18  Destination PeerType          Integer
19  Destination PeerAddress       String
20  Destination PeerMask          String
21  Destination TransType         Integer
22  Destination TransAddress      String
23  Destination TransMask         String

26  Rule Set Number               Integer    Meter attribute

27  Forward Bytes                 Integer    Source-to-Dest counters
28  Forward Packets               Integer
29  Reverse Bytes                 Integer    Dest-to-Source counters
30  Reverse Packets               Integer
31  First Time                    Timestamp  Activity times
32  Last Active Time              Timestamp
33  Source Subscriber ID          String     Session attributes
34  Destination Subscriber ID     String
35  Session ID                    String
36  Source Class                  Integer    "Computed" attributes
37  Destination Class             Integer
38  Flow Class                    Integer
39  Source Kind                   Integer
40  Destination Kind              Integer
41  Flow Kind                     Integer

50  MatchingStoD                  Integer    PME variable

51  v1                            Integer    Meter Variables
52  v2                            Integer
53  v3                            Integer
54  v4                            Integer
55  v5                            Integer

65-127 "Extended" attributes
          (to be defined by the RTFM working group)

4.5. ISDN MIB ⚑

The ISDN MIB [ISDN-MIB] is a minimal set of managed objects for SNMP-based management of ISDN terminal interfaces πŸ’…. It doesn't explicitly define anything about accounting, but it does define isdnBearerChargedUnits like this:

   The number of charged units for the current or last connection.
   For incoming calls or if charging information is not supplied by
   the switch, the value of this object is zero.

That's the hook πŸͺ. It lets an ISDN switch turn its traffic flow data (like Call Connect Time) into charging data 🧾

4.5.1. ISDN Attributes

The relevant object in the MIB is the ISDN bearer table, which has entries in this form πŸŽ€

IsdnBearerEntry ::=
    SEQUENCE {
        isdnBearerChannelType           INTEGER,
        isdnBearerOperStatus            INTEGER,
        isdnBearerChannelNumber         INTEGER,
        isdnBearerPeerAddress           DisplayString,
        isdnBearerPeerSubAddress        DisplayString,
        isdnBearerCallOrigin            INTEGER,
        isdnBearerInfoType              INTEGER,
        isdnBearerMultirate             TruthValue,
        isdnBearerCallSetupTime         TimeStamp,
        isdnBearerCallConnectTime       TimeStamp,
        isdnBearerChargedUnits          Gauge32
        }

4.6. AToMMIB πŸ’œ

Okay so the "ATM Accounting Information MIB" document [ATM-ACT] is basically a giant buffet of accounting objects for ATM connections πŸ“. An admin picks what they want with a selector shaped like (subtree, list). The "subtree" part names an object identifier from the AToMMIB, and every subtree has a table holding values for each ATM connection. The "list" is an octet string, and the connections you need get flagged by setting bits in it ✨. For example, (atmAcctngReceivedCells, 0xFF) selects the number of received cells for the first eight ATM connections. Bestie, that's precision πŸ’….

The Connection-Oriented Accounting MIB document [ATM-COLL] is the one that handles collection and storage of accounting info for connection-oriented networks like ATM 🧚. It defines the managed objects that control all of that. The data gets collected into files, which you can retrieve later with a file transfer protocol. Inside those files, records are stored as BER strings [ASN1, BER]. Very neat, very organised 🫢.

4.6.1. AToMMIB Attributes πŸ¦‹

Accounting data objects in the AToMMIB are identified by the last integer in their object identifiers. Here's the whole ATM accounting lineup:

   1   atmAcctngConnectionType
   2   atmAcctngCastType
   3   atmAcctngIfName
   4   atmAcctngIfAlias
   5   atmAcctngVpi
   6   atmAcctngVci
   7   atmAcctngCallingParty
   8   atmAcctngCalledParty
   9   atmAcctngCallReference
  10   atmAcctngStartTime
  11   atmAcctngCollectionTime
  12   atmAcctngCollectMode
  13   atmAcctngReleaseCause
  14   atmAcctngServiceCategory
  15   atmAcctngTransmittedCells
  16   atmAcctngTransmittedClp0Cells
  17   atmAcctngReceivedCells
  18   atmAcctngReceivedClp0Cells
  19   atmAcctngTransmitTrafficDescriptorType
  20   atmAcctngTransmitTrafficDescriptorParam1
  21   atmAcctngTransmitTrafficDescriptorParam2
  22   atmAcctngTransmitTrafficDescriptorParam3
  23   atmAcctngTransmitTrafficDescriptorParam4
  24   atmAcctngTransmitTrafficDescriptorParam5
  25   atmAcctngReceiveTrafficDescriptorType
  26   atmAcctngReceiveTrafficDescriptorParam1
  27   atmAcctngReceiveTrafficDescriptorParam2
  28   atmAcctngReceiveTrafficDescriptorParam3
  29   atmAcctngReceiveTrafficDescriptorParam4
  30   atmAcctngReceiveTrafficDescriptorParam5
  31   atmAcctngCallingPartySubAddress
  32   atmAcctngCalledPartySubAddress
  33   atmAcctngRecordCrc16

4.7. QoS: RSVP and DIFFSERV πŸŽ€

Okay, the internet is moving past plain "best effort" connectivity, and the vibes are immaculate 🌸. There's a huge wave of interest (and work) on protocols that give managed Quality of Service to Internet sessions. This matters most for "Integrated Services", which means carrying audio, video, real-time and classical data traffic over one single network infrastructure πŸ‘‘.

So far there are two approaches:

  • the Integrated Services architecture (intserv) [IIS-ARC], with its accompanying signaling protocol, RSVP [RSVP-ARC], and RSVP's Common Open Policy Service protocol, COPS [RAP-COPS]
  • the Differentiated Services architecture (diffserv) [DSRV-ARC]

RSVP is a signaling protocol that applications can use to request resources from the network. The network answers by explicitly admitting or rejecting those requests. Some applications have quantifiable resource requirements, and they express them using intserv parameters [IIS-SPEC] πŸ’….

Diffserv networks sort packets into a small number of aggregated flows, or "classes", based on the diffserv codepoint (DSCP) in the packet's IP header ✨. At each diffserv router, packets get a "per-hop behavior" (PHB), which is invoked by the DSCP. RSVP is purely a requirements signalling protocol, so it can also be used to request connections from a diffserv network [RS-DS-OP] πŸ¦‹.

4.7.1. RSVP and DIFFSERV Attributes 🧚

A set of parameters for specifying a requested Quality of Service is given in [IIS-SPEC]. Those got turned into accounting attributes in RTFM [RTFM-NEWA] and in the RSVP MIB [RSVP-MIB] πŸ’–.

The RTFM QoS attributes are:

   98      QoSService
   99      QoSStyle
  100      QoSRate
  101      QoSSlackTerm
  102      QoSTokenBucketRate
  103      QoSTokenBucketSize
  104      QoSPeakDataRate
  105      QoSMinPolicedUnit
  106      QoSMaxPolicedUnit

The RSVP MIB has a ton of objects, sorted into these sections:

   General Objects
   Session Statistics Table
   Session Sender Table
   Reservation Requests Received Table
   Reservation Requests Forwarded Table
   RSVP Interface Attributes Table
   RSVP Neighbor Table

The Session tables hold stuff like how many senders and receivers each session has, while the Reservation Requests tables hold details about requests the RSVP router handled πŸ”₯. There are way too many objects to list here, but lots of them could be used for accounting. The big one is RSVP Requests, which carry the service parameters a user asked for. Those, plus the actual usage data for the connection, make up an accounting record for that usage 🫢.

5. ITU-T Documents 🌈

5.1. Q.825: Call Detail Recording πŸ“ž

ITU-T Recommendation Q.825 spells out how CDRs (Call Detail Records) are produced and managed in Network Elements for POTS, ISDN and IN (Intelligent Networks) πŸ“. It also talks through the different ways Call Detail information can be used.

Each call produces one or more records describing the events that happened during its life 🌸. The data can come out in real time (single CDRs), near real-time (blocks of CDRs), or as batch files of CDRs.

The information model is formally described as an Entity-Relationship model, and there's an object model written in GDMO templates (Guidelines for the Definition of Managed Objects) 🧠. The model also covers how CDRs travel from the (NE) Network Element that generated them to the OS (Operations System) that uses them πŸš€.

5.2. Q.825 Attributes πŸ’…

Here are the attributes Q.825 defines. My explanations are super brief, so check [Q-825] for the full text πŸ™ˆ.

   1  accessDelivery
        Indicates that the call was delivered to the called subscriber

   2  accountCodeInput
        Account code (for billing), supplied by subscriber.

  78  additionalParticipantInfo
        (No details given)

   5  b-PartyCategory
        Subscriber category for called subscriber.

   4  bearerService
        Bearer capability information (only for ISDN calls).

  13  cDRPurpose
        Reason for triggering this Call Data Record.

  70  callDetailDataId
        Unique identifier for the CallDetailData object.

  79  callDuration
        Duration of call

   6  callIdentificationNumber
        Identification number for call; all records produced for this
        call have the same callIdenfificationNumber.

  73  callStatus
        Identifies whether the call was answered or not.

   9  calledPartyNumber
        Telephone number of the called subscriber (may be a
        "diverted-to" or "translated" number.

   7  callingPartyCategory
        Calling subscriber category.

   8  callingPartyNumber
        Telephone number of the calling party.

  10  callingPartyNumberNotScreened
        An additional, user-provided (not screened) number to the
        calling party.

  11  callingPartyType
        Calling subscriber type.

  74  carrierId
        Carrier ID to which the call is sent.

  12  cause
        Cause and location value for the termination of the call.

  14  chargedDirectoryNumber
        Charged directory number (where the charged participant
        element can't indicate the number).

  16  chargedParticipant
        Participant to be charged for the usage.

  15  chargingInformation
        Charging information generated by a Network Element which is
        capable of charging.

  17  configurationMask
        Time consumption, e.g. from B-answer to termination time,
        between partial call records, etc.

  18  conversationTime
        Time consumption from B-answer to end of call.

  19  creationTriggerList
        List of trigger values which will create Call Detail data
        objects.

  75  dPC
        Destination point code (for analysis purposes).

  20  dataValidity
        Indicates that the NE is having problems, contents of the
        generated Call Detail record is not reliable.

  23  durationTimeACM
        Time consumption from seizure until received ACM.

  21  durationTimeB-Answer
        Time consumption from seizure until B-answer.

  22  durationTimeNoB-Answer
        Time from seizure to termination when no B-answer was
        received.

  25  exchangeInfo
        Identity of exchange where Call Detail record was generated.

  26  fallbackBearerService
        Fallback bearer capability information for a call.

  27  glare
        Indicates if a glare condition was encountered.

  31  iNServiceInformationList
        Contains information about the use of IN (Intelligent Network)
        services.

  32  iNSpecificInformation
        Contains information about the use of one IN service.

  33  iSUPPreferred
        Indicate whether an ISUP preference was requested.

  28  immediateNotificationForUsageMetering
        Indicates that the Call Detail records requires
        immediate data transfer to the Operations System.

  34  maxBlockSize
        Maximum number of Call Detail records in a block.

  35  maxTimeInterval
        Maximum latency allowable for near-real-time Call Detail
        data delivery.

  36  networkManagementControls
        Indicates which Traffic Management Control has affected
        the call.

  37  networkProviderId
        Indicates the Network Provider for whom the CDR is generated.

  76  oPC
        Originating point code for a failed call (for analysis
        purposes).

  38  operatorSpecific1AdditionalNumber
  40  operatorSpecific2AdditionalNumber
  42  operatorSpecific3AdditionalNumber
        Operator-defined additional participant information.

  39  operatorSpecific1Number
  41  operatorSpecific2Number
  43  operatorSpecific3Number
        Operator-defined participant information.

  44  originalCalledNumber
        Telephone number of the original called party.

  45  partialGeneration
        Included if the CDR (Call Detail record) output is partial.
        Such CDRs have a field indicating their partial record number.

  77  participantInfo
        (No details given).

  46  percentageToBeBilled
        Percentage to be billed when normal billing rules are
        not to be followed.

  47  periodicTrigger
        Defines the intervals at which the CDR file should be created.

  48  personalUserId
        Internationally unique personal User Identity (for UPT calls).

  49  physicalLineCode
        Identifies the call subscriber's physical line.

  50  progress
        Describes an event which occurred during the life of a call.

  51  queueInfo
        Used to record usage of queueing resources with IN calls.

  52  receivedDigits
        The digits dialed by the subscriber.  (Normally only included
        for customer care purposes).

  53  recordExtensions
        Information elements added by network operators and/or
        manufacturers in addition to the standard ones above.

6. Other Documents ✨

6.1. TIPHON: ETSI TS 101 321 πŸ’–

Okay bestie, TIPHON [TIPHON] is an XML-based protocol that rides along on HTTP and handles accounting and authorization requests and responses. It's giving organized πŸ“‹βœ¨

These are the elements from TIPHON's DTD that are used for accounting:

<!ELEMENT Currency (#PCDATA)> <!ELEMENT Amount (#PCDATA)>
    Identifies a numeric value.  Expressed using the period (.) as a
    decimal separator with no punctuation as the thousands separator.

<!ELEMENT CallId (#PCDATA)>
    Contains a call's H.323 CallID value, and is thus used to
    uniquely identify individual calls.

<!ELEMENT Currency (#PCDATA)>
    Defines the financial currency in use for the parent element.

<!ELEMENT DestinationInfo type ( e164 | h323 | url | email |
                                 transport | international |
                                 national | network | subscriber |
                                 abbreviated | e164prefix )
    Gives the primary identification of the destination for a call.

<!ELEMENT Increment (#PCDATA)>
    Indicates the number of units being accounted.

<!ELEMENT Service EMPTY>
    Indicates a type of service being priced, authorized, or
    reported.  An empty Service element indicates basic Internet
    telephony service, which is the only service type defined by
    V1.4.2 of the specification.  The specification notes that "Later
    revisions of this standard are expected to specify more enhanced
    service definitions to represent quality of service,
    availability, payment methods, etc."

<!ELEMENT DestinationInfo type ( e164 | h323 | url | email |
                                 transport | international |
                                 national | network | subscriber |
                                 abbreviated | e164prefix)
    Gives the primary identification of the source of a call.


<!ELEMENT Timestamp (#PCDATA)>
    A restricted form of [ISO-DATE] that indicates the time at which
    the component was generated.

<!ELEMENT TransactionId (#PCDATA)>
    Contains an integer, decimal valued identifier assigned to a
    specific authorized transaction.

<!ELEMENT Unit (#PCDATA)>
    Indicates the units by which pricing is measured or usage
    recorded.  It shall contain one of the following values:
        s      seconds
        p      packets (datagrams)
        byte   bytes

<!Element UsageDetail ( Service, Amount, Increment, Unit ) >
    Collects information describing the usage of a service.

6.2. MSIX πŸ¦‹

MSIX [MSIX-SPEC] is an XML-based protocol transported by HTTP, and it's used to make accounting service definitions and send service usage information. Lowkey the best part is that its service definitions are parameterized and dynamic, so it doesn't define any services or attributes itself. Instead it lets implementors make their own πŸ”₯. It only specifies the base data types that attributes may take: STRING, UNISTRING, INT32, FLOAT, DOUBLE, BOOLEAN, TIMESTAMP.


7. Accounting File and Record Formats πŸŽ€

7.1. ASN.1 Records 🧚

7.1.1. RTFM and AToMMIB

RTFM and AToMMIB both use ASN.1 Basic Encoding Rules (BER) to encode lists of attributes into accounting records. RTFM uses SNMP to retrieve those records as BER strings, which means it doesn't need an object identifier for every object. Smart, right? πŸ™Œ

AToMMIB takes it a step further. It defines an accounting file format in ASN.1 and makes that file available for retrieval by a file transfer protocol, so it's a more efficient option than just retrieving the records one by one with SNMP. πŸ’…

7.1.2. Q.825

A Q.825 Call Record is an ASN.1 SET that contains a specified group of the Q.825 attributes. The call records would presumably be encoded as BER strings before they're collected for later processing. 🌸

7.2. Binary Records πŸ€–

7.2.1. RADIUS

Radius packets carry a sequence of attributes and their values, as (Type, Length, Value) triples. The value field is one of four data types:

  • string: 0-253 octets
  • address: 32 bit value, most significant octet first.
  • integer: 32 bit value, most significant octet first.
  • time: 32 bit value, most significant octet first -- seconds since 00:00:00 GMT, January 1, 1970. The standard Attributes do not use this data type but it is presented here for possible use within Vendor-Specific attributes.

7.2.2. DIAMETER 🩡

Each DIAMETER message is made of multiple AVP's that are 32-bit aligned, and each one looks like this:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |                           AVP Code                            |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |          AVP Length           |     Reserved        |P|T|V|R|M|
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |                        Vendor ID (opt)                        |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |                           Tag (opt)                           |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |    Data ...
      +-+-+-+-+-+-+-+-+

AVP Code: The AVP Code identifies the attribute uniquely. If the Vendor-Specific bit is set, the AVP Code is allocated from the vendor's private address space.

The first 256 AVP numbers are reserved for backward compatibility with RADIUS, and they're to be interpreted as per RADIUS [RAD-PROT]. AVP numbers 256 and above are used for DIAMETER, and IANA allocates them. πŸ“š

AVP Length: A 16-bit field that contains the total object length in bytes. Must always be a multiple of 4, and at least 8.

AVP Flags:

      P                      Protected bit
      T                      Tag bit
      V                      Vendor-ID bit
      R                      Reserved (MUST be set to 0)
      M                      Mandatory bit

7.3. Text Records πŸ“

7.3.1. ROAMOPS

ADIF (Accounting Data Interchange Format [ROAM-ADIF]) is a general, text-based format for accounting data files, described in a straightforward BNF grammar. Its file header has a field that indicates the default protocol that accounting attributes are drawn from. If an attribute from another protocol is to be used, it's preceded by its protocol name. For example, rtfm//27 would be RTFM's "forward bytes" attribute. Comments in an ADIF file begin with a cross-hatch. #aesthetic 🌈

Example: An ADIF file encoding RADIUS accounting data

     version: 1
     device: server3
     description: Accounting Server 3
     date: 02 Mar 1999 12:19:01 -0500
     defaultProtocol: radius

     rdate: 02 Mar 1999 12:20:17 -0500
     #NAS-IP-Address
     4: 204.45.34.12
     #NAS-Port
     5: 12
     #NAS-Port-Type
     61: 2
     #User-Name
     1: fred@bigco.com
     #Acct-Status-Type
     40: 2
     #Acct-Delay-Time
     41: 14
     #Acct-Input-Octets
     42: 234732
     #Acct-Output-Octets
     43: 15439
     #Acct-Session-Id
     44: 185
     #Acct-Authentic
     45: 1
     #Acct-Session-Time
     46: 1238
     #Acct-Input-Packets
     47: 153
     #Acct-Output-Packets
     48: 148
     #Acct-Terminate-Cause
     49: 11
     #Acct-Multi-Session-Id
     50: 73
     #Acct-Link-Count
     51: 2

8. AAA Requirements πŸ‘‘

8.1. A Well-Defined Set of Attributes ✨

AAA needs a well-defined set of attributes whose values are carried in records to or from accounting servers. Main character energy πŸ’…

Most of the existing sets of documents described above include a set of attributes, identified by small integers. These sets probably overlap, i.e. some of them have attributes that represent the same quantity under different names in different sets. That suggests it might be possible to produce a single combined set of "universal" accounting attributes, but honestly such a "universal" set doesn't seem worthwhile πŸ™ˆ.

The ADIF approach of specifying a default protocol (where attributes are assumed to come from) and then identifying any exceptions seems much more practical. So we propose that AAA should use the ADIF convention (or something like it) to identify attributes, together with all the sets of attributes covered by the [ASG-NBR] document. 🫢

8.2. A Simple Interchange Format πŸ“

AAA needs a simple interchange file format for accounting data. Several schemes for packaging and transporting that data have been described above.

The SNMP-based ones fit well within the context of an SNMP-based network management system. RTFM and AToMMIB provide ways to reduce the SNMP overhead for collecting data, and AToMMIB defines a complete file format. Both are solid ways to collect accounting data.

As an interchange format, though, ASN.1-based schemes are kind of messy 😭. They're rather complex binary structures, so you need suitable tools to work with them, unlike plain-text files where you can use existing text-based utilities.

The binary schemes like RADIUS and DIAMETER have simpler structures, but they too need purpose-built tools. For general use they would need to be extended so they can use attributes from other protocols.

For humans, ADIF is very promising ngl πŸ’œ. Any processing program would still need a suitable ADIF input parser, but plain-text files are so much easier to understand.

TIPHON's record format is specified by an XML DTD. XML representations have the advantage of being well-known, but they're limited by XML's inability to specify type or other validity checking for information within the tags. This situation will likely improve with the XML Schema [XML-SCHM] efforts that are underway, but a stable reference isn't available yet πŸ₯Ί.


9. Issues 🌸

It's generally agreed that there's a need for a standard record format and transport protocol for communication between Service Elements and Accounting Servers.

There's less agreement on the following issues:

  • Separate or integral record format and transport protocol
  • Standard set of base data types
  • Service definitions: part of the protocol or separately defined
  • Service definition namespace management

The following sections address these issues. πŸŽ€

9.1. Record Format vs. Protocol ✨

okay so every Internet billing protocol we've got so far has its record format baked right in πŸŽ€ The Properties that describe a Usage Event are part of the protocol itself, usually inside a "submit" message that sends a Usage Event from a Service Entity to an Accounting Server.

It might be a good move to define a record format that doesn't depend on the transport protocol πŸ’… That format should handle single records and bulk records too, since Usage Events are often bundled up and sent in batches.

A separate record format is also useful for archiving and temporary file storage πŸ“ Multiple transport protocols can be defined without changing the record format. Auditing gets easier when there's a standard file format. If a canonical format is used, bulk records may be hashed with MD5 [MD5] or a similar function, for reliability and security purposes πŸ”

                                  +------------+
                                  |  transport |
                                  |   header   |
            +------------+        +------------+
            |            |        |            |
            |   Usage    |        |   Usage    |
            |  Event(s)  |        |  Event(s)  |
            |            |        |            |
            |            |        |            |
            +------------+        +------------+
                                  |  trailer   |
                                  +------------+

            record format       transport protocol

If the protocol is written so it can carry Usage Events in the record format, you don't have to rewrite the records for transport at all πŸ¦‹ no extra work, just vibes.

9.2. Tagged, Typed Data 🏷️

Record formats and protocols use a mix of data locality and explicit tagging to figure out which data element is which 🧚 Mail [RFC822], for example, has a header block made of several Attribute-Value Pairs, followed by a message body. Each header field is explicitly tagged, but the order of the AVPs is undefined. The message body isn't tagged (except for the extra blank line in front of it), so you find it by its position, which has to come after all the header fields.

Some record formats don't use tags at all, so data elements are only identified by where they sit in the record structure πŸ™ˆ This keeps the record space overhead super low, but it's a pain to change the format later by adding or removing elements, because every record reader has to be updated to handle the change. Tagged data lets old readers spot unexpected tags and notice when required data is missing πŸ‘‘ If you can afford the overhead of carrying explicit tags, it's really worth using explicitly tagged data elements wherever possible πŸ’œ

An AVP approach has proven useful in accounting πŸ”₯ RADIUS [RADIUS] uses numeric data type identifiers. ETSI's TIPHON [TIPHON] uses XML markup.

For an AAA accounting record format, the authors suggest that each Property be named by a textual or numeric identifier and carry a value and a data type indicator, which governs how the value is interpreted πŸ“ It may also be useful for each Property to carry a units of measure identifier. The TIPHON specification takes this approach. TS 101 321 also carries an Increment field, which denominates the Property's Unit of Measure field. Whether this extra convenience is necessary is still up for discussion πŸ€”

It isn't strictly necessary for each data record to carry data type, units of measure, or increment identifiers 🌸 If this information is recorded in a record schema document that each data record references, then each record can be validated against the schema without the overhead of carrying type information.

9.2.1. Standard Type Definitions 🧩

It's useful to define a standard set of primitive data types for the record format and protocol to use πŸ’– Looking at the prior art, DIAMETER supports Data (arbitrary octets), String (UTF-8), Address (32 or 128 bit), Integer32, Integer64, Time (32 bits, seconds since 1970), and Complex. MSIX [MSIX-SPEC] supports String, Unistring, Int32, Float, Double, Boolean, and Timestamp. SMIv2 [SMI-V2] offers ASN.1 types INTEGER, OCTET STRING, and OBJECT IDENTIFIER, and the application-defined types Integer32, IpAddress, Counter32, Gauge32, Unsigned32, TimeTicks, Opaque, and Counter64.

A good set would probably include booleans, 32 and 64 bit signed integers, 32 and 64 bit floats, arbitrary octets, UTF-8 and UTF-16 strings, and ISO 8601:1988 [ISO-DATE] timestamps 🫢 Fixed-precision numbers that can represent currency amounts (with precision specified on both sides of the decimal point) have proven really useful in accounting record formats πŸ’° They're immune to the precision problems you run into when you try to represent fixed-point amounts with floating point numbers. Major ick avoided ✨

It may be worth looking at the datatypes specified by the W3C's "XML Schema Part 2: Datatypes" [XML-DATA] document 🌈 That document specifies a rich set of base types, along with a mechanism for specifying derivations that further constrain the base types.

9.3. Transaction Identifiers πŸ†”

Each Usage Event needs its own unique identifier πŸ’œ

It's convenient to let Service Elements create their own unique identifiers πŸ¦‹ That way, Usage Events can be created and archived without needing an Accounting Server or any other central authority.

There are a number of well-known methods for creating unique identifiers πŸŽ€ One popular one is a mix of a monotonically increasing sequence number, a large random value, a network element identifier, and a timestamp. Another possible source of entropy is a hash value of all or part of the record itself.

RFC 822 [MAIL], RFC 1036 [NEWS], and RFC 2445 [ICAL-CORE] give guidance on creating good unique identifiers πŸ“š

9.4. Service Definitions πŸ›ŽοΈ

A critical differentiator for accounting record formats and protocols is whether they can account for arbitrary service usage πŸ‘‘ Up to now, no accounting record format or protocol that can handle arbitrary service definitions has achieved broad acceptance on the Internet 😭

This section looks at the issues in service definition and makes the case for a record format and protocol that can carry Usage Events for rich, independently-defined services ✨

9.4.1. Service Independence 🌍

It's informative to survey a bunch of popular Internet protocols and document encodings and check how well they can be extended πŸ” They fall into two broad categories: "fully specified" protocols that have little provision for extension, and "framework" protocols that are incomplete but provide a basis for future extension when coupled with application documents.

Examples of fully-specified protocols are NTP [NTP], NNTP [NNTP], RADIUS Accounting [RAD-ACT], and HTML [HTML] πŸ’…

Aside from leaving some field values "reserved for future use", all of Network Time Protocol's fields are fixed-width and completely defined πŸ•°οΈ That's appropriate for a simple protocol solving a simple problem.

Network News Transfer Protocol [NEWS-PROT] says further commands may be added, and asks that non-standard implementations use the "X-" experimental prefix so they don't conflict with future additions πŸ™ƒ The content of news is 7-bit data, with the high-order bit cleared to 0. Nothing further about the content is defined. There's no in-protocol facility for automating decoding of content type.

We pay particular attention to RADIUS Accounting [RAD-ACT] πŸ‘€ Perhaps the second most frequently heard complaint about RADIUS Accounting (after security shortcomings) is its preassigned and fixed set of "Types". These are coded as a range of octets from 40 to 51, and they are as follows:

      40      Acct-Status-Type
      41      Acct-Delay-Time
      42      Acct-Input-Octets
      43      Acct-Output-Octets
      44      Acct-Session-Id
      45      Acct-Authentic
      46      Acct-Session-Time
      47      Acct-Input-Packets
      48      Acct-Output-Packets
      49      Acct-Terminate-Cause
      50      Acct-Multi-Session-Id
      51      Acct-Link-Count

These identifiers were designed to account for packet-based network access service, so they're kind of ill-suited for describing other services πŸ™„ While extension documents have specified additional types, the base protocol limits the type identifier to a single octet, which caps the total number of types at 256.

HTML/2.0 [HTML] is mostly a fully-specified protocol, but with W3C's HTML/4.0, HTML is becoming more of a framework protocol 🌱 HTML/2.0 specified a fixed set of markups with no provision for additions (without a protocol revision).

Examples of "framework" protocols and document encodings are HTTP, XML, and SNMP 🧠

HTTP/1.1 [HTTP] is somewhat similar to NNTP in that it's designed to transport arbitrary content. It's different in that it supports description of that content through its Content-Type, Content-Encoding, Accept-Encoding, and Transfer-Encoding header fields. New types of content can be designated and carried by HTTP/1.1 without modifying the HTTP protocol πŸŽ‰

XML [XML] is a preeminent general-purpose framework encoding 🌟 DTD publishing is left to users, and there's no standard registry of DTDs.

SNMP is a successful example of a framework protocol πŸ† SNMP's authors envisioned it as a general management protocol, and they allow extension through the use of private MIBs. SNMP's ASN.1 MIBs are defined, published, and standardized without any need to modify the SNMP standard itself. From "An Overview of SNMP" [SNMP-OVER]:

It can easily be argued that SNMP has become prominent mainly from its ability to augment the standard set of MIB objects with new values specific for certain applications and devices. Hence, new functionality can continuously be added to SNMP, since a standard method has been defined to incorporate that functionality into SNMP devices and network managers.

Most accounting protocols are fully-specified πŸ₯± Either they have a completely defined service or set of services (RADIUS Accounting), or they have one or more services defined with provision for "extension" services to be added later (TIPHON). The latter is preferable, but it may be even better to take a more SNMP-like approach, where the accounting record format and protocol provide only a framework for service definition, and the task of service definition (and standardization) is left to separate efforts πŸ’« That way, the accounting protocol itself wouldn't have to be modified to handle new services. Big brain move πŸ§šβ€β™€οΈ

9.4.2. Versioned Service Definitions πŸŽ€

okay so versioning is basically a naming and compatibility thing πŸ’… Version identifiers are super useful in service definitions bc they let you upgrade a definition without an awkward name change 😭 They also make it possible for different versions of the same service to play nicely together 🫢

Here's an example: a phone call πŸ“ž Version 1 might define Properties for the start time, duration, and called and calling party numbers. Later on, Version 2 comes along and adds a byte count on top πŸ¦‹ An Accounting Server that only knows about Version 1 can accept Version 2 records and just toss the extra info (that's forward compatibility ✨). Or, if the Accounting Server knows about version 2, it could optionally still accept version 1 records from Service Elements, as long as it doesn't need the extra info to correctly account for usage (that's backward compatibility πŸ’œ).


9.4.3. Relationships Among Usage Events πŸ’Œ

Real talk: accounting record formats and protocols haven't really handled "compound" service descriptions yet πŸ™ˆ

A compound service is one that's described as a mix of other services 🧩 A conference call, for example, could be described as a bunch of point-to-point calls to a conference bridge. It matters to account for each individual call instead of just adding everything into one big total, both for auditing and so you can do differential rating πŸ’– If those calls get reported to the Accounting Server one by one, the Usage Events need a shared identifier so the Accounting Server and other back-end systems can group them together 🫢

For a Service Element to report a compound event over time as a series of individual Usage Events, the accounting protocol needs a way to say the compound event has started and stopped 🎬 The "start" message can be implicit, since sending the first Usage Event is enough ✨ There's also an extra semaphore needed to tell the Accounting Server that the compound service is complete and can be processed further 🚦 This keeps the Accounting Server from prematurely processing compound events that run over the end of a billing period πŸ“…

RADIUS Accounting kinda has something for this with its Acct-Multi-Session-Id field πŸ‘€ Unfortunately, RADIUS Accounting has other shortcomings that stop it from being used for general purpose service usage description 😭


9.4.4. Service Namespace Management πŸ—‚οΈ

"Framework" protocols, like we mentioned, don't define a complete schema for their payload 🧠 For interoperability to be achieved, two things have to be possible:

  1. content definers can specify definitions without conflicting with the names of other definitions
  2. protocol users can find and use content definitions

Condition 1 can be managed pretty readily through IANA assignment, or by using an existing namespace differentiator (like DNS) βœ…

Condition 2 is way harder and puts a lot of burden on implementors 😩 Their clients and servers need to be able to find and validate definitions, statically or dynamically, and handle versioning issues too πŸ’€

As mentioned earlier, the XML specification provides no facility for DTD discovery or namespace management πŸ™ƒ XML only specifies a document format, so it doesn't need to support more "protocol" oriented problems πŸ’…

For an accounting record format and protocol, an approach closer to SNMP's is useful πŸ’œ SNMP uses an ISO-managed dotted-decimal namespace. An IANA-managed registry of service types is a possibility. Another possibility, used by MSIX [MSIX-SPEC], is for Service Element creators to identify their services by concatenating a new service name with an existing unique identifier, such as a domain name 🌐

A standard record format for service definitions would let Service Element creators directly hand accounting system managers the required definitions, over the network or by other means 🎁


10. Encodings 🧁

It may be useful to define more than one record encoding 🀷

A "verbose" XML encoding is easy to implement, and records can be syntactically verified with existing tools πŸ› οΈ "Human-readable" protocols tend to have an edge over "bitfield" protocols when ease of implementation is paramount and the application can handle any extra processing needed to generate, parse, and transport the records πŸ“–

An alternative "compressed" encoding that makes minimal use of storage and processing may be useful in many contexts πŸ—œοΈ

There are downsides to supporting multiple encodings 😬 Optionally supported multiple encodings require a capabilities exchange between the Service Element and the Accounting Server. Also, implementations can "drift apart," with one encoding getting better support than another πŸ’” Unless all encodings are mandatory, implementors may find they're unable to interoperate because they picked the wrong encoding πŸ™ˆ


11. Security Considerations πŸ”

⚠️ Bestie, this part is serious, so read it carefully! 🚨

This document summarizes many existing IETF and ITU documents, so please go check the original documents for the security considerations of their particular protocols πŸ“š

It must be possible for the accounting protocol to be carried by a secure transport. A canonical record format is useful so that regeneration of secure record hashes is possible πŸ”

When dealing with accounting data files, one must take care that their integrity and privacy are preserved πŸ—οΈ This document, however, is only concerned with the format of such files 🫣

12. References πŸ“š

  • [ACC-BKG] Mills, C., Hirsch, G. and G. Ruth, "Internet Accounting Background", RFC 1272, November 1991.
  • [ASG-NBR] Reynolds, J. and J. Postel, "Assigned Numbers", STD 2, RFC 1700, October 1994.
  • [ASN1] Information processing systems - Open Systems Interconnection - Specification of Abstract Syntax Notation One (ASN.1), International Organization for Standardization, International Standard 8824, December 1987.
  • [ATM-ACT] McCloghrie, K., Heinanen, J., Greene, W. and A. Prasad, "Accounting Information for ATM Networks", RFC 2512, February 1999.
  • [ATM-COLL] McCloghrie, K., Heinanen, J., Greene, W. and A. Prasad, " Managed Objects for Controlling the Collection and Storage of Accounting Information for Connection-Oriented Networks", RFC 2513, February 1999.
  • [BER] Information processing systems - Open Systems Interconnection - Specification of Basic Encoding Rules for Abstract Notation One (ASN.1), International Organization for Standardization, International Standard 8825, December 1987.
  • [DIAM-ACT] Arkko, J., Calhoun, P.R., Patel, P. and Zorn, G., "DIAMETER Accounting Extension", Work in Progress.
  • [DIAM-AUTH] Calhoun, P.R. and Bulley, W., "DIAMETER User Authentication Extensions", Work in Progress.
  • [DIAM-FRAM] Calhoun, P.R., Zorn, G. and Pan, P., "DIAMETER Framework Document", Work in Progress.
  • [DSRV-ARC] Blake, S., Black, D., Carlson, M., Davies, E., Wang, Z. and W. Weiss, "An Architecture for Differentiated Services", RFC 2475, December 1998.
  • [HTML] Berners-Lee, T. and D. Connolly, "Hypertext Markup Language - 2.0", RFC 1866, November 1995.
  • [HTTP] Fielding, R., Gettys, J., Mogul, J. Frystyk, H. and T. Berners-Lee, "Hypertext Transfer Protocol--HTTP/1.1", RFC 2068, January 1997.
  • [ICAL-CORE] Dawson, F. and D. Stenerson, "Internet Calendaring and Scheduling Core Object Specification", RFC 2445, November 1998.
  • [IIS-ARC] Braden, R., Clark, D. and S. Shenker, "Integrated Services in the Internet Architecture: an Overview", RFC 1633, June 1994.
  • [IIS-SPEC] Shenker, S., Partridge, C. and R. Guerin, "Specification of Guaranteed Quality of Service", RFC 2212, September 1997.
  • [ISDN-MIB] Roeck, G., "ISDN Management Information Base using SMIv2", RFC 2127, March 1997.
  • [ISO-DATE] "Data elements and interchange formats -- Information interchange -- Representation of dates and times", ISO 8601:1988.
  • [MAIL] Crocker, D., "STANDARD FOR THE FORMAT OF ARPA INTERNET TEXT MESSAGES", STD 11, RFC 822, August 1982.
  • [MD5] Rivest, R., "The MD5 Message-Digest Algorithm", RFC 1321, April 1992.
  • [MSIX-SPEC] Blount, A. and D. Young, "Metered Service Information Exchange 1.2", Work in Progress.
  • [NEWS-MSGS] Horton, M. and R. Adams, "Standard for Interchange of USENET Messages", RFC 1036, December 1987.
  • [NEWS-PROT] Kantor, B. and P. Lapsley, "Network News Transfer Protocol", RFC 977, February 1986.
  • [NTP] Mills, D., "Network Time Protocol (NTP)", RFC 958, September 1985.
  • [Q-825] "Specification of TMN applications at the Q3 interface: Call detail recording", ITU-T Recommendation Q.825, 1998.
  • [RAD-ACT] Rigney, C., "RADIUS Accounting", RFC 2866, June 2000.
  • [RAD-EXT] Rigney, C., Willats, W. and Calhoun, P., "RADIUS Extensions", RFC 2869, June 2000.
  • [RAD-PROT] Rigney, C., Willens, S., Rubens, A., and W. Simpson, "Remote Authentication Dial In User Service (RADIUS)", RFC 2865, June 2000.
  • [RAD-TACC] Zorn, G., Mitton, D. and A. Aboba, "RADIUS Accounting Modifications for Tunnel Protocol Support", RFC 2867, June 2000.
  • [RAP-COPS] Boyle, J., Cohen, R., Durham, D., Herzog, S., Rajan, R. and A. Sastry, "The COPS (Common Open Policy Service) Protocol", RFC 2748, January 2000.
  • [ROAM-ADIF] Aboba, B. and D. Lidyard, "The Accounting Data Interchange Format (ADIF)", Work in Progress.
  • [ROAM-IMPL] Aboba, B., Lu, J., Alsop, J., Ding, J. and W. Wang, "Review of Roaming Implementations", RFC 2194, September 1997.
  • [RS-DS-OP] Bernet, Y., Yavatkar, R., Ford, P., Baker, F., Zhang, L., Speer, M., Braden, R., Davie, B., Wroclawski, J. and E. Felstaine, "A Framework For Integrated Services Operation Over Diffserv Networks", Work in Progress.
  • [RSVP-ARC] Braden, R., Zhang, L., Berson, S., Herzog, S. and S. Jamin, "Resource Reservation Protocol (RSVP) Version 1 Functional Specification", RFC 2205, September 1997.
  • [RSVP-MIB] Baker, F., Krawczyk, J. and A. Sastry, "RSVP Management Information Base using SMIv2", RFC 2206, September 1997.
  • [RTFM-ARC] Brownlee, N., Mills, C. and G. Ruth, "Traffic Flow Measurement: Architecture", RFC 2722, October 1999.
  • [RTFM-MIB] Brownlee, N., "Traffic Flow Measurement: Meter MIB", Measurement: Architecture", RFC 2720, October 1999.
  • [RTFM-NEWA] Handelman, S., Brownlee, N., Ruth, G. and S. Stibler, "New Attributes for Traffic Flow Measurement", RFC 2724, October 1999.
  • [SIP-PROT] Handley, M., Schulzrinne, H., Schooler, E. and J. Rosenberg, "SIP: Session Initiation Protocol", RFC 2543, March 1999.
  • [SMI-V2] McCloghrie, K., Perkins, D. and J. Schoenwaelder, "Structure of Management Information Version 2 (SMIv2)", STD 58, RFC 2578, April 1999.
  • [SNMP-OVER] "AN OVERVIEW OF SNMP V2.0", Diversified Data Resources, Inc., http://www.ddri.com, 1999.
  • [TIPHON] "Telecommunications and Internet Protocol Harmonization Over Networks (TIPHON); Inter-domain pricing, authorization, and usage exchange", TS 101 321 V1.4.2, December 1998.
  • [XML] Bray, T., J. Paoli, and C. Sperberg-McQueen, "Extensible Markup Language (XML) 1.0", W3C Recommendation, February 1998.
  • [XML-DATA] "XML Schema Part 2: Datatypes", W3C Working Draft 07 April 2000, April 2000.
  • [XML-SCHM] "XML Schema Part 1: Structures", W3C Working Draft 7 April 2000, April 2000.

13. Authors' Addresses πŸŽ€

Nevil Brownlee
Information Technology Systems & Services
The University of Auckland

Phone: +64 9 373 7599 x8941
EMail: n.brownlee@auckland.ac.nz


Alan Blount
MetraTech Corp.
330 Bear Hill Road
Waltham, MA 02451

EMail: blount@alum.mit.edu

Copyright (C) The Internet Society (2000). All Rights Reserved.

This document and translations of it may be copied and furnished to others, and derivative works that comment on or otherwise explain it or assist in its implementation may be prepared, copied, published and distributed, in whole or in part, without restriction of any kind, provided that the above copyright notice and this paragraph are included on all such copies and derivative works. However, this document itself may not be modified in any way, such as by removing the copyright notice or references to the Internet Society or other Internet organizations, except as needed for the purpose of developing Internet standards in which case the procedures for copyrights defined in the Internet Standards process must be followed, or as required to translate it into languages other than English.

The limited permissions granted above are perpetual and will not be revoked by the Internet Society or its successors or assigns.

This document and the information contained herein is provided on an "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.

Acknowledgement 🫢

Funding for the RFC Editor function is currently provided by the Internet Society.

πŸ“¦ where this page comes from