Commit Graph

6 Commits

Author SHA1 Message Date
Guy Harris e12270a730 Limit the maximum *file* name length for exported objects.
Limiting the maximum *path* name length is bogus; if the user wants to
store the file in some directory deep under the root (UN*X) or the root
of the drive (Windows), that's their choice - don't prevent them from
saving in a directory with a path longer than some maximum or limit the
file name based on the length of the path leading up to it.

Limiting the maximum *file* name is presumably to cope with, for
example, HTTP objects with a URL that had a very long query component,
so it makes sense.

Change-Id: Idfc7de8124ee80bdd4950341ff2239834eb9f6f6
Reviewed-on: https://code.wireshark.org/review/31295
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2019-01-01 21:36:58 +00:00
Dario Lombardo 55c68ee69c epan: use SPDX indentifiers.
Skipping dissectors dir for now.

Change-Id: I717b66bfbc7cc81b83f8c2cbc011fcad643796aa
Reviewed-on: https://code.wireshark.org/review/25694
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-02-08 19:29:45 +00:00
Guy Harris 7165b60879 Note that the object size type is, in effect, size_t.
We currently accumulate all of the object data in memory, so we can't
support objects whose size doesn't fit in a size_t; that means the
maximum object size is 2^32-1 bytes on ILP32 platforms, even though we
allow the size to be up to 2^63-1 bytes.

Change-Id: I2b45f2f1a6a4a68c97d34931aea6f5294db41b6e
Reviewed-on: https://code.wireshark.org/review/25174
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-01-06 23:33:06 +00:00
Michael Mann 243c09fa06 Switch export objects to use wmem_tree_t instead of (sorted) GSList.
Change-Id: Iaaa7b44954337c7857dbb541b727924e2de57c9d
Reviewed-on: https://code.wireshark.org/review/20016
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-02-08 14:24:28 +00:00
Dario Lombardo baaff60b3b exported_object: add cleanup function.
Change-Id: If4c35d18db1dc982e981004838e0eabbf4479e78
Reviewed-on: https://code.wireshark.org/review/19653
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-01-17 15:39:58 +00:00
Moshe Kaplan 20c57cb298 Enable exporting objects with tshark
A new "--export-object <protocol>,<destdir>" option is added to tshark.

This required refactoring Export Object behavior in all GUIs to give the
export object handling to the dissector, rather than the ui layer.
Included in the refactoring was fixing some serious memory leaks in Qt
Export Object dialog, crash due to memory scope issues in GTK Export
Object dialog, and addition sorting column feature in Qt dialog (set
up by creating a widget to manage the items that were previously
leaking memory)

Bug: 9319
Ping-Bug: 13174
Change-Id: I515d7662fa1f150f672b1476716f347ec27deb9b
Reviewed-on: https://code.wireshark.org/review/18927
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-02 16:07:35 +00:00