diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:53 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-09-19 04:14:53 +0000 |
commit | a86c5f7cae7ec9a3398300555a0b644689d946a1 (patch) | |
tree | 39fe4b107c71174fd1e8a8ceb9a4d2aa14116248 /epan/dissectors/asn1/pkinit | |
parent | Releasing progress-linux version 4.2.6-1~progress7.99u1. (diff) | |
download | wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.tar.xz wireshark-a86c5f7cae7ec9a3398300555a0b644689d946a1.zip |
Merging upstream version 4.4.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'epan/dissectors/asn1/pkinit')
-rw-r--r-- | epan/dissectors/asn1/pkinit/PKINIT.asn | 10 | ||||
-rw-r--r-- | epan/dissectors/asn1/pkinit/packet-pkinit-template.c | 10 | ||||
-rw-r--r-- | epan/dissectors/asn1/pkinit/pkinit.cnf | 14 |
3 files changed, 24 insertions, 10 deletions
diff --git a/epan/dissectors/asn1/pkinit/PKINIT.asn b/epan/dissectors/asn1/pkinit/PKINIT.asn index ff25738f..686ff9b4 100644 --- a/epan/dissectors/asn1/pkinit/PKINIT.asn +++ b/epan/dissectors/asn1/pkinit/PKINIT.asn @@ -1,8 +1,8 @@ ---NOTE: we have to accomodate BOTH existing users of early drafts, such as +--NOTE: we have to accommodate BOTH existing users of early drafts, such as --packetcable as well as new users once the protocol is standardized. -- --This asn1 file is based on draft-ietf-cat-kerberos-pk-init-20.txt ---but has been modified to acocmodate the Wireshark asn2wrs compiler +--but has been modified to accommodate the Wireshark asn2wrs compiler --and our environment -- --new structures are uncommented and added on demand as they are required @@ -18,13 +18,13 @@ --ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, --INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE --INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED ---WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. +--WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. -- KerberosV5-PK-INIT-SPEC { iso(1) identified-organization(3) dod(6) internet(1) - security(5) kerberosV5(2) modules(4) pkinit(5) } -DEFINITIONS EXPLICIT TAGS ::= + security(5) kerberosV5(2) modules(4) pkinit(5) } +DEFINITIONS EXPLICIT TAGS ::= BEGIN diff --git a/epan/dissectors/asn1/pkinit/packet-pkinit-template.c b/epan/dissectors/asn1/pkinit/packet-pkinit-template.c index ec582729..0070f873 100644 --- a/epan/dissectors/asn1/pkinit/packet-pkinit-template.c +++ b/epan/dissectors/asn1/pkinit/packet-pkinit-template.c @@ -13,6 +13,8 @@ #include <epan/packet.h> #include <epan/asn1.h> +#include <epan/proto_data.h> +#include <wsutil/array.h> #include "packet-ber.h" #include "packet-pkinit.h" @@ -28,7 +30,7 @@ void proto_register_pkinit(void); void proto_reg_handoff_pkinit(void); /* Initialize the protocol and registered fields */ -static int proto_pkinit = -1; +static int proto_pkinit; #include "packet-pkinit-hf.c" /* Initialize the subtree pointers */ @@ -43,13 +45,13 @@ static int dissect_pkinit_PKAuthenticator_Win2k(bool implicit_tag _U_, tvbuff_t int dissect_pkinit_PA_PK_AS_REQ(proto_tree *tree, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_) { - offset = dissect_pkinit_PaPkAsReq(FALSE, tvb, offset, actx, tree, -1); + offset = dissect_pkinit_PaPkAsReq(false, tvb, offset, actx, tree, -1); return offset; } int dissect_pkinit_PA_PK_AS_REP(proto_tree *tree, tvbuff_t *tvb, int offset, asn1_ctx_t *actx _U_) { - offset = dissect_pkinit_PaPkAsRep(FALSE, tvb, offset, actx, tree, -1); + offset = dissect_pkinit_PaPkAsRep(false, tvb, offset, actx, tree, -1); return offset; } @@ -81,7 +83,7 @@ void proto_register_pkinit(void) { }; /* List of subtrees */ - static gint *ett[] = { + static int *ett[] = { #include "packet-pkinit-ettarr.c" }; diff --git a/epan/dissectors/asn1/pkinit/pkinit.cnf b/epan/dissectors/asn1/pkinit/pkinit.cnf index a64c322c..e8653236 100644 --- a/epan/dissectors/asn1/pkinit/pkinit.cnf +++ b/epan/dissectors/asn1/pkinit/pkinit.cnf @@ -13,8 +13,20 @@ PaPkAsRep PA-PK-AS-REQ-Win2k PA-PK-AS-REP-Win2k -#.FN_BODY PKAuthenticator +#.FN_BODY PA-PK-AS-REQ-Win2k + uint8_t v = 1; + + if (kerberos_is_win2k_pkinit(actx)) { + p_set_proto_data(actx->pinfo->pool, actx->pinfo, proto_pkinit, 0, &v); + } +%(DEFAULT_BODY)s if (kerberos_is_win2k_pkinit(actx)) { + p_remove_proto_data(actx->pinfo->pool, actx->pinfo, proto_pkinit, 0); + } + +#.FN_BODY PKAuthenticator + + if (p_get_proto_data(actx->pinfo->pool, actx->pinfo, proto_pkinit, 0)) { return dissect_pkinit_PKAuthenticator_Win2k(implicit_tag, tvb, offset, actx, tree, hf_index); } %(DEFAULT_BODY)s |