Initial commit

Signed-off-by: Gabor Szalai <gabor.szalai@ericsson.com>
diff --git a/5G_system_TS29503_Nudm_CNL113883.tpd b/5G_system_TS29503_Nudm_CNL113883.tpd
new file mode 100644
index 0000000..cd311c8
--- /dev/null
+++ b/5G_system_TS29503_Nudm_CNL113883.tpd
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<TITAN_Project_File_Information version="1.0">
+  <ProjectName>5G_system_TS29503_Nudm_CNL113883</ProjectName>
+  <ReferencedProjects>
+    <ReferencedProject name="5G_system_TS29509_Nausf_CNL113885" projectLocationURI="../5G_system_TS29509_Nausf_CNL113885/5G_system_TS29509_Nausf_CNL113885.tpd"/>
+    <ReferencedProject name="5G_system_TS29571_CommonData_CNL113880" projectLocationURI="../5G_system_TS29571_CommonData_CNL113880/5G_system_TS29571_CommonData_CNL113880.tpd"/>
+  </ReferencedProjects>
+  <Folders>
+    <FolderResource projectRelativePath="src" relativeURI="src"/>
+  </Folders>
+  <Files>
+    <FileResource projectRelativePath="src/TS29503_Nudm_EE.ttcn" relativeURI="src/TS29503_Nudm_EE.ttcn"/>
+    <FileResource projectRelativePath="src/TS29503_Nudm_PP.ttcn" relativeURI="src/TS29503_Nudm_PP.ttcn"/>
+    <FileResource projectRelativePath="src/TS29503_Nudm_SDM.ttcn" relativeURI="src/TS29503_Nudm_SDM.ttcn"/>
+    <FileResource projectRelativePath="src/TS29503_Nudm_UEAU.ttcn" relativeURI="src/TS29503_Nudm_UEAU.ttcn"/>
+    <FileResource projectRelativePath="src/TS29503_Nudm_UECM.ttcn" relativeURI="src/TS29503_Nudm_UECM.ttcn"/>
+  </Files>
+  <ActiveConfiguration>Default</ActiveConfiguration>
+  <Configurations>
+    <Configuration name="Default">
+      <ProjectProperties>
+        <MakefileSettings>
+          <GNUMake>true</GNUMake>
+          <incrementalDependencyRefresh>true</incrementalDependencyRefresh>
+          <targetExecutable>bin/5G_system_TS29503_Nudm_CNL113883</targetExecutable>
+        </MakefileSettings>
+        <LocalBuildSettings>
+          <workingDirectory>bin</workingDirectory>
+        </LocalBuildSettings>
+      </ProjectProperties>
+    </Configuration>
+  </Configurations>
+</TITAN_Project_File_Information>
\ No newline at end of file
diff --git a/doc/5G_system_TS29503_Nudm_Description.adoc b/doc/5G_system_TS29503_Nudm_Description.adoc
new file mode 100644
index 0000000..1b7cefd
--- /dev/null
+++ b/doc/5G_system_TS29503_Nudm_Description.adoc
@@ -0,0 +1,116 @@
+= 5G system TS29503 Nudm Protocol Modules for TTCN-3 Toolset with TITAN, Description
+:author: Gábor Szalai
+:toc: left
+
+== About This Document
+
+This is the description for the 5G system TS29503 Nudm protocol module. The 5G system TS29503 Nudm protocol modules are developed for the TTCN-3 Toolset with Titan. 
+
+== Functionality
+
+The 5G system TS29503 Nudm protocol module implements the object structures of the 3GPP TS 29503 v15.1.0<<_5, [5]>> in a formalized way, using the standard specification language TTCN-3. This allows defining of test data (templates) in the TTCN-3 language and correctly encoding/decoding messages when executing test suites using the Titan TTCN-3 test environment.
+The 5G system TS29503 Nudm protocol module uses Titan’s JSON encoding <<_3, [3]>> and hence is usable with the Titan test toolset only.
+
+=== System Requirements
+Protocol modules are a set of TTCN-3 source code files that can be used as part of TTCN-3 test suites only. Hence, protocol modules alone do not put specific requirements on the system used. However, in order to compile and execute a TTCN-3 test suite using the set of protocol modules the following system requirements must be satisfied:
+
+* Titan TTCN-3 Test Executor version CRL 113 200/6 R5A (6.5.pl0) or higher installed. For Installation Guide see <<_2, [2]>>. Please note: This version of the test port is not compatible with Titan releases earlier than CRL 113 200/6 R5A.
+
+===	Installation
+The set of protocol modules can be used in developing TTCN-3 test suites using any text editor. Since the 5G system TS29503 Nudm protocol is used as a part of a TTCN-3 test suite, this requires TTCN-3 Test Executor be installed before the module can be compiled and executed together with other parts of the test suite. For more details on the installation of TTCN-3 Test Executor see the relevant section of <<_2, [2]>>.
+
+== Interface description
+
+=== Encoding/decoding and other related functions
+This product also contains encoding/decoding functions, which assure correct encoding of messages when sent from Titan and correct decoding of messages when received by Titan. 
+
+==== Implemented encoding and decoding functions
+
+[source]
+----
+Name	Type of formal parameters	Type of return value
+f_enc_EeSubscription(in EeSubscription pdu) return octetstring 
+f_dec_EeSubscription(in octetstring stream, out EeSubscription pdu) return integer 
+f_enc_CreatedEeSubscription(in CreatedEeSubscription pdu) return octetstring 
+f_dec_CreatedEeSubscription(in octetstring stream, out CreatedEeSubscription pdu) return integer 
+f_enc_SubscriptionDataSets(in SubscriptionDataSets pdu) return octetstring 
+f_dec_SubscriptionDataSets(in octetstring stream, out SubscriptionDataSets pdu) return integer 
+f_enc_Nssai(in Nssai pdu) return octetstring 
+f_dec_Nssai(in octetstring stream, out Nssai pdu) return integer 
+f_enc_AccessAndMobilitySubscriptionData(in AccessAndMobilitySubscriptionData pdu) return octetstring 
+f_dec_AccessAndMobilitySubscriptionData(in octetstring stream, out AccessAndMobilitySubscriptionData pdu) return integer 
+f_enc_SmfSelectionSubscriptionData(in SmfSelectionSubscriptionData pdu) return octetstring 
+f_dec_SmfSelectionSubscriptionData(in octetstring stream, out SmfSelectionSubscriptionData pdu) return integer 
+f_enc_UeContextInSmfData(in UeContextInSmfData pdu) return octetstring 
+f_dec_UeContextInSmfData(in octetstring stream, out UeContextInSmfData pdu) return integer 
+f_enc_SmsSubscriptionData(in SmsSubscriptionData pdu) return octetstring 
+f_dec_SmsSubscriptionData(in octetstring stream, out SmsSubscriptionData pdu) return integer 
+f_enc_SmsManagementSubscriptionData(in SmsManagementSubscriptionData pdu) return octetstring 
+f_dec_SmsManagementSubscriptionData(in octetstring stream, out SmsManagementSubscriptionData pdu) return integer 
+f_enc_SdmSubscription(in SdmSubscription pdu) return octetstring 
+f_dec_SdmSubscription(in octetstring stream, out SdmSubscription pdu) return integer 
+f_enc_ModificationNotification(in ModificationNotification pdu) return octetstring 
+f_dec_ModificationNotification(in octetstring stream, out ModificationNotification pdu) return integer 
+f_enc_IdTranslationResult(in IdTranslationResult pdu) return octetstring 
+f_dec_IdTranslationResult(in octetstring stream, out IdTranslationResult pdu) return integer 
+f_enc_AcknowledgeInfo(in AcknowledgeInfo pdu) return octetstring 
+f_dec_AcknowledgeInfo(in octetstring stream, out AcknowledgeInfo pdu) return integer 
+f_enc_AuthenticationInfoRequest(in AuthenticationInfoRequest pdu) return octetstring 
+f_dec_AuthenticationInfoRequest(in octetstring stream, out AuthenticationInfoRequest pdu) return integer 
+f_enc_AuthenticationInfoResult(in AuthenticationInfoResult pdu) return octetstring 
+f_dec_AuthenticationInfoResult(in octetstring stream, out AuthenticationInfoResult pdu) return integer 
+f_enc_AuthEvent(in AuthEvent pdu) return octetstring 
+f_dec_AuthEvent(in octetstring stream, out AuthEvent pdu) return integer 
+f_enc_Amf3GppAccessRegistration(in Amf3GppAccessRegistration pdu) return octetstring 
+f_dec_Amf3GppAccessRegistration(in octetstring stream, out Amf3GppAccessRegistration pdu) return integer 
+f_enc_DeregistrationData(in DeregistrationData pdu) return octetstring 
+f_dec_DeregistrationData(in octetstring stream, out DeregistrationData pdu) return integer 
+f_enc_PcscfRestorationNotification(in PcscfRestorationNotification pdu) return octetstring 
+f_dec_PcscfRestorationNotification(in octetstring stream, out PcscfRestorationNotification pdu) return integer 
+f_enc_Amf3GppAccessRegistrationModification(in Amf3GppAccessRegistrationModification pdu) return octetstring 
+f_dec_Amf3GppAccessRegistrationModification(in octetstring stream, out Amf3GppAccessRegistrationModification pdu) return integer 
+f_enc_AmfNon3GppAccessRegistration(in AmfNon3GppAccessRegistration pdu) return octetstring 
+f_dec_AmfNon3GppAccessRegistration(in octetstring stream, out AmfNon3GppAccessRegistration pdu) return integer 
+f_enc_AmfNon3GppAccessRegistrationModification(in AmfNon3GppAccessRegistrationModification pdu) return octetstring 
+f_dec_AmfNon3GppAccessRegistrationModification(in octetstring stream, out AmfNon3GppAccessRegistrationModification pdu) return integer 
+f_enc_SmfRegistration(in SmfRegistration pdu) return octetstring 
+f_dec_SmfRegistration(in octetstring stream, out SmfRegistration pdu) return integer 
+f_enc_SmsfRegistration(in SmsfRegistration pdu) return octetstring 
+f_dec_SmsfRegistration(in octetstring stream, out SmsfRegistration pdu) return integer 
+----
+
+== Usage
+
+The protocol module provides abstract data types for JSON objects used by the services defined in the standard <<_5, [5]>>. The protocol module provides encoder and decoder functions for the JSON objects. The decoder validates the received JSON object based on the JSON schema as well. Only the validated JSON value is decoded.
+
+== Terminology	
+
+=== Abbreviations
+
+JSON:: JavaScript Object Notation
+
+PDU:: Protocol Data Unit
+
+TTCN-3:: Testing and Test Control Notation version 3
+
+== References
+
+[[_1]]
+[1]	ETSI ES 201 873-1 v4.4.1 (2012-04) +
+The Testing and Test Control Notation version 3. Part 1: Core Language
+
+[[_2]]
+[2]	1/ 198 17-CRL 113 200/6 Uen +
+Installation Guide for the TITAN TTCN-3 Test Executor
+
+[[_3]]
+[3]	2/198 17-CRL 113 200/6 Uen +
+Programmer's Technical Reference for Titan TTCN-3 Test Executor
+
+[[_4]]
+[4]	https://www.json.org
+
+[[_5]]
+[5] 3GPP TS 29503 v15.1.0+
+5G System; Unified Data Management Services; Stage 3
+
diff --git a/doc/change.log b/doc/change.log
new file mode 100644
index 0000000..fb84066
--- /dev/null
+++ b/doc/change.log
@@ -0,0 +1,9 @@
+= 5G system TS29503 Nudm Protocol Modules for TTCN-3 Toolset with TITAN, Change log

+:author: Gábor Szalai

+:toc: left

+

+== Changes

+

+=== R1A

+

+Initial revision
\ No newline at end of file
diff --git a/src/TS29503_Nudm_EE.ttcn b/src/TS29503_Nudm_EE.ttcn
new file mode 100644
index 0000000..dec6022
--- /dev/null
+++ b/src/TS29503_Nudm_EE.ttcn
@@ -0,0 +1,106 @@
+/******************************************************************************
+* Copyright (c) 2000-2019  Ericsson AB
+* All rights reserved. This program and the accompanying materials
+* are made available under the terms of the Eclipse Public License v2.0
+* which accompanies this distribution, and is available at
+* https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html
+*
+* Contributors:
+*   Gabor Szalai - initial implementation and initial documentation
+******************************************************************************/
+//
+//  File:               TS29503_Nudm_EE.ttcn
+//  Description:	      Type definitions for 3GPP TS29503
+/////////////////////////////////////////////// 
+module TS29503_Nudm_EE {
+
+  import from TS29571_CommonData all
+
+external function f_enc_EeSubscription(in EeSubscription pdu) return octetstring 
+with { extension "prototype(convert) encode(JSON)" }
+
+external function f_dec_EeSubscription(in octetstring stream, out EeSubscription pdu) return integer 
+with { extension "prototype(backtrack) decode(JSON)" }
+
+external function f_enc_CreatedEeSubscription(in CreatedEeSubscription pdu) return octetstring 
+with { extension "prototype(convert) encode(JSON)" }
+
+external function f_dec_CreatedEeSubscription(in octetstring stream, out CreatedEeSubscription pdu) return integer 
+with { extension "prototype(backtrack) decode(JSON)" }
+
+
+  type set CreatedEeSubscription {
+    EeSubscription    eeSubscription,
+    TS29571_CommonData.Uinteger    numberOfUes optional,
+    set of       MonitoringReport    eventReports optional
+  }
+
+  type set EeSubscription {
+    TS29571_CommonData.Uri    callbackReference,
+    set of record {
+      universal charstring key,
+      MonitoringConfiguration    additionalProperties
+    } monitoringConfiguration,
+    ReportingOptions    reportingOptions optional,
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional
+  } with {
+    variant (monitoringConfiguration) "as map"
+  }
+
+  type set MonitoringConfiguration {
+    ReferenceId    referenceId,
+    EventType    eventType,
+    boolean immediateFlag optional
+  }
+
+  type set ReportingOptions {
+    MaxNumOfReports    maxNumOfReports optional,
+    TS29571_CommonData.DateTime    monitoringDuration optional
+  }
+
+  type set MonitoringReport {
+    ReferenceId    referenceId optional,
+    EventType    eventType,
+    Report    report optional,
+    TS29571_CommonData.Gpsi    gpsi optional,
+    TS29571_CommonData.DateTime    timeStamp
+  }
+
+  type union Report {
+    ChangeOfSupiPeiAssociationReport    changeOfSupiPeiAssociationReport,
+    RoamingStatusReport    roamingStatusReport
+  } with {
+    variant "JSON: as value"
+  }
+
+
+  type set ChangeOfSupiPeiAssociationReport {
+    TS29571_CommonData.Pei    newPei
+  }
+
+  type set RoamingStatusReport {
+    boolean roaming,
+    TS29571_CommonData.PlmnId    newServingPlmn
+  }
+
+  type integer ReferenceId
+
+  type integer MaxNumOfReports
+
+  type enumerated EventType_enum { LOSS_OF_CONNECTIVITY, UE_REACHABILITY_FOR_DATA, UE_REACHABILITY_FOR_SMS, LOCATION_REPORTING, CHANGE_OF_SUPI_PEI_ASSOCIATION, ROAMING_STATUS, COMMUNICATION_FAILURE, AVAILABILITY_AFTER_DNN_FAILURE}
+
+  type union EventType {
+    EventType_enum  enum_val,
+    charstring           other_val
+  } with {
+    variant "JSON: as value"
+  }
+
+
+
+
+
+
+} with {
+  encode "JSON"
+}
diff --git a/src/TS29503_Nudm_PP.ttcn b/src/TS29503_Nudm_PP.ttcn
new file mode 100644
index 0000000..a7cdd2a
--- /dev/null
+++ b/src/TS29503_Nudm_PP.ttcn
@@ -0,0 +1,59 @@
+/******************************************************************************
+* Copyright (c) 2000-2019  Ericsson AB
+* All rights reserved. This program and the accompanying materials
+* are made available under the terms of the Eclipse Public License v2.0
+* which accompanies this distribution, and is available at
+* https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html
+*
+* Contributors:
+*   Gabor Szalai - initial implementation and initial documentation
+******************************************************************************/
+//
+//  File:               TS29503_Nudm_PP.ttcn
+//  Description:	      Type definitions for 3GPP TS29503
+/////////////////////////////////////////////// 
+module TS29503_Nudm_PP {
+
+  import from TS29571_CommonData all
+
+  external function f_enc_PpData(in PpData pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_PpData(in octetstring stream, out PpData pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+
+  type set PpData {
+    CommunicationCharacteristics    communicationCharacteristics optional,
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional
+  }
+
+  type set CommunicationCharacteristics {
+    PpSubsRegTimer    ppSubsRegTimer optional,
+    PpActiveTime    ppActiveTime optional,
+    PpDlPacketCount    ppDlPacketCount optional
+  }
+
+  type set PpSubsRegTimer {
+    TS29571_CommonData.DurationSec    subsRegTimer,
+    TS29571_CommonData.NfInstanceId    afInstanceId,
+    ReferenceId    referenceId
+  }
+
+  type set PpActiveTime {
+    TS29571_CommonData.DurationSec    activeTime,
+    TS29571_CommonData.NfInstanceId    afInstanceId,
+    ReferenceId    referenceId
+  }
+
+  type integer ReferenceId
+
+  type integer PpDlPacketCount
+
+
+
+
+
+} with {
+  encode "JSON"
+}
diff --git a/src/TS29503_Nudm_SDM.ttcn b/src/TS29503_Nudm_SDM.ttcn
new file mode 100644
index 0000000..423ab2f
--- /dev/null
+++ b/src/TS29503_Nudm_SDM.ttcn
@@ -0,0 +1,328 @@
+/******************************************************************************
+* Copyright (c) 2000-2019  Ericsson AB
+* All rights reserved. This program and the accompanying materials
+* are made available under the terms of the Eclipse Public License v2.0
+* which accompanies this distribution, and is available at
+* https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html
+*
+* Contributors:
+*   Gabor Szalai - initial implementation and initial documentation
+******************************************************************************/
+//
+//  File:               TS29503_Nudm_SDM.ttcn
+//  Description:	      Type definitions for 3GPP TS29503
+/////////////////////////////////////////////// 
+module TS29503_Nudm_SDM {
+
+  import from TS29571_CommonData all
+  import from TS29509_Nausf_SoRProtection all
+
+  external function f_enc_SubscriptionDataSets(in SubscriptionDataSets pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_SubscriptionDataSets(in octetstring stream, out SubscriptionDataSets pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_Nssai(in Nssai pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_Nssai(in octetstring stream, out Nssai pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_AccessAndMobilitySubscriptionData(in AccessAndMobilitySubscriptionData pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_AccessAndMobilitySubscriptionData(in octetstring stream, out AccessAndMobilitySubscriptionData pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_SmfSelectionSubscriptionData(in SmfSelectionSubscriptionData pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_SmfSelectionSubscriptionData(in octetstring stream, out SmfSelectionSubscriptionData pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_UeContextInSmfData(in UeContextInSmfData pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_UeContextInSmfData(in octetstring stream, out UeContextInSmfData pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_SmsSubscriptionData(in SmsSubscriptionData pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_SmsSubscriptionData(in octetstring stream, out SmsSubscriptionData pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_SmsManagementSubscriptionData(in SmsManagementSubscriptionData pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_SmsManagementSubscriptionData(in octetstring stream, out SmsManagementSubscriptionData pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_SdmSubscription(in SdmSubscription pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_SdmSubscription(in octetstring stream, out SdmSubscription pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_ModificationNotification(in ModificationNotification pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_ModificationNotification(in octetstring stream, out ModificationNotification pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_IdTranslationResult(in IdTranslationResult pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_IdTranslationResult(in octetstring stream, out IdTranslationResult pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_AcknowledgeInfo(in AcknowledgeInfo pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_AcknowledgeInfo(in octetstring stream, out AcknowledgeInfo pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+
+  type set of     DataSetName    DatasetNames
+
+  type set SubscriptionDataSets {
+    AccessAndMobilitySubscriptionData    amData optional,
+    SmfSelectionSubscriptionData    smfSelData optional,
+    UeContextInSmfData    uecSmfData optional,
+    UeContextInSmsfData    uecSmsfData optional,
+    SmsSubscriptionData    smsSubsData optional,
+    set of       SessionManagementSubscriptionData    smData optional,
+    TS29571_CommonData.TraceData    traceData optional,
+    SmsManagementSubscriptionData    smsMngData optional
+  }
+
+  type set UeContextInSmsfData {
+    SmsfInfo    smsfInfo3GppAccess optional,
+    SmsfInfo    smsfInfoNon3GppAccess optional
+  }
+
+  type set SmsfInfo {
+    TS29571_CommonData.NfInstanceId    smsfInstanceId,
+    TS29571_CommonData.PlmnId    plmnId
+  }
+
+  type set AccessAndMobilitySubscriptionData {
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    set of       TS29571_CommonData.Gpsi    gpsis optional,
+    set of       InternalGroupId    internalGroupIds optional,
+    TS29571_CommonData.Ambr    subscribedUeAmbr optional,
+    Nssai    nssai optional,
+    set of       TS29571_CommonData.RatType    ratRestrictions optional,
+    set of       TS29571_CommonData.Area    forbiddenAreas optional,
+    TS29571_CommonData.ServiceAreaRestriction    serviceAreaRestriction optional,
+    set of       TS29571_CommonData.CoreNetworkType    coreNetworkTypeRestrictions optional,
+    TS29571_CommonData.RfspIndex    rfspIndex optional,
+    TS29571_CommonData.DurationSec    subsRegTimer optional,
+    UeUsageType    ueUsageType optional,
+    MpsPriorityIndicator    mpsPriority optional,
+    TS29571_CommonData.DurationSec    activeTime optional,
+    DlPacketCount    dlPacketCount optional,
+    SorInfo    sorInfo optional,
+    MicoAllowed    micoAllowed optional,
+    SharedDataIds    sharedDataIds optional
+  }
+
+  type set SmfSelectionSubscriptionData {
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    set of       SnssaiInfo    subscribedSnssaiInfos optional
+  }
+
+  type set SnssaiInfo {
+    TS29571_CommonData.Snssai    singleNssai,
+    set of       DnnInfo    dnnInfos
+  }
+
+  type set DnnInfo {
+    TS29571_CommonData.Dnn    dnn,
+    DnnIndicator    defaultDnnIndicator optional,
+    LboRoamingAllowed    lboRoamingAllowed optional,
+    IwkEpsInd    iwkEpsInd optional,
+    LadnIndicator    ladnIndicator optional
+  }
+
+  type set Nssai {
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    set of       TS29571_CommonData.Snssai    defaultSingleNssais optional,
+    set of       TS29571_CommonData.Snssai    singleNssais optional
+  }
+
+  type set UeContextInSmfData {
+    set of record {
+      universal charstring key,
+      PduSession    additionalProperties
+    } pduSessions optional,
+    set of       PgwInfo    pgwInfo optional
+  } with {
+    variant (pduSessions) "as map"
+  }
+
+
+  type set PduSession {
+    TS29571_CommonData.PduSessionId    pduSessionId,
+    TS29571_CommonData.Dnn    dnn,
+    TS29571_CommonData.NfInstanceId    smfInstanceId,
+    TS29571_CommonData.PlmnId    plmnId
+  }
+
+  type set PgwInfo {
+    TS29571_CommonData.Dnn    dnn,
+    charstring pgwFqdn,
+    TS29571_CommonData.PlmnId    plmnId optional
+  }
+
+  type set SessionManagementSubscriptionData {
+    TS29571_CommonData.Snssai    singleNssai,
+    record of record {
+      universal charstring key,
+      DnnConfiguration    additionalProperties
+    } dnnConfiguration optional
+  } with {
+    variant (dnnConfiguration) "as map"
+  }
+
+
+  type set DnnConfiguration {
+    TS29571_CommonData.Dnn    dnn,
+    PduSessionTypes    pduSessionTypes,
+    SscModes    sscModes,
+    IwkEpsInd    iwkEpsInd optional,
+    LadnIndicator    ladnIndicator optional,
+    FiveGQosProfile    fivegQosProfile optional,
+    TS29571_CommonData.Ambr    sessionAmbr optional,
+    ThreeGppChargingCharacteristics    threegppChargingCharacteristics optional,
+    IpAddress    staticIpAddress optional,
+    TS29571_CommonData.UpSecurity    upSecurity optional
+  } with {
+    variant (fivegQosProfile) "name as '5gQosProfile'"
+    variant (threegppChargingCharacteristics) "name as '3gppChargingCharacteristics'"
+  }
+
+  type set IpAddress {
+    TS29571_CommonData.Ipv4Addr    ipv4Addr optional,
+    TS29571_CommonData.Ipv6Addr    ipv6Addr optional,
+    TS29571_CommonData.Ipv6Prefix    ipv6Prefix optional
+  }
+
+  type set PduSessionTypes {
+    TS29571_CommonData.PduSessionType    defaultSessionType,
+    set of       TS29571_CommonData.PduSessionType    allowedSessionTypes optional
+  }
+
+  type set SscModes {
+    TS29571_CommonData.SscMode    defaultSscMode,
+    set of       TS29571_CommonData.SscMode    allowedSscModes optional
+  }
+
+  type set FiveGQosProfile {
+    TS29571_CommonData.FiveQi    fiveqi,
+    TS29571_CommonData.NonDynamic5Qi    nonDynamic5Qi optional,
+    TS29571_CommonData.Dynamic5Qi    dynamic5Qi optional,
+    TS29571_CommonData.Arp    arp optional
+  } with {
+    variant (fiveqi) "name as '5qi'"
+  }
+
+
+  type set SmsSubscriptionData {
+    SmsSubscribed    smsSubscribed,
+    SharedDataIds    sharedDataIds optional
+  }
+
+  type set SmsManagementSubscriptionData {
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    boolean mtSmsSubscribed,
+    boolean mtSmsBarringAll optional,
+    boolean mtSmsBarringRoaming optional,
+    boolean moSmsSubscribed,
+    boolean moSmsBarringAll optional,
+    boolean moSmsBarringRoaming optional,
+    SharedDataIds    sharedDataIds optional
+  }
+
+  type set SdmSubscription {
+    TS29571_CommonData.NfInstanceId    nfInstanceId,
+    boolean implicitUnsubscribe optional,
+    TS29571_CommonData.DateTime    expires optional,
+    TS29571_CommonData.Uri    callbackReference optional,
+    set of       TS29571_CommonData.Uri    monitoredResourceUris optional,
+    TS29571_CommonData.Snssai    singleNssai optional,
+    TS29571_CommonData.Dnn    dnn optional
+  }
+
+  type set ModificationNotification {
+    set of       TS29571_CommonData.NotifyItem    notifyItems
+  }
+
+  type set IdTranslationResult {
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    TS29571_CommonData.Supi    supi,
+    TS29571_CommonData.Gpsi    gpsi optional
+  }
+
+  type set AcknowledgeInfo {
+    TS29509_Nausf_SoRProtection.SorMac    sorMacIue optional
+  }
+
+  type set SorInfo {
+    set of       TS29509_Nausf_SoRProtection.SteeringInfo    steeringInfoList,
+    TS29509_Nausf_SoRProtection.AckInd    ackInd,
+    TS29509_Nausf_SoRProtection.SorMac    sorMacIausf,
+    TS29509_Nausf_SoRProtection.CounterSor    countersor
+  }
+
+  type set of     SharedDataId    SharedDataIds
+
+  type set SharedData {
+    SharedDataId    sharedDataId,
+    AccessAndMobilitySubscriptionData    sharedAmData optional,
+    SmsSubscriptionData    sharedSmsSubsData optional,
+    SmsManagementSubscriptionData    sharedSmsMngSubsData optional
+  }
+
+  type integer UeUsageType
+
+  type boolean MpsPriorityIndicator
+
+  type boolean DnnIndicator
+
+  type boolean LboRoamingAllowed
+
+  type boolean LadnIndicator
+
+  type boolean SmsSubscribed
+
+  type charstring ThreeGppChargingCharacteristics
+
+  type integer DlPacketCount (-1..infinity)
+
+  type charstring InternalGroupId
+
+  type boolean MicoAllowed
+
+  type charstring SharedDataId // (pattern "^[0-9]{5,6}-.+$")
+
+  type boolean IwkEpsInd
+
+  type enumerated DataSetName_enum { AM, SMF_SEL, UEC_SMF, UEC_SMSF, SMS_SUB, SM, TRACE, SMS_MNG}
+
+  type union DataSetName {
+    DataSetName_enum  enum_val,
+    charstring           other_val
+  } with {
+    variant "JSON: as value"
+  }
+
+
+
+
+
+
+} with {
+  encode "JSON"
+}
diff --git a/src/TS29503_Nudm_UEAU.ttcn b/src/TS29503_Nudm_UEAU.ttcn
new file mode 100644
index 0000000..68364a4
--- /dev/null
+++ b/src/TS29503_Nudm_UEAU.ttcn
@@ -0,0 +1,143 @@
+/******************************************************************************
+* Copyright (c) 2000-2019  Ericsson AB
+* All rights reserved. This program and the accompanying materials
+* are made available under the terms of the Eclipse Public License v2.0
+* which accompanies this distribution, and is available at
+* https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html
+*
+* Contributors:
+*   Gabor Szalai - initial implementation and initial documentation
+******************************************************************************/
+//
+//  File:               TS29503_Nudm_UEAU.ttcn
+//  Description:	      Type definitions for 3GPP TS29503
+/////////////////////////////////////////////// 
+module TS29503_Nudm_UEAU {
+
+  import from TS29571_CommonData all
+
+  external function f_enc_AuthenticationInfoRequest(in AuthenticationInfoRequest pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_AuthenticationInfoRequest(in octetstring stream, out AuthenticationInfoRequest pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_AuthenticationInfoResult(in AuthenticationInfoResult pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_AuthenticationInfoResult(in octetstring stream, out AuthenticationInfoResult pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_AuthEvent(in AuthEvent pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_AuthEvent(in octetstring stream, out AuthEvent pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+
+  type set AuthenticationInfoRequest {
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    ServingNetworkName    servingNetworkName,
+    ResynchronizationInfo    resynchronizationInfo optional,
+    TS29571_CommonData.NfInstanceId    ausfInstanceId
+  }
+
+  type set AuthenticationInfoResult {
+    AuthType    authType,
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    AuthenticationVector    authenticationVector optional,
+    TS29571_CommonData.Supi    supi optional
+  }
+
+  type union AuthenticationVector {
+    AvEapAkaPrime    avEapAkaPrime,
+    Av5GHeAka        av5GHeAka
+  } with {
+    variant "JSON: as value"
+  }
+
+
+  type set AvEapAkaPrime {
+    AvType    avType,
+    Rand    rand,
+    Xres    xres,
+    Autn    autn,
+    CkPrime    ckPrime,
+    IkPrime    ikPrime
+  }
+
+  type set Av5GHeAka {
+    AvType    avType,
+    Rand    rand,
+    XresStar    xresStar,
+    Autn    autn,
+    Kausf    kausf
+  }
+
+  type set ResynchronizationInfo {
+    Rand    rand,
+    Auts    auts
+  }
+
+  type set AuthEvent {
+    TS29571_CommonData.NfInstanceId    nfInstanceId,
+    Success    success,
+    TS29571_CommonData.DateTime    timeStamp,
+    AuthType    authType
+  }
+
+  type charstring Autn // (pattern "^[A-Fa-f0-9]{32}$")
+
+  type charstring Auts // (pattern "^[A-Fa-f0-9]{28}$")
+
+  type charstring CkPrime // (pattern "^[A-Fa-f0-9]{32}$")
+
+  type charstring IkPrime // (pattern "^[A-Fa-f0-9]{32}$")
+
+  type charstring Kausf // (pattern "^[A-Fa-f0-9]{64}$")
+
+  type charstring Rand // (pattern "^[A-Fa-f0-9]{32}$")
+
+  type charstring Xres // (pattern "^[A-Fa-f0-9]{8,32}$")
+
+  type charstring XresStar // (pattern "^[A-Fa-f0-9]{32}$")
+
+  type charstring SupiOrSuci // (pattern "^(imsi-[0-9]{5,15}|nai-.+| suci-(0-[0-9]{3}-[0-9]{2,3}|[1-7]-.+)-[0-9]{1,4}-(0-0-.+|[a-fA-F1-9]-([1-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])-[a-fA-F0-9]+)|.+)$")
+
+  type charstring ServingNetworkName // (pattern "^5G:mnc[0-9]{3}[.]mcc[0-9]{3}[.]3gppnetwork[.]org$")
+
+  type boolean Success
+
+  type enumerated AuthType_enum { FIVEG_AKA, EAP_AKA_PRIME, EAP_TLS}
+    with {
+      variant "text 'FIVEG_AKA' as '5G_AKA' "
+    }
+
+  type union AuthType {
+    AuthType_enum  enum_val,
+    charstring           other_val
+  } with {
+    variant "JSON: as value"
+  }
+
+
+  type enumerated AvType_enum { FIVEG_HE_AKA, EAP_AKA_PRIME}
+    with {
+      variant "text 'FIVEG_HE_AKA' as '5G_HE_AKA' "
+    }
+
+  type union AvType {
+    AvType_enum  enum_val,
+    charstring           other_val
+  } with {
+    variant "JSON: as value"
+  }
+
+
+
+
+
+
+} with {
+  encode "JSON"
+}
diff --git a/src/TS29503_Nudm_UECM.ttcn b/src/TS29503_Nudm_UECM.ttcn
new file mode 100644
index 0000000..766abf0
--- /dev/null
+++ b/src/TS29503_Nudm_UECM.ttcn
@@ -0,0 +1,169 @@
+/******************************************************************************
+* Copyright (c) 2000-2019  Ericsson AB
+* All rights reserved. This program and the accompanying materials
+* are made available under the terms of the Eclipse Public License v2.0
+* which accompanies this distribution, and is available at
+* https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.html
+*
+* Contributors:
+*   Gabor Szalai - initial implementation and initial documentation
+******************************************************************************/
+//
+//  File:               TS29503_Nudm_UECM.ttcn
+//  Description:	      Type definitions for 3GPP TS29503
+/////////////////////////////////////////////// 
+module TS29503_Nudm_UECM {
+
+  import from TS29571_CommonData all
+
+  external function f_enc_Amf3GppAccessRegistration(in Amf3GppAccessRegistration pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_Amf3GppAccessRegistration(in octetstring stream, out Amf3GppAccessRegistration pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_DeregistrationData(in DeregistrationData pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_DeregistrationData(in octetstring stream, out DeregistrationData pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_PcscfRestorationNotification(in PcscfRestorationNotification pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_PcscfRestorationNotification(in octetstring stream, out PcscfRestorationNotification pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_Amf3GppAccessRegistrationModification(in Amf3GppAccessRegistrationModification pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_Amf3GppAccessRegistrationModification(in octetstring stream, out Amf3GppAccessRegistrationModification pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_AmfNon3GppAccessRegistration(in AmfNon3GppAccessRegistration pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_AmfNon3GppAccessRegistration(in octetstring stream, out AmfNon3GppAccessRegistration pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_AmfNon3GppAccessRegistrationModification(in AmfNon3GppAccessRegistrationModification pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_AmfNon3GppAccessRegistrationModification(in octetstring stream, out AmfNon3GppAccessRegistrationModification pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_SmfRegistration(in SmfRegistration pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_SmfRegistration(in octetstring stream, out SmfRegistration pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+  external function f_enc_SmsfRegistration(in SmsfRegistration pdu) return octetstring 
+  with { extension "prototype(convert) encode(JSON)" }
+
+  external function f_dec_SmsfRegistration(in octetstring stream, out SmsfRegistration pdu) return integer 
+  with { extension "prototype(backtrack) decode(JSON)" }
+
+
+  type set Amf3GppAccessRegistration {
+    TS29571_CommonData.NfInstanceId    amfInstanceId,
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    PurgeFlag    purgeFlag optional,
+    TS29571_CommonData.Pei    pei optional,
+    ImsVoPS    imsVoPS optional,
+    TS29571_CommonData.Uri    deregCallbackUri,
+    TS29571_CommonData.Uri    pcscfRestorationCallbackUri optional,
+    TS29571_CommonData.Guami    guami optional,
+    TS29571_CommonData.PlmnId    plmnId,
+    set of       TS29571_CommonData.BackupAmfInfo    backupAmfInfo optional
+  }
+
+  type set Amf3GppAccessRegistrationModification {
+    PurgeFlag    purgeFlag optional,
+    TS29571_CommonData.Pei    pei optional,
+    ImsVoPS    imsVoPS optional,
+    set of       TS29571_CommonData.BackupAmfInfo    backupAmfInfo optional
+  }
+
+  type set AmfNon3GppAccessRegistration {
+    TS29571_CommonData.NfInstanceId    amfInstanceId,
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    PurgeFlag    purgeFlag optional,
+    TS29571_CommonData.Pei    pei optional,
+    TS29571_CommonData.Uri    deregCallbackUri,
+    TS29571_CommonData.Uri    pcscfRestorationCallbackUri optional,
+    TS29571_CommonData.Guami    guami optional,
+    TS29571_CommonData.PlmnId    plmnId,
+    set of       TS29571_CommonData.BackupAmfInfo    backupAmfInfo optional
+  }
+
+  type set AmfNon3GppAccessRegistrationModification {
+    PurgeFlag    purgeFlag optional,
+    TS29571_CommonData.Pei    pei optional,
+    set of       TS29571_CommonData.BackupAmfInfo    backupAmfInfo optional
+  }
+
+  type set SmfRegistration {
+    TS29571_CommonData.NfInstanceId    smfInstanceId,
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    TS29571_CommonData.PduSessionId    pduSessionId,
+    TS29571_CommonData.Dnn    dnn,
+    TS29571_CommonData.Uri    pcscfRestorationCallbackUri optional,
+    TS29571_CommonData.PlmnId    plmnId,
+    charstring pgwFqdn optional
+  }
+
+  type set SmsfRegistration {
+    TS29571_CommonData.NfInstanceId    smsfInstanceId,
+    TS29571_CommonData.SupportedFeatures    supportedFeatures optional,
+    TS29571_CommonData.PlmnId    plmnId,
+    E164Number    smsfMAPAddress optional,
+    NetworkNodeDiameterAddress    smsfDiameterAddress optional
+  }
+
+  type set DeregistrationData {
+    DeregistrationReason    deregReason,
+    TS29571_CommonData.AccessType    accessType
+  }
+
+  type set PcscfRestorationNotification {
+    TS29571_CommonData.Supi    supi
+  }
+
+  type set NetworkNodeDiameterAddress {
+    TS29571_CommonData.DiameterIdentity    name,
+    TS29571_CommonData.DiameterIdentity    realm
+  }
+
+  type boolean PurgeFlag
+
+  type charstring E164Number // (pattern "^[0-9]{1,15}$")
+
+  type enumerated ImsVoPS_enum { HOMOGENEOUS_SUPPORT, HOMOGENEOUS_NON_SUPPORT, NON_HOMOGENEOUS_OR_UNKNOWN}
+
+  type union ImsVoPS {
+    ImsVoPS_enum  enum_val,
+    charstring           other_val
+  } with {
+    variant "JSON: as value"
+  }
+
+
+  type enumerated DeregistrationReason_enum { UE_INITIAL_REGISTRATION, UE_REGISTRATION_AREA_CHANGE, SUBSCRIPTION_WITHDRAWN, FIVEGS_TO_EPS_MOBILITY}
+  with {variant "text 'FIVEGS_TO_EPS_MOBILITY' as '5GS_TO_EPS_MOBILITY'"}
+
+  type union DeregistrationReason {
+    DeregistrationReason_enum  enum_val,
+    charstring           other_val
+  } with {
+    variant "JSON: as value"
+  }
+
+
+
+
+
+
+} with {
+  encode "JSON"
+}