Commit 416a9607 authored by ASN.1 Documenter's avatar ASN.1 Documenter
Browse files

Initial

parents
Loading
Loading
Loading
Loading

.gitmodules

0 → 100644
+45 −0
Original line number Diff line number Diff line
[submodule "ttcn/LibCommon"]
	path = ttcn/LibCommon
	url = https://forge.etsi.org/rep/LIBS/LibCommon.git
[submodule "ttcn/LibIts"]
	path = ttcn/LibIts
	url = https://forge.etsi.org/rep/LIBS/LibIts.git
	branch = devel
[submodule "ttcn/AtsCAM"]
	path = ttcn/AtsCAM
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_cam_ts102868-3.git
	branch = devel
[submodule "ttcn/AtsDENM"]
	path = ttcn/AtsDENM
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_denm_ts102869-3.git
	branch = devel
[submodule "ttcn/AtsGeoNetworking"]
	path = ttcn/AtsGeoNetworking
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_gn_ts102871-3.git
	branch = devel
[submodule "ttcn/AtsBTP"]
	path = ttcn/AtsBTP
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_btp_ts102870-3.git
	branch = devel
[submodule "ttcn/AtsIPv6OverGeoNetworking"]
	path = ttcn/AtsIPv6OverGeoNetworking
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_gnipv6_ts102859-3.git
	branch = devel
[submodule "ttcn/AtsPki"]
	path = ttcn/AtsPki
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_pki_ts103525-3.git
	branch = devel
[submodule "ttcn/AtsIS"]
	path = ttcn/AtsIS
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_ts103191-3.git
	branch = devel
[submodule "ttcn/AtsSecurity"]
	path = ttcn/AtsSecurity
	url = https://forge.etsi.org/rep/ITS/ttcn/ats_sec_ts103096-3.git
	branch = devel
[submodule "ttcn/modules/titan.TestPorts.HTTPmsg/module"]
	path = ttcn/modules/titan.TestPorts.HTTPmsg/module
	url = https://github.com/eclipse/titan.TestPorts.HTTPmsg.git
[submodule "ttcn/modules/titan.TestPorts.Common_Components.Abstract_Socket/module"]
	path = ttcn/modules/titan.TestPorts.Common_Components.Abstract_Socket/module
	url = https://github.com/eclipse/titan.TestPorts.Common_Components.Abstract_Socket.git

Makefile

0 → 100755
+147 −0
Original line number Diff line number Diff line
-include config.mk

ifeq (,$(ATS))
 $(error ATS shall be defined)
endif

ifeq (,$(TOPDIR))
 TOPDIR := .
endif

ifeq (,$(TTCN3_DIR))
 $(error TTCN3_DIR shall be defined in config.mk)
endif
first: all

define IncludeModule
undefine sources
undefine modules
undefine includes
include $(1)/module.mk
$$(foreach S, $$(sources),  $$(eval all_sources +=  $$(if $$(filter /%, $$(S)), $$(TOPDIR)/$$(S), $(1)/$$(S))))
$$(foreach I, $$(includes), $$(eval all_includes += $$(if $$(filter /%, $$(I)), $$(TOPDIR)/$$(I), $(1)/$$(I))))
$$(foreach M, $$(modules),  $$(eval $$(call IncludeModule, $$(if $$(filter /%, $$(M)), $$(TOPDIR)/$$(M), $(1)/$$(M)))))
endef

all_includes := $(TTCN3_DIR)/include $(TTCN3_DIR)/src $(TOPDIR)/ccsrc/Framework /usr/include/jsoncpp
defines  += TITAN_RUNTIME_2 _NO_SOFTLINKS_ $(ATS)
libs     += $(TTCN3_DIR)/lib/libttcn3-rt2-parallel.a -lstdc++fs

ifeq (Windows_NT,$(OS))
# Silence linker warnings.
LDFLAGS += -Wl,--enable-auto-import,--enable-runtime-pseudo-reloc
defines += WIN32
libs += $(patsubst %, -L%/lib, $(OPENSSL_DIR))
all_includes += $(addsuffix /include, $(OPENSSL_DIR))
libs += $(WPCAP_DLL_PATH)
else
defines += LINUX
libs += -lpcap -lrt -lpthread
endif

libs += -lssl -lcrypto -lxml2 -ljsoncpp

$(eval $(call IncludeModule, $(TOPDIR)/ttcn/$(ATS)))

outdir := $(TOPDIR)/build/$(ATS)
bindir := $(TOPDIR)/bin

sources     := $(sort $(all_sources))
includes    := $(outdir) $(outdir)/.. $(outdir)/../asn1 $(all_includes) $(NPCAP_INCLUDE)

ifeq (Windows_NT,$(OS))
  EXE=.exe
endif

ttcn_sources  := $(filter %.ttcn , $(sources))
ttcn3_sources := $(filter %.ttcn3, $(sources))
asn_sources   := $(filter %.asn,   $(sources))
asn1_sources  := $(filter %.asn1,  $(sources))

tt_sources    := $(ttcn_sources) $(ttcn3_sources) $(asn_sources) $(asn1_sources)
cc_sources    := $(filter %.cc,    $(sources))

gen_ttcn_sources  := $(addprefix $(outdir)/, $(notdir $(patsubst %.ttcn,  %.cc, $(ttcn_sources))))
gen_ttcn_headers  := $(addprefix $(outdir)/, $(notdir $(patsubst %.ttcn,  %.hh, $(ttcn_sources))))
gen_ttcn3_sources := $(addprefix $(outdir)/, $(notdir $(patsubst %.ttcn3, %.cc, $(ttcn3_sources))))
gen_ttcn3_headers := $(addprefix $(outdir)/, $(notdir $(patsubst %.ttcn3, %.hh, $(ttcn3_sources))))
gen_asn_sources   := $(addprefix $(outdir)/, $(notdir $(patsubst %.asn,   %.cc, $(asn_sources))))
gen_asn_headers   := $(addprefix $(outdir)/, $(notdir $(patsubst %.asn,   %.hh, $(asn_sources))))
gen_asn1_sources  := $(addprefix $(outdir)/, $(notdir $(patsubst %.asn1,  %.cc, $(asn1_sources))))
gen_asn1_headers  := $(addprefix $(outdir)/, $(notdir $(patsubst %.asn1,  %.hh, $(asn1_sources))))

gen_sources := $(gen_ttcn_sources) $(gen_ttcn3_sources) $(gen_asn_sources) $(gen_asn1_sources)
gen_headers := $(gen_ttcn_headers) $(gen_ttcn3_headers) $(gen_asn_headers) $(gen_asn1_headers)

gen_objects := $(patsubst %.cc, %.o, $(gen_sources))
cc_objects  := $(patsubst  %.cc, $(outdir)/%.o, $(cc_sources))

.PHONY: all FORCE echo

all: $(bindir) $(outdir) $(bindir)/$(ATS)$(EXE)

echo_sources:
	@echo -e "$(addsuffix \n,$(all_sources))"

echo: echo_sources
	@echo -e "sources:\n $(addsuffix \n, $(sources))"
	@echo -e "gen_sources:\n $(addsuffix \n, $(gen_sources))"
	@echo -e "gen_objects:\n $(addsuffix \n, $(gen_objects))"
	@echo -e "cc_objects:\n $(addsuffix \n, $(cc_objects))"
	@echo -e "includes:\n $(addsuffix \n, $(includes))"
	@echo -e "defines: $(addsuffix \n, $(defines))"

clean:
	rm -f $(outdir)/$(ATS)$(EXE) $(gen_objects) $(gen_sources) $(gen_headers) $(cc_objects) $(outdir)/.generate $(outdir)/../libItsAsn.so
#	rm -f $(outdir)/asn1/*.so $(outdir)/asn1/*.o $(outdir)/asn1/*.c $(outdir)/asn1/*.h $(outdir)/asn1/Makefile.am.libasncodec

regen: force_regen $(outdir)/.generate
force_regen:
	rm -f $(outdir)/.generate

t3q: all
	@echo -e "Code checking in progress..."
	@java -Xmx3g -Xss512m -jar $(T3Q_PATH)/t3q.jar --config $(T3Q_PATH)/$(T3Q_CONFIG) $(tt_sources) > $(outdir)/t3q.out 2>&1 ; cd -
	@echo -e "Code checking in done..."
	@echo -e "Output file is located here: $(outdir)/t3q.out"

t3d: all
	@echo -e "TTCN-3 doc generation in progress..."
	@java -Xmx3g -Xss512m -jar $(T3D_PATH)/t3d.jar --config $(T3D_PATH)/$(T3D_CONFIG) $(tt_sources) > $(outdir)/t3d.out 2>&1 ; cd -
	@echo -e "TTCN-3 doc generation done..."
	@echo -e "Output file is located here: $(outdir)/t3d.out"

$(outdir) $(bindir):
	mkdir -p $@

$(bindir)/$(ATS)$(EXE): $(outdir)/../asn1/libItsAsn.a $(gen_objects) $(cc_objects) 
	g++ -g -O0 -o $@ $(LDFLAGS) $(gen_objects) $(cc_objects) $(outdir)/../asn1/libItsAsn.a $(libs)

$(gen_objects) :%.o :%.cc
	g++ -g -O0 -c $(addprefix -D, $(defines)) $(addprefix -I, $(includes)) -o $@ $<

$(cc_objects) : $(outdir)/%.o : %.cc
	mkdir -p $(dir $@)
	g++ -g -O0 -c $(addprefix -D, $(defines)) $(addprefix -I, $(includes)) -o $@ $<

#$(gen_sources):
#	$(TTCN3_DIR)/bin/compiler -n -e -L -R -U none -o $(outdir) $(tt_sources)

$(gen_sources): $(outdir)/.generate

$(outdir)/.generate: Makefile $(tt_sources)
	$(TTCN3_DIR)/bin/compiler -w -d -e -f -g -l -L -R -U none -x -X -o $(outdir) $(tt_sources)
	touch $@

$(bindir)/libItsAsn.so: $(outdir)/asn1/libItsAsn.so
	cp -f $< $@

$(outdir)/../asn1/libItsAsn.a: FORCE
	mkdir -p $(outdir)/../asn1
	$(MAKE) -C $(outdir)/../asn1 -f ../../asn1/Makefile

$(foreach S, $(ttcn_sources),  $(eval $(outdir)/$(notdir $(patsubst %.ttcn, %.cc,  $(S))): $(S)))
$(foreach S, $(ttcn3_sources), $(eval $(outdir)/$(notdir $(patsubst %.ttcn3, %.cc, $(S))): $(S)))
$(foreach S, $(asn_sources),   $(eval $(outdir)/$(notdir $(patsubst %.asn, %.cc,   $(S))): $(S)))
$(foreach S, $(asn1_sources),  $(eval $(outdir)/$(notdir $(patsubst %.asn1, %.cc,  $(S))): $(S)))

asn1/Makefile

0 → 100755
+176 −0
Original line number Diff line number Diff line
##########################################################
#  This Makefile is to build the ASN1 library to be used
#  for external codec in Titan
#  This Makefile is expected that asn1c compiler is 
#  installed in the PATHs
##########################################################

# The name of the library
ASN_LIBRARY = libItsAsn.a
# ASN.1 files to be included in the library
ASN_FILES = AtsCAM/lib/asn1/CAM_PDU_Descriptions.asn \
            AtsCAM/lib/asn1/cdd/ITS_Container.asn \
            AtsDENM/lib/asn1/DENM_PDU_Descriptions.asn \
            AtsSecurity/lib/asn1/EtsiTs103097ExtensionModule.asn \
            AtsSecurity/lib/asn1/EtsiTs103097Module.asn \
            AtsSecurity/lib/asn1/ieee1609dot2/Ieee1609Dot2.asn \
            AtsSecurity/lib/asn1/ieee1609dot2/Ieee1609Dot2BaseTypes.asn\
            AtsIS/lib/asn1/IVIM_PDU_Descriptions.asn \
            AtsIS/lib/asn1/MAPEM_PDU_Descriptions.asn \
            AtsIS/lib/asn1/RTCMEM_PDU_Descriptions.asn \
            AtsIS/lib/asn1/SPATEM_PDU_Descriptions.asn \
            AtsIS/lib/asn1/SREM_PDU_Descriptions.asn \
            AtsIS/lib/asn1/SSEM_PDU_Descriptions.asn \
            AtsIS/lib/asn1/iso-patched/EfcDsrcApplication.asn  \
            AtsIS/lib/asn1/iso-patched/EfcDsrcGeneric.asn  \
            AtsIS/lib/asn1/iso-patched/ElectronicRegistrationIdentificationVehicleDataModule.asn \
            AtsIS/lib/asn1/iso-patched/GDD.asn \
            ../build/asn1/ISO_TS_14816/AVIAEINumberingAndDataStructures.asn \
            ../build/asn1/ISO_TS_17419/CITSapplMgmtIDs.asn \
            ../build/asn1/ISO_TS_19321/IVI.asn \
            ../build/asn1/ISO_TS_19091/ISO-TS-19091-addgrp-C-2018-patched.asn \

#            ../build/asn1/ISO_TS_19091/AddGrpC.asn \
#            ../build/asn1/ISO_TS_19091/AddGrpC_noCircular.asn \
#            ../build/asn1/ISO_TS_19091/DSRC.asn \
#            ../build/asn1/ISO_TS_19091/DSRC_REGION_noCircular.asn \
#            ../build/asn1/ISO_TS_19091/REGION.asn \

#            AtsPki/lib/asn1/EtsiTs102941BaseTypes.asn \
#            AtsPki/lib/asn1/EtsiTs102941MessagesCa.asn \
#            AtsPki/lib/asn1/EtsiTs102941TrustLists.asn \
#            AtsPki/lib/asn1/EtsiTs102941TypesAuthorization.asn \
#            AtsPki/lib/asn1/EtsiTs102941TypesAuthorizationValidation.asn \
#            AtsPki/lib/asn1/EtsiTs102941TypesCaManagement.asn \
#            AtsPki/lib/asn1/EtsiTs102941TypesEnrolment.asn \
#            AtsPki/lib/asn1/EtsiTs102941TypesLinkCertificate.asn \

# PDUs
PDU = CAM DENM MAPEM SPATEM SREM SSEM IVIM RTCMEM EtsiTs103097Data EtsiTs103097Certificate
#EtsiTs102941Data

#patches
PATCHES = PsidGroupPermissions.c.diff

ASN1C:=asn1c
#Override ASN1C instalation path
#ASN1C_PATH = 

ifneq (, $(ASN1C_PATH))
# OS=$(shell uname)
 ifneq (Windows_NT,$(OS))
  ASN1C:=$(ASN1C_PATH)/asn1c/asn1c -S $(ASN1C_PATH)/skeletons
 else
  ASN1C:=$(ASN1C_PATH)/asn1c/asn1c.exe -S $(ASN1C_PATH)/skeletons
 endif
endif

ifeq (,$(ASN_DIR))
##########################################################
# Build path for the library
BIN_DIR := .
SCRIPT_DIR := $(dir $(lastword $(MAKEFILE_LIST)))
ASN_DIR := $(dir $(SCRIPT_DIR))../ttcn

.PHONY: FORCE

all: $(BIN_DIR)/$(ASN_LIBRARY)
clean:
	rm -rf $(BIN_DIR)

$(BIN_DIR)/$(ASN_LIBRARY): $(BIN_DIR)/Makefile
	make -C $(BIN_DIR) all

$(BIN_DIR):
	mkdir -p $@

$(BIN_DIR)/Makefile: $(BIN_DIR) $(SCRIPT_DIR)/Makefile
	echo SCRIPT_DIR=$(SCRIPT_DIR) > $@
	echo ASN_DIR=$(ASN_DIR)       >>$@
	cat $(SCRIPT_DIR)/Makefile    >>$@

##########################################################
else
##########################################################
# This part is executed within the BIN_DIR directory to
# override variables from the Makefile.am.libasncodec 
# generated by asn1c
LIB_MAKEFILE=Makefile.am.libasncodec
include $(LIB_MAKEFILE)
OBJS = ${ASN_MODULE_SRCS:.c=.o}
CONVERTER=converter
ASN_CONVERTER_SOURCES := \
	converter-example.c\
	pdu_collection.c
CONVERTER_OBJS=${ASN_CONVERTER_SOURCES:.c=.o}
CFLAGS += $(ASN_MODULE_CFLAGS) -DPDU=CAM -DASN_PDU_COLLECTION -fPIC -I.

all: Makefile $(ASN_LIBRARY)

$(LIB_MAKEFILE): $(addprefix $(ASN_DIR)/, $(ASN_FILES))
	$(ASN1C) -no-gen-example $(addprefix -pdu=,$(PDU)) -fcompound-names $^
	-for n in $(PATCHES); do git apply "$(SCRIPT_DIR)/$$n"; done

$(CONVERTER): $(ASN_LIBRARY) $(CONVERTER_OBJS) 
	$(CC) $(CFLAGS) -o $@ $(CONVERTER_OBJS) $(ASN_LIBRARY) $(LIBS)

$(ASN_LIBRARY): ${ASN_MODULE_SRCS:.c=.o}
	ar rcs $@ $^
#	$(CC) $(CFLAGS) -o $@ $^ -shared $(LDFLAGS) $(LIBS)

.SUFFIXES:
.SUFFIXES: .c .o

.c.o:
	$(CC) $(CFLAGS) -o $@ -c $<

clean:
	rm -f $(CONVERTER) $(ASN_LIBRARY)
	rm -f $(OBJS) $(CONVERTER_OBJS)

regen: clear-asn1c $(LIB_MAKEFILE)
clear-asn1c:
	rm -f $(LIB_MAKEFILE)

Makefile: $(SCRIPT_DIR)/Makefile
	echo SCRIPT_DIR=$(SCRIPT_DIR) > $@
	echo ASN_DIR=$(ASN_DIR) >>$@
	cat $<                  >>$@
##########################################################

$(ASN_DIR)/../build/asn1/ISO_TS_14816/AVIAEINumberingAndDataStructures.asn: $(ASN_DIR)/../build/asn1/ISO_TS_14816
	curl -o "$@" 'https://standards.iso.org/iso/14816/ISO14816%20ASN.1%20repository/ISO14816_AVIAEINumberingAndDataStructures.asn'

#../build/asn1/ISO_TS_14906/EfcDsrcApplication.asn: $(ASN_DIR)/../build/asn1/ISO_TS_14906
#	curl -o "$@" 'https://standards.iso.org/iso/14906/ed-3/en/ISO14906(2018)EfcDsrcApplicationv6.asn'

#../build/asn1/ISO_TS_14906/EfcDsrcGeneric.asn: $(ASN_DIR)/../build/asn1/ISO_TS_14906
#	curl -o "$@" 'https://standards.iso.org/iso/14906/ed-3/en/ISO14906(2018)EfcDsrcGenericv7.asn'

$(ASN_DIR)/../build/asn1/ISO_TS_17419/CITSapplMgmtIDs.asn: $(ASN_DIR)/../build/asn1/ISO_TS_17419
	curl -o "$@" 'https://standards.iso.org/iso/ts/17419/TS%2017419%20ASN.1%20repository/TS17419_2014_CITSapplMgmtIDs.asn'

$(ASN_DIR)/../build/asn1/ISO_TS_19091/ISO-TS-19091-addgrp-C-2018-patched.asn: $(ASN_DIR)/../build/asn1/ISO_TS_19091
	curl 'https://standards.iso.org/iso/ts/19091/ed-2/en/ISO-TS-19091-addgrp-C-2018.asn' | \
	sed -e 's/\bHeadingConfidence\b/HeadingConfidenceDSRC/g' \
        -e 's/\bSpeedConfidence\b/SpeedConfidenceDSRC/g' \
        -e 's/\bHeading\b/HeadingDSRC/g' > "$@"

#../build/asn1/ISO_TS_19091/AddGrpC.asn:
#../build/asn1/ISO_TS_19091/AddGrpC_noCircular.asn:
#../build/asn1/ISO_TS_19091/DSRC.asn:
#../build/asn1/ISO_TS_19091/DSRC_REGION_noCircular.asn
#../build/asn1/ISO_TS_19091/REGION.asn

$(ASN_DIR)/../build/asn1/ISO_TS_19321/IVI.asn: $(ASN_DIR)/../build/asn1/ISO_TS_19321
	curl -o "$@" 'https://standards.iso.org/iso/ts/19321/ed-2/en/ISO19321IVIv2.asn'


#../build/asn1/ISO_TS_24534-3/ElectronicRegistrationIdentificationVehicleDataModule.asn: ../build/asn1/ISO_TS_24534-3
#	curl -o "$@" 'https://standards.iso.org/iso/24534/-3/ISO%2024534-3%20ASN.1%20repository/ISO24534-3_ElectronicRegistrationIdentificationVehicleDataModule_ForBallot.asn'


$(addprefix $(ASN_DIR)/, ../build/asn1/ISO_TS_24534-3 ../build/asn1/ISO_TS_19321 ../build/asn1/ISO_TS_19091 ../build/asn1/ISO_TS_17419 ../build/asn1/ISO_TS_14906 ../build/asn1/ISO_TS_14816):
	mkdir -p "$@"

endif
+35 −0
Original line number Diff line number Diff line
--- PsidGroupPermissions.c-orig	2018-08-23 15:50:25.762030100 +0200
+++ PsidGroupPermissions.c	2018-09-10 16:47:19.921571200 +0200
@@ -51,6 +51,22 @@
 	*st = 0;
 	return 0;
 }
+static int asn_DFL_5_cmp_0(const void *sptr) {
+	uint8_t def_buf[] = { 0 };
+	BIT_STRING_t def = { &def_buf[0], 1, 7 };
+	return BIT_STRING_compare(&asn_DEF_EndEntityType, sptr, &def);
+}
+
+static int asn_DFL_5_set_0(void **sptr) {
+	BIT_STRING_t * st = *(BIT_STRING_t **)sptr;
+	if (!st) {
+		st = (*sptr = CALLOC(1, sizeof(*st)));
+		if (!st) return -1;
+	}
+	OCTET_STRING_fromBuf((OCTET_STRING_t *)st, "\x0", 1);
+	return 0;
+}
+
 asn_TYPE_member_t asn_MBR_PsidGroupPermissions_1[] = {
 	{ ATF_NOFLAGS, 0, offsetof(struct PsidGroupPermissions, subjectPermissions),
 		(ASN_TAG_CLASS_CONTEXT | (0 << 2)),
@@ -87,7 +103,8 @@
 		&asn_DEF_EndEntityType,
 		0,
 		{ 0, 0, 0 },
-		0, 0, /* No default value */
+		asn_DFL_5_cmp_0,
+		asn_DFL_5_set_0,
 		"eeType"
 		},
 };
+53 −0
Original line number Diff line number Diff line
#include <asn1/asn_application.h>

#include "asn1_recode_per.hh"

#include <TTCN3.hh>

extern "C" {
  static int asn1c_collect_encoded_data(const void *buffer, size_t size, void *application_specific_key)
  {
    TTCN_Buffer * tb = (TTCN_Buffer *)application_specific_key;
    tb->put_s(size, (unsigned char *)buffer);
    return 0;
  }
}

int asn1_recode_per::recode(const asn_TYPE_descriptor_s & td, int from, int to, TTCN_Buffer & buf)
{
  int rc = -1;
  void * ptr = NULL;
  asn_dec_rval_t rc_d;
  rc_d = asn_decode(NULL, (asn_transfer_syntax)from, (asn_TYPE_descriptor_s*)&td, &ptr, buf.get_data(), buf.get_len());
  if(rc_d.code == RC_OK){
	// Encode as PER
    asn_enc_rval_t rc_e;
    buf.clear();
    rc_e = asn_encode(NULL, (asn_transfer_syntax)to, (asn_TYPE_descriptor_s*)&td, ptr, asn1c_collect_encoded_data, &buf);
    rc = rc_e.encoded;
  }
  if(ptr){
    ASN_STRUCT_FREE(td, ptr);
  }
  return rc;
}

int asn1_recode_per::ber2per(const asn_TYPE_descriptor_s & td, TTCN_Buffer & buf)
{
  return recode(td, (int)ATS_BER, (int)ATS_UNALIGNED_CANONICAL_PER, buf);
}

int asn1_recode_per::per2ber(const asn_TYPE_descriptor_s & td, TTCN_Buffer & buf)
{
  return recode(td, (int)ATS_UNALIGNED_BASIC_PER, (int)ATS_DER, buf);
}

/*int asn1_recode_oer::ber2oer(const asn_TYPE_descriptor_s & td, TTCN_Buffer & buf)
{
  return recode(td, (int)ATS_XER, (int)ATS_CANONICAL_OER, buf);
}

int asn1_recode_oer::oer2ber(const asn_TYPE_descriptor_s & td, TTCN_Buffer & buf)
{
  return recodeOer(td, (int)ATS_BASIC_OER, (int)ATS_XER, buf);
  }*/