/*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*\ File: octvc1_common.h Copyright (c) 2014 Octasic Inc. All rights reserved. Description: Contain the wireshark module dissector related functions This program is free software; you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. This program 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 General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . Release: Octasic Application Development Framework OCTADF-01.00.01-B497 (2014/01/09) $Octasic_Revision: $ \*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*/ /***************************** INCLUDE FILES *******************************/ #ifndef _OCTVC1_COMMON_H__ #define _OCTVC1_COMMON_H__ #include #include "octdev_common.h" #include "octpkt_common.h" #include "octvocnet_common.h" /**************************************************************************** COMMON API ENUMERATION STRING VALUES ****************************************************************************/ extern const value_string vals_tOCTVC1_OBJECT_CURSOR_ENUM[]; extern const value_string vals_tOCTVC1_BUFFER_FORMAT_ENUM[]; extern const value_string vals_tOCTVC1_BUFFER_FORMAT_MAIN_ENUM[]; extern const value_string vals_tOCTVC1_ETH_PORT_ID_ENUM[]; extern const value_string vals_tOCTVC1_IP_VERSION_ENUM[]; extern const value_string vals_tOCTVC1_VLAN_PROTOCOL_ID_ENUM[]; extern const value_string vals_tOCTVC1_MSG_FLAGS_MASK[]; extern const value_string vals_tOCTVC1_LOG_TYPE_ENUM[]; extern const value_string vals_tOCTVC1_LOG_LEVEL_ENUM[]; extern const value_string vals_tOCTVC1_LOG_TRACE_MASK[]; extern const value_string vals_tOCTVC1_FILE_TYPE_ENUM[]; extern const value_string vals_tOCTVC1_FILE_FORMAT_ENUM[]; /**************************************************************************** COMMON API DISSECTOR ****************************************************************************/ extern unsigned int dissect_tOCTVC1_CURSOR_HANDLE_GET(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_CURSOR_HANDLE_GET_HANDLE(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_CURSOR_HANDLE_GET_HANDLE_OBJECT(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_CURSOR_HANDLE_GET_SUB_OBJECT_ID(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_CURSOR_HANDLE_OBJECT_GET(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_CURSOR_HANDLE_OBJECT_GET_HANDLE_OBJECT(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_CURSOR_HANDLE_OBJECT_GET_SUB_OBJECT_ID(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_CURSOR_INDEX_GET(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_VLAN_TAG(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_VLAN_HEADER_INFO(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_LIST_HANDLE_GET(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_LIST_HANDLE_GET_SUB_OBJECT_ID(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_LIST_HANDLE_OBJECT_GET(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_LIST_HANDLE_OBJECT_GET_SUB_OBJECT_ID(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_LIST_INDEX_GET(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_MSG_HEADER(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_EVENT_HEADER(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_LOG_HEADER(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_FILE_HEADER(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); extern unsigned int dissect_tOCTVC1_HANDLE(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, unsigned int offset, tWS_EXTRA_VALUE *pExtValue ); /**************************************************************************** COMMON USER REGISTATION ****************************************************************************/ void ws_register_OCTVC1_common(void); #define cOCTVC1_PRIVATE_ID_STRING "unknowned_private" #define cOCTVC1_UNKNOWN_STRING "Unknown" #define cOCTVC1_GOD_USER "oct-super-user" #define cOCTVC1_GOD_USER_ID "octsu98asic" #define cOCTVC1_PRIVATE_VISIBILITY_USER "oct-dev" #ifdef OCT_DECLARE_COMMON gchar* aOCTVC1_user_list[][2] = { { "oct-dev","octdev98asic"}, { "feature-spec","feature-psw"}, { "company","company-psw"}, { "company-2","company-2-psw"}, {NULL,NULL} }; #else gchar* aOCTVC1_user_list[][2]; #endif /* OCT_DECLARE_COMMON */ extern const gchar* octvc1_chck_private( guint32 f_event_id_code, const value_string *f_PrivateApi, gint32 * f_piRegistered ); #endif /* _OCTVC1_COMMON_H__ */