Log ping requests

Hello!
I am new both to the forum and to FreeBSD. Hoping that my question is not too ordinary or well-known: is there a way to keep trace of the ping requests received by a FreeBSD host?
May these requests be written for example in /var/log/somefile?
Thank you!

Jerry
 
You can use the log keyword in a PF rule, see pf.conf(5). Be careful though, it could severely overrun your logs.

Code:
     log   In addition to the action specified, a log message is generated.
           Only the packet that establishes the state is logged, unless the no
           state option is specified.  The logged packets are sent to a
           pflog(4) interface, by default pflog0.  This interface is monitored
           by the pflogd(8) logging daemon, which dumps the logged packets to
           the file /var/log/pflog in pcap(3) binary format.
 
Back
Top