This commit is contained in:
crusader 2018-05-11 11:24:21 +09:00
parent 3ae9f53619
commit f547c15d95
33 changed files with 84 additions and 84 deletions

View File

@ -15,5 +15,5 @@ type Host struct {
Mac string `json:"mac,omitempty"`
OS string `json:"os,omitempty"`
DiscoveredDate util.Timestamp `json:"discoveredDate,omitempty"`
DiscoveredDate *util.Timestamp `json:"discoveredDate,omitempty"`
}

View File

@ -16,7 +16,7 @@ type Port struct {
PortType constants.PortType `json:"portType,omitempty"`
PortNumber json.Number `json:"portNumber,omitempty"`
DiscoveredDate util.Timestamp `json:"discoveredDate,omitempty"`
DiscoveredDate *util.Timestamp `json:"discoveredDate,omitempty"`
UDPLayer gopacket.Layer `json:"-"`
}

View File

@ -14,5 +14,5 @@ type Service struct {
CryptoType constants.CryptoType `json:"cryptoType,omitempty"`
ServiceName string `json:"serviceName,omitempty"`
DiscoveredDate util.Timestamp `json:"discoveredDate,omitempty"`
DiscoveredDate *util.Timestamp `json:"discoveredDate,omitempty"`
}

View File

@ -15,7 +15,7 @@ type Zone struct {
Iface string `json:"iface,omitempty"`
Mac string `json:"mac,omitempty"`
DiscoveredDate util.Timestamp `json:"discoveredDate,omitempty"`
DiscoveredDate *util.Timestamp `json:"discoveredDate,omitempty"`
mtx sync.RWMutex `json:"-"`
}

View File

@ -9,5 +9,5 @@ import (
type Domain struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -9,7 +9,7 @@ import (
type DomainMember struct {
ID json.Number `json:"id,Number,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Member *member.Member `json:"member,omitempty"`
Domain *Domain `json:"domain,omitempty"`
}

View File

@ -12,7 +12,7 @@ import (
type Infra struct {
ID json.Number `json:"id,Number,omitempty"`
MetaInfraType *meta.MetaInfraType `json:"type,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Probe *probe.Probe `json:"probe,omitempty"`
Target *target.Target `json:"target,omitempty"`
}

View File

@ -9,5 +9,5 @@ type InfraHost struct {
InfraOS *InfraOS `json:"os,omitempty"`
IP string `json:"ip,omitempty"`
Mac string `json:"mac,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -5,5 +5,5 @@ import "git.loafle.net/overflow/commons-go/core/util"
type InfraMachine struct {
Infra
Meta string `json:"meta,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -9,6 +9,6 @@ type InfraOS struct {
Infra
InfraMachine *InfraMachine `json:"machine,omitempty"`
Meta string `json:"meta,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
MetaInfraVendor *meta.MetaInfraVendor `json:"vendor,omitempty"`
}

View File

@ -6,5 +6,5 @@ type InfraOSApplication struct {
Infra
InfraOS *InfraOS `json:"os,omitempty"`
Name string `json:"name,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -8,5 +8,5 @@ type InfraOSDaemon struct {
Infra
InfraOS *InfraOS `json:"os,omitempty"`
Name string `json:"name,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -10,7 +10,7 @@ import (
type InfraOSPort struct {
Infra
InfraOS *InfraOS `json:"os,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Port json.Number `json:"port,omitempty"`
PortType string `json:"portType,omitempty"`
MetaInfraVendor *meta.MetaInfraVendor `json:"vendor,omitempty"`

View File

@ -13,6 +13,6 @@ type InfraServiceApplication struct {
PortType string `json:"portType,omitempty"`
Port json.Number `json:"port,omitempty"`
MetaInfraVendor *meta.MetaInfraVendor `json:"vendor,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
TLSType bool `json:"tlsType,omitempty"`
}

View File

@ -14,7 +14,7 @@ type Member struct {
Name string `json:"name,omitempty"`
Phone string `json:"phone,omitempty"`
CompanyName string `json:"companyName,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Status *meta.MetaMemberStatus `json:"status,omitempty"`
SigninFailCount int `json:"signinFailCount,omitempty"`
TotpType bool `json:"totpType,omitempty"`

View File

@ -10,5 +10,5 @@ type MetaContainer struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -10,6 +10,6 @@ type MetaCrawler struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Container *MetaContainer `json:"container,omitempty"`
}

View File

@ -9,5 +9,5 @@ import (
type MetaHistoryType struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -9,5 +9,5 @@ import (
type MetaInfraType struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -9,6 +9,6 @@ import (
type MetaInfraVendor struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
InfraType *MetaInfraType `json:"infraType,omitempty"`
}

View File

@ -10,5 +10,5 @@ type MetaProbeTaskType struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -11,6 +11,6 @@ type MetaSensorDisplayItem struct {
Name string `json:"name,omitempty"`
Crawler *MetaCrawler `json:"crawler,omitempty"`
Unit *MetaSensorItemUnit `json:"unit,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
ItemType *MetaSensorItemType `json:"itemType,omitempty"`
}

View File

@ -11,5 +11,5 @@ type MetaSensorItem struct {
SensorItemType *MetaSensorItemType `json:"sensorItemType,omitempty"`
Key string `json:"key,omitempty"`
Name string `json:"name,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -13,6 +13,6 @@ type MetaSensorItemKey struct {
Froms string `json:"froms,omitempty"`
Option string `json:"option,omitempty"`
Crawler *MetaCrawler `json:"crawler,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Unit *MetaSensorItemUnit `json:"unit,omitempty"`
}

View File

@ -10,5 +10,5 @@ type MetaSensorItemType struct {
ID json.Number `json:"id,Number,omitempty"`
Name string `json:"name,omitempty"`
Description string `json:"description,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -9,6 +9,6 @@ import (
type MetaSensorItemUnit struct {
ID json.Number `json:"id,Number,omitempty"`
Unit string `json:"unit,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Mark string `json:"mark,omitempty"`
}

View File

@ -14,10 +14,10 @@ type NoAuthProbe struct {
Description string `json:"description,omitempty"`
Status *meta.MetaNoAuthProbeStatus `json:"status,omitempty"`
TempProbeKey string `json:"tempProbeKey,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
APIKey string `json:"apiKey,omitempty"`
Domain *domain.DomainMember `json:"domain,omitempty"`
Probe *probe.Probe `json:"probe,omitempty"`
ConnectDate util.Timestamp `json:"connectDate,omitempty"`
ConnectDate *util.Timestamp `json:"connectDate,omitempty"`
ConnectAddress string `json:"connectAddress,omitempty"`
}

View File

@ -9,10 +9,10 @@ import (
type Notification struct {
ID json.Number `json:"id,Number,omitempty"`
CreateDate util.Timestamp `json:"date,omitempty"`
CreateDate *util.Timestamp `json:"date,omitempty"`
Title string `json:"title,omitempty"`
Message string `json:"message,omitempty"`
Member *member.Member `json:"member,omitempty"`
ConfirmDate util.Timestamp `json:"confirmDate,omitempty"`
ConfirmDate *util.Timestamp `json:"confirmDate,omitempty"`
Url string `json:"url,omitempty"`
}

View File

@ -13,15 +13,15 @@ type Probe struct {
ID json.Number `json:"id,Number,omitempty"`
Status *meta.MetaProbeStatus `json:"status,omitempty"`
Description string `json:"description,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Domain *domain.Domain `json:"domain,omitempty"`
ProbeKey string `json:"probeKey,omitempty"`
EncryptionKey string `json:"encryptionKey,omitempty"`
DisplayName string `json:"displayName,omitempty"`
Cidr string `json:"cidr,omitempty"`
AuthorizeDate util.Timestamp `json:"authorizeDate,omitempty"`
AuthorizeDate *util.Timestamp `json:"authorizeDate,omitempty"`
AuthorizeMember *member.Member `json:"authorizeMember,omitempty"`
ConnectDate util.Timestamp `json:"connectDate,omitempty"`
ConnectDate *util.Timestamp `json:"connectDate,omitempty"`
ConnectAddress string `json:"connectAddress,omitempty"`
TargetCount int `json:"targetCount,omitempty"`

View File

@ -12,9 +12,9 @@ type ProbeTask struct {
MetaProbeTaskType *meta.MetaProbeTaskType `json:"metaProbeTaskType,omitempty"`
Probe *Probe `json:"probe,omitempty"`
Data string `json:"data,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
SendDate util.Timestamp `json:"sendDate,omitempty"`
StartDate util.Timestamp `json:"startDate,omitempty"`
EndDate util.Timestamp `json:"endDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
SendDate *util.Timestamp `json:"sendDate,omitempty"`
StartDate *util.Timestamp `json:"startDate,omitempty"`
EndDate *util.Timestamp `json:"endDate,omitempty"`
Succeed bool `json:"succeed,omitempty"`
}

View File

@ -10,7 +10,7 @@ import (
type Sensor struct {
ID json.Number `json:"id,Number,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
Description string `json:"description,omitempty"`
MetaSensorStatus *meta.MetaSensorStatus `json:"status,omitempty"`
Target *target.Target `json:"target,omitempty"`

View File

@ -11,5 +11,5 @@ type SensorItem struct {
ID json.Number `json:"id,Number,omitempty"`
Sensor *Sensor `json:"sensor,omitempty"`
MetaSensorItem *meta.MetaSensorItem `json:"item,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
}

View File

@ -8,7 +8,7 @@ import (
type Target struct {
ID json.Number `json:"id,Number,omitempty"`
CreateDate util.Timestamp `json:"createDate,omitempty"`
CreateDate *util.Timestamp `json:"createDate,omitempty"`
DisplayName string `json:"displayName,omitempty"`
Description string `json:"description,omitempty"`
}