Monitoring network usage excluding local traffic

前端 未结 8 2059
一整个雨季
一整个雨季 2020-12-29 13:14

I am working on an app that monitors network usage. However I noticed many ways to do this does not allow exclusion of local traffic (say, Time Machine).

I am lookin

8条回答
  •  不思量自难忘°
    2020-12-29 13:43

    I think, an approximate solution: getifaddrs can be used to get statistics on network usage.

    It can get separate statistics for Wi-Fi and WWAN interfaces.

    You might find more information from :

    http://www.gsp.com/cgi-bin/man.cgi?section=3&topic=getifaddrs

提交回复
热议问题