summaryrefslogtreecommitdiff
path: root/cleaner.go
diff options
context:
space:
mode:
Diffstat (limited to 'cleaner.go')
-rw-r--r--cleaner.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/cleaner.go b/cleaner.go
index 03914e4..d79e462 100644
--- a/cleaner.go
+++ b/cleaner.go
@@ -53,7 +53,7 @@ func cleanData(conf Config, db_user, db_pass, db_conn, db_name string) (err erro
//Add noise for differential privacy
for i := range cDat {
- cDat[i].occurances = diffpriv(cDat[i].occurances, 1, conf.Epsilon)
+ cDat[i].occurences = diffpriv(cDat[i].occurences, 1, conf.Epsilon)
}
//Begin transaction
@@ -133,7 +133,7 @@ func clean(rDat []RawData, conf Config) (cDat []CleanData, err error) {
iplist = append(iplist, ip)
}
- pairs, err := findASAndIPBlock(iplist...)
+ pairs, err := findIPBlock(iplist...)
if err != nil {
return
}
@@ -152,7 +152,7 @@ func clean(rDat []RawData, conf Config) (cDat []CleanData, err error) {
asDst: rd.asDst,
portSrc: rd.portSrc,
portDst: rd.portDst,
- occurances: 1,
+ occurences: 1,
volume: rd.pktLenDist,
time: tim,
})
@@ -172,9 +172,9 @@ func removeDups(cDat []CleanData) []CleanData {
//Check if an equal struct already is appended
for ri := range ret {
if ret[ri].equals(&cDat[ci]) {
- //If found, increase it occurances instead of
+ //If found, increase it occurences instead of
//appending a new struct
- ret[ri].occurances += cDat[ci].occurances
+ ret[ri].occurences += cDat[ci].occurences
found = true
break
}