Hello,
I am toying around with the various features of QCLI_demo, and stumbled upon the packet filtering feature. Unfortunately, I've been unable to set up a working example so far. In my simplest example, I want to reject all packets of all types except ICMP, which should be allowed.
the wlan ChangeDefaultFilterAction function accepts three parameters - action, WoL, header type. I think I am getting the header type parameter wrong. I think it's the value from enum qapi_WLAN_Pkt_Filter_Type_e, but so far, I've been unable to make it work, as seen below.
> wlan EnablePktFilter 0
> net ping 8.8.8.8
>
Net: 64 bytes from 8.8.8.8: seq=1 time=20 ms
wlan ChangeDefaultFilterAction 2 0 6
> net ping 8.8.8.8
>
Net: 64 bytes from 8.8.8.8: seq=1 time=40 mswlan EnablePktFilter 1
> net ping 8.8.8.8
>
Net: Request timed out
What is the correct usage of the packet filter?
Thanks.
Kindly use below commands to apply pakcet filtering for ICMP packets:
> wlan EnableWow
> wlan EnablePktFilter 1
> wlan ChangeDefaultFilterAction 2 1 6 // 6 refers to ICMP packets