aboutsummaryrefslogtreecommitdiffstats
path: root/wiretap
AgeCommit message (Collapse)AuthorFilesLines
2012-09-24Some improvements after looking at profile of large reordercap run.Martin Mathieson1-18/+89
- speed up writing timestamp by avoiding g_snprintf() - avoid call to strstr() - don't use g_snprintf() for writing a liternal string - avoid atio() for single-digit strings - avoid some strcmp() calls where the release number at the end wasn't important svn path=/trunk/; revision=45091
2012-09-20Shouldn't set the time in seek_read() after all. At least the pcapMartin Mathieson1-8/+0
support doesn't. svn path=/trunk/; revision=45022
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss3-6/+0
svn path=/trunk/; revision=45016
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss50-100/+0
svn path=/trunk/; revision=45015
2012-09-19Fix a couple of dumping issues seen while working on 'reorder'.Martin Mathieson1-4/+21
svn path=/trunk/; revision=45003
2012-09-14Create a common libui using CMake similar to what we do with Autotools.Gerald Combs3-0/+29
Move the GTK+ text import code to the common UI directory. Create wtap_encap_requires_phdr() from code in file_import_dlg.c. svn path=/trunk/; revision=44904
2012-09-14From Nikhil Kalu:Anders Broman3-11/+86
Enhancement to add more trace record fields in Citrix NetScaler capture file format. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7713 svn path=/trunk/; revision=44895
2012-09-07From Stephen Donnelly via ↵Jeff Morriss1-3/+5
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7266 : Since we have to 'downconvert' the ERF time stamps to Wireshark's internal representation anyway, we may as well report the resolution which we convert to, rather than the original native resolution. svn path=/trunk/; revision=44800
2012-08-21Avoid some calls to strlen() by remembering return value fromMartin Mathieson1-10/+11
g_strlcpy(). svn path=/trunk/; revision=44608
2012-08-11Ignore '\r' which will be found at the end of a line when a windows hostMartin Mathieson1-27/+32
writes a log. Also re-line-up args under function definitions. svn path=/trunk/; revision=44444
2012-08-06Create (fake)interface information when loading a libpcap file it might be ↵Anders Broman1-1/+27
needed when wrinting the file if the format is converted to pcapng. Should we do this for other file formats as well? A pcapng file with per packet encapsulation will need an IDB per encapsulation as the EPB does not have a linktype indicator only a interface index. svn path=/trunk/; revision=44281
2012-08-02From Richard Stearn: support for AX.25, including support forGuy Harris3-0/+5
LINKTYPE_AX25. svn path=/trunk/; revision=44211
2012-08-02From Richard Stearn: AX.25 KISS protocol support.Guy Harris3-1/+7
Part 1 of the fix for bug 7529. svn path=/trunk/; revision=44202
2012-07-30Avoid a division by zero due to overflow.Michael Tüxen1-2/+2
This should fix the crash in https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7266 svn path=/trunk/; revision=44141
2012-07-30Added missing entry for WTAP_ENCAP_SDH.Stig Bjørlykke1-0/+3
svn path=/trunk/; revision=44138
2012-07-27Some more debug info.Michael Tüxen1-0/+5
svn path=/trunk/; revision=44076
2012-07-27It seems that the length should unsigned, not signed.Michael Tüxen1-1/+1
This fixes part of https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7533 which deals with Crash in vwr.c while reading the capture file. svn path=/trunk/; revision=44075
2012-07-27Handle the case where no IDB follows the SHB. This fixes part ofMichael Tüxen1-34/+30
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7533 which deals with Div by 0 crash in pcapng_read_packet_block(). svn path=/trunk/; revision=44074
2012-07-26Fix another uninitialised bug (the same bug in _read() I fixedMartin Mathieson1-1/+1
yesterday, also in _seek_read()). Spotted by running 'valgrind-wireshark.sh -2'. svn path=/trunk/; revision=44043
2012-07-25Initialize a byte to avoid more valgrind warnings.Martin Mathieson1-1/+1
svn path=/trunk/; revision=44019
2012-07-25Don't write one payload byte too many. Spotted by valgrind!Martin Mathieson1-2/+2
svn path=/trunk/; revision=44016
2012-07-20Add a routine that, given a set of packet encapsulation types, returnsGuy Harris3-13/+39
the per-file encapsulation type needed to write out a set of packets with all those encapsulation types. If there's only one such encapsulation type, that's the type, otherwise WTAP_ENCAP_PER_PACKET is needed. Use that in wtap_dump_can_write_encaps(). Also use it in cf_save_packets() and cf_export_specified_packets(), so that we can write out files with WTAP_ENCAP_PER_PACKET as the file encapsulation type and only one actual per-packet encapsulation type in some cases where that failed before. This fixes the case that showed up in bug 7505, although there are other cases where we *could* write out a capture in a given file format but won't be able to do so; fixing those will take more work. #BACKPORT (Note: this adds a routine to libwiretap, so, when backported, the *minor* version of the library should be increased. Code that worked with the version of the library prior to this change will continue to work, so there's no need to change the *major* version of the library.) svn path=/trunk/; revision=43847
2012-07-19Addresses https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3895. Note ↵Michael Mann3-1/+57
that this doesn't write a Nokia file type properly, it just doesn't corrupt an existing one (read in by Wireshark) if resaved. svn path=/trunk/; revision=43815
2012-07-18Set the 802.11 "already decrypted" flag to FALSE for file formats otherGuy Harris6-0/+9
than Network Instruments Observer files, as we don't know whether they are already decrypted. svn path=/trunk/; revision=43796
2012-07-18Add to the 802.11 pseudo-header a "this is already decrypted" flag, setGuy Harris2-22/+11
it as appropriate in the code to read Network Instruments Observer captures (rather than tweaking the "protected" flag in the packet data), and use that flag in the 802.11 dissector. Fix indentation while we're at it (tabs are not *ipso facto* 4 spaces). svn path=/trunk/; revision=43795
2012-07-15From Network Instruments by Tom Brezinski When a Network Instruments ↵Anders Broman2-8/+30
wireless capture is decrypted a flag is set on the packet in the BFR file indicating that the packet is decrypted instead of modifying the protected flag in the frame control flags of the packet header. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7478 svn path=/trunk/; revision=43727
2012-07-11memcpy() is quite a bit faster than g_strlcpy()!Martin Mathieson1-3/+2
svn path=/trunk/; revision=43675
2012-07-11Don't ask for information about an interface greater than the maximumGuy Harris1-0/+7
interface for which we have information. Fixes bug 7467. Should also cause an error message, rather than an unreadable capture file, to be produced for the cases in bug 7381. (This isn't a fix for bug 7381; it's arguably an improvement, in the sense that a circuit breaker tripping or a fuse blowing for a short circuit is an improvement over a fire starting, but it's not a *fix*, any more than a circuit break or fuse *fixes* the short circuit.) #BACKPORT svn path=/trunk/; revision=43657
2012-07-11AARGH. There are two lumps of (almost-)identical code to handleGuy Harris1-41/+26
interface information when opening an output file, one of which I fixed in my previous checkin and the other of which I didn't notice. Shuffle code around a little bit so that the lumps are identical and then put them into a common routine (*with* the fix in question). #BACKPORT svn path=/trunk/; revision=43655
2012-07-10Set the time units per second correctly if, in wtap_dump_open_ng(),Guy Harris1-1/+1
we're making a fake interface description (it should match the time stamp resolution). The dump code for pcap-NG now requires the time units per second value, as it needs to correctly compute the time stamp value to write out in an EPB. svn path=/trunk/; revision=43652
2012-07-10When writing an EPB, calculate the time stamp based on the resolutionGuy Harris1-15/+22
for the interface, not based on the default resolution of 1 microsecond. Fixes bug 7457. Fix a comment. Clean up indentation. #BACKPORT svn path=/trunk/; revision=43649
2012-07-09Fix up some comments.Guy Harris1-6/+6
svn path=/trunk/; revision=43633
2012-07-09Fix another comment.Guy Harris1-1/+1
svn path=/trunk/; revision=43632
2012-07-09Fix some comments.Guy Harris1-4/+4
svn path=/trunk/; revision=43631
2012-07-09The names "etherpeek" and "airopeek" are a bit misleading, as theGuy Harris8-224/+236
"etherpeek.c" file format is used by AiroPeek and the "airopeek9.c" file format is used by EtherPeek. Instead, use the names that WildPackets apparently uses for those formats - "classic" and "tagged". svn path=/trunk/; revision=43630
2012-07-09From Evan Huus:Anders Broman1-6/+1
Grab-bag of unused variables. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7452 svn path=/trunk/; revision=43616
2012-06-29Initial support for D-Bus dissection (bug #5502)Jakub Zawadzki3-0/+6
svn path=/trunk/; revision=43542
2012-06-28Update Free Software Foundation address.Jakub Zawadzki92-92/+92
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-06-19ascend_scanner.c includes ascend.h. Add corresponding makefileGerald Combs2-4/+8
dependencies, otherwise we might have a race condition when doing parallel makes. Hopefully this will fix intermitten buildbot failures we've been getting lately. svn path=/trunk/; revision=43387
2012-06-17Forgot to use wtap_dump_can_write_encaps()'s final name.Guy Harris1-6/+6
svn path=/trunk/; revision=43317
2012-06-17Export a wtap_dump_can_write_encaps() routine from Wiretap; it takes aGuy Harris3-10/+23
file type and a GArray of encapsulation types and returns TRUE if a capture with all those encapsulation types can be written to a file in that file type and FALSE otherwise. Use it where appropriate. svn path=/trunk/; revision=43315
2012-06-17Have wtap_get_savable_file_types() take an array of encapsulations andGuy Harris2-15/+39
only return file types that could handle a single file with all those encapsulations - this means that 1) if there's more then one encapsulation, the file format has to handle per-packet encapsulation; 2) just because a file format handles per-packet encapsulation, that doesn't mean that it can handle the *particular* encapsulations being handed to it. This fixes some cases where we were claiming that a file could be saved in a format that doesn't actually support it (e.g., ISDN files being reported as savable in pcap-NG format - there's no LINKTYPE_ value for ISDN including B and D channels). svn path=/trunk/; revision=43300
2012-06-08Forward-port r43165 and r43168 from trunk-1.6.Gerald Combs1-5/+7
------------------------------------------------------------------------ r43165 | gerald | 2012-06-08 14:23:25 -0700 (Fri, 08 Jun 2012) | 4 lines Changed paths: M /trunk-1.6/epan/Makefile.am M /trunk-1.6/wiretap/Makefile.am M /trunk-1.6/wsutil/Makefile.am Use separate commands in the dumpabi recipes instead a big huge long chain. If abi-compliance-checker fails print the contents of its log file. ------------------------------------------------------------------------ r43168 | gerald | 2012-06-08 15:43:50 -0700 (Fri, 08 Jun 2012) | 2 lines Changed paths: M /trunk-1.6/epan/Makefile.am M /trunk-1.6/wiretap/Makefile.am M /trunk-1.6/wsutil/Makefile.am Make sure ln happens in the right directory. ------------------------------------------------------------------------ We don't currently have a usable tag for "git describe --tags --abbrev=0" to latch onto so just use the first 1.9 commit. svn path=/trunk/; revision=43170
2012-06-08Fix some dead assignments.Gerald Combs1-1/+0
svn path=/trunk/; revision=43157
2012-06-06From Stephen Donnelly: Correct ERF name, add WTAP_ENCAP string display ↵Anders Broman1-1/+1
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7313 svn path=/trunk/; revision=43141
2012-06-06Fix bug #7340Jakub Zawadzki1-1/+1
interface name can also contain hyphen (v1-untrust, v1-trust). svn path=/trunk/; revision=43139
2012-06-05From Andrew Kampjes:Anders Broman1-0/+1
SDH support for wireshark. - Added GPL license. - Removed not needed includes. - Skipped th .h file as it wasn't used. svn path=/trunk/; revision=43106
2012-06-05Casting a negative value to unsigned makes it positive; I'm not sureGuy Harris1-3/+16
that will do the right thing here. Instead, cast its negative (which is positive) to unsigned, use that value as the adjustment, and flip the signs of the subsequent adjustment operations. svn path=/trunk/; revision=43105
2012-06-05Add another cast to make it build on Win32.Anders Broman1-1/+1
svn path=/trunk/; revision=43104
2012-06-05Making "had" a ptrdiff_t caused warnings, even if it eliminated aGuy Harris1-1/+6
warning about assigning the difference between two (64-bit) pointers to a (32-bit) variable. That difference is guaranteed to fit in an unsigned int; make "had" an unsigned int, and cast the difference to unsigned int before assigning it to "had". svn path=/trunk/; revision=43103