예제 #1
0
파일: icmpping.go 프로젝트: abrander/alerto
func init() {
	var err error
	conn, err = icmp.ListenPacket("ip4:icmp", "0.0.0.0")
	if err != nil {
		if err.Error() == "listen ip4:icmp 0.0.0.0: socket: operation not permitted" {
			logger.Error("icmpping", "Please run:\nsudo setcap cap_net_raw=ep %s\n", os.Args[0])
		} else {
			logger.Error("icmpping", err.Error())
		}
	}

	active = make(map[uint16]chan IcmpReply)

	plugins.Register("icmp4", NewIcmpPing)

	go ListenLoop()
}
예제 #2
0
func init() {
	plugins.Register("localtransport", NewLocalTransport)
}
예제 #3
0
func init() {
	plugins.Register("ssh-command", NewSshCommand)
}
예제 #4
0
파일: pidof.go 프로젝트: abrander/alerto
func init() {
	plugins.Register("pidof", NewPidOf)
}
예제 #5
0
파일: dns.go 프로젝트: abrander/alerto
func init() {
	plugins.Register("dns", NewDns)
}
예제 #6
0
파일: load.go 프로젝트: abrander/alerto
func init() {
	plugins.Register("load", NewLoad)
}
예제 #7
0
파일: noop.go 프로젝트: abrander/alerto
func init() {
	plugins.Register("noop", NewNoop)
}
예제 #8
0
파일: http.go 프로젝트: abrander/alerto
func init() {
	plugins.Register("http", NewHttp)
}