|
| 1 | +- required_engine_version: 17 |
| 2 | + |
| 3 | + |
| 4 | +- macro: rocketmq_check_netty_server |
| 5 | + condition: (proc.name contains NettyServer and proc.env contains ROCKETMQ) |
| 6 | + |
| 7 | +- macro: read_socket |
| 8 | + condition: evt.type=read and (fd.typechar='4' or fd.typechar='6') |
| 9 | + |
| 10 | +- macro: rocketmq_check_payload_for_conf_update |
| 11 | + condition: (read_socket and evt.buffer contains 'code":25' and evt.buffer contains serialize) |
| 12 | + |
| 13 | +- rule: Apache Rocketmq CVE-2023-33246 Exploit Detection |
| 14 | + desc: > |
| 15 | + CVE-2023-33246 is exploited at the function used to update configuration & can be detected by looking at the buffer for broker code-25 and serializeTypeCurrentRPC function. |
| 16 | + condition: > |
| 17 | + evt.dir=< and rocketmq_check_netty_server and rocketmq_check_payload_for_conf_update |
| 18 | + output: CVE-2023-33246 exploit detected (event=%evt.type server_ip=%fd.sip server_port=%fd.sport proto=%fd.l4proto parent=%proc.pname process=%proc.name command=%proc.cmdline container_id=%container.id) |
| 19 | + priority: CRITICAL |
| 20 | + tags: [host, container, exploit, CVE_2023_33246, rocketmq, apache,Mitre_Initial_Access, Mitre_Execution,TA0001, TA0002, T1133, T1059] |
| 21 | + |
| 22 | +- macro: open_write |
| 23 | + condition: (evt.type in (open,openat,openat2) and evt.is_open_write=true and fd.typechar='f' and fd.num>=0) |
| 24 | + |
| 25 | +- macro: rocketmq_check_env_variable |
| 26 | + condition: (proc.env contains ROCKETMQ) |
| 27 | + |
| 28 | +- macro: rocketmq_check_properties_file_write_conf |
| 29 | + condition: (fd.nameraw contains conf and fd.nameraw endswith '.properties') |
| 30 | + |
| 31 | +- rule: Apache Rocketmq CVE-2023-33246 Exploit Attempt based on properties file |
| 32 | + desc: > |
| 33 | + Observed the file ends with '.properties' created under folder 'CONF' upon exploit CVE-2023-33246 attempt |
| 34 | + condition: > |
| 35 | + open_write and evt.dir=< and rocketmq_check_env_variable and rocketmq_check_properties_file_write_conf |
| 36 | + output: CVE-2023-33246 exploit attempt detected (event=%evt.type filepath=%fd.name server_ip=%fd.sip server_port=%fd.sport proto=%fd.l4proto parent=%proc.pname process=%proc.name command=%proc.cmdline container_id=%container.id) |
| 37 | + priority: WARNING |
| 38 | + tags: [host, container, anomaly, CVE_2023_33246, rocketmq, apache,Mitre_Initial_Access, Mitre_Execution,TA0001, TA0002, T1133, T1059] |
0 commit comments