smb/dce_iface: use DCERPC_TYPE_REQUEST

The smb dce_iface keyword must match for all those dcerpc requests and
responses sent in the context of the given interface. They are not
matching because in rs_smb_tx_get_dce_iface, x.req_cmd is erroneously
compared with 1. Fix this by comparing with DCERPC_TYPE_REQUEST instead.

Ticket: 4767
(cherry picked from commit 1ae22fd5de)
pull/7537/head
Eloy Pérez González 5 years ago committed by Victor Julien
parent ffc7b686e3
commit c3d4fa3308

@ -183,7 +183,9 @@ pub extern "C" fn rs_smb_tx_get_dce_iface(state: &mut SMBState,
-> u8
{
let is_dcerpc_request = match tx.type_data {
Some(SMBTransactionTypeData::DCERPC(ref x)) => { x.req_cmd == 1 },
Some(SMBTransactionTypeData::DCERPC(ref x)) => {
x.req_cmd == DCERPC_TYPE_REQUEST
},
_ => { false },
};
if !is_dcerpc_request {

Loading…
Cancel
Save