ChargePoint / wireshark-v2g

Dissector for the V2G Protocols
Other
48 stars 19 forks source link

wip dissect apphandshake #7

Closed chardin-cpi closed 2 years ago

chardin-cpi commented 2 years ago

Finally got some interesting output ....

SDP Protocol Version: 0x01  (V2GTP Version 1)
SDP Inverted Protocol Version: 0xfe  (V2GTP Version 1)
SDP Payload Type: 0x8001  (EXI ENCODED)
SDP Payload Length: 0x00000044
V2G Efficient XML Interchange
    [Handshake Request: 90]
    [AppProtocol Array Len: 2]
    AppProtocols Array
        AppProtocol
            [AppProtocol Entry: 1]
            [AppProtocol Namespace: urn:din:70121:2012:MsgDef]
            [AppProtocol Version Major: 2]
            [AppProtocol Version Minor: 0]
            [AppProtocol SchemaID: 1]
            [AppProtocol Priority: 1]
        AppProtocol
            [AppProtocol Entry: 2]
            [AppProtocol Namespace: urn:iso:15118:2:2013:MsgDef]
            [AppProtocol Version Major: 2]
            [AppProtocol Version Minor: 0]
            [AppProtocol SchemaID: 2]
            [AppProtocol Priority: 2]

So, was hitting several issues until I found the pattern to add the photo item at 0,0 so it wouldn't try to verify the output and add the generated.

                it = proto_tree_add_uint(v2gexi_tree,
                                         hf_v2gexi_handshake_request_ap_arraylen,
                                         tvb, 0, 0,
                                         ahexi.supportedAppProtocolReq.AppProtocol.arrayLen);
                proto_item_set_generated(it);