added some comment and source for threading
added loopback sniffing capture