Pcap.cpp revision 4ad29c8f6cdb903e72162c3d5d0446b6798e712a
2N/A * Helpers for writing libpcap files. 2N/A * Copyright (C) 2006-2011 Oracle Corporation 2N/A * This file is part of VirtualBox Open Source Edition (OSE), as 2N/A * you can redistribute it and/or modify it under the terms of the GNU 2N/A * General Public License (GPL) as published by the Free Software 2N/A * Foundation, in version 2 as it comes in the "COPYING" file of the 2N/A * VirtualBox OSE distribution. VirtualBox OSE is distributed in the 2N/A * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind. 2N/A/******************************************************************************* 2N/A*******************************************************************************/ 2N/A/******************************************************************************* 2N/A* Structures and Typedefs * *******************************************************************************/ /* "libpcap" file header (minus magic number). */ /* "libpcap" record header. */ /******************************************************************************* *******************************************************************************/ {
2,
4, 0, 0,
0xffff,
1 },
* Writes the stream header. * @returns IPRT status code, @see RTStrmWrite. * @param pStream The stream handle. * @param StartNanoTS What to subtract from the RTTimeNanoTS output. * Writes a frame to a stream. * @returns IPRT status code, @see RTStrmWrite. * @param pStream The stream handle. * @param StartNanoTS What to subtract from the RTTimeNanoTS output. * @param pvFrame The start of the frame. * @param cbFrame The size of the frame. * @param cbMax The max number of bytes to include in the file. * Writes a GSO frame to a stream. * @returns IPRT status code, @see RTStrmWrite. * @param pStream The stream handle. * @param StartNanoTS What to subtract from the RTTimeNanoTS output. * @param pGso Pointer to the GSO context. * @param pvFrame The start of the GSO frame. * @param cbFrame The size of the GSO frame. * @param cbSegMax The max number of bytes to include in the file for * Writes the file header. * @returns IPRT status code, @see RTFileWrite. * @param File The file handle. * @param StartNanoTS What to subtract from the RTTimeNanoTS output. * Writes a frame to a file. * @returns IPRT status code, @see RTFileWrite. * @param File The file handle. * @param StartNanoTS What to subtract from the RTTimeNanoTS output. * @param pvFrame The start of the frame. * @param cbFrame The size of the frame. * @param cbMax The max number of bytes to include in the file. * Writes a GSO frame to a file. * @returns IPRT status code, @see RTFileWrite. * @param File The file handle. * @param StartNanoTS What to subtract from the RTTimeNanoTS output. * @param pGso Pointer to the GSO context. * @param pvFrame The start of the GSO frame. * @param cbFrame The size of the GSO frame. * @param cbSegMax The max number of bytes to include in the file for