Lev Walkin | f15320b | 2004-06-03 03:38:44 +0000 | [diff] [blame] | 1 | /* |
| 2 | * This is a parser of the ASN.1 grammar. |
| 3 | */ |
| 4 | #ifndef ASN1PARSER_H |
| 5 | #define ASN1PARSER_H |
| 6 | |
| 7 | #ifdef HAVE_CONFIG_H |
| 8 | #include "config.h" |
| 9 | #endif /* HAVE_CONFIG_H */ |
| 10 | |
Lev Walkin | c0e03b9 | 2017-08-22 01:48:23 -0700 | [diff] [blame] | 11 | #include "asn1_ref.h" |
| 12 | #include "asn1_buffer.h" |
| 13 | #include "asn1_namespace.h" |
| 14 | |
Lev Walkin | da997b1 | 2017-08-04 01:38:41 -0700 | [diff] [blame] | 15 | #include "asn1p_integer.h" |
Lev Walkin | 4efbfb7 | 2005-02-25 14:20:30 +0000 | [diff] [blame] | 16 | #include "asn1p_list.h" |
| 17 | #include "asn1p_oid.h" /* Object identifiers (OIDs) */ |
Bi-Ruei, Chiu | 80fd306 | 2017-05-07 21:00:51 +0800 | [diff] [blame] | 18 | #include "asn1p_module.h" /* ASN.1 definition module */ |
Lev Walkin | 4efbfb7 | 2005-02-25 14:20:30 +0000 | [diff] [blame] | 19 | #include "asn1p_value.h" /* Value definition */ |
Lev Walkin | a00d6b3 | 2006-03-21 03:40:38 +0000 | [diff] [blame] | 20 | #include "asn1p_param.h" /* Parameterization */ |
Lev Walkin | 4efbfb7 | 2005-02-25 14:20:30 +0000 | [diff] [blame] | 21 | #include "asn1p_constr.h" /* Type Constraints */ |
| 22 | #include "asn1p_xports.h" /* IMports/EXports */ |
Lev Walkin | 4efbfb7 | 2005-02-25 14:20:30 +0000 | [diff] [blame] | 23 | #include "asn1p_class.h" /* CLASS-related stuff */ |
| 24 | #include "asn1p_expr.h" /* A single ASN.1 expression */ |
Lev Walkin | f15320b | 2004-06-03 03:38:44 +0000 | [diff] [blame] | 25 | |
| 26 | /* |
| 27 | * Parser flags. |
| 28 | */ |
| 29 | enum asn1p_flags { |
| 30 | A1P_NOFLAGS, |
| 31 | /* |
| 32 | * Enable verbose debugging output from lexer. |
| 33 | */ |
Lev Walkin | 7085305 | 2005-11-26 11:21:55 +0000 | [diff] [blame] | 34 | A1P_LEXER_DEBUG = 0x0001 |
Lev Walkin | f15320b | 2004-06-03 03:38:44 +0000 | [diff] [blame] | 35 | }; |
| 36 | |
| 37 | /* |
| 38 | * Perform low-level parsing of ASN.1 module[s] |
| 39 | * and return a list of module trees. |
| 40 | */ |
| 41 | asn1p_t *asn1p_parse_file(const char *filename, |
| 42 | enum asn1p_flags); |
| 43 | asn1p_t *asn1p_parse_buffer(const char *buffer, int size /* = -1 */, |
| 44 | enum asn1p_flags); |
| 45 | |
Bi-Ruei, Chiu | 3dcf05b | 2017-05-04 21:45:05 +0800 | [diff] [blame] | 46 | int asn1p_lex_destroy(); |
Lev Walkin | d370e9f | 2006-03-16 10:03:35 +0000 | [diff] [blame] | 47 | |
Lev Walkin | f15320b | 2004-06-03 03:38:44 +0000 | [diff] [blame] | 48 | #endif /* ASN1PARSER_H */ |