mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
25 lines
583 B
JavaScript
25 lines
583 B
JavaScript
refine casetype Command += {
|
|
MQTT_SUBACK -> suback : MQTT_suback;
|
|
};
|
|
|
|
type MQTT_suback = record {
|
|
msg_id : uint16;
|
|
granted_QoS : uint8;
|
|
} &let {
|
|
proc: bool = $context.flow.proc_mqtt_suback(this);
|
|
};
|
|
|
|
refine flow MQTT_Flow += {
|
|
function proc_mqtt_suback(msg: MQTT_suback): bool
|
|
%{
|
|
if ( mqtt_suback )
|
|
{
|
|
BifEvent::enqueue_mqtt_suback(connection()->bro_analyzer(),
|
|
connection()->bro_analyzer()->Conn(),
|
|
${msg.msg_id},
|
|
${msg.granted_QoS});
|
|
}
|
|
|
|
return true;
|
|
%}
|
|
};
|