monitube2-data_packet.h

Go to the documentation of this file.
00001 /*
00002  * $Id: monitube2-data_packet.h 347265 2009-11-19 13:55:39Z kdickman $
00003  *
00004  * This code is provided as is by Juniper Networks SDK Developer Support.
00005  * It is provided with no warranties or guarantees, and Juniper Networks
00006  * will not provide support or maintenance of this code in any fashion.
00007  * The code is provided only to help a developer better understand how
00008  * the SDK can be used.
00009  *
00010  * Copyright (c) 2009, Juniper Networks, Inc.
00011  * All rights reserved.
00012  */
00013 
00021 #ifndef __MONITUBE_DATA_PACKET_H__
00022 #define __MONITUBE_DATA_PACKET_H__
00023 
00024 /*** Constants ***/
00025 
00026 
00027 /*** Data structures ***/
00028 
00032 typedef struct flow_entry_s {
00033     // flow information
00034     time_t                       age_ts;     
00035     in_addr_t                    daddr;      
00036     uint16_t                     dport;      
00037 
00038     // mirroring related:
00039     in_addr_t                    maddr;      
00040     uint32_t                     m_vrf;      
00041 
00042     // monitoring related:
00043        // MDI media loss rate related:
00044     uint32_t                     ssrc;       
00045     source_t                     source;     
00046     int32_t                      mdi_mlr;    
00047        // MDI delay factor related:
00048     uint32_t                     rate;       
00049     msp_hw_ts32_t                base_ts;    
00050     uint32_t                     pl_sum;     
00051     double                       vb_pre;     
00052     double                       vb_post;    
00053     double                       vb_min;     
00054     double                       vb_max;     
00055     double                       mdi_df;     
00056 
00057     // for list at this hash bucket:
00058     TAILQ_ENTRY(flow_entry_s)    entries;    
00059 } flow_entry_t;
00060 
00061 /*** GLOBAL/EXTERNAL Functions ***/
00062 
00063 
00078 status_t
00079 pullup_bytes(struct jbuf ** pkt_buf, uint16_t num_bytes);
00080 
00081 
00095 void
00096 process_packet(struct jbuf * jb, flow_entry_t * flow, uint16_t ssid);
00097 
00098 #endif

2007-2009 Juniper Networks, Inc. All rights reserved. The information contained herein is confidential information of Juniper Networks, Inc., and may not be used, disclosed, distributed, modified, or copied without the prior written consent of Juniper Networks, Inc. in an express license. This information is subject to change by Juniper Networks, Inc. Juniper Networks, the Juniper Networks logo, and JUNOS are registered trademarks of Juniper Networks, Inc. in the United States and other countries. All other trademarks, service marks, registered trademarks, or registered service marks are the property of their respective owners.
Generated on Sun May 30 20:27:09 2010 for SDK Your Net Corporation Monitube2 IPTV Monitoring Example: monitube2-plugin 1.0 by Doxygen 1.5.1