aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-btsmp.c
diff options
context:
space:
mode:
authorJakub Pawlowski <jpawlowski@google.com>2016-11-10 11:31:59 -0800
committerAlexis La Goutte <alexis.lagoutte@gmail.com>2016-11-10 22:40:58 +0000
commit1d56b0a48c6e023a0d24739029722b773fe3282a (patch)
treee232c763badb9404a6b418a2dd08c8a05faad696 /epan/dissectors/packet-btsmp.c
parent73145b4d7c2b6928dfe4b62f5f837aaac866a5ec (diff)
Bluetooth: BTLE: Add SC bit paring in AuthReq
Change-Id: I91db50aadd572a81559bb8d22af19fffefea592f Reviewed-on: https://code.wireshark.org/review/18735 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-btsmp.c')
-rw-r--r--epan/dissectors/packet-btsmp.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/epan/dissectors/packet-btsmp.c b/epan/dissectors/packet-btsmp.c
index 5cdc4b2181..f12fa03ae5 100644
--- a/epan/dissectors/packet-btsmp.c
+++ b/epan/dissectors/packet-btsmp.c
@@ -46,6 +46,7 @@ static int hf_btsmp_id_resolving_key = -1;
static int hf_btsmp_signature_key = -1;
static int hf_btsmp_bonding_flags = -1;
static int hf_btsmp_mitm_flag = -1;
+static int hf_btsmp_sc_flag = -1;
static int hf_btsmp_max_enc_key_size = -1;
static int hf_btsmp_key_dist_enc = -1;
static int hf_btsmp_key_dist_id = -1;
@@ -135,9 +136,12 @@ dissect_btsmp_auth_req(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree
proto_tree_add_item(st_param, hf_btsmp_bonding_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
proto_item_append_text(ti_param, "%s, ", val_to_str_const(param & 0x03, bonding_flag_vals, "<unknown>"));
proto_tree_add_item(st_param, hf_btsmp_mitm_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_item_append_text(ti_param, "%s", (param & 0x04) ? "MITM" : "No MITM");
+ proto_item_append_text(ti_param, "%s, ", (param & 0x04) ? "MITM" : "No MITM");
+ proto_tree_add_item(st_param, hf_btsmp_sc_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(ti_param, "%s", (param & 0x08) ? "SC" : "No SC");
- col_append_fstr(pinfo->cinfo, COL_INFO, "%s, %s", val_to_str_const(param & 0x03, bonding_flag_vals, "<unknown>"), (param & 0x04) ? "MITM" : "No MITM");
+ col_append_fstr(pinfo->cinfo, COL_INFO, "%s, %s, %s", val_to_str_const(param & 0x03, bonding_flag_vals, "<unknown>"),
+ (param & 0x04) ? "MITM" : "No MITM", (param & 0x08) ? "SC" : "No SC");
return offset + 1;
}
@@ -366,6 +370,11 @@ proto_register_btsmp(void)
FT_UINT8, BASE_DEC, NULL, 0x04,
NULL, HFILL}
},
+ {&hf_btsmp_sc_flag,
+ {"SC Flag", "btsmp.sc_flag",
+ FT_UINT8, BASE_DEC, NULL, 0x08,
+ NULL, HFILL}
+ },
{&hf_btsmp_max_enc_key_size,
{"Max Encryption Key Size", "btsmp.max_enc_key_size",
FT_UINT8, BASE_DEC, NULL, 0x00,