]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
dcerpc: accept ALTER_CONTEXT as a valid request 9291/head
authorShivani Bhardwaj <shivani@oisf.net>
Wed, 26 Jul 2023 09:41:59 +0000 (15:11 +0530)
committerShivani Bhardwaj <shivanib134@gmail.com>
Thu, 27 Jul 2023 05:28:31 +0000 (10:58 +0530)
So far, if only the starting request was a DCERPC request, it would be
considered DCERPC traffic. Since ALTER_CONTEXT is a valid request type,
it should be accepted too.

Reported and patch proposed in the following Redmine ticket by
InterNALXz.

Bug 6191

rust/src/dcerpc/dcerpc.rs

index 57f3d41f0f915cb9e72a3e4a7d5b4d092a3f58bc..759d5c26343ad22fe65fd222208feece56d2f2ca 100644 (file)
@@ -1278,7 +1278,7 @@ pub unsafe extern "C" fn rs_dcerpc_get_stub_data(
 fn probe(input: &[u8]) -> (bool, bool) {
     match parser::parse_dcerpc_header(input) {
         Ok((_, hdr)) => {
-            let is_request = hdr.hdrtype == 0x00;
+            let is_request = hdr.hdrtype == 0x00 || hdr.hdrtype == 0x0e;
             let is_dcerpc = hdr.rpc_vers == 0x05 &&
                 hdr.rpc_vers_minor == 0x00 &&
                 hdr.packed_drep[0] & 0xee == 0 &&