Forum Discussion
YossiV
Nimbostratus
Hi @Niels van Sluis thanks for your Replay. this irule is working but works for Header and it looks like i made a mistake and the SOAPActino is located at the message body and not at the header as i though . mean i need to look at the body. this is already made by payload ?
YossiV
Nov 22, 2016Nimbostratus
ok so i manged this to work (SOAPAction is now passing on the Header) so now this catch the SOAPAction from the header. but now my Quashtion now is how to log spesific events and not all SOAPAction messages. i was trying the switch -glob but than no logs came at all.
when RULE_INIT {set static::bigip [info hostname]
set static::facility <191>
set static::hsl_prefix "$static::facility|host=$static::bigip"
}
when CLIENT_ACCEPTED {
set hsl [HSL::open -proto UDP -pool pool-tng-graylog-HSL]
set tcp_start_time [clock clicks -milliseconds]
}
when HTTP_REQUEST {
set http_request_time [clock clicks -milliseconds]
set SOAPAction [HTTP::header "SOAPAction"]
set hsl_prefix0 $SOAPAction
}
when HTTP_REQUEST_SEND {
set http_request_send_time [clock clicks -milliseconds]
}
when LB_SELECTED {
set lb_selected_time [clock clicks -milliseconds]
set hsl_prefix "${static::hsl_prefix}|Winweb=[LB::server addr]|F5_ClientIP=[client_addr]"
}
when SERVER_CONNECTED {
set connection_time [expr {[clock clicks -milliseconds] - $lb_selected_time}]
}
when HTTP_RESPONSE {
set upstream_time [expr {[clock clicks -milliseconds] - $http_request_send_time}]
}
when HTTP_RESPONSE_RELEASE {
HSL::send $hsl "$hsl_prefix|event=X_REQUEST|total_time=[expr {[clock clicks -milliseconds] - $http_request_time}]|upstream_time=$upstream_time|connection_time=$connection_time|vserver_name= [virtual name]\n|SOAPAction=$hsl_prefix0"
}