1 /*-------------------------------------------------------------------------- 2 // Copyright (C) 2015-2021 Cisco and/or its affiliates. All rights reserved. 3 // 4 // This program is free software; you can redistribute it and/or modify it 5 // under the terms of the GNU General Public License Version 2 as published 6 // by the Free Software Foundation. You may not use, modify or distribute 7 // this program under any other version of the GNU General Public License. 8 // 9 // This program is distributed in the hope that it will be useful, but 10 // WITHOUT ANY WARRANTY; without even the implied warranty of 11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 12 // General Public License for more details. 13 // 14 // You should have received a copy of the GNU General Public License along 15 // with this program; if not, write to the Free Software Foundation, Inc., 16 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 //-------------------------------------------------------------------------- 18 */ 19 /* daq_user.h author Russ Combs <rucombs@cisco.com> */ 20 /* this is a C include, not C++ */ 21 22 #ifndef DAQ_USER_H 23 #define DAQ_USER_H 24 25 #include <stdint.h> 26 #include <daq_common.h> 27 28 /* for raw payload only */ 29 #define DLT_USER 230 30 31 /* DAQ_UsrHdr_t.flags */ 32 #define DAQ_USR_FLAG_TO_SERVER 0x01 33 #define DAQ_USR_FLAG_START_FLOW 0x02 34 #define DAQ_USR_FLAG_END_FLOW 0x04 35 36 typedef struct 37 { 38 uint32_t src_addr; 39 uint32_t dst_addr; 40 uint16_t src_port; 41 uint16_t dst_port; 42 uint8_t ip_proto; 43 uint8_t flags; 44 } DAQ_UsrHdr_t; 45 46 #define DIOCTL_QUERY_USR_PCI (DAQ_IoctlCmd) 2048 47 typedef struct 48 { 49 DAQ_Msg_h msg; 50 DAQ_UsrHdr_t* pci; 51 } DIOCTL_QueryUsrPCI; 52 53 #endif 54 55