libtasn1: Import libtasn1-4.19.0

Import a very trimmed-down set of libtasn1 files:

  curl -L -O https://ftp.gnu.org/gnu/libtasn1/libtasn1-4.19.0.tar.gz
  tar xvzf libtasn1-4.19.0.tar.gz
  rm -rf grub-core/lib/libtasn1
  mkdir -p grub-core/lib/libtasn1/lib
  mkdir -p grub-core/lib/libtasn1/tests
  cp libtasn1-4.19.0/{README.md,COPYING} grub-core/lib/libtasn1
  cp libtasn1-4.19.0/lib/{coding.c,decoding.c,element.c,element.h,errors.c,gstr.c,gstr.h,int.h,parser_aux.c,parser_aux.h,structure.c,structure.h} grub-core/libtasn1/lib
  cp libtasn1-4.19.0/lib/includes/libtasn1.h grub-core/lib/libtasn1
  cp libtasn1-4.19.0/tests/{CVE-2018-1000654-1_asn1_tab.h,CVE-2018-1000654-2_asn1_tab.h,CVE-2018-1000654.c,object-id-decoding.c,object-id-encoding.c,octet-string.c,reproducers.c,Test_overflow.c,Test_simple.c,Test_strings.c} grub-core/lib/libtasn1/tests
  rm -rf libtasn1-4.19.0*

Signed-off-by: Daniel Axtens <dja@axtens.net>
Signed-off-by: Gary Lin <glin@suse.com>
Reviewed-by: Vladimir Serbinenko <phcoder@gmail.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
Tested-by: Stefan Berger <stefanb@linux.ibm.com>
This commit is contained in:
Daniel Axtens authored and Daniel Kiper committed 2024-11-28 21:50:53 +01:00
1 parent c85c2b9f5f
commit 9a26abbc36
25 files changed
+10164

No files matched your search

File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
+42
View File
@@ -0,0 +1,42 @@
/*
* Copyright (C) 2000-2022 Free Software Foundation, Inc.
*
* This file is part of LIBTASN1.
*
* The LIBTASN1 library is free software; you can redistribute it
* and/or modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/
#ifndef _ELEMENT_H
# define _ELEMENT_H
struct node_tail_cache_st
{
asn1_node head; /* the first element of the sequence */
asn1_node tail;
};
int _asn1_append_sequence_set (asn1_node node,
struct node_tail_cache_st *pcached);
int _asn1_convert_integer (const unsigned char *value,
unsigned char *value_out,
int value_out_size, int *len);
void _asn1_hierarchical_name (asn1_node_const node, char *name,
int name_size);
#endif
+100
View File
@@ -0,0 +1,100 @@
/*
* Copyright (C) 2002-2022 Free Software Foundation, Inc.
*
* This file is part of LIBTASN1.
*
* The LIBTASN1 library is free software; you can redistribute it
* and/or modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/
#include <int.h>
#ifdef STDC_HEADERS
# include <stdarg.h>
#endif
#define LIBTASN1_ERROR_ENTRY(name) { #name, name }
struct libtasn1_error_entry
{
const char *name;
int number;
};
typedef struct libtasn1_error_entry libtasn1_error_entry;
static const libtasn1_error_entry error_algorithms[] = {
LIBTASN1_ERROR_ENTRY (ASN1_SUCCESS),
LIBTASN1_ERROR_ENTRY (ASN1_FILE_NOT_FOUND),
LIBTASN1_ERROR_ENTRY (ASN1_ELEMENT_NOT_FOUND),
LIBTASN1_ERROR_ENTRY (ASN1_IDENTIFIER_NOT_FOUND),
LIBTASN1_ERROR_ENTRY (ASN1_DER_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_VALUE_NOT_FOUND),
LIBTASN1_ERROR_ENTRY (ASN1_GENERIC_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_VALUE_NOT_VALID),
LIBTASN1_ERROR_ENTRY (ASN1_TAG_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_TAG_IMPLICIT),
LIBTASN1_ERROR_ENTRY (ASN1_ERROR_TYPE_ANY),
LIBTASN1_ERROR_ENTRY (ASN1_SYNTAX_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_MEM_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_MEM_ALLOC_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_DER_OVERFLOW),
LIBTASN1_ERROR_ENTRY (ASN1_NAME_TOO_LONG),
LIBTASN1_ERROR_ENTRY (ASN1_ARRAY_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_ELEMENT_NOT_EMPTY),
LIBTASN1_ERROR_ENTRY (ASN1_TIME_ENCODING_ERROR),
LIBTASN1_ERROR_ENTRY (ASN1_RECURSION),
{0, 0}
};
/**
* asn1_perror:
* @error: is an error returned by a libtasn1 function.
*
* Prints a string to stderr with a description of an error. This
* function is like perror(). The only difference is that it accepts
* an error returned by a libtasn1 function.
*
* Since: 1.6
**/
void
asn1_perror (int error)
{
const char *str = asn1_strerror (error);
fprintf (stderr, "LIBTASN1 ERROR: %s\n", str ? str : "(null)");
}
/**
* asn1_strerror:
* @error: is an error returned by a libtasn1 function.
*
* Returns a string with a description of an error. This function is
* similar to strerror. The only difference is that it accepts an
* error (number) returned by a libtasn1 function.
*
* Returns: Pointer to static zero-terminated string describing error
* code.
*
* Since: 1.6
**/
const char *
asn1_strerror (int error)
{
const libtasn1_error_entry *p;
for (p = error_algorithms; p->name != NULL; p++)
if (p->number == error)
return p->name + sizeof ("ASN1_") - 1;
return NULL;
}
+74
View File
@@ -0,0 +1,74 @@
/*
* Copyright (C) 2002-2022 Free Software Foundation, Inc.
*
* This file is part of LIBTASN1.
*
* The LIBTASN1 library is free software; you can redistribute it
* and/or modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/
#include <int.h>
#include "gstr.h"
/* These function are like strcat, strcpy. They only
* do bounds checking (they shouldn't cause buffer overruns),
* and they always produce null terminated strings.
*
* They should be used only with null terminated strings.
*/
void
_asn1_str_cat (char *dest, size_t dest_tot_size, const char *src)
{
size_t str_size = strlen (src);
size_t dest_size = strlen (dest);
if (dest_tot_size - dest_size > str_size)
{
strcat (dest, src);
}
else
{
if (dest_tot_size > dest_size)
{
strncat (dest, src, (dest_tot_size - dest_size) - 1);
dest[dest_tot_size - 1] = 0;
}
}
}
/* Returns the bytes copied (not including the null terminator) */
unsigned int
_asn1_str_cpy (char *dest, size_t dest_tot_size, const char *src)
{
size_t str_size = strlen (src);
if (dest_tot_size > str_size)
{
strcpy (dest, src);
return str_size;
}
else
{
if (dest_tot_size > 0)
{
str_size = dest_tot_size - 1;
memcpy (dest, src, str_size);
dest[str_size] = 0;
return str_size;
}
else
return 0;
}
}
+50
View File
@@ -0,0 +1,50 @@
/*
* Copyright (C) 2002-2022 Free Software Foundation, Inc.
*
* This file is part of LIBTASN1.
*
* The LIBTASN1 library is free software; you can redistribute it
* and/or modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/
#ifndef GSTR_H
# define GSTR_H
unsigned int _asn1_str_cpy (char *dest, size_t dest_tot_size,
const char *src);
void _asn1_str_cat (char *dest, size_t dest_tot_size, const char *src);
# define Estrcpy(x,y) _asn1_str_cpy(x,ASN1_MAX_ERROR_DESCRIPTION_SIZE,y)
# define Estrcat(x,y) _asn1_str_cat(x,ASN1_MAX_ERROR_DESCRIPTION_SIZE,y)
inline static void
safe_memset (void *data, int c, size_t size)
{
volatile unsigned volatile_zero = 0;
volatile char *vdata = (volatile char *) data;
/* This is based on a nice trick for safe memset,
* sent by David Jacobson in the openssl-dev mailing list.
*/
if (size > 0)
do
{
memset (data, c, size);
}
while (vdata[volatile_zero] != c);
}
#endif /* GSTR_H */
+221
View File
@@ -0,0 +1,221 @@
/*
* Copyright (C) 2002-2022 Free Software Foundation, Inc.
*
* This file is part of LIBTASN1.
*
* The LIBTASN1 library is free software; you can redistribute it
* and/or modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/
#ifndef INT_H
# define INT_H
# ifdef HAVE_CONFIG_H
# include <config.h>
# endif
# include <string.h>
# include <stdlib.h>
# include <stdio.h>
# include <stdint.h>
# ifdef HAVE_SYS_TYPES_H
# include <sys/types.h>
# endif
# include <libtasn1.h>
# define ASN1_SMALL_VALUE_SIZE 16
/* This structure is also in libtasn1.h, but then contains less
fields. You cannot make any modifications to these first fields
without breaking ABI. */
struct asn1_node_st
{
/* public fields: */
char name[ASN1_MAX_NAME_SIZE + 1]; /* Node name */
unsigned int name_hash;
unsigned int type; /* Node type */
unsigned char *value; /* Node value */
int value_len;
asn1_node down; /* Pointer to the son node */
asn1_node right; /* Pointer to the brother node */
asn1_node left; /* Pointer to the next list element */
/* private fields: */
unsigned char small_value[ASN1_SMALL_VALUE_SIZE]; /* For small values */
/* values used during decoding/coding */
int tmp_ival;
unsigned start; /* the start of the DER sequence - if decoded */
unsigned end; /* the end of the DER sequence - if decoded */
};
typedef struct tag_and_class_st
{
unsigned tag;
unsigned class;
const char *desc;
} tag_and_class_st;
/* the types that are handled in _asn1_tags */
# define CASE_HANDLED_ETYPES \
case ASN1_ETYPE_NULL: \
case ASN1_ETYPE_BOOLEAN: \
case ASN1_ETYPE_INTEGER: \
case ASN1_ETYPE_ENUMERATED: \
case ASN1_ETYPE_OBJECT_ID: \
case ASN1_ETYPE_OCTET_STRING: \
case ASN1_ETYPE_GENERALSTRING: \
case ASN1_ETYPE_NUMERIC_STRING: \
case ASN1_ETYPE_IA5_STRING: \
case ASN1_ETYPE_TELETEX_STRING: \
case ASN1_ETYPE_PRINTABLE_STRING: \
case ASN1_ETYPE_UNIVERSAL_STRING: \
case ASN1_ETYPE_BMP_STRING: \
case ASN1_ETYPE_UTF8_STRING: \
case ASN1_ETYPE_VISIBLE_STRING: \
case ASN1_ETYPE_BIT_STRING: \
case ASN1_ETYPE_SEQUENCE: \
case ASN1_ETYPE_SEQUENCE_OF: \
case ASN1_ETYPE_SET: \
case ASN1_ETYPE_UTC_TIME: \
case ASN1_ETYPE_GENERALIZED_TIME: \
case ASN1_ETYPE_SET_OF
# define ETYPE_TAG(etype) (_asn1_tags[etype].tag)
# define ETYPE_CLASS(etype) (_asn1_tags[etype].class)
# define ETYPE_OK(etype) (((etype) != ASN1_ETYPE_INVALID && \
(etype) < _asn1_tags_size && \
_asn1_tags[(etype)].desc != NULL)?1:0)
# define ETYPE_IS_STRING(etype) ((etype == ASN1_ETYPE_GENERALSTRING || \
etype == ASN1_ETYPE_NUMERIC_STRING || etype == ASN1_ETYPE_IA5_STRING || \
etype == ASN1_ETYPE_TELETEX_STRING || etype == ASN1_ETYPE_PRINTABLE_STRING || \
etype == ASN1_ETYPE_UNIVERSAL_STRING || etype == ASN1_ETYPE_BMP_STRING || \
etype == ASN1_ETYPE_UTF8_STRING || etype == ASN1_ETYPE_VISIBLE_STRING || \
etype == ASN1_ETYPE_OCTET_STRING)?1:0)
extern unsigned int _asn1_tags_size;
extern const tag_and_class_st _asn1_tags[];
# define _asn1_strlen(s) strlen((const char *) s)
# define _asn1_strtol(n,e,b) strtol((const char *) n, e, b)
# define _asn1_strtoul(n,e,b) strtoul((const char *) n, e, b)
# define _asn1_strcmp(a,b) strcmp((const char *)a, (const char *)b)
# define _asn1_strcpy(a,b) strcpy((char *)a, (const char *)b)
# define _asn1_strcat(a,b) strcat((char *)a, (const char *)b)
# if SIZEOF_UNSIGNED_LONG_INT == 8
# define _asn1_strtou64(n,e,b) strtoul((const char *) n, e, b)
# else
# define _asn1_strtou64(n,e,b) strtoull((const char *) n, e, b)
# endif
# define MAX_LOG_SIZE 1024 /* maximum number of characters of a log message */
/* Define used for visiting trees. */
# define UP 1
# define RIGHT 2
# define DOWN 3
/***********************************************************************/
/* List of constants to better specify the type of typedef asn1_node_st. */
/***********************************************************************/
/* Used with TYPE_TAG */
# define CONST_UNIVERSAL (1U<<8)
# define CONST_PRIVATE (1U<<9)
# define CONST_APPLICATION (1U<<10)
# define CONST_EXPLICIT (1U<<11)
# define CONST_IMPLICIT (1U<<12)
# define CONST_TAG (1U<<13) /* Used in ASN.1 assignement */
# define CONST_OPTION (1U<<14)
# define CONST_DEFAULT (1U<<15)
# define CONST_TRUE (1U<<16)
# define CONST_FALSE (1U<<17)
# define CONST_LIST (1U<<18) /* Used with TYPE_INTEGER and TYPE_BIT_STRING */
# define CONST_MIN_MAX (1U<<19)
# define CONST_1_PARAM (1U<<20)
# define CONST_SIZE (1U<<21)
# define CONST_DEFINED_BY (1U<<22)
/* Those two are deprecated and used for backwards compatibility */
# define CONST_GENERALIZED (1U<<23)
# define CONST_UTC (1U<<24)
/* #define CONST_IMPORTS (1U<<25) */
# define CONST_NOT_USED (1U<<26)
# define CONST_SET (1U<<27)
# define CONST_ASSIGN (1U<<28)
# define CONST_DOWN (1U<<29)
# define CONST_RIGHT (1U<<30)
# define ASN1_ETYPE_TIME 17
/****************************************/
/* Returns the first 8 bits. */
/* Used with the field type of asn1_node_st */
/****************************************/
inline static unsigned int
type_field (unsigned int ntype)
{
return (ntype & 0xff);
}
/* To convert old types from a static structure */
inline static unsigned int
convert_old_type (unsigned int ntype)
{
unsigned int type = ntype & 0xff;
if (type == ASN1_ETYPE_TIME)
{
if (ntype & CONST_UTC)
type = ASN1_ETYPE_UTC_TIME;
else
type = ASN1_ETYPE_GENERALIZED_TIME;
ntype &= ~(CONST_UTC | CONST_GENERALIZED);
ntype &= 0xffffff00;
ntype |= type;
return ntype;
}
else
return ntype;
}
static inline void *
_asn1_realloc (void *ptr, size_t size)
{
void *ret;
if (size == 0)
return ptr;
ret = realloc (ptr, size);
if (ret == NULL)
{
free (ptr);
}
return ret;
}
#endif /* INT_H */
File diff suppressed because it is too large. Load diff
+172
View File
@@ -0,0 +1,172 @@
/*
* Copyright (C) 2000-2022 Free Software Foundation, Inc.
*
* This file is part of LIBTASN1.
*
* The LIBTASN1 library is free software; you can redistribute it
* and/or modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/
#ifndef _PARSER_AUX_H
# define _PARSER_AUX_H
/***********************************************/
/* Type: list_type */
/* Description: type used in the list during */
/* the structure creation. */
/***********************************************/
typedef struct list_struct
{
asn1_node node;
struct list_struct *next;
} list_type;
/***************************************/
/* Functions used by ASN.1 parser */
/***************************************/
asn1_node _asn1_add_static_node (list_type ** e_list, unsigned int type);
void _asn1_delete_list (list_type * e_list);
void _asn1_delete_list_and_nodes (list_type * e_list);
void _asn1_delete_node_from_list (list_type * list, asn1_node node);
asn1_node
_asn1_set_value (asn1_node node, const void *value, unsigned int len);
asn1_node _asn1_set_value_m (asn1_node node, void *value, unsigned int len);
asn1_node
_asn1_set_value_lv (asn1_node node, const void *value, unsigned int len);
asn1_node
_asn1_append_value (asn1_node node, const void *value, unsigned int len);
asn1_node _asn1_set_name (asn1_node node, const char *name);
asn1_node _asn1_cpy_name (asn1_node dst, asn1_node_const src);
asn1_node _asn1_set_right (asn1_node node, asn1_node right);
asn1_node _asn1_get_last_right (asn1_node_const node);
void _asn1_remove_node (asn1_node node, unsigned int flags);
/* Max 64-bit integer length is 20 chars + 1 for sign + 1 for null termination */
# define LTOSTR_MAX_SIZE 22
char *_asn1_ltostr (int64_t v, char str[LTOSTR_MAX_SIZE]);
asn1_node _asn1_find_up (asn1_node_const node);
int _asn1_change_integer_value (asn1_node node);
# define EXPAND_OBJECT_ID_MAX_RECURSION 16
int _asn1_expand_object_id (list_type ** list, asn1_node node);
int _asn1_type_set_config (asn1_node node);
int _asn1_check_identifier (asn1_node_const node);
int _asn1_set_default_tag (asn1_node node);
/******************************************************************/
/* Function : _asn1_get_right */
/* Description: returns the element pointed by the RIGHT field of */
/* a NODE_ASN element. */
/* Parameters: */
/* node: NODE_ASN element pointer. */
/* Return: field RIGHT of NODE. */
/******************************************************************/
inline static asn1_node
_asn1_get_right (asn1_node_const node)
{
if (node == NULL)
return NULL;
return node->right;
}
/******************************************************************/
/* Function : _asn1_set_down */
/* Description: sets the field DOWN in a NODE_ASN element. */
/* Parameters: */
/* node: element pointer. */
/* down: pointer to a NODE_ASN element that you want be pointed */
/* by NODE. */
/* Return: pointer to *NODE. */
/******************************************************************/
inline static asn1_node
_asn1_set_down (asn1_node node, asn1_node down)
{
if (node == NULL)
return node;
node->down = down;
if (down)
down->left = node;
return node;
}
/******************************************************************/
/* Function : _asn1_get_down */
/* Description: returns the element pointed by the DOWN field of */
/* a NODE_ASN element. */
/* Parameters: */
/* node: NODE_ASN element pointer. */
/* Return: field DOWN of NODE. */
/******************************************************************/
inline static asn1_node
_asn1_get_down (asn1_node_const node)
{
if (node == NULL)
return NULL;
return node->down;
}
/******************************************************************/
/* Function : _asn1_get_name */
/* Description: returns the name of a NODE_ASN element. */
/* Parameters: */
/* node: NODE_ASN element pointer. */
/* Return: a null terminated string. */
/******************************************************************/
inline static char *
_asn1_get_name (asn1_node_const node)
{
if (node == NULL)
return NULL;
return (char *) node->name;
}
/******************************************************************/
/* Function : _asn1_mod_type */
/* Description: change the field TYPE of an NODE_ASN element. */
/* The new value is the old one | (bitwise or) the */
/* paramener VALUE. */
/* Parameters: */
/* node: NODE_ASN element pointer. */
/* value: the integer value that must be or-ed with the current */
/* value of field TYPE. */
/* Return: NODE pointer. */
/******************************************************************/
inline static asn1_node
_asn1_mod_type (asn1_node node, unsigned int value)
{
if (node == NULL)
return node;
node->type |= value;
return node;
}
#endif
File diff suppressed because it is too large. Load diff
+46
View File
@@ -0,0 +1,46 @@
/*
* Copyright (C) 2002-2022 Free Software Foundation, Inc.
*
* This file is part of LIBTASN1.
*
* The LIBTASN1 library is free software; you can redistribute it
* and/or modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA
*/
/*************************************************/
/* File: structure.h */
/* Description: list of exported object by */
/* "structure.c" */
/*************************************************/
#ifndef _STRUCTURE_H
# define _STRUCTURE_H
# include "parser_aux.h" /* list_type */
int _asn1_create_static_structure (asn1_node_const pointer,
char *output_file_name, char *vector_name);
asn1_node _asn1_copy_structure3 (asn1_node_const source_node);
asn1_node _asn1_add_single_node (unsigned int type);
asn1_node _asn1_find_left (asn1_node_const node);
int
_asn1_delete_structure (list_type * e_list, asn1_node * structure,
unsigned int flags);
#endif