results

package
v1.0.1-0...-fc9375b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 22, 2024 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NoRoot      chainRoot = 0
	SystemStore chainRoot = 1
	Loop        chainRoot = 2
)
View Source
const (
	FileHosts = "hosts.csv"

	// files to save SSH scan results
	FileHostKeys  = "host_keys.csv"
	FileRelations = "relations.csv"

	// files to save TLS scan results
	FileCerts       = "certs.csv"
	FileCertHostRel = "cert_chain.csv"
	FileScsv        = "scsv.csv"
	FileHttp        = "http.csv"
	FileHttpVerbose = "http_verbose.csv"
	FileTLSVerbose  = "tls_verbose.csv"
	FileDissecTLS   = "dissectls.csv"
	FileStapledOCSP = "stapled_ocsp_responses.csv"
	FileJarm        = "jarm.csv"
	FileKeyLog      = "tls-keylog"
)

Output files

Variables

View Source
var HttpCsvHeader = []string{"id", "protocol", "http_method", "http_path", "http_code", "error_data"}
View Source
var HttpExtendedCsvHeader = []string{"id", "position", "header", "content"}
View Source
var JarmCsvHeader = []string{"id", "fingerprint", "fingerprint_raw", "error_data"}

Functions

func HandshakeErrorLookup

func HandshakeErrorLookup(err error) string

handshakeErrorLookup returns a string for a certain handshake error

func TrimLoop

func TrimLoop(certs []*x509.Certificate) ([]*x509.Certificate, bool)

Types

type CertRelationResult

type CertRelationResult struct {
	Chain []x509.Certificate
	Root  chainRoot
}

func (*CertRelationResult) GetCsvFileName

func (t *CertRelationResult) GetCsvFileName() string

func (*CertRelationResult) GetCsvHeader

func (t *CertRelationResult) GetCsvHeader() []string

func (*CertRelationResult) WriteCsv

func (t *CertRelationResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type CertResult

type CertResult struct {
	Depth       int
	Cert        *x509.Certificate
	SystemStore bool
}

func (*CertResult) GetCsvFileName

func (t *CertResult) GetCsvFileName() string

func (*CertResult) GetCsvHeader

func (t *CertResult) GetCsvHeader() []string

func (*CertResult) WriteCsv

func (t *CertResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type DissecTLSResult

type DissecTLSResult struct {
	Model          ServerModel
	NumRequests    int
	NumTimeouts    int
	InformationCut bool
	Timeout        bool
	TcpError       bool
}

func (DissecTLSResult) GetCsvFileName

func (t DissecTLSResult) GetCsvFileName() string

func (DissecTLSResult) GetCsvHeader

func (t DissecTLSResult) GetCsvHeader() []string

func (DissecTLSResult) WriteCsv

func (t DissecTLSResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type HTTPExtendedResult

type HTTPExtendedResult struct {
	Header   string
	Position int
	Content  string
}

func (*HTTPExtendedResult) GetCsvFileName

func (t *HTTPExtendedResult) GetCsvFileName() string

func (*HTTPExtendedResult) GetCsvHeader

func (t *HTTPExtendedResult) GetCsvHeader() []string

func (*HTTPExtendedResult) WriteCsv

func (t *HTTPExtendedResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type HTTPResult

type HTTPResult struct {
	Protocol    string
	HttpMethod  string
	HttpPath    string
	HttpCode    int
	HttpHeaders []string
	HttpError   error
}

func (*HTTPResult) GetCsvFileName

func (t *HTTPResult) GetCsvFileName() string

func (*HTTPResult) GetCsvHeader

func (t *HTTPResult) GetCsvHeader() []string

func (*HTTPResult) WriteCsv

func (t *HTTPResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type JARMResult

type JARMResult struct {
	Fingerprint string
	Raw         string
	Error       error
}

func (*JARMResult) GetCsvFileName

func (t *JARMResult) GetCsvFileName() string

func (*JARMResult) GetCsvHeader

func (t *JARMResult) GetCsvHeader() []string

func (*JARMResult) WriteCsv

func (t *JARMResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type Result

type Result interface {
	GetCsvFileName() string
	GetCsvHeader() []string
	WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error
}

type SCSVResult

type SCSVResult struct {
	Version uint16
	Cipher  uint16
	Err     error
}

func (*SCSVResult) GetCsvFileName

func (t *SCSVResult) GetCsvFileName() string

func (*SCSVResult) GetCsvHeader

func (t *SCSVResult) GetCsvHeader() []string

func (*SCSVResult) WriteCsv

func (t *SCSVResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type SSHResult

type SSHResult struct {
	HostKey                  ssh.PublicKey
	Fingerprint              string
	KexAlgos                 []string
	ServerHostKeyAlgos       []string
	CiphersServerClient      []string
	CiphersClientServer      []string
	MacsServerClient         []string
	MacsClientServer         []string
	CompressionsClientServer []string
	CompressionsServerClient []string
	LanguagesClientServer    []string
	LanguagesServerClient    []string
	SshVersion               string
	ServerVersion            string
	Err                      error
}

func (SSHResult) GetCsvFileName

func (t SSHResult) GetCsvFileName() string

func (SSHResult) GetCsvHeader

func (t SSHResult) GetCsvHeader() []string

func (SSHResult) WriteCsv

func (t SSHResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type ScanResult

type ScanResult struct {
	SubResults []ScanSubResult
	Id         misc.SessionUID
	Ip         string
	Domain     string
	Address    string
	CHName     string
}

func (*ScanResult) AddResult

func (s *ScanResult) AddResult(r ScanSubResult)

type ScanSubResult

type ScanSubResult struct {
	SynStart time.Time
	SynEnd   time.Time
	ScanEnd  time.Time
	Result   Result
}

ScanResult contains the time when the measurement occurred and the result

type ServerModel

type ServerModel struct {
	VersionSSLv3 *string
	VersionTLS10 *string
	VersionTLS11 *string
	VersionTLS12 *string
	VersionTLS13 *string
	VersionError *string

	CipherPrio         []uint16
	CipherError        *string
	CipherDone         *bool
	PreferClientCipher *bool
	IgnoresCipher      *bool

	SupportedGroupsPrio            []tls.CurveID
	GroupsError                    *string
	SupportedGroupsDone            *bool
	PreferClientGroups             *bool
	PreferClientGroupsWithKeyShare *bool
	IgnoresGroups                  *bool

	AlpnPrio         []string
	AlpnError        *string
	IgnoresAlpn      *bool
	PreferClientAlpn *bool

	ExtendedMasterSecret             *bool
	StatusRequest                    *bool
	EncryptThenMac                   *bool
	MaxFragmentSizeSupport           *bool
	RecordSizeLimitSupport           *bool
	InappropriateFallbackSupport     *bool
	SupportedPoints                  []string
	SupportedSignaturealgorithms     []uint16
	SupportedSignaturealgorithmsCert []uint16
	CertificateAuthorities           []string

	Heartbeat []uint8

	AlertSequence []tls.Alert

	ExtensionOrderSH  [][]uint16
	ExtensionOrderEE  [][]uint16
	ExtensionOrderCR  [][]uint16
	ExtensionOrderHRR [][]uint16
	ExtensionOrderCT  [][]uint16

	ExtensionsConsistent bool

	CipherScanComplete bool
	ScanKnownCipher    bool
	ReEnableCipherScan bool
}

type StapledOCSPResult

type StapledOCSPResult struct {
	OCSPResponseBytes []byte
}

func (StapledOCSPResult) GetCsvFileName

func (t StapledOCSPResult) GetCsvFileName() string

func (StapledOCSPResult) GetCsvHeader

func (t StapledOCSPResult) GetCsvHeader() []string

func (StapledOCSPResult) WriteCsv

func (t StapledOCSPResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type TCPResult

type TCPResult struct {
	Err error
}

func (*TCPResult) GetCsvFileName

func (t *TCPResult) GetCsvFileName() string

func (*TCPResult) GetCsvHeader

func (t *TCPResult) GetCsvHeader() []string

func (*TCPResult) WriteCsv

func (t *TCPResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type TLSFingerprintResult

type TLSFingerprintResult struct {
	TLSState tls.ConnectionState
}

func (*TLSFingerprintResult) GetCsvFileName

func (t *TLSFingerprintResult) GetCsvFileName() string

func (*TLSFingerprintResult) GetCsvHeader

func (t *TLSFingerprintResult) GetCsvHeader() []string

func (*TLSFingerprintResult) WriteCsv

func (t *TLSFingerprintResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

type TLSResult

type TLSResult struct {
	Certificate     *x509.Certificate
	AllCertificates []*x509.Certificate
	Version         uint16
	Cipher          uint16
	SendAlerts      []tls.Alert
	RecvAlerts      []tls.Alert
	Err             error
	Errors          []error
}

func (*TLSResult) GetCsvFileName

func (t *TLSResult) GetCsvFileName() string

func (*TLSResult) GetCsvHeader

func (t *TLSResult) GetCsvHeader() []string

func (*TLSResult) WriteCsv

func (t *TLSResult) WriteCsv(writer *csv.Writer, parentResult *ScanResult, synStart time.Time, synEnd time.Time, scanEnd time.Time, skipErrors bool, certCache *misc.CertCache) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL