aboutsummaryrefslogtreecommitdiffstats
path: root/wiretap
AgeCommit message (Collapse)AuthorFilesLines
2015-07-07Initialize the 11b presence flag to 0.Guy Harris1-0/+1
There were some cases where it wasn't getting initialized when we set the PHY to 11b, in addition to the one Pascal found. Change-Id: I127737cd29dc53c96342364de5cb722b135f23f3 Reviewed-on: https://code.wireshark.org/review/9540 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-07Use the NSS provided by the Ixia Veriwave hardware.Guy Harris1-2/+3
It doesn't appear to provide the FEC type, although radiotap does, so add a flag to indicate whether we have that. Change-Id: I298d79bc6b640ee2408c3d70075c32bf331a210c Reviewed-on: https://code.wireshark.org/review/9533 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-06Clean up a bunch of stuff.Guy Harris1-99/+157
The command byte values aren't FPGA-specific - if they were, the code wouldn't have worked. Provide #defines for the main ones and check for them, and use that to determine whether the packet is transmitted or received. Add a bunch of #defines, shuffle some defines to cluster related ones together and separate unrelated ones, get rid of duplicate #defines (where different FPGAs use the same value). Fix some typoes. Change-Id: Ic8adc589d7c36a4a91a81858de40c904743dd067 Reviewed-on: https://code.wireshark.org/review/9529 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-06Update a comment.Guy Harris1-1/+4
Change-Id: I71e66a8f6faf3b213ab6db2856a36c1d31897166 Reviewed-on: https://code.wireshark.org/review/9527 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-06Add some comments.Guy Harris1-0/+5
OK, where's NSS for the presumably-one-and-only user hiding for 11ac? Change-Id: I53eb216c5d209dc5bb46c1d0aca7f8a200161e3e Reviewed-on: https://code.wireshark.org/review/9512 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-06Stub out the US public safety band.Guy Harris1-0/+9
OK, anybody know how to convert a frequency between 4.9 GHz and 5.0 GHz into a channel number, in a fashion that handles what's actually used in both the US and Japan? Change-Id: I95f4f9649e379b3d6651aadf8f62d8406b81b3b3 Reviewed-on: https://code.wireshark.org/review/9511 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-05Use space indentation consistently.Guy Harris1-7/+7
Change-Id: I1af52157a8c7383981c514d9dddea3b7186dbe6d Reviewed-on: https://code.wireshark.org/review/9509 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-02Zero out the nss array when we don't have the 802.11ac information we need.Guy Harris1-0/+3
Change-Id: I576be8c1a1badf6befe90a226f83e8d03f8326a7 Reviewed-on: https://code.wireshark.org/review/9470 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-28"Short preamble" is 802.11[bg]-only, so put it in the PHY-specifc info.Guy Harris1-22/+60
We're already only setting it for 11b and 11g; this makes it a bit cleaner, e.g. we don't need to say "oh, wait, we *don't* have short preamble" for 11n and 11ac. Change-Id: Idcf3e8c93d6a417f0319e4bd33247b98f07b6052 Reviewed-on: https://code.wireshark.org/review/9209 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-28Set 802.11.ac Partial AID field sizeGraham Bloice1-1/+1
The assignment of a short to a guint8 in packet-ieee80211-radiotap.c line 1696 generates a narrowing warning. In my reading of the spec which shows the field as 9 bits, and looking at the hf fields for this item I think it should be a guint16. Change-Id: Ic7785c2bfc66d72f7b1e914b1a46f32079fc99d9 Reviewed-on: https://code.wireshark.org/review/9197 Reviewed-by: Graham Bloice <graham.bloice@trihedral.com> Petri-Dish: Graham Bloice <graham.bloice@trihedral.com> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2015-06-26Fix handling of 11ac radio metadata.Guy Harris2-12/+28
Add more fields to the metadata to handle everything radiotap has, and show them. Call the FEC type field just "FEC", and have it be an integer field with 0 meaning BCC and 1 meaning LDPC, rather than a Boolean. 11ac doesn't have *an* MCS, it can have up to 4, one per user. Label the 11ac bandwidth values the same way we do in the radiotap dissector. Change-Id: I2c2415baff3e5d68d49dda497980e8271d26b1f6 Reviewed-on: https://code.wireshark.org/review/9176 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-25If we don't have both frequency and channel, try to calculate the other.Guy Harris1-0/+45
Just for completeness' sake. Change-Id: I1ed609431c8bc62a79ebbf837fa2fc62f627a002 Reviewed-on: https://code.wireshark.org/review/9157 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-25Squelch a compiler warning.Guy Harris1-0/+2
Change-Id: I7a833915173248cda68857493f2000a71052ec53 Reviewed-on: https://code.wireshark.org/review/9151 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-25Clean up 802.11 radio information handling.Guy Harris8-113/+339
Have a field that holds the PHY type but nothing else. Have a union with structures holding PHY-type-specific information, as a bunch of attributes are PHY-specific. If we have a channel and band, but don't have the frequency, attempt to calculate the frequency, and add that to the radio information if we succeed. If we have the frequency, but don't have the channel, attempt to calculate the channel, and add that to the radio information if we succeed. Handle FHSS information, 11a "half/quarter-clocked" and turbo information, 11g normal vs. Super G, additional 11n and 11ac information, and the "short preamble" flag for 11b and 11g. Add a PHY type for 11 legacy DSSS and detect it if possible. Clean up the AVS dissector - make all fields wlancap. fields (if you want generic fields, use the wlan_radio. fields). Set more fields when writing out Commview Wi-Fi files. Change-Id: I691ac59f5e9e1a23779b56a65124049914b72e69 Reviewed-on: https://code.wireshark.org/review/9146 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-25File: Add BTSNOOP File Format supportMichal Labedzki1-1/+3
BTSNOOP format is supported by libwiretap and this dissector add ability to open the same file in second mode: 1. Wireshark aka Protocol Viewer (default) 2. Fileshark aka File Viewer Mode 2 also has feature to dissect protocols contained by this file, try "Protocol Preferences -> Dissect next layer". Change-Id: I99f0df5b55d31bf5a7d6e9269bfc054c09022b51 Reviewed-on: https://code.wireshark.org/review/17 Reviewed-by: Evan Huus <eapache@gmail.com> Petri-Dish: Evan Huus <eapache@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-25editcap: keep timestamp resolution when converting a nseclibpcap file to pcapngPascal Quantin1-3/+9
As reported on https://ask.wireshark.org/questions/43483/why-does-editcap-write-out-nseclibpcap-correctly-with-nanosecond-timestamps-but-not-with-pcapng Change-Id: I81ec6dd6bdc6008297141ca8e210f4fb989cd3d6 Reviewed-on: https://code.wireshark.org/review/9111 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-22Provide PHY type and band information in the 802.11 pseudo-header.Guy Harris5-140/+217
Provide that information so that the "802.11 radio information" protocol can indicate whether a packet was 802.11 legacy/11b/11a/11g/11n/11ac, and possibly whether it's 2.4 GHz or 5 GHz 11n. (Sometimes the center frequency might not be supplied, so the band information can be useful.) Also, provide some 11ac information, now that we can distinguish between 11n and 11ac. Don't calculate the data rate from the MCS index unless it's 11n; we don't yet have code to calculate it for 11ac. For radiotap, only provide guard interval information for 11n and 11ac, not for earlier standards. Handle the 11ac flag in the Peek remote protocol. For Peek tagged files, the "extension flags" are 11n/11ac flags, so we don't have to check for the "MCS used" bit in order to decide that the packet is 11n or 11ac or to decide whether to provide the "bandwidth" or "short GI" information. Change-Id: Ia8a1a9b11a35243ed84eb4e72c384cc77512b098 Reviewed-on: https://code.wireshark.org/review/9032 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-20Call the "802.11 radio information" dissector for radio headers.Guy Harris9-24/+37
Have dissectors of various forms of radio information headers in the packets fill in a struct ieee_802_11_phdr with radio information as appropriate, and call the "802.11 radio information" dissector rather than the raw 802.11 dissector. This means that the radio information can be found in a protocol-independent and encapsulation-independent form when you're looking at the packet; that information can be presented in a form somewhat easier to read than the raw metadata header format. It also enables having a single "radio information" tap that allows statistics to handle all different sorts of radio information encapsulation. In addition, it lets us clean up some of the arguments passed to the common 802.11 dissector routine, by having it pull that information from the struct ieee_802_11_phdr. Ensure that the right structure gets passed to that routine, and that all the appropriate parts of that structure are filled in. Rename the 802.11 radio protocol to "wlan_radio", rather than just "radio", as it's 802.11-specific. Give all its fields "wlan_radio." names rather than "wlan." names. Change-Id: I78d79afece0ce0cf5fc17293c1e29596413b31c8 Reviewed-on: https://code.wireshark.org/review/8992 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-181.99.7 → 1.99.8Gerald Combs2-2/+2
Change-Id: I3423fd2959b1031480f15504ce38336ce3475b17 Reviewed-on: https://code.wireshark.org/review/8979 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-06-18Get rid of some unused members of struct ieee_802_11_phdr.Guy Harris1-3/+1
Remove some unused members, and move the presence flags after the should-always-be-set fields, right before the fields to which it applies. Change-Id: I8d6f08e1d3d8de0c11a9e04de4e98408d6b90693 Reviewed-on: https://code.wireshark.org/review/8972 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-15Define XXX_phdr structures in the order in which they appear in the union.Guy Harris1-34/+35
Change-Id: Ia1fe1758998237a344889bdf8215ecfba7b871ee Reviewed-on: https://code.wireshark.org/review/8942 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-15Move some structures used only in pcap-common.c there.Guy Harris2-30/+30
Those aren't pseudo-headers exported from libwiretap, they're just structures corresponding to the pseudo-headers for some pcap/pcap-ng link-layer header types. Change-Id: Iec37cfc162b64adacdeb57e14e546bced7b673fa Reviewed-on: https://code.wireshark.org/review/8941 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-11Replace tabs in files with editor modeline "expandtab"Bill Meier2-2/+2
Change-Id: I4667fd4091c510a4c798f79dae333a07dc42dad6 Reviewed-on: https://code.wireshark.org/review/8880 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2015-06-06Don't initialize a variable if the first thing we do is set it.Guy Harris1-1/+1
Change-Id: I14e8a15fdea1526c1c4bd2a0f19925ff41c15608 Reviewed-on: https://code.wireshark.org/review/8800 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-06-03Netscaler: Fix issue where packets were lost when selected packets were exportedanilkumar9111-5/+21
Only this issue with a netscaler trace file Bug: 11248 Change-Id: I2bc2cae5c988eeff7bdd08471bf421faafcd4e73 Reviewed-on: https://code.wireshark.org/review/8672 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-05-281.99.6 → 1.99.7.Gerald Combs2-2/+2
Change-Id: I8c431f162d199c8507ba57d84e496dce5f5a0933 Reviewed-on: https://code.wireshark.org/review/8677 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-05-09Make option_content a guint8 *.Guy Harris1-39/+49
It points to an array of bytes, not a character string. Add some casts to squelch other Sun/Oracle C warnings. Clean up some comments while we're at it. Change-Id: Id0908178cb00d537e95569b9ce6f745c8fd6d716 Reviewed-on: https://code.wireshark.org/review/8369 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-05-09Fix definition of tnef_open().Guy Harris1-1/+1
Change-Id: I8d030ab48fc47e4948c9f6dcad08f0bd08ca5ff8 Reviewed-on: https://code.wireshark.org/review/8364 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-05-09Make everything unsigned.Guy Harris1-1/+1
The LHS of the & operation is unsigned; make the RHS unsigned as well. That squelches a Sun/Oracle C warning. Change-Id: I6983cc89603a512020b8e8b560c00632de6b2fb3 Reviewed-on: https://code.wireshark.org/review/8363 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-05-06WildPackets → Savvius.Gerald Combs3-17/+17
Change-Id: I2494c2b1dcc9e324535b3f659b51b44059c478bd Reviewed-on: https://code.wireshark.org/review/8304 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-05-04nettrace 3GPP: Fix Dead Store (Dead assignement/Dead increment) warning ↵Alexis La Goutte1-1/+0
found by Clang Change-Id: Ie94165a45d9af23eee6e4d6406ad6fba4de785c0 Reviewed-on: https://code.wireshark.org/review/8281 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-01Fix checkAPI: Warning: i4b_trace.h has an SVN Id tag. Please remove it!Joerg Mayer1-9/+0
Change-Id: Ia82801866edb2783f896e624da4553717370c36b Reviewed-on: https://code.wireshark.org/review/8267 Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2015-04-30Fix some cases where we're shifting a signed 1 left.Guy Harris1-1/+1
Shift 1U instead, to make sure it's unsigned; the result of, for example, the result of shifting a signed value left is undefined if the value times 2^{shift count} doesn't fit in the *signed* type of the shifted value. That means, in particular, that the result of shifting 1 left by {number of bits in an int - 1} is undefined. (In *practice*, it'll probably be -2^32, with the bit you want set, but that's not guaranteed, and GCC 5.1 seems not to like it.) Change-Id: I0d27565c382a04ceda9eec65f45a430ceb74cf53 Reviewed-on: https://code.wireshark.org/review/8255 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-04-30[nettrace_3gpp_32_423] Fix nettrace_3gpp_32_423.c:292: warning:AndersBroman1-3/+3
declaration of 'random' shadows a global declaration. Change-Id: I2dde89a3f0e5abb3b8acc3c7d09e1a0d53a6c0f7 Reviewed-on: https://code.wireshark.org/review/8245 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-04-30Add the abillity to read 3GPP trace records with format accoding toAndersBroman6-1/+586
TS 32 423(XML) Change-Id: I37895ec35797089a32c7d1695e735046d6aa979e Reviewed-on: https://code.wireshark.org/review/8237 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-04-21Calculate *Peek tagged timestamps in fixed-point.Guy Harris1-17/+7
Add a variant of filetime_to_nstime() that takes a value that's like a FILETIME but in units of nanoseconds rather than tenths of a microsecond, and use that. (It looks as if they might just get FILETIME values from the OS and multiply them by 100, as the nanosecond-FILETIME values appear to be multiples of 100 in the captures I've seen, but they might have chosen nanosecond resolution in case they need to support a higher-resolution time stamp source, so we don't assume that the values will always be a multiple of 100.) Change-Id: If6a1cb2cb673688b042eb113b79cfd267f5454a5 Reviewed-on: https://code.wireshark.org/review/8150 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-04-20Have a common routine to convert FILETIME to nstime_t.Guy Harris1-42/+5
We had several copies of that code; put it into a filetime_to_nstime() routine in wsutil, and call that common routine instead. Change-Id: I1eb5579c36c129ff8d23f9212285ab3f63be0f43 Reviewed-on: https://code.wireshark.org/review/8142 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-04-20Make various structure members the right size for time-in-seconds.Guy Harris1-5/+5
I.e., make them time_t's. Change-Id: I102e9f585ae2798927757fe7f0f7a5a3fa251ec2 Reviewed-on: https://code.wireshark.org/review/8134 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-04-20Visual Networks captures have only millisecond resolution.Guy Harris1-1/+1
Change-Id: I59d7a6b5e29a068fd820075c913ac3c546593b9e Reviewed-on: https://code.wireshark.org/review/8133 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-04-20Simplify the calculation of the time stamp.Guy Harris1-12/+7
The time is calculated based on a 32-bit "seconds since the Epoch" value for the start time and a 32-bit delta from that time, in milliseconds. We can just split that delta into seconds and milliseconds, add the seconds to the start time to get the seconds part of the time stamp, and multiply the milliseconds by 1,000,000 to get the nanoseconds part of the time stamp. The only 64-bit arithmetic needed is adding the seconds to a 64-bit version of the start time (just in case seconds+start time goes past Y2.038K). Change-Id: Id7c4c6255870627f81fc99dae919abaf47efc710 Reviewed-on: https://code.wireshark.org/review/8132 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-04-19Use 64-bit fixed point to calculate time stamps.Guy Harris1-4/+4
Change-Id: I77c470937366dbaf50adbf174569ef0676ae3658 Reviewed-on: https://code.wireshark.org/review/8126 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-04-18MIME: Allow to dissect big filesMichal Labedzki1-3/+1
Increase file size limit for mime files that can be loaded by Wireshark to AddressSpace/2. On 32bit machines the limit can be 2 GiB. Change-Id: I5b38b3ebe401077f4e1e873cff4b37da560d592f Reviewed-on: https://code.wireshark.org/review/4907 Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com> Tested-by: Michal Labedzki <michal.labedzki@tieto.com> Reviewed-by: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-04-13Support for new netscaler 3.5 trace format.anilkumar9115-6/+139
Change-Id: Ica74f3f9239a96486967cf248feb4313bc390734 Reviewed-on: https://code.wireshark.org/review/7751 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-04-07ieee80211.c: "IEEE 802.11 plus Network Monitor radio header" encap: Fix ↵Bill Meier1-3/+8
dissection Specifically: Management/Control frames saved by Microsoft Netmon (3.4?) with "IEEE 802.11 plus Network Monitor radio header" encapsulation may or may not be saved with an FCS. See Bug 11105. Fix: Use "check fcs" preference to specify whether Management & Control frames have an fcs for this encapsulation. Change-Id: Ibd0be7b4765c2df2b959cb2234aeed027266246b Reviewed-on: https://code.wireshark.org/review/7939 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-04-04try to silence the OS X builbots by renaming index to idxMartin Kaiser1-8/+8
mp2t.c: In function 'mp2t_find_next_pcr': mp2t.c:160: warning: declaration of 'index' shadows a global declaration /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.6.sdk/usr/include/string.h:125: warning: shadowed declaration is here mp2t.c: In function 'mp2t_bits_per_second': mp2t.c:208: warning: declaration of 'index' shadows a global declaration /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.6.sdk/usr/include/string.h:125: warning: shadowed declaration is here Change-Id: Ia8591990409a0730d913c50d80b6950425a22052 Reviewed-on: https://code.wireshark.org/review/7905 Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2015-04-04Add PCR based stream times for MPEG ts files.Weston Schmidt1-3/+117
Change-Id: Ie1308829c3ad44d842bf12c7ebc5c200c942d8cc Reviewed-on: https://code.wireshark.org/review/7750 Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2015-03-201.99.5 → 1.99.6.Gerald Combs2-2/+2
Change-Id: Iff642606bdb9858dc54b90abe02bf1572f44fc25 Reviewed-on: https://code.wireshark.org/review/7766 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-03-191.99.4 → 1.99.5.Gerald Combs2-2/+2
Change-Id: Ifa1a57ac2db5d921d9b53dbe997cfa1916720c26 Reviewed-on: https://code.wireshark.org/review/7759 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-03-10Change a lot of http:// URLs to https://.Gerald Combs1-3/+5
Most of our sites are now HTTPS-only. Update URLs accordingly. Update other URLs while we're at it. Remove or comment out dead links. Change-Id: I7c4f323e6585d22760bb90bf28fc0faa6b893a33 Reviewed-on: https://code.wireshark.org/review/7621 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-03-051.99.3 → 1.99.4.Gerald Combs2-2/+2
Change-Id: I96953b6ca34140972a783c3066614399981ca1e2 Reviewed-on: https://code.wireshark.org/review/7549 Reviewed-by: Gerald Combs <gerald@wireshark.org>