xref: /illumos-gate/usr/src/lib/libsip/common/sip_parse_generic.h (revision 1da57d551424de5a9d469760be7c4b4d4f10a755)
140cb5e5dSvi117747 /*
240cb5e5dSvi117747  * CDDL HEADER START
340cb5e5dSvi117747  *
440cb5e5dSvi117747  * The contents of this file are subject to the terms of the
540cb5e5dSvi117747  * Common Development and Distribution License (the "License").
640cb5e5dSvi117747  * You may not use this file except in compliance with the License.
740cb5e5dSvi117747  *
840cb5e5dSvi117747  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
940cb5e5dSvi117747  * or http://www.opensolaris.org/os/licensing.
1040cb5e5dSvi117747  * See the License for the specific language governing permissions
1140cb5e5dSvi117747  * and limitations under the License.
1240cb5e5dSvi117747  *
1340cb5e5dSvi117747  * When distributing Covered Code, include this CDDL HEADER in each
1440cb5e5dSvi117747  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
1540cb5e5dSvi117747  * If applicable, add the following below this CDDL HEADER, with the
1640cb5e5dSvi117747  * fields enclosed by brackets "[]" replaced with your own identifying
1740cb5e5dSvi117747  * information: Portions Copyright [yyyy] [name of copyright owner]
1840cb5e5dSvi117747  *
1940cb5e5dSvi117747  * CDDL HEADER END
2040cb5e5dSvi117747  */
2140cb5e5dSvi117747 
2240cb5e5dSvi117747 /*
232c2c4183Svi117747  * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
2440cb5e5dSvi117747  * Use is subject to license terms.
2540cb5e5dSvi117747  */
2640cb5e5dSvi117747 
2740cb5e5dSvi117747 #ifndef	_SIP_PARSE_GENERIC_H
2840cb5e5dSvi117747 #define	_SIP_PARSE_GENERIC_H
2940cb5e5dSvi117747 
3040cb5e5dSvi117747 #ifdef	__cplusplus
3140cb5e5dSvi117747 extern "C" {
3240cb5e5dSvi117747 #endif
3340cb5e5dSvi117747 
342c2c4183Svi117747 #include <sip.h>
352c2c4183Svi117747 #include <sys/types.h>
362c2c4183Svi117747 
372c2c4183Svi117747 #include "sip_msg.h"
382c2c4183Svi117747 
3940cb5e5dSvi117747 extern int		sip_atoi(_sip_header_t	*, int *);
4040cb5e5dSvi117747 extern int		sip_find_token(_sip_header_t  *, char);
4140cb5e5dSvi117747 extern int		sip_find_cr(_sip_header_t *);
42*df4705eaSgm209912 extern int		sip_find_separator(_sip_header_t *, char, char, char,
43*df4705eaSgm209912 			    boolean_t);
4440cb5e5dSvi117747 extern int		sip_find_white_space(_sip_header_t *);
4540cb5e5dSvi117747 extern int		sip_skip_white_space(_sip_header_t *);
4640cb5e5dSvi117747 extern int		sip_reverse_skip_white_space(_sip_header_t *);
4740cb5e5dSvi117747 extern int		sip_parse_goto_values(_sip_header_t  *);
4840cb5e5dSvi117747 extern int		sip_goto_next_value(_sip_header_t *);
4940cb5e5dSvi117747 extern int		sip_parse_params(_sip_header_t *, sip_param_t **);
5040cb5e5dSvi117747 extern int		sip_prim_parsers(_sip_header_t *,
5140cb5e5dSvi117747 			    sip_parsed_header_t **);
5240cb5e5dSvi117747 extern boolean_t	sip_is_empty_hdr(_sip_header_t *);
5340cb5e5dSvi117747 extern int		sip_parse_hdr_empty(_sip_header_t *,
5440cb5e5dSvi117747 			    sip_parsed_header_t **);
5540cb5e5dSvi117747 int			sip_get_protocol_version(_sip_header_t *,
5640cb5e5dSvi117747 			    sip_proto_version_t *sip_proto_version);
5740cb5e5dSvi117747 extern int		sip_parse_first_line(_sip_header_t *,
5840cb5e5dSvi117747 			    sip_message_type_t **);
5940cb5e5dSvi117747 extern int		sip_parse_hdr_parser1(_sip_header_t *,
6040cb5e5dSvi117747 			    sip_parsed_header_t **, char);
6140cb5e5dSvi117747 extern int		sip_parse_hdr_parser2(_sip_header_t *,
6240cb5e5dSvi117747 			    sip_parsed_header_t **, int);
6340cb5e5dSvi117747 extern int		sip_parse_hdr_parser3(_sip_header_t *,
6440cb5e5dSvi117747 			    sip_parsed_header_t **, int, boolean_t);
6540cb5e5dSvi117747 extern int		sip_parse_hdr_parser4(_sip_header_t *,
6640cb5e5dSvi117747 			    sip_parsed_header_t **);
6740cb5e5dSvi117747 extern int		sip_parse_hdr_parser5(_sip_header_t *,
6840cb5e5dSvi117747 			    sip_parsed_header_t **, boolean_t);
6940cb5e5dSvi117747 #ifdef	__cplusplus
7040cb5e5dSvi117747 }
7140cb5e5dSvi117747 #endif
7240cb5e5dSvi117747 
7340cb5e5dSvi117747 #endif	/* _SIP_PARSE_GENERIC_H */
74