-
Notifications
You must be signed in to change notification settings - Fork 360
/
beacon.go
40 lines (37 loc) · 1.5 KB
/
beacon.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
package beacon
import (
"gopkg.in/mgo.v2/bson"
)
type (
//straight output from the beacon analysis
BeaconAnalysisOutput struct {
ID bson.ObjectId `bson:"_id,omitempty"`
UconnID bson.ObjectId `bson:"uconn_id"`
TS_iRange int64 `bson:"ts_iRange"`
TS_iMode int64 `bson:"ts_iMode"`
TS_iModeCount int64 `bson:"ts_iMode_count"`
TS_iSkew float64 `bson:"ts_iSkew"`
TS_iDispersion int64 `bson:"ts_iDispersion"`
TS_duration float64 `bson:"ts_duration"`
TS_score float64 `bson:"ts_score"`
TS_intervals []int64 `bson:"ts_intervals"`
TS_intervalCounts []int64 `bson:"ts_interval_counts"`
}
//Used in order to join the uconn and beacon tables
BeaconAnalysisView struct {
ID bson.ObjectId `bson:"_id,omitempty"`
Src string `bson:"src"`
Dst string `bson:"dst"`
LocalSrc bool `bson:"local_src"`
LocalDst bool `bson:"local_dst"`
Connections int64 `bson:"connection_count"`
AvgBytes float64 `bson:"avg_bytes"`
TS_iRange int64 `bson:"ts_iRange"`
TS_iMode int64 `bson:"ts_iMode"`
TS_iModeCount int64 `bson:"ts_iMode_count"`
TS_iSkew float64 `bson:"ts_iSkew"`
TS_iDispersion int64 `bson:"ts_iDispersion"`
TS_duration float64 `bson:"ts_duration"`
TS_score float64 `bson:"ts_score"`
}
)