Documentation
¶
Index ¶
- type Address
- type Archive
- type ArchiveFile
- type Attachment
- type BaseInfos
- type DKIMValidation
- type DKIMVerification
- type DocMeta
- type Event
- type FeaturesMail
- type FromAddress
- type GeoIPResult
- type IncomingMail
- func (z *IncomingMail) DecodeMsg(dc *msgp.Reader) (err error)
- func (z *IncomingMail) EncodeMsg(en *msgp.Writer) (err error)
- func (z *IncomingMail) MarshalMsg(b []byte) (o []byte, err error)
- func (z *IncomingMail) Msgsize() (s int)
- func (z *IncomingMail) UnmarshalMsg(bts []byte) (o []byte, err error)
- type LatLon
- type PDFMeta
- type PhishtankEntry
- type ReceivedBy
- type ReceivedElement
- type ReceivedFrom
- type ReceivedIP
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArchiveFile ¶
type Attachment ¶
type Attachment struct { Name string `json:"name,omitempty"` InferredType string `json:"inferred_type,omitempty"` ReportedType string `json:"reported_type,omitempty"` Size int64 `json:"size_bytes"` Hash string `json:"hash,omitempty"` PDFMetadata *PDFMeta `json:"pdf_metadata,omitempty"` DocMetadata *DocMeta `json:"doc_metadata,omitempty"` ExeMetadata map[string]interface{} `json:"exe_metadata,omitempty"` EventsMetadata []*Event `json:"event_metadata,omitempty"` // TODO: ImageMetadata should be more defined ImageMetadata map[string]interface{} `json:"image_metadata,omitempty"` Archives map[string]*Archive `json:"archive_content,omitempty"` SubAttachment *Attachment `json:"sub_attachment,omitempty"` // TODO Executable bool `json:"is_executable"` }
type BaseInfos ¶
type BaseInfos struct { MailFrom string `json:"mail_from,omitempty"` RcptTo []string `json:"rcpt_to,omitempty" yaml:",flow"` Host string `json:"host,omitempty"` Family string `json:"family,omitempty"` Port int `json:"port"` Addr string `json:"addr,omitempty"` Helo string `json:"helo,omitempty"` TimeReported time.Time `json:"-" yaml:"-"` UID [16]byte `json:"-" yaml:"-"` }
func (*BaseInfos) MarshalMsg ¶
MarshalMsg implements msgp.Marshaler
type DKIMValidation ¶
type DKIMValidation struct { Error string `json:"error,omitempty"` Verifications []DKIMVerification `json:"verifications,omitempty"` }
type DKIMVerification ¶
type FeaturesMail ¶
type FeaturesMail struct { BaseInfos `yaml:",inline"` UID string `json:"uid,omitempty"` Size int64 `json:"size_bytes"` ContentType string `json:"content_type,omitempty"` Reported string `json:"timereported,omitempty"` Headers map[string][]string `json:"headers,omitempty"` Attachments []*Attachment `json:"attachments,omitempty"` BagOfWords map[string]int `json:"bag_of_words,omitempty"` Keywords []string `json:"keywords,omitempty" yaml:",flow"` Phrases []string `json:"phrases,omitempty" yaml:",flow"` Language string `json:"language,omitempty"` TimeHeader string `json:"time_header,omitempty"` Received []ReceivedElement `json:"received,omitempty"` // TODO: check that From is consistent/scam From *FromAddress `json:"from,omitempty"` To []Address `json:"to,omitempty" yaml:",flow"` Title string `json:"title,omitempty"` Emails []string `json:"emails,omitempty"` URLs []string `json:"urls,omitempty"` PhishtankURLS []*PhishtankEntry `json:"phishtank_urls,omitempty"` Images []string `json:"images,omitempty"` DKIM *DKIMValidation `json:"dkim,omitempty"` }
type FromAddress ¶
type GeoIPResult ¶
type IncomingMail ¶
func (*IncomingMail) DecodeMsg ¶
func (z *IncomingMail) DecodeMsg(dc *msgp.Reader) (err error)
DecodeMsg implements msgp.Decodable
func (*IncomingMail) EncodeMsg ¶
func (z *IncomingMail) EncodeMsg(en *msgp.Writer) (err error)
EncodeMsg implements msgp.Encodable
func (*IncomingMail) MarshalMsg ¶
func (z *IncomingMail) MarshalMsg(b []byte) (o []byte, err error)
MarshalMsg implements msgp.Marshaler
func (*IncomingMail) Msgsize ¶
func (z *IncomingMail) Msgsize() (s int)
Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message
func (*IncomingMail) UnmarshalMsg ¶
func (z *IncomingMail) UnmarshalMsg(bts []byte) (o []byte, err error)
UnmarshalMsg implements msgp.Unmarshaler
type PDFMeta ¶
type PDFMeta struct { Title string `json:"title,omitempty"` Author string `json:"author,omitempty"` Creator string `json:"creator,omitempty"` Producer string `json:"producer,omitempty"` CreationDate *time.Time `json:"creation_date,omitempty"` ModDate *time.Time `json:"mod_date,omitempty"` Tagged bool `json:"tagged"` UserProperties bool `json:"user_properties"` Form string `json:"form,omitempty"` Javascript bool `json:"javascript"` Pages int64 `json:"pages"` Encrypted bool `json:"encrypted"` PageSize string `json:"page_size,omitempty"` FileSize int64 `json:"file_size_bytes"` Optimized bool `json:"optimized"` Version string `json:"version,omitempty"` Language string `json:"language,omitempty"` Keywords []string `json:"keywords,omitempty"` Phrases []string `json:"phrases,omitempty"` }
type PhishtankEntry ¶
type PhishtankEntry struct { URL string `json:"url,omitempty"` PhishID int `json:"phish_id"` DetailsURL string `json:"details_url,omitempty"` SubmissionTime *time.Time `json:"submission_time,omitempty"` Online bool `json:"online"` Verified bool `json:"verified"` VerificationTime *time.Time `json:"verification_time,omitempty"` }
type ReceivedBy ¶
type ReceivedElement ¶
type ReceivedElement struct { From *ReceivedFrom `json:"from,omitempty"` By *ReceivedBy `json:"by,omitempty"` Protocol string `json:"protocol,omitempty"` ID string `json:"id,omitempty"` TLS string `json:"tls,omitempty"` For string `json:"for,omitempty"` Timestamp *time.Time `json:"time,omitempty"` EnvelopeFrom string `json:"envelope_from,omitempty"` Helo string `json:"helo,omitempty"` Raw string `json:"raw,omitempty"` }
type ReceivedFrom ¶
type ReceivedFrom struct { ReportedName string `json:"reported_name,omitempty"` IP *ReceivedIP `json:"ip,omitempty"` DNSReversedName string `json:"reversed_name,omitempty"` }
type ReceivedIP ¶
type ReceivedIP struct { Parsed net.IP `json:"parsed_ip,omitempty"` Reported string `json:"reported,omitempty"` Public bool `json:"public"` Location *GeoIPResult `json:"location,omitempty"` }
Click to show internal directories.
Click to hide internal directories.