aboutsummaryrefslogtreecommitdiffstats
path: root/wiretap/file_access.c
AgeCommit message (Collapse)AuthorFilesLines
2009-10-17From Marton Nemeth:Stig Bjørlykke1-0/+5
Add the ability to open JPEG/JFIF files directly. From me: Some code cleanup + add new file to cmake. svn path=/trunk/; revision=30588
2009-06-15Rename all of the ascend files:Jörg Mayer1-1/+1
That way we hopefully won't need the runlex.sh hack any more. Also the ylwrap stuff is (hopefully) obsolete. ascend.[hc] -> ascendtext.[hc] ascend-scanner.l -> ascend_scanner.l ascend-grammar.y -> ascend.y svn path=/trunk/; revision=28744
2009-06-01From Ravi Kondamuru via bug 3457: Stig Bjørlykke1-2/+13
Add support to read citrix netscaler capture file format. From me: - Renamed packet-ns.c to packet-nstrace.c - Rewrote to not use "goto" in netscaler.c - Moved dissecting of coreid svn path=/trunk/; revision=28564
2009-05-24From Fred Fierling (bug 3486):Stig Bjørlykke1-1/+6
Added support for Daintree's Sensor Network Analyzer capture files. svn path=/trunk/; revision=28463
2009-05-22From Kovarththanan Rajaratnam via bug 2680:Gerald Combs1-1/+17
Currently Wireshark doesn't support saving WTAP_ENCAP_BLUETOOTH_H4_WITH_PHDR files as btsnoop files. svn path=/trunk/; revision=28442
2009-04-23Added PacketLogger to dump_open_table_base to be able to open pklg filesStig Bjørlykke1-1/+4
(and avoid crash). svn path=/trunk/; revision=28137
2009-03-09P64 fixes.Gerald Combs1-2/+2
svn path=/trunk/; revision=27683
2009-02-16Add support for reading Apple's Bluetooth PacketLogger capture files toStephen Fisher1-1/+4
wiretap. Modify various other locations to accommodate the fact that PacketLogger files do not specify the direction of packets. svn path=/trunk/; revision=27463
2009-01-07From Duncan Salerno:Jaap Keuter1-1/+6
Added LAPDm protocol dissector, GSM Um layer, and wiretap support for dct3trace captures, generated by gammu (many available at http://wiki.thc.org/gsm). svn path=/trunk/; revision=27176
2009-01-04Fix some indentationBill Meier1-13/+13
svn path=/trunk/; revision=27156
2008-11-27Added support for open TNEF files directly.Stig Bjørlykke1-1/+9
No we can decode those winmail.dat files. svn path=/trunk/; revision=26864
2008-09-15Fix for bug 2875:Jaap Keuter1-10/+21
Fix a final eth_fopen -> ws_fopen When configuring with --without-zlib these functions need to have some parameters tagged _U_ svn path=/trunk/; revision=26212
2008-05-22Move the file utility functions from wiretap to libwsutil so thatJeff Morriss1-29/+29
libwireshark (and the plugins using those functions) do not depend on wiretap on Windows. While doing that, rename the eth_* functions to ws_*. svn path=/trunk/; revision=25354
2008-02-03From Shane Kearns (bug 2237):Stig Bjørlykke1-2/+6
Added support for Symbian OS btsnoop. The bluetooth HCI layer in Symbian OS can be configured to log all packets to a file. The log format, "btsnoop" is based on the RFC1761 "snoop" format - but differences in the header make it incompatible. The btsnoop format supports logging of these formats: "H1" (raw HCI packets without framing) "H4" (HCI UART packets including packet type header) "H5" (HCI 3 wire UART packets including framing) "BCSP" (HCI bluecore serial protocol including framing) "H1" and "H4" are section numbers in the original v1 bluetooth specifications, but still used colloquially - wireshark's existing support for Linux bluez HCI logs uses the "H4" name. In practice, the "H1" format is used for H5,BCSP and USB HCI logs, as the HCI packet logs are mainly useful for debugging higher layers, bluetooth profiles and bluetooth applications. From me: Deleted some unused prototypes. Mark an unused parameter. svn path=/trunk/; revision=24263
2008-01-13add very experimental support for pcapng "PCAP Next Generation Dump File ↵Ulf Lamping1-1/+7
Format" - this is incomplete and buggy, be careful! svn path=/trunk/; revision=24079
2007-11-26Add writing support for the CommView file format.Stephen Fisher1-1/+1
svn path=/trunk/; revision=23594
2007-11-24Initial checkin of support to read TamoSoft's CommView packet capture filesStephen Fisher1-0/+6
per enhancement bug #1795. svn path=/trunk/; revision=23558
2007-08-17(http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1717)Sake Blok1-1/+11
This patch adds support for the Juniper NetScreen snoop output format. It takes a text-dump op the captured packets and parses the headers and hex-data. Since the snoop files on a Junpiper NetScreen can be saved to a tftp-server, this patch makes it quite easy to use the snoop function of the Juniper NetScreen firewalls. /* XXX TODO: * * o Create a wiki-page with instruction on how to make tracefiles * on Juniper NetScreen devices. Also put a few examples up * on the wiki (Done: wiki-page added 2007-08-03) * * o Use the interface names to properly detect the encapsulation * type (ie adsl packets are now not properly dissected) * (Done: adsl packets are now correctly seen as PPP, 2007-08-03) * * o Pass the interface names and the traffic direction to either * the frame-structure, a pseudo-header or use PPI. This needs * to be discussed on the dev-list first * (Posted a message to wireshark-dev abou this 2007-08-03) * */ svn path=/trunk/; revision=22533
2007-06-08From Stephen Donnelly of Endace:Guy Harris1-1/+1
The code for reading ERF files has not been significantly updated since 2004. This patch brings it up to date with a number of changes. 1) Increase number of decodable ERF types from 7 to 12. This covers newer DAG card models and firmware updates. 2) Fix timestamp conversion. Was calculating only microsecond precision, now displaying with nanosecond resolution. Hardware precision is 7.5 to 30 ns depending on model. 3) Allow the user to specify HDLC encapsulation as 'chdlc', 'ppp_serial', 'frelay' or 'mtp2'. This is needed because the ERF HDLC capture formats do not include information on what protocol is used at the next level. This is currently done via an environment variable 'ERF_HDLC_ENCAP' and is analagous to the existing 'ERF_ATM_ENCAP' variable. If the user does not specify an HDLC encapsulation it tries to guess, and falls back to MTP2 for backwards compatibility with Florent's existing behaviour. I know environment variables are ugly, suggestions are welcome. 4) When reading HDLC captures as MTP2, use WTAP_ENCAP_MTP2_WITH_PHDR rather than WTAP_ENCAP_MTP2. This allows us to put the 'Multi-Channel ERF' record 'channel number' field into the MTP2 pseudo header > 'link_number' field. This is then displayed in Frame information, and can be filtered on. (Would be nice if it could be made a display column?) Because the ERF record does not specify whether Annex A is used or not, we pass MTP2_ANNEX_A_USED_UNKNOWN and allow the existing user preference to decide. Move the MTP2_ANNEX_A_ definitions into Wiretap, make the annex_a_used field a guint8, and change MTP2_ANNEX_A_USED_UNKNOWN to 2 so it fits in a guint8. (This means that if you can save an ERF MTP2 file as a libpcap file, the pseudo-header will have MTP2_ANNEX_A_USED_UNKNOWN in it.) svn path=/trunk/; revision=22067
2007-06-06Actually implement wtap_register_file_type() and have it returning the ID of ↵Luis Ontanon1-11/+35
the new file type. Add few functions to wiretap's exported API. svn path=/trunk/; revision=22060
2007-05-05fix win32 build by using wtap_get_num_file_types() instead of direct ↵Ulf Lamping1-0/+5
variable access svn path=/trunk/; revision=21689
2007-05-04Add a plugin interface to wiretap.Luis Ontanon1-32/+41
So far I've done only regression testing (the new functionality and what's in wtap-plugins.c has not yet being tested). it is a first step in the way to have lua opening files. svn path=/trunk/; revision=21686
2007-05-02add support for the text export format of textronix k1[25]Luis Ontanon1-1/+6
svn path=/trunk/; revision=21651
2007-03-22From Shaun JackmanRonnie Sahlberg1-0/+5
Wiretap support to read MPEG files svn path=/trunk/; revision=21112
2006-11-29Froim Rene Pilz:Anders Broman1-1/+1
This patch consists also the last issues. Additionally it solves: - For the SSCOP frames the AAL5 decoding was not performed due to an earlier patch. This caused that no SSCOP message was properly decoded. - As the detection between a LANE frame and a SSCOP frame is rather hard a switch within the atm dissector is included which enforce SSCOP dissecting over a LANE frame. At the moment I do not see a better solution for that. svn path=/trunk/; revision=20013
2006-11-05change all file offsets from long to gint64 so we can - theoretically - ↵Ulf Lamping1-2/+2
handle files > 2GB correct. Please distclean Win32 builds! svn path=/trunk/; revision=19814
2006-06-23add file extension information (filter "*.pcap;*.cap" and default extension ↵Ulf Lamping1-114/+153
".pcap") to wiretap sort file types in alphabetical order, but keep the libpcap like entries at the start svn path=/trunk/; revision=18562
2006-06-06Ethereal -> WiresharkGerald Combs1-3/+3
svn path=/trunk/; revision=18369
2006-05-22ethereal->wireshark updatesRonnie Sahlberg1-1/+1
svn path=/trunk/; revision=18206
2006-05-08Basic Encoding Rules (BER) encoded file reading. Not really a packet trace ↵Graeme Lunt1-1/+7
format but still useful for dissecting arbitrary BER/DER ASN.1. svn path=/trunk/; revision=18110
2006-04-14From Martin Mathieson:Anders Broman1-0/+5
patch and new files provide support for Catapult DCT2000 .out files to wiretap and ethereal. This wiretap support (catapult_dct2000.c+h) appends a short header to each packet giving some context, and a corresponding ethereal dissector (packet-catapult-dct2000.c) parses this before passing the real payload onto an existing ethereal dissector (for ethernet, ip, lapd, ppp, frame-relay,...). For now, there is only support for saving dct2000 files in their own format, although I may add support for converting between dct2000 and libpcap later. updated version of these files and patch, now with support for MTP2. Olivier's trace used the ANSI variant - the MTP2 and MTP3 decode fine with the right preferences set (although the ISUP dissector reports a reserved/retired message type). Witha a change to NOT to declare gboolean catapult_dct2000_board_ports_only; as extern as MSVC choked on it. svn path=/trunk/; revision=17862
2006-02-17even if we don't want to close stdout on wtap_dump_close(), we might at ↵Ulf Lamping1-1/+4
least try to flush it svn path=/trunk/; revision=17326
2006-01-06code cleanup: use "-" for all places, where stdin/stdout is meantUlf Lamping1-2/+2
tethereal internally converted the stdout capture filename "-" into "" which doesn't make any real sense and only complicated things. To make things even more confusing, wiretap expected "" for dump output and "-" for offline reading ... svn path=/trunk/; revision=16962
2006-01-05Win32: set stdout to binary mode in wtap_dump_fdopen(), so tethereal is also ↵Ulf Lamping1-0/+6
able to write capture files to stdout using -w - svn path=/trunk/; revision=16958
2005-11-25From Martin Warnes:Anders Broman1-0/+11
Add Support for reading of IBM iSeries (AS/400) Comms traces svn path=/trunk/; revision=16588
2005-11-07If we're using libz, make file_open() construct the open() flagGuy Harris1-1/+1
argument, rather than requiring the caller to get the open() flag and the fopen() flag in sync. That also means that if we're *not* using libz, it can just be a wrapper around eth_fopen(). We need to include <fcntl.h>, at least on UN*X, to get open() declared and the O_ flags defined. svn path=/trunk/; revision=16409
2005-11-06replace *a lot* of file related calls by their GLib counterparts. This is ↵Ulf Lamping1-19/+8
necessary for the switch to GTK 2.6 (at least on WIN32). to do this, I've added file_util.h to wiretap (would file_compat.h be a better name?), and provide compat_macros like eth_open() instead of open(). While at it, move other file related things there, like #include <io.h>, definition of O_BINARY and alike, so it's all in one place. deleted related things from config.h.win32 As of these massive changes, I'm almost certain that this will break the Unix build. I'll keep an eye on the buildbot so hopefully everything is working again soon. svn path=/trunk/; revision=16403
2005-09-14added compression support for capture file output. The Save/As dialog now ↵Ulf Lamping1-80/+200
has a checkbox "Compress with gzip" currently limited to Ethereal and all the variants of libpcap filetypes only. We might want to add output compression support to the other tools as well (tethereal, mergecap, ...). We might also want to add support for the other filetypes, but this is only possible if the filetype functions doesn't use special output operations like fseek. One bug is still left: if the input and output filetypes while saving are the same, Ethereal currently optimizes this by simply copy the binary file instead of using wiretap (so it will be faster but it will ignore the compress setting). Don't know a good workaround for this, as I don't know a way to find out if the input file is currently compressed or not. One idea might be to use a heuristic on the filesize (compared to the packet size summmary). Another workaround I see is to remove this optimization, which is of course not the way I like to do it ... svn path=/trunk/; revision=15804
2005-08-30Add support for slightly modified libpcap file format with nanosecond ↵Ulf Lamping1-0/+4
resolution (currently supported by Ethereal only). Support for both read and write was added. The file format stays the same as the common libpcap format, only the lower part of the timestamp field uses nanoseconds instead of microseconds. This file format uses the libpcap magic number 0xa1b23c4d. svn path=/trunk/; revision=15623
2005-08-24EVERYTHING IN THE BUILDBOT IS GOING TO BE RED!!! Sorry! Ulf Lamping1-0/+1
I've done more than a day to change the timestamp resolution from microseconds to nanoseconds. As I really don't want to loose those changes, I'm going to check in the changes I've done so far. Hopefully someone else will give me a helping hand with the things left ... What's done: I've changed the timestamp resolution from usec to nsec in almost any place in the sources. I've changed parts of the implementation in nstime.s/.h and a lot of places elsewhere. As I don't understand the editcap source (well, I'm maybe just too tired right now), hopefully someone else might be able to fix this soon. Doing all those changes, we get native nanosecond timestamp resolution in Ethereal. After fixing all the remaining issues, I'll take a look how to display this in a convenient way... As I've also changed the wiretap timestamp resolution from usec to nsec we might want to change the wiretap version number... svn path=/trunk/; revision=15520
2005-06-17- Write rf5 files (I don't think tektronix software will be able to read ↵Luis Ontanon1-1/+1
these, ethereal does) - change k12.atm.vci and k12.atm.vpi into atm.vci and atm.vpi svn path=/trunk/; revision=14682
2005-06-10Initial checkin of the 32 bit tektronix k12 binary format (rf5)Luis Ontanon1-2/+9
There is still much to do, but at the very least it can import files allowing the user to choose which protocols handle the diferent sources. svn path=/trunk/; revision=14606
2005-03-01The DBS Etherwatch file handler does look for a magic number (the wordGuy Harris1-1/+1
"ETHERWATCH"). svn path=/trunk/; revision=13567
2005-01-28From Yoshihiro Oyama: support "-" as a file name, referring to theGuy Harris1-4/+40
standard input. Opening it for random access isn't supported; we add a new error for that. svn path=/trunk/; revision=13189
2004-10-11From Mark C. Brown: add support for writing nettl files.Guy Harris1-2/+2
svn path=/trunk/; revision=12258
2004-07-18Set the svn:eol-style property on all text files to "native", so thatGuy Harris1-1/+1
they have LF at the end of the line on UN*X and CR/LF on Windows; hopefully this means that if a CR/LF version is checked in on Windows, the CRs will be stripped so that they show up only when checked out on Windows, not on UN*X. svn path=/trunk/; revision=11400
2004-06-30On at least some platforms, a #define of O_BINARY is needed even ifGuy Harris1-1/+6
<fcntl.h> is included, as <fcntl.h> doesn't define it. svn path=/trunk/; revision=11276
2004-06-29define of O_BINARY not needed, if fcntl.h is includedUlf Lamping1-6/+1
other #include related cleanups svn path=/trunk/; revision=11272
2004-04-28From Joe Marcus Clarke: force the standard output to be in binary modeGuy Harris1-3/+6
on Windows. svn path=/trunk/; revision=10717
2004-02-11From Rolf Fiedler: support for reading EyeSDN USB S0 trace files.Guy Harris1-1/+7
svn path=/trunk/; revision=10038