Electricity metering - Payment systems - Part 42: Transaction Reference Numbers (TRN)

This document specifies a token generation mechanism and token structure for smart
prepayment functionality in markets where IEC 62055-41 compliant systems are not used, and
where a different security mechanism is required by project-specific or national requirements.
This document specifies token structure, authentication and an anti-replay mechanism, token
operating model, and protocol.
This document is informed by the STS Association key management services, and by the key
management mechanisms used within the DLMS/COSEM security model within IEC 62056‑6‑2.
Reference is made to the international STS token standards (IEC 62055-41, IEC 62055-51 and
IEC 62055-52) for payment metering systems, and interworking has been considered where
appropriate in terms of token carrier ranges in the decimal domain. IEC 62055-41 tokens and
those described in this document are not interoperable, however their domains are designed to
be mutually exclusive to ensure the two kinds of tokens do not interfere with each other.
Metering application processing and functionality, HAN interface commands and attributes,
WAN interface commands and attributes are outside the scope of this document; however,
reference is made to other standards in this regard.
The mechanism for auditing and retrieving data from the meter relating to tariffication, meter
readings, profile data and other legal metrology information is outside the scope of this
document; however, this is defined as part of any overall metering solution. Such interfaces for
retrieving data from a meter may be defined using suitable protocols such as DLMS/COSEM as
defined in the IEC 62056 series.

Messung der elektrischen Energie - Zählersysteme mit Inkassofunktion - Teil 42: Transaktionsreferenznummern (TRN)

Comptage de l’électricité - Systèmes de paiement - Partie 42: Numéros de référence des transactions (TRN)

IEC 62055-42:2022, spécifie un mécanisme de génération de jetons ainsi que la structure de jetons associée à la fonctionnalité de prépaiement intelligent, destinée aux marchés où les systèmes conformes à l’IEC 62055-41 ne sont pas utilisés et lorsque les exigences nationales ou spécifiques à un projet imposent l’utilisation d’un autre mécanisme de sécurité. Le présent document spécifie la structure des jetons, leur authentification, un mécanisme antirediffusion, le modèle d’exploitation des jetons et le protocole associé.
Le présent document est informé par les services de gestion de clés de la STS Association ainsi que par les mécanismes de gestion de clés utilisés dans le modèle de sécurité DLMS/COSEM spécifié dans l’IEC 62056-6-2. Une référence est faite aux normes internationales relatives aux jetons STS (IEC 62055-41, IEC 62055-51 et IEC 62055-52) pour les systèmes de comptage à paiement, et l’interconnexion a été envisagée le cas échéant en ce qui concerne les plages des supports de jetons dans le domaine décimal. Les jetons conformes à l’IEC 62055-41 et ceux décrits dans le présent document ne sont pas interopérables, mais leurs domaines sont conçus pour être mutuellement exclusifs afin d’assurer que les deux types de jetons n’interfèrent pas l’un avec l’autre.
Le traitement et la fonctionnalité des applications de comptage ainsi que les commandes et attributs des interfaces HAN et WAN ne relèvent pas du domaine d’application du présent document. Une référence est toutefois faite à d’autres normes traitant de ces aspects.
Le mécanisme d’audit et de récupération des données du compteur relatives à la tarification, des relevés de compteurs, des données sur les profils et autres informations métrologiques légales ne relève pas du domaine d’application du présent document. Il est cependant défini dans le cadre de toute solution de comptage globale. Il est permis de définir de telles interfaces pour la récupération des données d’un compteur en utilisant des protocoles adaptés, tels que DLMS/COSEM défini dans la série IEC 62056.

Merjenje električne energije - Plačilni sistemi - 42. del: Referenčne vrednosti transakcij (TRN)

Ta dokument določa mehanizem za ustvarjanje žetonov in strukturo žetonov za funkcionalnost pametnega predplačila na trgih, kjer se ne uporabljajo sistemi, skladni s standardom IEC 62055-41, in kjer imajo zaradi projektnih ali nacionalnih zahtev drugačen varnostni mehanizem. Ta dokument določa strukturo žetona, potrjevanje pristnosti in mehanizem za preprečevanje ponovnega predvajanja, operacijski model žetona in protokol. Ta dokument temelji na storitvah upravljanja ključev Združenja STS in mehanizmih upravljanja ključev, ki se uporabljajo v varnostnem modelu DLMS/COSEM v okviru standarda IEC 62056 6 2. Dokument se sklicuje na mednarodne standarde za žetone STS (IEC 62055-41, IEC 62055-51 in IEC 62055-52) za sisteme merjenja plačil, medsebojno delovanje pa je bilo upoštevano, kjer je to primerno, v smislu razponov nosilcev žetonov v decimalni domeni. Žetoni iz standarda IEC 62055-41 in žetoni, opisani v tem dokumentu, niso interoperabilni. Njihove domene so zasnovane tako, da se medsebojno izključujejo, kar zagotavlja, da obe vrsti žetonov ne motita druga druge. Obdelava in funkcionalnost aplikacije za merjenje, ukazi in atributi vmesnika HAN, ukazi in atributi vmesnika WAN ne spadajo na področje uporabe tega dokumenta, vendar obstaja v zvezi s tem sklic na druge standarde. Mehanizem za revizijo in pridobivanje podatkov iz števca v zvezi s tarifiranjem, odčitki števcev, profilnimi podatki in drugimi pravnimi meroslovnimi informacijami, ne spada na področje uporabe tega dokumenta, vendar je našteto opredeljeno kot del vseh celovitih rešitev merjenja. Taki vmesniki za pridobivanje podatkov iz števca se lahko definirajo z uporabo ustreznih protokolov, npr. DLMS/COSEM, kot je opredeljeno v skupini standardov IEC 62056.

General Information

Status
Published
Publication Date
19-Oct-2022
Current Stage
6060 - National Implementation/Publication (Adopted Project)
Start Date
12-Oct-2022
Due Date
17-Dec-2022
Completion Date
20-Oct-2022

Buy Standard

Standard
EN IEC 62055-42:2022 - BARVE
English language
84 pages
sale 10% off
Preview
sale 10% off
Preview
e-Library read for
1 day

Standards Content (Sample)

SLOVENSKI STANDARD
SIST EN IEC 62055-42:2022
01-november-2022
Merjenje električne energije - Plačilni sistemi - 42. del: Referenčne vrednosti
transakcij (TRN)
Electricity metering - Payment systems - Part 42: Transaction Reference Numbers (TRN)
Ta slovenski standard je istoveten z: EN IEC 62055-42:2022
ICS:
17.220.20 Merjenje električnih in Measurement of electrical
magnetnih veličin and magnetic quantities
91.140.50 Sistemi za oskrbo z elektriko Electricity supply systems
SIST EN IEC 62055-42:2022 en
2003-01.Slovenski inštitut za standardizacijo. Razmnoževanje celote ali delov tega standarda ni dovoljeno.

---------------------- Page: 1 ----------------------
SIST EN IEC 62055-42:2022

---------------------- Page: 2 ----------------------
SIST EN IEC 62055-42:2022


EUROPEAN STANDARD EN IEC 62055-42

NORME EUROPÉENNE

EUROPÄISCHE NORM September 2022
ICS 17.220.20; 35.100.70; 91.140.50

English Version
Electricity metering - Payment systems - Part 42: Transaction
Reference Numbers (TRN)
(IEC 62055-42:2022)
Comptage de l'électricité - Systèmes de paiement - Partie Messung der elektrischen Energie - Zählersysteme mit
42: Numéros de référence des transactions (TRN) Inkassofunktion - Teil 42: Transaktionsreferenznummern
(IEC 62055-42:2022) (TRN)
(IEC 62055-42:2022)
This European Standard was approved by CENELEC on 2022-08-17. CENELEC members are bound to comply with the CEN/CENELEC
Internal Regulations which stipulate the conditions for giving this European Standard the status of a national standard without any alteration.
Up-to-date lists and bibliographical references concerning such national standards may be obtained on application to the CEN-CENELEC
Management Centre or to any CENELEC member.
This European Standard exists in three official versions (English, French, German). A version in any other language made by translation
under the responsibility of a CENELEC member into its own language and notified to the CEN-CENELEC Management Centre has the
same status as the official versions.
CENELEC members are the national electrotechnical committees of Austria, Belgium, Bulgaria, Croatia, Cyprus, the Czech Republic,
Denmark, Estonia, Finland, France, Germany, Greece, Hungary, Iceland, Ireland, Italy, Latvia, Lithuania, Luxembourg, Malta, the
Netherlands, Norway, Poland, Portugal, Republic of North Macedonia, Romania, Serbia, Slovakia, Slovenia, Spain, Sweden, Switzerland,
Türkiye and the United Kingdom.


European Committee for Electrotechnical Standardization
Comité Européen de Normalisation Electrotechnique
Europäisches Komitee für Elektrotechnische Normung
CEN-CENELEC Management Centre: Rue de la Science 23, B-1040 Brussels
© 2022 CENELEC All rights of exploitation in any form and by any means reserved worldwide for CENELEC Members.
 Ref. No. EN IEC 62055-42:2022 E

---------------------- Page: 3 ----------------------
SIST EN IEC 62055-42:2022
EN IEC 62055-42:2022 (E)
European foreword
The text of document 13/1843/CDV, future edition 1 of IEC 62055-42, prepared by IEC/TC 13
"Electrical energy measurement and control" was submitted to the IEC-CENELEC parallel vote and
approved by CENELEC as EN IEC 62055-42:2022.
The following dates are fixed:
• latest date by which the document has to be implemented at national (dop) 2023-05-17
level by publication of an identical national standard or by endorsement
• latest date by which the national standards conflicting with the (dow) 2025-08-17
document have to be withdrawn

Attention is drawn to the possibility that some of the elements of this document may be the subject of
patent rights. CENELEC shall not be held responsible for identifying any or all such patent rights.
Any feedback and questions on this document should be directed to the users’ national committee. A
complete listing of these bodies can be found on the CENELEC website.
Endorsement notice
The text of the International Standard IEC 62055-42:2022 was approved by CENELEC as a European
Standard without any modification.
In the official version, for Bibliography, the following notes have to be added for the standards
indicated:
IEC 62056-4-7:2015 NOTE Harmonized as EN 62056-4-7:2016 (not modified)
IEC 62056-6-1 NOTE Harmonized as EN 62056-6-1
IEC 62056-6-2 NOTE Harmonized as EN IEC 62056-6-2
IEC 62056-21 NOTE Harmonized as EN 62056-21
IEC 62056-42 NOTE Harmonized as EN 62056-42
IEC 62056-46 NOTE Harmonized as EN 62056-46
2

---------------------- Page: 4 ----------------------
SIST EN IEC 62055-42:2022
EN IEC 62055-42:2022 (E)
Annex ZA
(normative)

Normative references to international publications
with their corresponding European publications
The following documents are referred to in the text in such a way that some or all of their content
constitutes requirements of this document. For dated references, only the edition cited applies. For
undated references, the latest edition of the referenced document (including any amendments)
applies.
NOTE 1 Where an International Publication has been modified by common modifications, indicated by (mod), the
relevant EN/HD applies.
NOTE 2 Up-to-date information on the latest versions of the European Standards listed in this annex is available
here: www.cenelec.eu.
Publication Year Title EN/HD Year
IEC 60050-300 2001 International Electrotechnical Vocabulary - - -
Electrical and electronic measurements
and measuring instruments - Part 311:
General terms relating to measurements -
Part 312: General terms relating to
electrical measurements - Part 313: Types
of electrical measuring instruments - Part
314: Specific terms according to the type of
instrument
+ AMD1 2015  - -
+ AMD2 2016  - -
+ AMD3 2017  - -
+ AMD4 2020  - -
IEC/TR 62051 1999 Electricity metering - Glossary of terms - -
IEC/TR 62055-21 2005 Electricity metering - Payment systems - - -
Part 21: Framework for standardization
IEC 62055-31 2005 Electricity metering - Payment systems - EN 62055-31 2005
Part 31: Particular requirements - Static
payment meters for active energy (classes
1 and 2)
IEC 62055-41 2018 Electricity metering - Payment systems - - -
Part 41: Standard transfer specification
(STS) - Application layer protocol for one-
way token carrier systems
IEC 62056-5-3 2017 Electricity metering data exchange - The EN 62056-5-3 2017
DLMS/COSEM suite - Part 5-3:
DLMS/COSEM application layer
IEEE EUI 64 - https://standards.ieee.org/develop/regauth/ - -
tut/eui64.pdf
- 1975 Verhoeff, J, Error Detecting Decimal - -
Codes, (Tract 29)
3

---------------------- Page: 5 ----------------------
SIST EN IEC 62055-42:2022
EN IEC 62055-42:2022 (E)
NIST SP 800-38D - Recommendation for Block Cipher Modes - -
of Operation: Galois/Counter Mode (GCM)
and GMAC

4

---------------------- Page: 6 ----------------------
SIST EN IEC 62055-42:2022




IEC 62055-42

®


Edition 1.0 2022-07




INTERNATIONAL



STANDARD




NORME


INTERNATIONALE
colour

inside










Electricity metering – Payment systems –

Part 42: Transaction Reference Numbers (TRN)



Comptage de l’électricité – Systèmes de paiement –

Partie 42: Numéros de référence des transactions (TRN)
















INTERNATIONAL

ELECTROTECHNICAL

COMMISSION


COMMISSION

ELECTROTECHNIQUE


INTERNATIONALE




ICS 17.220.20, ICS 35.100.70, ICS 91.140.50 ISBN 978-2-8322-3951-3




Warning! Make sure that you obtained this publication from an authorized distributor.

Attention! Veuillez vous assurer que vous avez obtenu cette publication via un distributeur agréé.

® Registered trademark of the International Electrotechnical Commission
Marque déposée de la Commission Electrotechnique Internationale

---------------------- Page: 7 ----------------------
SIST EN IEC 62055-42:2022
– 2 – IEC 62055-42:2022 © IEC 2022
CONTENTS
FOREWORD . 7
INTRODUCTION . 9
1 Scope . 10
2 Normative references . 10
3 Terms, definitions, abbreviated terms and notation . 11
3.1 Terms and definitions . 11
3.2 Abbreviated terms . 12
3.3 Notation . 13
4 Numbering conventions in this document . 13
5 Reference smart meter model . 13
5.1 Generic functional reference diagram . 13
5.2 Token transfer protocol reference model . 15
5.3 Dataflow from the POSApplicationProcess to the TokenCarrier . 16
5.4 Dataflow from the TokenCarrier to the MeterApplicationProcess . 16
5.5 MeterFunctionObjects / companion specifications . 17
6 POSToTokenCarrierInterface application layer protocol . 17
6.1 APDU: ApplicationProtocolDataUnit . 17
6.1.1 Data elements in the APDU . 17
6.1.2 SupplierID . 19
6.1.3 MeterID . 19
6.1.4 TokenOriginationID . 19
6.1.5 MessageIdentifier . 19
6.1.6 SequentialTokenNumber (STN) . 21
6.1.7 TruncatedSequentialTokenNumber (TSTN) . 21
6.1.8 Deducing the MS part of STN and validating TSTN . 21
6.1.9 FunctionIndex . 24
6.1.10 Relating the FunctionIndex and STN . 25
6.1.11 SingleTokenPayload . 27
6.1.12 SuperTokenPayload . 27
6.1.13 MessageAuthenticationCode (MAC) and TruncatedMAC (TMAC) . 27
6.1.14 AdditionalAuthenticationData (AAD). 30
6.1.15 SingleTokenPayload AAD preparation, TMAC derivation and APDU
preparation . 30
6.1.16 SuperTokenPayload AAD preparation, TMAC derivation and APDU
preparation . 31
6.1.17 Offset . 34
6.2 Tokens . 34
6.2.1 Token definition and format . 34
6.2.2 Class 4: RESERVED FOR FUTURE ASSIGNMENT . 35
6.2.3 Class 5 tokens . 35
6.2.4 Class 5: Unencrypted tokens . 39
6.2.5 Class 5: Encrypted tokens . 41
6.3 Token data elements. 47
6.4 TCDU Generation functions . 47
6.5 Security functions . 49
6.5.1 General requirements . 49
6.5.2 Key management . 49

---------------------- Page: 8 ----------------------
SIST EN IEC 62055-42:2022
IEC 62055-42:2022 © IEC 2022 – 3 –
6.5.3 Key deriviation . 50
6.5.4 Encryption process . 50
7 TokenCarriertoMeterInterface application layer protocol . 50
7.1 APDU: ApplicationProtocolDataUnit . 50
7.1.1 Data elements in the APDU . 50
7.1.2 TokenData . 50
7.1.3 AuthenticationResult . 50
7.1.4 ValidationResult . 51
7.1.5 TokenResult . 51
7.2 APDU Extraction processes . 52
7.2.1 APDU Extraction process for Class 5 tokens . 52
7.2.2 APDU Extraction process for SubClass 0 unencrypted token . 53
7.2.3 APDU Extraction process for SubClass 8 encrypted token . 53
7.3 Security functions . 54
7.3.1 Key attributes and key changes . 54
7.3.2 Decryption algorithm . 55
7.3.3 TokenAuthentication . 55
7.3.4 TokenValidation . 55
7.3.5 TokenResult . 55
8 MeterApplicationProcess requirements . 56
8.1 General requirements . 56
8.2 Token acceptance/rejection . 56
8.3 Display indicators and markings . 57
8.4 TransferCredit tokens . 57
8.5 Engineering/SpecialFunction tokens . 57
9 KMS: KeyManagementSystem generic requirements . 58
10 Maintenance of unassigned entities . 58
Annex A (informative)  Verhoeff code implementation example . 59
A.1 Sample code . 59
Annex B (informative)  Example of ExtendedTransferCredit . 61
B.1 Class 5: SubClass 10: TransferCredit + Tariff . 61
B.1.1 General . 61
B.1.2 Block sequence/SuperTokenBlockToFollow . 61
B.1.3 Complete tariff . 62
B.1.4 Tariff sub-information. 62
B.1.5 Tariff activation month . 62
B.1.6 Tariff data . 63
B.1.7 Tariff types . 63
B.1.8 Tariff sub-information. 63
B.2 Class 5, SubClass 10, tariff type 0: TransferCredit + slab or time-of-use tariff . 64
B.2.1 Class 5, SubClass 10, tariff type 0, sub-type 0: TransferCredit + slab

tariff . 64
B.2.2 Number of slab boundaries . 65
B.2.3 Slab scaling . 65
B.2.4 Slab field size . 65
B.2.5 Slab value . 66
B.2.6 Class 5, SubClass 10, tariff type 0, sub-type 1: TransferCredit + time of

use (TOU) tariff . 66
B.2.7 Week definition . 66

---------------------- Page: 9 ----------------------
SIST EN IEC 62055-42:2022
– 4 – IEC 62055-42:2022 © IEC 2022
B.2.8 Time period definitions . 67
B.2.9 Register definitions . 68
B.3 Class 5, SubClass 10, tariff type 1: TransferCredit + rate prices or fixed
charge price token format . 68
B.3.1 Class 5, SubClass 10, tariff type 1: tariff sub-information . 68
B.3.2 Class 5, SubClass 10, tariff type 1, sub-type 0: TransferCredit + rate
prices . 68
B.3.3 Class 5, SubClass 10, tariff type 1: tariff sub-information . 69
B.3.4 Number of rate prices . 69
B.3.5 Rate price multiplier . 70
B.3.6 Rate price field size . 70
B.3.7 Rate price value . 70
B.3.8 Class 5, SubClass 10, tariff type 1, sub type 1: TransferCredit + fixed
charge prices . 71
B.3.9 Number of fixed charge prices . 71
B.3.10 Fixed charge price multiplier . 72
B.3.11 Fixed charge price field size . 72
B.3.12 Fixed charge application . 72
B.3.13 Fixed charge price value . 72
B.4 Class 5, SubClass 10, tariff type 2: TransferCredit + electricity duty (ED)
token format . 72
B.4.1 Electricity duty (ED) . 72
B.4.2 Electricity duty on energy charges . 73
B.4.3 Electricity duty on fixed charges . 73
B.4.4 Number of electricity duty slabs . 73
B.4.5 Electricity duty rate . 73
B.4.6 Electricity duty slab size . 74
B.5 SubClass 0 TCDU generation detailed process . 75
B.6 SubClass 8 TCDU generation detailed process . 75
B.7 SubClass 10 TCDU generation detailed process . 76
B.8 SubClass 10 APDU extraction detailed process . 77
Bibliography . 80

Figure 1 – Functional block diagram of a generic payment meter . 14
Figure 2 – Reference model as a 2-layer collapsed OSI protocol stack . 15
Figure 3 – Generic model of POSApplicationProcess to TokenCarrier . 16
Figure 4 – Dataflow from the TokenCarrier to the MeterApplicationProcess . 16
Figure 5 – Generic data elements for AAD payload construction for
SingleTokenPayload . 28
Figure 6 – Generic data elements for AAD payload construction for
SuperTokenPayload . 29
Figure 7 – InitializationVector (IV) construction . 29
Figure 8 – GMAC construction . 30
Figure 9 – Class 5 SubClass 8 TMAC derivation and full APDU preparation example. 31
Figure 10 – Class 5 SubClass 10 TMAC derivation and full APDU preparation example . 33
Figure 11 – TCDU generation for SubClass 0 unencrypted tokens . 48
Figure 12 – TCDU generation for SubClass 8 encrypted tokens . 49
Figure 13 – APDU extraction process for SubClass 0 tokens . 53

---------------------- Page: 10 ----------------------
SIST EN IEC 62055-42:2022
IEC 62055-42:2022 © IEC 2022 – 5 –
Figure 14 – APDU extraction process for SubClass 8 tokens . 54
Figure B.1 – TCDU generation process for SubClass 0 . 75
Figure B.2 – TCDU generation process for SubClass 8 . 76
Figure B.3 – TCDU generation process for SubClass 10 . 77
Figure B.4 – APDU extraction process for SubClass 10 . 78

Table 1 – Basic and derived elements of APDU and TCDU construction . 17
Table 2 – SubClass-wise MessageIdentifier detail and SubClass Functional Class . 20
Table 3 – Example of defining L and U for each SubClass . 22
N N
Table 4 – Process of validating STN and deducing MS(N) . 23
Table 5 – Last accepted token example(a) . 23
Table 6 – Last accepted token example(b) . 23
Table 7 – Last accepted token example(c) . 24
Table 8 – Last accepted token example(d) . 24
Table 9 – Numeric constants and their purpose . 34
Table 10 – Token definition and format . 35
Table 11 – Class 5 SubClass assignment . 36
Table 12 –SubClass-wise boundaries for Class 5 APDU before encryption . 37
Table 13 – SubClass-wise boundaries for Class 5 tokens, TCDU after encryption (if
applicable) and adding offset (without CheckDigit) . 37
Table 14 – Class 5 SubClass boundaries for TCDU (reserved space) . 38
Table 15 – SubClass related FunctionalClass and associated use cases . 39
Table 16 – SubClass 0: TransferCredit token . 40
Table 17 – SubClass 8: TransferCredit token . 41
Table 18 – Class 5, SubClass 9: SpecialFunction token . 41
Table 19 – Service types . 42
Table 20 – Block 1 of TransferCredit + Function token . 43
Table 21 – Block 2 to N-1 of N (N > 2) TransferCredit + Function token . 44
Table 22 – Last block TransferCredit + Function token. 44
Table 23 – Block 1 for Class 5 SubClass 11 meter generated token structure . 45
Table 24 – Block 2 for Class 5 SubClass 11 meter generated token structure . 45
Table 25 – Token data elements . 47
Table 26 – Data elements in the APDU . 50
Table 27 – Possible values for AuthenticationResult . 51
Table 28 – Possible values for ValidationResult . 51
Table 29 – Possible values for TokenResult . 52
Table B.1 – Block 1 of TransferCredit + tariff token . 61
Table B.2 – Block 2 of TransferCredit + Tariff token . 61
Table B.3 – Block 3 of TransferCredit + Tariff token . 63
Table B.4 – Block 4 of TransferCredit + Tariff token . 63
Table B.5 – Tariff types . 63
Table B.6 – Details of tariff sub-information . 64
Table B.7 – Block 2 for class 5, SubClass 10, tariff type 0, sub-type 0

(TransferCredit + slab tariff) . 64

---------------------- Page: 11 ----------------------
SIST EN IEC 62055-42:2022
– 6 – IEC 62055-42:2022 © IEC 2022
Table B.8 – Block 2 for Class 5, SubClass 10, tariff type 0, sub-type 0
(TransferCredit + slab tariff) – tariff data part . 65
Table B.9 – Block 3 for class 5, SubClass 10, tariff type 0, sub-type 0

(TransferCredit + slab tariff) . 66
Table B.10 – Block 2 for class 5, SubClass 10, tarif
...

Questions, Comments and Discussion

Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.