Commit Graph

116 Commits

Author SHA1 Message Date
Pascal Quantin 6ebc058f47 Add proto_tree_add_ts_23_038_7bits_item() / tvb_get_ts_23_038_7bits_string() functions and update dissectors to use it.
Remove gsm_sms_char_7bit_unpack() / gsm_sms_chars_to_utf8() functions.
Update documentation a bit.

svn path=/trunk/; revision=54534
2014-01-01 14:33:19 +00:00
Jakub Zawadzki deb2b236f2 Add missing includes
svn path=/trunk/; revision=54332
2013-12-21 17:23:17 +00:00
Guy Harris 4a346b7188 Use tvb_get_string_enc(), or proto_tree_add_item(), rather than
tvb_get_unicode_string() or g_iconv stuff.

svn path=/trunk/; revision=54244
2013-12-19 03:12:59 +00:00
Pascal Quantin 0db718781b Comment a useless increment
svn path=/trunk/; revision=54173
2013-12-17 10:54:57 +00:00
Jakub Zawadzki c45475ab45 Fix [-Wmissing-prototypes]
svn path=/trunk/; revision=54135
2013-12-15 23:44:12 +00:00
Pascal Quantin 5db2d622e4 From Michael Lum via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9554 :
GSM SMS: remove some globals and expose some UDH fields through dis_field_udh()

svn path=/trunk/; revision=53997
2013-12-12 22:35:45 +00:00
Pascal Quantin b4020a83d1 From Michael Lum via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9550 :
GSM SMS UDH EMS control expects 4 octets instead of 3 with OPTIONAL 4th

svn path=/trunk/; revision=53940
2013-12-11 18:47:15 +00:00
Pascal Quantin 93398e794e Use STR_UNICODE display instead of proto_tree_add_unicode_string() in the remaining dissectors
svn path=/trunk/; revision=53867
2013-12-08 20:03:15 +00:00
Pascal Quantin 03085a5c9a Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9503 :
Fix dissection of STK SEND SHORT MESSAGE proactive command

svn path=/trunk/; revision=53793
2013-12-05 06:23:17 +00:00
Pascal Quantin 37660f413b Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9478 :
GSM SMS User Data header fill bits are wrong when using a 7 bits ASCII / IA5 encoding

svn path=/trunk/; revision=53631
2013-11-28 21:59:02 +00:00
Bill Meier 64f4e13fff Create/use value_string_ext to reference certain value-string-arrays.
Define an array as const.
Remove some unneeded initializers.
Add editor modelines.
Do some minor whitespace changes.

svn path=/trunk/; revision=53325
2013-11-14 22:26:08 +00:00
Pascal Quantin 76e8ff1d8d Replace the 3 dissector tables (with a single entry in each) by a direct call to the GSM SMS dissector
svn path=/trunk/; revision=52336
2013-10-02 18:04:06 +00:00
Pascal Quantin 07fb69f57e Revert files committed by mistake in r52331
svn path=/trunk/; revision=52332
2013-10-02 16:40:06 +00:00
Pascal Quantin 5d183ee5a2 From Peter Lemenkov via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9211 :
Add basic conversation support for rtpproxy dissector

svn path=/trunk/; revision=52331
2013-10-02 16:37:10 +00:00
Pascal Quantin a0c53ffaa1 emem -> wmem conversion:
- ep_tvb_get_bits() -> wmem_packet_tvb_get_bits()
- tvb_g_memdup()/ep_tvb_memdup() -> tvb_memdup()
- tvb_fake_unicode()/tvb_get_ephemeral_faked_unicode() -> tvb_get_faked_unicode()
- tvb_get_g_string()/tvb_get_ephemeral_string()/tvb_get_seasonal_string() -> tvb_get_string()
- tvb_get_g_unicode_string()/tvb_get_ephemeral_unicode_string() -> tvb_get_unicode_string()
- tvb_get_ephemeral_string_enc() -> tvb_get_string_enc()
- update docs accordingly

svn path=/trunk/; revision=52172
2013-09-22 15:50:55 +00:00
Pascal Quantin 868b345eea Convert a few more dissectors to wmem API
svn path=/trunk/; revision=52053
2013-09-15 10:29:49 +00:00
Pascal Quantin 84bf0acc00 Convert a few dissectors from EMEM to WMEM API
svn path=/trunk/; revision=51597
2013-08-30 14:49:55 +00:00
Jakub Zawadzki a18172147f Remove fragment_data, add fragment_head, fragment_item - for now alias it to the same structure.
This is begin of work to split fragment head and fragments items.

svn path=/trunk/; revision=50708
2013-07-17 21:12:24 +00:00
Pascal Quantin 0975d03e8d Fix dissection of 3GPP2 SMS messages when the User Data Header field is present (for fragmented SMS)
svn path=/trunk/; revision=49910
2013-06-12 16:59:59 +00:00
Pascal Quantin b0646c0756 Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8756 :
Compute the number of septets needed for an alphanumeric address

svn path=/trunk/; revision=49698
2013-06-02 20:57:48 +00:00
Pascal Quantin 608fe54c05 Fix computation of TP-User-Data-Length when SMS is coded with GSM 7 bit default alphabet and TP-User-Data-Header field is present
svn path=/trunk/; revision=49546
2013-05-23 20:28:59 +00:00
Michael Mann ce537f6b94 Remove static packet_info *gpinfo and just use the packet_info provided by the function.
svn path=/trunk/; revision=49145
2013-05-03 14:54:39 +00:00
Evan Huus 37600a157b Rename value string (and similar) functions to use a consistent pattern. This
was done using textual search+replace, not anything syntax-aware, so presumably
it got most comments as well (except where there were typos).

Use a consistent coding style, and make proper use of the WS_DLL_* defines.

Group the functions appropriately in the header.

I ended up getting rid of most of the explanatory comments since many of them
duplicated what was in the value_string.c file (and were out of sync with the
recent updates I made to those in r48633). Presumably most of the comments
should be in the .h file not the .c file, but there's enough churn ahead that
it's not worth fixing yet.

Part of https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8467

svn path=/trunk/; revision=48634
2013-03-29 00:26:23 +00:00
Guy Harris a2414d8909 Don't wire into the reassembly code the notion that reassemblies should
be done on flows from one address to another; reassembly for protocols
running atop TCP should be done on flows from one TCP endpoint to
another.

We do this by:

	adding "reassembly table" as a data structure;

	associating hash tables for both in-progress reassemblies and
	completed reassemblies with that data structure (currently, not
	all reassemblies use the latter; they might keep completed
	reassemblies in the first table);

	having functions to create and destroy keys in that table;

	offering standard routines for doing address-based and
	address-and-port-based flow processing, so that dissectors not
	needing their own specialized flow processing can just use them.

This fixes some mis-reassemblies of NIS YPSERV YPALL responses (where
the second YPALL response is processed as if it were a continuation of
a previous response between different endpoints, even though said
response is already reassembled), and also allows the DCE RPC-specific
stuff to be moved out of epan/reassembly.c into the DCE RPC dissector.

svn path=/trunk/; revision=48491
2013-03-22 23:59:54 +00:00
Anders Broman 6bde918078 From beroset:
remove C++ incompatibilities 
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416

svn path=/trunk/; revision=48426
2013-03-19 20:00:52 +00:00
Anders Broman 5c1bc94608 "Fill" a couple of value_string(ext)
svn path=/trunk/; revision=46518
2012-12-12 12:48:12 +00:00
Pascal Quantin 6d99fb6a9f Add dissection of ENVELOPE 3GPP SMS-PP Download
svn path=/trunk/; revision=45768
2012-10-24 16:05:50 +00:00
Jeff Morriss 2552c750e5 We always HAVE_CONFIG_H so don't bother checking whether we have it or not.
svn path=/trunk/; revision=45017
2012-09-20 02:03:38 +00:00
Jeff Morriss aa5d9d78dd From Robert Bullen via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7683 :
The reassembled fragments tree in the Packet Details view is awesome, but it
lacks one thing: a field that exposes the reassembled data.

tcp.data already exists for exposing a single TCP segment's payload as a byte
array. It would be handy to have something similar for a single application
layer PDU when TCP segment reassembly is involved. I propose
tcp.reassembled.data, named and placed after the already existing field
tcp.reassembled.length.

My primary use case for this feature is outputting tcp.reassembled.data with
tshark for further processing with a script.

The attached patch implements this very feature. Because the reassembled
fragment tree code is general purpose, i.e. not specific to just TCP, any
dissector that relies upon it can add a similar field very cheaply. In that
vein I've also implemented ip.reassembled.data and ipv6.reassembled.data, which
expose reassembled fragment data as a single byte stream for IPv4 and IPv6,
respectively. All other protocols that use the reassembly code have been left
alone, other than inserting NULL into their initializer lists for the newly
introduced struct field reassemble.h:fragment_items.hf_reassembled_data.

svn path=/trunk/; revision=44802
2012-09-07 02:09:59 +00:00
Evan Huus 9c924315b6 Use parentheses to clarify ambiguous operator precedence.
svn path=/trunk/; revision=44743
2012-09-02 17:12:12 +00:00
Bill Meier 638d74d43f Use val_to_str_const() where appropriate;
Also (for a few files):
- create/use some extended value strings;
- remove unneeded #include files;
- remove unneeded variable initialization;
- re-order fcns slightly so prefs_reg_handoff...() at end, etc

svn path=/trunk/; revision=44438
2012-08-10 22:55:02 +00:00
Michael Mann 175851fb40 Updated GSM dissectors display filters per checkfiltername.pl
Tried to provide consistency with GSM dissector (protocol) names, even if the filenames now don't match the dissector name.

svn path=/trunk/; revision=44162
2012-07-31 18:54:11 +00:00
Jakub Zawadzki b18e880040 Update FSF address - part II.
svn path=/trunk/; revision=43538
2012-06-28 23:18:38 +00:00
Anders Broman 7364abf0bc Typo
svn path=/trunk/; revision=43365
2012-06-19 14:46:21 +00:00
Jakub Zawadzki 85aad38347 Add proto_tree_add_unicode_string() to add UTF-8 string to tree.
Convert some proto_tree_add_string_format_value(..., val, "%s", val); to use new function.

svn path=/trunk/; revision=43363
2012-06-19 14:32:24 +00:00
Jakub Zawadzki 7c59ac0280 Fix bug #7378: Wireshark 1.8.0rc1: gsm_a_dtap SMS 7-bit default alphabet regression w.r.t. 1.6.8
proto_item_add_string() can be only used with ASCII strings.

svn path=/trunk/; revision=43362
2012-06-19 14:25:50 +00:00
Anders Broman a6deef666c Fix a typo
svn path=/trunk/; revision=42805
2012-05-23 06:26:46 +00:00
pascal 0ba1ab2909 Display Element ID in hexadecimal (like in 3GPP specs)
Display EPS bearer ID in decimal

svn path=/trunk/; revision=42755
2012-05-21 19:27:38 +00:00
Bill Meier d12d5a606c AFAICT sys/types.h & netinet/in.h #includes are not needed for these files.
(Let's see if any of the buildbots give any errors).
Also: remove trailing whitespace on lines.

svn path=/trunk/; revision=42429
2012-05-04 21:29:00 +00:00
pascal 5df9055044 Fix a few clang warnings
svn path=/trunk/; revision=42343
2012-04-30 08:38:26 +00:00
Guy Harris 6163bcfa89 Just use a Boring Old ASCII Dash for hex ranges.
svn path=/trunk/; revision=42272
2012-04-26 16:58:30 +00:00
Anders Broman 0820e375b0 Prepare to use value_string or range_string.
svn path=/trunk/; revision=42267
2012-04-26 16:11:34 +00:00
pascal 81c1371d5d From Evan Huus:
Add missing break
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7201

svn path=/trunk/; revision=42265
2012-04-26 15:44:01 +00:00
pascal 4a530904f8 Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7131 :
Always store UDL/length in hash table and check pointer coming from lookup before using it

svn path=/trunk/; revision=42111
2012-04-17 13:17:39 +00:00
pascal a01bf60abf Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6202 :
Stop applying a specific treatment when receiving a SMS-DELIVER packet with an unknown direction (no such treatment is done for SMS-SUBMIT).
Store SMS fragment length in hash table to avoid mangling the output when displaying the reassembled SMS.

svn path=/trunk/; revision=42064
2012-04-14 11:56:12 +00:00
Guy Harris f2f11f4a2b GUINT_TO_POINTER() causes warnings when passed something *shorter* than
a guint; cast the argument to guint.

svn path=/trunk/; revision=42051
2012-04-13 19:40:57 +00:00
Guy Harris 01b2867f4e Clean up white space.
svn path=/trunk/; revision=42050
2012-04-13 19:36:44 +00:00
Jakub Zawadzki 25178510bd Try to fix OSX builds.
svn path=/trunk/; revision=42049
2012-04-13 18:27:51 +00:00
pascal 6f91bcc65a Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6477:
Use T-User-Data-Length to define the string size decoded with the 7 bits alphabet

svn path=/trunk/; revision=42041
2012-04-13 10:01:38 +00:00
Jakub Zawadzki 80445e5a99 Fix off by one shift errors introduced in r39530 where it seemed proper[1]
[1] I'm unsure of packet-dtpt, so I haven't patch it.

svn path=/trunk/; revision=41873
2012-03-31 20:57:15 +00:00