misc: decoupled session record loading to external package

This commit is contained in:
evilsocket 2019-04-03 10:26:54 +02:00
parent b743b26dde
commit 126cb7febf
No known key found for this signature in database
GPG key ID: 1564D7F30393A456
78 changed files with 2063 additions and 490 deletions

26
vendor/github.com/mdlayher/raw/timeout_bsd.go generated vendored Normal file
View file

@ -0,0 +1,26 @@
// +build darwin dragonfly freebsd netbsd openbsd
package raw
import (
"time"
)
const (
// Maximum read timeout per syscall.
// It is required because read/recvfrom won't be interrupted on closing of the file descriptor.
readTimeout = 200 * time.Millisecond
)
// Copyright (c) 2012 The Go Authors. All rights reserved.
// Source code in this file is based on src/net/interface_linux.go,
// from the Go standard library. The Go license can be found here:
// https://golang.org/LICENSE.
// Taken from:
// https://github.com/golang/go/blob/master/src/net/net.go#L417-L421.
type timeoutError struct{}
func (e *timeoutError) Error() string { return "i/o timeout" }
func (e *timeoutError) Timeout() bool { return true }
func (e *timeoutError) Temporary() bool { return true }