aboutsummaryrefslogtreecommitdiffstats
path: root/wiretap
AgeCommit message (Collapse)AuthorFilesLines
2013-05-17Don't pass globals as arguments to k12text_set_headers(), just use theGuy Harris1-7/+5
globals directly. If we ever manage to make them *not* globals (which might only be possible with newer versions of Flex), then we can do better. Get rid of an unused variable. Squelch a 64-bit-to-32-bit conversion warning. svn path=/trunk/; revision=49396
2013-05-17Rename k12text_set_pseudo_header() to k12text_set_headers() and have itGuy Harris1-13/+15
fill in the entire struct wtap_pkthdr. svn path=/trunk/; revision=49388
2013-05-17Prevent "'len' may be used uninitialized in this function" error when ↵Pascal Quantin1-1/+1
compiling with gcc 4.3.2 svn path=/trunk/; revision=49378
2013-05-17Pull some functions that fill in a struct wtap_pkthdr into common code,Guy Harris1-139/+83
and use it in both the read and seek-read routines. svn path=/trunk/; revision=49377
2013-05-17Have iseries_parse_packet() fill in a struct wtap_pkthdr; that means itGuy Harris1-55/+41
doesn't need to return the number of bytes of captured packet data (it can just stuff that into the struct wtap_pkthdr), so have it return a Boolean success/failure indication. svn path=/trunk/; revision=49376
2013-05-17If iseries_seek_next_packet() hits the EOF, *err will be set to 0; justGuy Harris1-13/+5
have it return -1 for errors or EOF, and have iseries_read() check for a negative return value and return FALSE. That simplifies it a bit, and handles the "no more records in the file" case (iseries_seek_next_packet() will hit EOF and return -1 with *err set to 0, which is what the callers of a read routine expect at EOF). Get rid of duplicate (and incorrect before the change) comment. svn path=/trunk/; revision=49375
2013-05-17Get rid of duplicate code.Guy Harris1-13/+0
svn path=/trunk/; revision=49374
2013-05-17Pull the reading of record data and ATM post-processing into anotherGuy Harris1-46/+40
common routine. svn path=/trunk/; revision=49373
2013-05-17Add iptrace_process_rec_header_ routines to read record headers and fillGuy Harris1-151/+152
in a wtap_pkthdr, as well as skipping FDDI padding, etc.. svn path=/trunk/; revision=49372
2013-05-17IPFIX records have a time stamp (and, according to RFC 5101, it's UNIXGuy Harris1-2/+2
time, i.e. seconds since January 1, 1970, 00:00:00 UTC). svn path=/trunk/; revision=49370
2013-05-17We need ipfix_read_message_header() for the open routine; haveGuy Harris1-29/+46
ipfix_read_and_process_message_header() call it and then fill in the wtap_pkthdr structure, and use the latter routine in the read and seek-read routines. Expand a comment, and fix indentation. svn path=/trunk/; revision=49369
2013-05-17Pull the code that fills in a wtap_pkthdr structure intoGuy Harris1-37/+34
ipfix_read_message_header() and rename it ipfix_process_message_header(). Use it in the read and seek-read routines. svn path=/trunk/; revision=49368
2013-05-17Pull the record header processing code into i4b_read_rec_header(),Guy Harris1-112/+86
renaming it to i4b_process_rec_header(), so that it's used in the read and the seek-read routines. svn path=/trunk/; revision=49367
2013-05-17Pull code to fill in a wtap_pkthdr into a hcidump_process_header()Guy Harris1-29/+30
routine, and use it in both the read and seek-read routines. svn path=/trunk/; revision=49365
2013-05-17Fill in the wtap_pkthdr in dct3trace_get_packet().Guy Harris1-40/+38
svn path=/trunk/; revision=49360
2013-05-17Set *data_offset early in the read process, to emphasize that it's theGuy Harris1-12/+6
offset of the entire packet, not the offset of the data. Pull the setting of the FCS length into a common routine. svn path=/trunk/; revision=49359
2013-05-17Pass parse_dbs_etherwatch_packet() a pointer to a struct wtap_pkthdr,Guy Harris1-20/+19
not a wtap *, and have it fill in the specified struct wtap_pkthdr. That makes the seek-read routine do the right thing. svn path=/trunk/; revision=49358
2013-05-17Move the header-processing code into a common daintree_sna_scan_header()Guy Harris1-63/+80
routine. Rename daintree_sna_hex_char() to daintree_sna_process_hex_data() (to more clearly indicate what it does - it doesn't process a single character, it processes a whole bunch of them), and have it do some error checking and fill in the length field in the wtap_pkthdr. svn path=/trunk/; revision=49356
2013-05-16Pull code to read and process the packet header, and to read and processGuy Harris1-59/+57
the packet data, into common routines. svn path=/trunk/; revision=49355
2013-05-16Fill in the presence flags in parse_cosine_rec_hdr(), so it's done atGuy Harris1-31/+29
the same point at which the rest of the wtap_pkthdr is filled in (so it's done in seek-read routines). parse_cosine_hex_dump()'s return value is used as the return value of read routines, so it should be Boolean. Make it so (and have it stuff the actual length of packet data read into a wtap_pkthdr, which also ensure that this is done in seek-read routines). svn path=/trunk/; revision=49352
2013-05-16Pull up the code to read the packet data and check for errors into aGuy Harris1-17/+19
common routine. svn path=/trunk/; revision=49351
2013-05-16Move the code to read the CommView record header, check for an unhandledGuy Harris1-62/+52
encapsulation, and to process it into a commview_read_and_process_header() routine. svn path=/trunk/; revision=49350
2013-05-16Pull code to fill in the wtap_pkthdr into a btsnoop_read_record_header()Guy Harris1-86/+59
routine, for use both by the seek and read routines, and move some common code there. Make the delta between Symbian and UNIX time a static value. Make the prefix for all routine names "btsnoop" rather than "snoop". svn path=/trunk/; revision=49348
2013-05-16Pull the code to set the wtap_pkthdr into a common routine, so it's doneGuy Harris1-7/+16
for read and seek-read. Clarify a comment. (wtap_open_offline() only rewinds the file before calling each open routine; once one of those routines has decided the file belongs to it, the seek offset belongs to it, so it needs to do all the seeking necessary - files with a file header *don't* want a rewind, they want to leave the seek offset positioned *past* the file header so it can read the records that follow the file header.) svn path=/trunk/; revision=49347
2013-05-16Move some packet-header handling code into aethra_read_rec_header(), soGuy Harris1-39/+37
it's done in both the read and seek-read routines. svn path=/trunk/; revision=49346
2013-05-16Pull the code to set the struct wtap_pkthdr into _5views_read_header(),Guy Harris1-90/+83
so it's done by both the read and seek-read routines. svn path=/trunk/; revision=49345
2013-05-16Hoist a bunch of common code between ascend_read() andGuy Harris3-91/+70
ascend_seek_read() into parse_ascend(). Adjust the buffer size *before* attempting to fill it up. svn path=/trunk/; revision=49343
2013-05-16Get rid of unused global variable.Guy Harris1-3/+1
svn path=/trunk/; revision=49341
2013-05-16wth->priv is always set in the open routine; no need to check that it'sGuy Harris1-15/+0
non-null. svn path=/trunk/; revision=49338
2013-05-16Pull all the post-processing for a parsed line into a common routine,Guy Harris1-122/+88
used in both the seek and seek_read routines. (And, yes, the time stamp *is* supposed to be filled in by seek_read routines.) Pull some now-used-only-once routines into the new routine. svn path=/trunk/; revision=49335
2013-05-16From Weston Schmidt via ↵Pascal Quantin1-2/+2
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8689: csids wiretap heuristic overriding mp2t svn path=/trunk/; revision=49334
2013-05-11From Ravi Kondamuru via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8637Evan Huus3-0/+71
Add support for version 2.6 of netscaler capture format. svn path=/trunk/; revision=49250
2013-04-24dumpabi: This would create the directories in the sourcedir insteadJörg Mayer1-1/+1
of the binary dir. Fixed that. NOTE: It fails with and without this patch for out of tree builds: jmayer@egg:~/work/wireshark/svn/build/qt-gtk3> make dumpabi [ 1%] Built target wsutil [ 1%] Generating libwsutil.abi.tar.gz ERROR: can't find modules cp: cannot stat `abi_dumps/libwsutil/libwsutil_*': No such file or directory make[3]: *** [wsutil/libwsutil.abi.tar.gz] Error 1 make[2]: *** [wsutil/CMakeFiles/dumpabi-libwsutil.dir/all] Error 2 make[1]: *** [CMakeFiles/dumpabi.dir/rule] Error 2 make: *** [dumpabi] Error 2 jmayer@egg:~/work/wireshark/svn/build/qt-gtk3> svn path=/trunk/; revision=49014
2013-04-221.9.3 → 1.11.0.Gerald Combs1-1/+1
svn path=/trunk/; revision=48972
2013-04-14From Tomasz Mon via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8503 :Pascal Quantin3-0/+12
Add USBPcap support svn path=/trunk/; revision=48847
2013-04-04From Anthony Coddington: don't check for MPEG-2 Transport beforeGuy Harris1-4/+4
checking for ERF. From me: note some heuristic checkers that are in the "magic number" set. #BACKPORT 1.8 svn path=/trunk/; revision=48724
2013-04-01In the Lua dumper code, don't bother checking whether the encapsulationGuy Harris2-14/+13
is supported before trying to open for writing - the attempt to open for writing will do the check for you. Instead, check for specific errors if the attempt to open for writing fails, and use somewhat more specific error messages for certain error codes. (We should perhaps check for even more error codes in those cases.) That gets rid of all external calls to wtap_dump_can_write_encap(), so remove it from wtap.h and make it static. svn path=/trunk/; revision=48691
2013-04-01Add a wtap_dump_can_write() routine that indicates whether WiretapGuy Harris2-24/+60
supports writing files with a given set of encapsulations and comment types. Use it, rather than asking for a list of file formats that support the given set of encapsulation and comment types and checking whether we got back such a list, or duplicating its logic. Having file.c use it means that nobody's using wtap_dump_can_write_encaps() any more; get rid of it. Instead, have a private routine that checks whether a given file format supports a given set of encapsulations *and* comment types, and use that internally. svn path=/trunk/; revision=48690
2013-04-01Define a collection of bits for different types of capture file comments.Guy Harris2-91/+200
For each capture file type, have a bitset of comment types supported by that capture file type. Add a Wiretap routine that, for a given file type, returns the bitset of comment types it supports. Have wtap_get_savable_file_types() take a bitset of comment types that need to be supported by the file types it returns. Replace cf_has_comments() with a routine that returns a bitset of capture file comment types in the capture file. Use those routines in the capture file dialogs; don't wire in the notion that pcap-NG supports all comment types and no other file formats support any comment types. (That's currently true, but we don't want to wire that in as being forever true.) svn path=/trunk/; revision=48689
2013-03-30wiretap support for the CAM Inspector file formatMartin Kaiser6-2/+445
svn path=/trunk/; revision=48647
2013-03-281.9.2 → 1.9.3.Gerald Combs1-1/+1
svn path=/trunk/; revision=48627
2013-03-25Wiretap file open routines should not free wth->priv on error, since thatEvan Huus7-33/+8
leads to a double-free in wtap_close. Fix all the instances I found via manual code review, and add a brief comment to the list of open routines in file_access.c Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8518 svn path=/trunk/; revision=48552
2013-03-23From Prafulla Harpanhalli via ↵Evan Huus2-1/+3
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8513 Add support for encapsulation 136, Juniper service PIC cookie. svn path=/trunk/; revision=48494
2013-03-19From beroset:Anders Broman5-6/+6
remove C++ incompatibilities https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 svn path=/trunk/; revision=48424
2013-03-181.9.1 → 1.9.2.Gerald Combs1-1/+1
svn path=/trunk/; revision=48406
2013-03-17From beroset:Anders Broman10-54/+88
implemented wtap_dump_file_seek() and _tell() implemented the previously declared but unimplemented wtap_dump_file_seek() and wtap_dump_file_tell() functions and used them in the seven files that had previously used a plain ftell or fseek and added error checking as appropriate. I also added a new error WTAP_ERR_CANT_SEEK_COMPRESSED and put it next to WTAP_ERR_CANT_SEEK causing renumbering of two of the existing error codes. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 svn path=/trunk/; revision=48348
2013-03-12From David Arnold:Jaap Keuter1-1/+1
Replace use of INCLUDES with AM_CPPFLAGS in all Makefiles to placate recent autotools. svn path=/trunk/; revision=48261
2013-03-05Use consistent indentation (4 spaces);Bill Meier1-534/+657
Reformat long single line comments for readability; Add editor modelines. svn path=/trunk/; revision=48086
2013-03-03From beroset:Anders Broman1-4/+4
remove C++ incompatibilities https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 svn path=/trunk/; revision=48038
2013-03-02Try to fix LNK4217 (locally defined symbol imported in function) and C4273 ↵Pascal Quantin1-2/+3
(inconsistent DLL linkage) warnings when compiling for Windows svn path=/trunk/; revision=48021