OPC Unified Architecture - Part 6: Mappings

IEC 62541-6:2020 is available as IEC 62541-6:2020 RLV which contains the International Standard and its Redline version, showing all changes of the technical content compared to the previous edition.
IEC 62541-6:2020 specifies the OPC Unified Architecture (OPC UA) mapping between the security model described in IEC TR 62541-2, the abstract service definitions specified in IEC 62541-4, the data structures defined in IEC 62541-5 and the physical network protocols that can be used to implement the OPC UA specification. This third edition cancels and replaces the second edition published in 2015. This edition constitutes a technical revision. This edition includes the following significant technical changes with respect to the previous edition:
a) Encodings:
• added JSON encoding for PubSub (non-reversible);
• added JSON encoding for Client/Server (reversible);
• added support for optional fields in structures;
• added support for Unions.
b) Transport mappings:
• added WebSocket secure connection – WSS;
• added support for reverse connectivity;
• added support for session-less service invocation in HTTPS.
c) Deprecated Transport (missing support on most platforms):
• SOAP/HTTP with WS-SecureConversation (all encodings).
d) Added mapping for JSON Web Token.
e) Added support for Unions to NodeSet Schema.
f) Added batch operations to add/delete nodes to/from NodeSet Schema.
g) Added support for multi-dimensional arrays outside of Variants.
h) Added binary representation for Decimal data types.
i) Added mapping for an OAuth2 Authorization Framework.

Architecture unifiée OPC - Partie 6: Mappings

IEC 62541-6:2020 est disponible sous forme de IEC 62541-6:2020 RLV qui contient la Norme internationale et sa version Redline, illustrant les modifications du contenu technique depuis l'édition précédente.
L'IEC 62541-6:2020 spécifie les mappings de l'Architecture unifiée OPC (OPC UA) entre le modèle de sécurité décrit dans l'IEC TR 62541 2, les définitions de services abstraits spécifiées dans l'IEC 62541 4, les structures de données définies dans l'IEC 62541 5 et les protocoles de réseaux physiques qui peuvent être utilisés pour mettre en œuvre la spécification OPC UA. Cette troisième édition annule et remplace la deuxième édition parue en 2015. Cette édition constitue une révision technique. Cette édition inclut les modifications techniques majeures suivantes par rapport à l'édition précédente:
a) codages:
• ajout du codage JSON pour PubSub (irréversible);
• ajout du codage JSON pour le Client/Serveur (réversible);
• ajout de la prise en charge des champs facultatifs dans les structures;
• ajout de la prise en charge des Unions;
b) mappings de transport:
• ajout de la connexion sécurisée WebSocket (WSS);
• ajout de la prise en charge de la connectivité inversée;
• ajout de la prise en charge de l'invocation de service sans session dans HTTPS;
c) transport déconseillé (absence de prise en charge sur la plupart des plateformes):
• SOAP/HTTP avec WS-SecureConversation (tous les codages);
d) ajout du mapping pour JSON Web Token;
e) ajout de la prise en charge des Unions pour le Schéma de NodeSet;
f) ajout d'opérations par lots permettant d'ajouter/de supprimer des nœuds au niveau du Schéma de NodeSet;
g) ajout de la prise en charge des matrices multidimensionnelles à l'extérieur des Variantes;
h) ajout d'une représentation binaire pour les types de données Décimaux;
i) ajout du mapping pour le Cadre d'autorisation OAuth2.

General Information

Status
Published
Publication Date
12-Jul-2020
Current Stage
PPUB - Publication issued
Completion Date
13-Jul-2020
Ref Project

Buy Standard

Standard
IEC 62541-6:2020 - OPC Unified Architecture - Part 6: Mappings
English and French language
237 pages
sale 15% off
Preview
sale 15% off
Preview

Standards Content (sample)

IEC 62541-6
Edition 3.0 2020-07
INTERNATIONAL
STANDARD
NORME
INTERNATIONALE
colour
inside
OPC unified architecture –
Part 6: Mappings
Architecture unifiée OPC –
Partie 6: Mappings
IEC 62541-6:2020-07(en-fr)
---------------------- Page: 1 ----------------------
THIS PUBLICATION IS COPYRIGHT PROTECTED
Copyright © 2020 IEC, Geneva, Switzerland

All rights reserved. Unless otherwise specified, no part of this publication may be reproduced or utilized in any form

or by any means, electronic or mechanical, including photocopying and microfilm, without permission in writing from

either IEC or IEC's member National Committee in the country of the requester. If you have any questions about IEC

copyright or have an enquiry about obtaining additional rights to this publication, please contact the address below or

your local IEC member National Committee for further information.

Droits de reproduction réservés. Sauf indication contraire, aucune partie de cette publication ne peut être reproduite

ni utilisée sous quelque forme que ce soit et par aucun procédé, électronique ou mécanique, y compris la photocopie

et les microfilms, sans l'accord écrit de l'IEC ou du Comité national de l'IEC du pays du demandeur. Si vous avez des

questions sur le copyright de l'IEC ou si vous désirez obtenir des droits supplémentaires sur cette publication, utilisez

les coordonnées ci-après ou contactez le Comité national de l'IEC de votre pays de résidence.

IEC Central Office Tel.: +41 22 919 02 11
3, rue de Varembé info@iec.ch
CH-1211 Geneva 20 www.iec.ch
Switzerland
About the IEC

The International Electrotechnical Commission (IEC) is the leading global organization that prepares and publishes

International Standards for all electrical, electronic and related technologies.
About IEC publications

The technical content of IEC publications is kept under constant review by the IEC. Please make sure that you have the

latest edition, a corrigendum or an amendment might have been published.

IEC publications search - webstore.iec.ch/advsearchform Electropedia - www.electropedia.org

The advanced search enables to find IEC publications by a The world's leading online dictionary on electrotechnology,

variety of criteria (reference number, text, technical containing more than 22 000 terminological entries in English

committee,…). It also gives information on projects, replaced and French, with equivalent terms in 16 additional languages.

and withdrawn publications. Also known as the International Electrotechnical Vocabulary

(IEV) online.
IEC Just Published - webstore.iec.ch/justpublished

Stay up to date on all new IEC publications. Just Published IEC Glossary - std.iec.ch/glossary

details all new publications released. Available online and 67 000 electrotechnical terminology entries in English and

once a month by email. French extracted from the Terms and Definitions clause of

IEC publications issued since 2002. Some entries have been

IEC Customer Service Centre - webstore.iec.ch/csc collected from earlier publications of IEC TC 37, 77, 86 and

If you wish to give us your feedback on this publication or CISPR.
need further assistance, please contact the Customer Service
Centre: sales@iec.ch.
A propos de l'IEC

La Commission Electrotechnique Internationale (IEC) est la première organisation mondiale qui élabore et publie des

Normes internationales pour tout ce qui a trait à l'électricité, à l'électronique et aux technologies apparentées.

A propos des publications IEC

Le contenu technique des publications IEC est constamment revu. Veuillez vous assurer que vous possédez l’édition la

plus récente, un corrigendum ou amendement peut avoir été publié.
Recherche de publications IEC - Electropedia - www.electropedia.org

webstore.iec.ch/advsearchform Le premier dictionnaire d'électrotechnologie en ligne au

La recherche avancée permet de trouver des publications IEC monde, avec plus de 22 000 articles terminologiques en

en utilisant différents critères (numéro de référence, texte, anglais et en français, ainsi que les termes équivalents dans

comité d’études,…). Elle donne aussi des informations sur les 16 langues additionnelles. Egalement appelé Vocabulaire

projets et les publications remplacées ou retirées. Electrotechnique International (IEV) en ligne.

IEC Just Published - webstore.iec.ch/justpublished Glossaire IEC - std.iec.ch/glossary

Restez informé sur les nouvelles publications IEC. Just 67 000 entrées terminologiques électrotechniques, en anglais

Published détaille les nouvelles publications parues. et en français, extraites des articles Termes et Définitions des

Disponible en ligne et une fois par mois par email. publications IEC parues depuis 2002. Plus certaines entrées

antérieures extraites des publications des CE 37, 77, 86 et
Service Clients - webstore.iec.ch/csc CISPR de l'IEC.
Si vous désirez nous donner des commentaires sur cette
publication ou si vous avez des questions contactez-nous:
sales@iec.ch.
---------------------- Page: 2 ----------------------
IEC 62541-6
Edition 3.0 2020-07
INTERNATIONAL
STANDARD
NORME
INTERNATIONALE
colour
inside
OPC unified architecture –
Part 6: Mappings
Architecture unifiée OPC –
Partie 6: Mappings
INTERNATIONAL
ELECTROTECHNICAL
COMMISSION
COMMISSION
ELECTROTECHNIQUE
INTERNATIONALE
ICS 25.040.40; 35.100.05 ISBN 978-2-8322-8596-1

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: 3 ----------------------
– 2 – IEC 62541-6:2020 © IEC 2020
CONTENTS

FOREWORD ........................................................................................................................... 8

1 Scope ............................................................................................................................ 11

2 Normative references .................................................................................................... 11

3 Terms, definitions, abbreviated terms and symbols ........................................................ 13

3.1 Terms and definitions ............................................................................................ 13

3.2 Abbreviated terms and symbols ............................................................................ 14

4 Overview ....................................................................................................................... 14

5 Data encoding ............................................................................................................... 16

5.1 General ................................................................................................................. 16

5.1.1 Overview ....................................................................................................... 16

5.1.2 Built-in Types ................................................................................................ 16

5.1.3 Guid .............................................................................................................. 17

5.1.4 ByteString ...................................................................................................... 17

5.1.5 ExtensionObject ............................................................................................ 17

5.1.6 Variant ........................................................................................................... 18

5.1.7 Decimal ......................................................................................................... 18

5.2 OPC UA Binary ..................................................................................................... 19

5.2.1 General ......................................................................................................... 19

5.2.2 Built-in Types ................................................................................................ 19

5.2.3 Decimal ......................................................................................................... 30

5.2.4 Enumerations ................................................................................................ 30

5.2.5 Arrays ............................................................................................................ 30

5.2.6 Structures ...................................................................................................... 31

5.2.7 Structures with optional fields ........................................................................ 33

5.2.8 Unions ........................................................................................................... 35

5.2.9 Messages ...................................................................................................... 36

5.3 OPC UA XML ........................................................................................................ 37

5.3.1 Built-in Types ................................................................................................ 37

5.3.2 Decimal ......................................................................................................... 43

5.3.3 Enumerations ................................................................................................ 43

5.3.4 Arrays ............................................................................................................ 44

5.3.5 Structures ...................................................................................................... 44

5.3.6 Structures with optional fields ........................................................................ 45

5.3.7 Unions ........................................................................................................... 45

5.3.8 Messages ...................................................................................................... 46

5.4 OPC UA JSON ...................................................................................................... 46

5.4.1 General ......................................................................................................... 46

5.4.2 Built-in Types ................................................................................................ 46

5.4.3 Decimal ......................................................................................................... 52

5.4.4 Enumerations ................................................................................................ 52

5.4.5 Arrays ............................................................................................................ 52

5.4.6 Structures ...................................................................................................... 53

5.4.7 Structures with optional fields ........................................................................ 53

5.4.8 Unions ........................................................................................................... 54

5.4.9 Messages ...................................................................................................... 54

6 Message SecurityProtocols ........................................................................................... 55

---------------------- Page: 4 ----------------------
IEC 62541-6:2020 © IEC 2020 – 3 –

6.1 Security handshake .............................................................................................. 55

6.2 Certificates ........................................................................................................... 56

6.2.1 General ......................................................................................................... 56

6.2.2 Application Instance Certificate...................................................................... 57

6.2.3 Certificate Chains .......................................................................................... 58

6.3 Time synchronization ............................................................................................ 58

6.4 UTC and International Atomic Time (TAI) .............................................................. 58

6.5 Issued User Identity Tokens .................................................................................. 58

6.5.1 Kerberos ........................................................................................................ 58

6.5.2 JSON Web Token (JWT) ................................................................................ 59

6.5.3 OAuth2 .......................................................................................................... 60

6.6 WS Secure Conversation ...................................................................................... 62

6.7 OPC UA Secure Conversation .............................................................................. 62

6.7.1 Overview ....................................................................................................... 62

6.7.2 MessageChunk structure ............................................................................... 62

6.7.3 MessageChunks and error handling ............................................................... 67

6.7.4 Establishing a SecureChannel ....................................................................... 67

6.7.5 Deriving keys ................................................................................................. 69

6.7.6 Verifying Message security ............................................................................ 70

7 TransportProtocols ........................................................................................................ 71

7.1 OPC UA Connection Protocol................................................................................ 71

7.1.1 Overview ....................................................................................................... 71

7.1.2 Message structure ......................................................................................... 72

7.1.3 Establishing a connection .............................................................................. 75

7.1.4 Closing a connection ..................................................................................... 77

7.1.5 Error handling ................................................................................................ 77

7.2 OPC UA TCP ........................................................................................................ 79

7.3 SOAP/HTTP .......................................................................................................... 79

7.4 OPC UA HTTPS .................................................................................................... 79

7.4.1 Overview ....................................................................................................... 79

7.4.2 Session-less Services .................................................................................... 81

7.4.3 XML Encoding ............................................................................................... 81

7.4.4 OPC UA Binary Encoding .............................................................................. 82

7.4.5 JSON Encoding ............................................................................................. 82

7.5 WebSockets .......................................................................................................... 83

7.5.1 Overview ....................................................................................................... 83

7.5.2 Protocol Mapping ........................................................................................... 84

7.5.3 Security ......................................................................................................... 84

7.6 Well known addresses .......................................................................................... 85

8 Normative Contracts ...................................................................................................... 86

8.1 OPC Binary Schema ............................................................................................. 86

8.2 XML Schema and WSDL ....................................................................................... 86

8.3 Information Model Schema .................................................................................... 86

8.4 Formal definition of UA Information Model............................................................. 86

8.5 Constants ............................................................................................................. 86

8.6 DataType encoding ............................................................................................... 86

8.7 Security configuration ........................................................................................... 86

Annex A (normative) Constants ............................................................................................ 87

A.1 Attribute Ids .......................................................................................................... 87

---------------------- Page: 5 ----------------------
– 4 – IEC 62541-6:2020 © IEC 2020

A.2 Status Codes ........................................................................................................ 87

A.3 Numeric Node Ids ................................................................................................. 88

Annex B (normative) OPC UA Nodeset ................................................................................ 89

Annex C (normative) Type declarations for the OPC UA native Mapping .............................. 90

Annex D (normative) WSDL for the XML Mapping ................................................................ 91

D.1 XML Schema ........................................................................................................ 91

D.2 WDSL Port Types ................................................................................................. 91

D.3 WSDL Bindings ..................................................................................................... 91

Annex E (normative) Security settings management ............................................................ 92

E.1 Overview............................................................................................................... 92

E.2 SecuredApplication ............................................................................................... 93

E.3 CertificateIdentifier ............................................................................................... 96

E.4 CertificateStoreIdentifier ....................................................................................... 98

E.5 CertificateList ........................................................................................................ 99

E.6 CertificateValidationOptions .................................................................................. 99

Annex F (normative) Information Model XML Schema ........................................................ 101

F.1 Overview............................................................................................................. 101

F.2 UANodeSet ......................................................................................................... 101

F.3 UANode .............................................................................................................. 103

F.4 Reference ........................................................................................................... 104

F.5 RolePermission ................................................................................................... 104

F.6 UAType ............................................................................................................... 104

F.7 UAInstance ......................................................................................................... 105

F.8 UAVariable ......................................................................................................... 105

F.9 UAMethod ........................................................................................................... 106

F.10 TranslationType .................................................................................................. 106

F.11 UADataType ....................................................................................................... 107

F.12 DataTypeDefinition ............................................................................................. 108

F.13 DataTypeField .................................................................................................... 108

F.14 Variant ................................................................................................................ 109

F.15 Example.............................................................................................................. 110

F.16 UANodeSetChanges ........................................................................................... 112

F.17 NodesToAdd ....................................................................................................... 113

F.18 ReferencesToChange ......................................................................................... 113

F.19 ReferenceToChange ........................................................................................... 114

F.20 NodesToDelete ................................................................................................... 114

F.21 NodeToDelete ..................................................................................................... 114

F.22 UANodeSetChangesStatus ................................................................................. 115

F.23 NodeSetStatusList .............................................................................................. 115

F.24 NodeSetStatus .................................................................................................... 115

Bibliography ........................................................................................................................ 117

Figure 1 – The OPC UA Stack Overview ............................................................................... 15

Figure 2 – Encoding Integers in a binary stream ................................................................... 20

Figure 3 – Encoding Floating Points in a binary stream ......................................................... 20

Figure 4 – Encoding Strings in a binary stream ..................................................................... 21

Figure 5 – Encoding Guids in a binary stream ....................................................................... 22

---------------------- Page: 6 ----------------------
IEC 62541-6:2020 © IEC 2020 – 5 –

Figure 6 – Encoding XmlElement in a binary stream ............................................................. 22

Figure 7 – A String NodeId .................................................................................................... 23

Figure 8 – A Two Byte NodeId .............................................................................................. 24

Figure 9 – A Four Byte NodeId .............................................................................................. 24

Figure 10 – Security handshake ............................................................................................ 55

Figure 11 – OPC UA Secure Conversation MessageChunk ................................................... 63

Figure 12 – OPC UA Connection Protocol Message structure ............................................... 72

Figure 13 – Client initiated OPC UA Connection Protocol connection .................................... 76

Figure 14 – Server initiated OPC UA Connection Protocol connection ................................... 76

Figure 15 – Closing a OPC UA Connection Protocol connection ........................................... 77

Figure 16 – Scenarios for the HTTPS Transport .................................................................... 80

Figure 17 – Setting up Communication over a WebSocket .................................................... 84

Table 1 – Built-in Data Types ................................................................................................ 16

Table 2 – Guid structure ....................................................................................................... 17

Table 3 – Layout of Decimal ................................................................................................. 19

Table 4 – Supported Floating Point Types ............................................................................. 20

Table 5 – NodeId components .............................................................................................. 22

Table 6 – NodeId DataEncoding values ................................................................................ 23

Table 7 – Standard NodeId Binary DataEncoding .................................................................. 23

Table 8 – Two Byte NodeId Binary DataEncoding ................................................................. 24

Table 9 – Four Byte NodeId Binary DataEncoding................................................................. 24

Table 10 – ExpandedNodeId Binary DataEncoding ............................................................... 25

Table 11 – DiagnosticInfo Binary DataEncoding .................................................................... 26

Table 12 – QualifiedName Binary DataEncoding ................................................................... 26

Table 13 – LocalizedText Binary DataEncoding .................................................................... 27

Table 14 – Extension Object Binary DataEncoding................................................................ 28

Table 15 – Variant Binary DataEncoding ............................................................................... 29

Table 16 – Data Value Binary DataEncoding ......................................................................... 30

Table 17 – Sample OPC UA Binary Encoded structure .......................................................... 32

Table 18 – Sample OPC UA Binary Encoded Structure with optional fields ........................... 34

Table 19 – Sample OPC UA Binary Encoded Structure ......................................................... 35

Table 20 – XML Data Type Mappings for Integers ................................................................. 37

Table 21 – XML Data Type Mappings for Floating Points ...................................................... 37

Table 22 – Components of NodeId ........................................................................................ 39

Table 23 – Components of ExpandedNodeId ........................................................................ 40

Table 24 – Components of Enumeration ............................................................................... 44

Table 25 – JSON Object Definition for a NodeId ................................................................... 48

Table 26 – JSON Object Definition for an ExpandedNodeId .................................................. 49

Table 27 – JSON Object Definition for a StatusCode ............................................................ 49

Table 28 – JSON Object Definition for a DiagnosticInfo ........................................................ 50

Table 29 – JSON Object Definition for a QualifiedName ........................................................ 50

Table 30 – JSON Object Definition for a LocalizedText ......................................................... 50

---------------------- Page: 7 ----------------------
– 6 – IEC 62541-6:2020 © IEC 2020

Table 31 – JSON Object Definition for an ExtensionObject ................................................... 51

Table 32 – JSON Object Definition for a Variant ................................................................... 51

Table 33 – JSON Object Definition for a DataValue .............................................................. 52

Table 34 – JSON Object Definition for a Decimal .................................................................. 52

Table 35 – JSON Object Definition for a Structure with Optional Fields ................................. 53

Table 36 – JSON Object Definition for a Union ..................................................................... 54

Table 37 – SecurityPolicy ..................................................................................................... 56

Table 38 – Application Instance Certificate ........................................................................... 57

Table 39 – Kerberos UserTokenPolicy .................................................................................. 59

Table 40 – JWT UserTokenPolicy ......................................................................................... 59

Table 41 – JWT IssuerEndpointUrl Definition ........................................................................ 60

Table 42 – Access Token Claims ...................................
...

Questions, Comments and Discussion

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