Changeset 58c226e for lib/libtrace.h.in


Ignore:
Timestamp:
02/05/19 15:12:49 (2 years ago)
Author:
Jacob Van Walraven <jcv9@…>
Branches:
develop
Children:
4e5a51f
Parents:
7b4f5e2
Message:

Move function descriptions to the correct header file, Revert trace_get_interface_ipv4 changes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lib/libtrace.h.in

    r7b4f5e2 r58c226e  
    37253725/*@}*/
    37263726
     3727/* Destroy libtrace_meta_t structure
     3728 *
     3729 * @params libtrace_meta_t structure
     3730 * returns 1 on success, -1 on failure
     3731 */
    37273732DLLEXPORT int trace_destroy_meta(libtrace_meta_t *result);
    37283733
    3729 DLLEXPORT libtrace_meta_t *trace_get_meta_option(libtrace_packet_t *packet, uint32_t section,
    3730         uint32_t option);
    3731 
     3734/* Get the interface name/s for a meta packet.
     3735 * Must be destroyed with trace_destroy_meta().
     3736 *
     3737 * @params libtrace_packet_t meta packet.
     3738 * @returns Pointer to libtrace_meta_t structure containing all found interface names
     3739 * or NULL.
     3740 */
    37323741DLLEXPORT libtrace_meta_t *trace_get_interface_name_meta(libtrace_packet_t *packet);
    37333742
     3743/* Get the interface name for a meta packet.
     3744 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3745 * specify the interface index.
     3746 *
     3747 * @params libtrace_packet_t meta packet to extract the interface name from.
     3748 * @params A pointer to a character buffer to store the interface name in.
     3749 * @params The size of the buffer passed in.
     3750 * @params The interface index within the meta packet.
     3751 * @returns Pointer to the character buffer containing the interface name or NULL.
     3752 */
    37343753DLLEXPORT char *trace_get_interface_name(libtrace_packet_t *packet, char *space, int spacelen,
    37353754        int index);
    37363755
     3756/* Get the interface MAC address/s for a meta packet.
     3757 * Must be destroyed with trace_destroy_meta().
     3758 *
     3759 * @params libtrace_packet_t meta packet.
     3760 * @returns Pointer to libtrace_meta_t structure containing all found interface mac
     3761 * addresses or NULL.
     3762 */
    37373763DLLEXPORT libtrace_meta_t *trace_get_interface_mac_meta(libtrace_packet_t *packet);
    37383764
     3765/* Get the interface MAC address for a meta packet.
     3766 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3767 * specify the interface index.
     3768 *
     3769 * @params libtrace_packet_t meta packet to extract the MAC address from.
     3770 * @params A pointer to a character buffer to store the MAC address in.
     3771 * @params The size of the buffer passed in.
     3772 * @params The interface index within the meta packet.
     3773 * @returns Pointer to the character buffer containing the MAC address or NULL.
     3774 */
    37393775DLLEXPORT char *trace_get_interface_mac(libtrace_packet_t *packet, char *space, int spacelen,
    37403776        int index);
    37413777
     3778/* Get the interface speed/s from a meta packet.
     3779 * Must be destroyed with trace_destroy_meta().
     3780 *
     3781 * @params libtrace_packet_t packet.
     3782 * @returns Pointer to libtrace_meta_t structure containing all found interface
     3783 * speeds or NULL.
     3784 */
    37423785DLLEXPORT libtrace_meta_t *trace_get_interface_speed_meta(libtrace_packet_t *packet);
    37433786
     3787/* Get the interface speed for a meta packet.
     3788 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3789 * specify the interface index.
     3790 *
     3791 * @params libtrace_packet_t meta packet to extract the interface speed from.
     3792 * @params The interface index within the meta packet.
     3793 * @returns uint64_t interface speed or NULL.
     3794 */
    37443795DLLEXPORT uint64_t trace_get_interface_speed(libtrace_packet_t *packet, int index);
    37453796
    3746 
     3797/* Get the interface ipv4 address/s for a meta packet.
     3798 * Must be destroyed with trace_destroy_meta().
     3799 *
     3800 * @params libtrace_packet_t meta packet.
     3801 * @returns Pointer to libtrace_meta_t structure containing all found ipv4 addresses
     3802 * or NULL
     3803 */
    37473804DLLEXPORT libtrace_meta_t *trace_get_interface_ipv4_meta(libtrace_packet_t *packet);
    37483805
     3806/* Get the interface ipv4 address for a meta packet.
     3807 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3808 * specify the interface index.
     3809 *
     3810 * @params libtrace_packet_t meta packet to extract the ipv4 address from.
     3811 * @params The interface index within the meta packet.
     3812 * @returns uint32_t ipv4 address or 0.
     3813 */
    37493814DLLEXPORT uint32_t trace_get_interface_ipv4(libtrace_packet_t *packet, int index);
    37503815
    3751 DLLEXPORT char *trace_get_interface_ipv4_string(libtrace_packet_t *packet, int index);
    3752 
     3816/* Get the interface ipv4 address string for a meta packet.
     3817 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3818 * specify the interface index.
     3819 *
     3820 * @params libtrace_packet_t meta packet to extract the ipv4 address from.
     3821 * @params A pointer to a character buffer to store the ipv4 address string in.
     3822 * @params The size of the buffer passed in.
     3823 * @params The interface index within the meta packet.
     3824 * @returns Pointer to the character buffer containing the ipv4 address string or NULL.
     3825 */
     3826DLLEXPORT char *trace_get_interface_ipv4_string(libtrace_packet_t *packet, char* space, int spacelen,
     3827        int index);
     3828
     3829/* Get the interface ipv6 address/s for a meta packet.
     3830 * Must be destroyed with trace_destroy_meta().
     3831 *
     3832 * @params libtrace_packet_t meta packet.
     3833 * @returns Pointer to libtrace_meta_t structure containing all found ipv6 addresses
     3834 * or NULL.
     3835 */
    37533836DLLEXPORT libtrace_meta_t *trace_get_interface_ipv6_meta(libtrace_packet_t *packet);
    37543837
     3838/* Get the interface ipv6 address for a meta packet.
     3839 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3840 * specify the interface index.
     3841 *
     3842 * @params libtrace_packet_t meta packet to extract the ipv6 address from.
     3843 * @params A pointer to a character buffer to store the ipv6 address in.
     3844 * @params The size of the buffer passed in.
     3845 * @params The interface index within the meta packet.
     3846 * @returns Pointer to the buffer containing the ipv6 address or NULL.
     3847 */
    37553848DLLEXPORT void *trace_get_interface_ipv6(libtrace_packet_t *packet, void *space, int spacelen,
    37563849        int index);
    37573850
     3851/* Get the interface ipv6 address string for a meta packet.
     3852 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3853 * specify the interface index.
     3854 *
     3855 * @params libtrace_packet_t meta packet to extract the ipv6 address from.
     3856 * @params A pointer to a character buffer to store the ipv6 address in.
     3857 * @params The size of the buffer passed in.
     3858 * @params The interface index within the meta packet.
     3859 * @returns Pointer to the character buffer containing the ipv6 address string or NULL.
     3860 */
    37583861DLLEXPORT char *trace_get_interface_ipv6_string(libtrace_packet_t *packet, char *space, int spacelen,
    37593862        int index);
    37603863
     3864/* Get the interface description/s for a meta packet.
     3865 * Must be destroyed with trace_destroy_meta().
     3866 *
     3867 * @params libtrace_packet_t meta packet.
     3868 * @returns Pointer to libtrace_meta_t structure containing all found interface
     3869 * descriptions or NULL.
     3870 */
    37613871DLLEXPORT libtrace_meta_t *trace_get_interface_description_meta(libtrace_packet_t *packet);
    37623872
     3873/* Get the interface description for a meta packet.
     3874 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3875 * specify the interface index.
     3876 *
     3877 * @params libtrace_packet_t meta packet to extract the interface description from.
     3878 * @params A pointer to a character buffer to store the interface description in.
     3879 * @params The size of the buffer passed in.
     3880 * @params The interface index within the meta packet.
     3881 * @returns Pointer to the character buffer containing the interface description or NULL.
     3882 */
    37633883DLLEXPORT char *trace_get_interface_description(libtrace_packet_t *packet, char *space, int spacelen,
    3764 
    37653884        int index);
    37663885
     3886/* Get the host OS for a meta packet.
     3887 * Must be destroyed with trace_destroy_meta().
     3888 *
     3889 * @params libtrace_packet_t meta packet.
     3890 * @returns Pointer to libtrace_meta_t structure containing the host OS or NULL.
     3891 */
    37673892DLLEXPORT libtrace_meta_t *trace_get_host_os_meta(libtrace_packet_t *packet);
    37683893
     3894/* Get the host OS for a meta packet.
     3895 *
     3896 * @params libtrace_packet_t meta packet to extract the host OS from.
     3897 * @params A pointer to a character buffer to store the host OS in.
     3898 * @params The size of the buffer passed in.
     3899 * @returns Pointer to the character buffer containing the host OS or NULL.
     3900 */
    37693901DLLEXPORT char *trace_get_host_os(libtrace_packet_t *packet, char *space, int spacelen);
    37703902
     3903/* Get the interface frame check sequence length for a meta packet.
     3904 * Must be destroyed with trace_destroy_meta().
     3905 *
     3906 * @params libtrace_packet_t meta packet.
     3907 * @returns Pointer to libtrace_meta_t structure containing all found frame check
     3908 * sequence lengths or NULL.
     3909 */
    37713910DLLEXPORT libtrace_meta_t *trace_get_interface_fcslen_meta(libtrace_packet_t *packet);
    37723911
     3912/* Get the interface frame check sequence length for a meta packet.
     3913 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3914 * specify the interface index.
     3915 *
     3916 * @params libtrace_packet_t meta packet to extract the interface fcslen from.
     3917 * @params The interface index within the meta packet.
     3918 * @returns uint32_t frame check sequence length or 0.
     3919 */
    37733920DLLEXPORT uint32_t trace_get_interface_fcslen(libtrace_packet_t *packet, int index);
    37743921
     3922/* Get any interface comments for a meta packet
     3923 * Must be destroyed with trace_destroy_meta()
     3924 *
     3925 * @params libtrace_packet_t packet
     3926 * @returns Pointer to libtrace_meta_t structure or NULL
     3927 */
    37753928DLLEXPORT libtrace_meta_t *trace_get_interface_comment_meta(libtrace_packet_t *packet);
    37763929
     3930/* Get the interface comment for a meta packet.
     3931 * Note: ERF packets can contain multiple interfaces per meta packet. Use index to
     3932 * specify the interface ID.
     3933 *
     3934 * @params libtrace_packet_t meta packet to extract the interface comment from.
     3935 * @params A pointer to a character buffer to store the interface description in.
     3936 * @params The size of the buffer passed in.
     3937 * @params The interface number within the meta packet.
     3938 * @returns Pointer to the character buffer containing the hardware description or NULL.
     3939 */
    37773940DLLEXPORT char *trace_get_interface_comment(libtrace_packet_t *packet, char *space, int spacelen,
    37783941        int index);
    37793942
     3943/* Get the capture application for a meta packet
     3944 * Must be destroyed with trace_destroy_meta()
     3945 *
     3946 * @params libtrace_packet_t packet
     3947 * @returns Pointer to libtrace_meta_t structure or NULL
     3948 */
    37803949DLLEXPORT libtrace_meta_t *trace_get_capture_application_meta(libtrace_packet_t *packet);
    37813950
     3951/* Get the capture application for a meta packet.
     3952 *
     3953 * @params libtrace_packet_t meta packet to extract the application name from.
     3954 * @params A pointer to a character buffer to store the application name in.
     3955 * @params The size of the buffer passed in.
     3956 * @returns Pointer to the character buffer containing the application name or NULL.
     3957 */
    37823958DLLEXPORT char *trace_get_capture_application(libtrace_packet_t *packet, char *space, int spacelen);
    37833959
     3960/* Get a meta section option from a meta packet
     3961 * Must be destroyed with trace_destroy_meta()
     3962 *
     3963 * @params libtrace_packet_t packet
     3964 * @params Section code
     3965 * @params Option code
     3966 * @returns Pointer to libtrace_meta_t structure or NULL
     3967 */
    37843968DLLEXPORT libtrace_meta_t *trace_get_section_option(libtrace_packet_t *packet, uint32_t section_code,
    37853969        uint16_t option_code);
    37863970
     3971/* Get a section from a meta packet
     3972 * Must be destroyed with trace_destroy_meta()
     3973 *
     3974 * @params libtrace_packet_t packet
     3975 * @params Section code
     3976 * @returns Pointer to libtrace_meta_t structure or NULL
     3977 */
    37873978DLLEXPORT libtrace_meta_t *trace_get_section(libtrace_packet_t *packet, uint32_t section_code);
    37883979
     3980/* Get the DAG card model from a meta packet.
     3981 *
     3982 * @params libtrace_packet_t meta packet to extract the DAG model from.
     3983 * @params A pointer to a character buffer to store the DAG model in.
     3984 * @params The size of the buffer passed in.
     3985 * @returns Pointer to the character buffer containing the DAG model or NULL.
     3986 */
    37893987DLLEXPORT char *trace_get_erf_dag_card_model(libtrace_packet_t *packet, char *space,
    37903988        int spacelen);
    37913989
     3990/* Get the host DAG software version for a meta packet.
     3991 *
     3992 * @params libtrace_packet_t meta packet to extract the hosts DAG verion from.
     3993 * @params A pointer to a character buffer to store the DAG version in.
     3994 * @params The size of the buffer passed in.
     3995 * @returns Pointer to the character buffer containing the DAG version or NULL.
     3996 */
    37923997DLLEXPORT char *trace_get_erf_dag_version(libtrace_packet_t *packet, char *space,
    37933998        int spacelen);
    37943999
     4000/* Get the firmware version for a DAG module from a meta packet.
     4001 *
     4002 * @params libtrace_packet_t meta packet to extract the FW version from.
     4003 * @params A pointer to a character buffer to store the FW version in.
     4004 * @params The size of the buffer passed in.
     4005 * @returns Pointer to the character buffer containing the FW version or NULL.
     4006 */
    37954007DLLEXPORT char *trace_get_erf_dag_fw_version(libtrace_packet_t *packet, char *space,
    37964008        int spacelen);
Note: See TracChangeset for help on using the changeset viewer.