Documentation
¶
Overview ¶
Package safebrowsing_proto is a generated protocol buffer package.
It is generated from these files:
safebrowsing.proto
It has these top-level messages:
ThreatInfo ThreatMatch FindThreatMatchesRequest FindThreatMatchesResponse FetchThreatListUpdatesRequest FetchThreatListUpdatesResponse FindFullHashesRequest FindFullHashesResponse ClientInfo Checksum ThreatEntry ThreatEntrySet RawIndices RawHashes RiceDeltaEncoding ThreatEntryMetadata ThreatListDescriptor ListThreatListsResponse
Index ¶
- Variables
- type Checksum
- type ClientInfo
- type CompressionType
- type FetchThreatListUpdatesRequest
- func (*FetchThreatListUpdatesRequest) Descriptor() ([]byte, []int)
- func (m *FetchThreatListUpdatesRequest) GetClient() *ClientInfo
- func (m *FetchThreatListUpdatesRequest) GetListUpdateRequests() []*FetchThreatListUpdatesRequest_ListUpdateRequest
- func (*FetchThreatListUpdatesRequest) ProtoMessage()
- func (m *FetchThreatListUpdatesRequest) Reset()
- func (m *FetchThreatListUpdatesRequest) String() string
- type FetchThreatListUpdatesRequest_ListUpdateRequest
- func (*FetchThreatListUpdatesRequest_ListUpdateRequest) Descriptor() ([]byte, []int)
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetConstraints() *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetPlatformType() PlatformType
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetState() []byte
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetThreatEntryType() ThreatEntryType
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetThreatType() ThreatType
- func (*FetchThreatListUpdatesRequest_ListUpdateRequest) ProtoMessage()
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) Reset()
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) String() string
- type FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints
- func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) Descriptor() ([]byte, []int)
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetMaxDatabaseEntries() int32
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetMaxUpdateEntries() int32
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetRegion() string
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetSupportedCompressions() []CompressionType
- func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) ProtoMessage()
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) Reset()
- func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) String() string
- type FetchThreatListUpdatesResponse
- func (*FetchThreatListUpdatesResponse) Descriptor() ([]byte, []int)
- func (m *FetchThreatListUpdatesResponse) GetListUpdateResponses() []*FetchThreatListUpdatesResponse_ListUpdateResponse
- func (m *FetchThreatListUpdatesResponse) GetMinimumWaitDuration() *google_protobuf.Duration
- func (*FetchThreatListUpdatesResponse) ProtoMessage()
- func (m *FetchThreatListUpdatesResponse) Reset()
- func (m *FetchThreatListUpdatesResponse) String() string
- type FetchThreatListUpdatesResponse_ListUpdateResponse
- func (*FetchThreatListUpdatesResponse_ListUpdateResponse) Descriptor() ([]byte, []int)
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetAdditions() []*ThreatEntrySet
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetChecksum() *Checksum
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetNewClientState() []byte
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetPlatformType() PlatformType
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetRemovals() []*ThreatEntrySet
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetResponseType() FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetThreatEntryType() ThreatEntryType
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetThreatType() ThreatType
- func (*FetchThreatListUpdatesResponse_ListUpdateResponse) ProtoMessage()
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) Reset()
- func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) String() string
- type FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType
- type FindFullHashesRequest
- func (*FindFullHashesRequest) Descriptor() ([]byte, []int)
- func (m *FindFullHashesRequest) GetClient() *ClientInfo
- func (m *FindFullHashesRequest) GetClientStates() [][]byte
- func (m *FindFullHashesRequest) GetThreatInfo() *ThreatInfo
- func (*FindFullHashesRequest) ProtoMessage()
- func (m *FindFullHashesRequest) Reset()
- func (m *FindFullHashesRequest) String() string
- type FindFullHashesResponse
- func (*FindFullHashesResponse) Descriptor() ([]byte, []int)
- func (m *FindFullHashesResponse) GetMatches() []*ThreatMatch
- func (m *FindFullHashesResponse) GetMinimumWaitDuration() *google_protobuf.Duration
- func (m *FindFullHashesResponse) GetNegativeCacheDuration() *google_protobuf.Duration
- func (*FindFullHashesResponse) ProtoMessage()
- func (m *FindFullHashesResponse) Reset()
- func (m *FindFullHashesResponse) String() string
- type FindThreatMatchesRequest
- func (*FindThreatMatchesRequest) Descriptor() ([]byte, []int)
- func (m *FindThreatMatchesRequest) GetClient() *ClientInfo
- func (m *FindThreatMatchesRequest) GetThreatInfo() *ThreatInfo
- func (*FindThreatMatchesRequest) ProtoMessage()
- func (m *FindThreatMatchesRequest) Reset()
- func (m *FindThreatMatchesRequest) String() string
- type FindThreatMatchesResponse
- type ListThreatListsResponse
- type PlatformType
- type RawHashes
- type RawIndices
- type RiceDeltaEncoding
- func (*RiceDeltaEncoding) Descriptor() ([]byte, []int)
- func (m *RiceDeltaEncoding) GetEncodedData() []byte
- func (m *RiceDeltaEncoding) GetFirstValue() int64
- func (m *RiceDeltaEncoding) GetNumEntries() int32
- func (m *RiceDeltaEncoding) GetRiceParameter() int32
- func (*RiceDeltaEncoding) ProtoMessage()
- func (m *RiceDeltaEncoding) Reset()
- func (m *RiceDeltaEncoding) String() string
- type ThreatEntry
- type ThreatEntryMetadata
- type ThreatEntryMetadata_MetadataEntry
- func (*ThreatEntryMetadata_MetadataEntry) Descriptor() ([]byte, []int)
- func (m *ThreatEntryMetadata_MetadataEntry) GetKey() []byte
- func (m *ThreatEntryMetadata_MetadataEntry) GetValue() []byte
- func (*ThreatEntryMetadata_MetadataEntry) ProtoMessage()
- func (m *ThreatEntryMetadata_MetadataEntry) Reset()
- func (m *ThreatEntryMetadata_MetadataEntry) String() string
- type ThreatEntrySet
- func (*ThreatEntrySet) Descriptor() ([]byte, []int)
- func (m *ThreatEntrySet) GetCompressionType() CompressionType
- func (m *ThreatEntrySet) GetRawHashes() *RawHashes
- func (m *ThreatEntrySet) GetRawIndices() *RawIndices
- func (m *ThreatEntrySet) GetRiceHashes() *RiceDeltaEncoding
- func (m *ThreatEntrySet) GetRiceIndices() *RiceDeltaEncoding
- func (*ThreatEntrySet) ProtoMessage()
- func (m *ThreatEntrySet) Reset()
- func (m *ThreatEntrySet) String() string
- type ThreatEntryType
- type ThreatInfo
- func (*ThreatInfo) Descriptor() ([]byte, []int)
- func (m *ThreatInfo) GetPlatformTypes() []PlatformType
- func (m *ThreatInfo) GetThreatEntries() []*ThreatEntry
- func (m *ThreatInfo) GetThreatEntryTypes() []ThreatEntryType
- func (m *ThreatInfo) GetThreatTypes() []ThreatType
- func (*ThreatInfo) ProtoMessage()
- func (m *ThreatInfo) Reset()
- func (m *ThreatInfo) String() string
- type ThreatListDescriptor
- func (*ThreatListDescriptor) Descriptor() ([]byte, []int)
- func (m *ThreatListDescriptor) GetPlatformType() PlatformType
- func (m *ThreatListDescriptor) GetThreatEntryType() ThreatEntryType
- func (m *ThreatListDescriptor) GetThreatType() ThreatType
- func (*ThreatListDescriptor) ProtoMessage()
- func (m *ThreatListDescriptor) Reset()
- func (m *ThreatListDescriptor) String() string
- type ThreatMatch
- func (*ThreatMatch) Descriptor() ([]byte, []int)
- func (m *ThreatMatch) GetCacheDuration() *google_protobuf.Duration
- func (m *ThreatMatch) GetPlatformType() PlatformType
- func (m *ThreatMatch) GetThreat() *ThreatEntry
- func (m *ThreatMatch) GetThreatEntryMetadata() *ThreatEntryMetadata
- func (m *ThreatMatch) GetThreatEntryType() ThreatEntryType
- func (m *ThreatMatch) GetThreatType() ThreatType
- func (*ThreatMatch) ProtoMessage()
- func (m *ThreatMatch) Reset()
- func (m *ThreatMatch) String() string
- type ThreatType
Constants ¶
This section is empty.
Variables ¶
var CompressionType_name = map[int32]string{
0: "COMPRESSION_TYPE_UNSPECIFIED",
1: "RAW",
2: "RICE",
}
var CompressionType_value = map[string]int32{
"COMPRESSION_TYPE_UNSPECIFIED": 0,
"RAW": 1,
"RICE": 2,
}
var FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType_name = map[int32]string{
0: "RESPONSE_TYPE_UNSPECIFIED",
1: "PARTIAL_UPDATE",
2: "FULL_UPDATE",
}
var FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType_value = map[string]int32{
"RESPONSE_TYPE_UNSPECIFIED": 0,
"PARTIAL_UPDATE": 1,
"FULL_UPDATE": 2,
}
var PlatformType_name = map[int32]string{
0: "PLATFORM_TYPE_UNSPECIFIED",
1: "WINDOWS",
2: "LINUX",
3: "ANDROID",
4: "OSX",
5: "IOS",
6: "ANY_PLATFORM",
7: "ALL_PLATFORMS",
8: "CHROME",
}
var PlatformType_value = map[string]int32{
"PLATFORM_TYPE_UNSPECIFIED": 0,
"WINDOWS": 1,
"LINUX": 2,
"ANDROID": 3,
"OSX": 4,
"IOS": 5,
"ANY_PLATFORM": 6,
"ALL_PLATFORMS": 7,
"CHROME": 8,
}
var ThreatEntryType_name = map[int32]string{
0: "THREAT_ENTRY_TYPE_UNSPECIFIED",
1: "URL",
2: "EXECUTABLE",
3: "IP_RANGE",
}
var ThreatEntryType_value = map[string]int32{
"THREAT_ENTRY_TYPE_UNSPECIFIED": 0,
"URL": 1,
"EXECUTABLE": 2,
"IP_RANGE": 3,
}
var ThreatType_name = map[int32]string{
0: "THREAT_TYPE_UNSPECIFIED",
1: "MALWARE",
2: "SOCIAL_ENGINEERING",
3: "UNWANTED_SOFTWARE",
4: "POTENTIALLY_HARMFUL_APPLICATION",
}
var ThreatType_value = map[string]int32{
"THREAT_TYPE_UNSPECIFIED": 0,
"MALWARE": 1,
"SOCIAL_ENGINEERING": 2,
"UNWANTED_SOFTWARE": 3,
"POTENTIALLY_HARMFUL_APPLICATION": 4,
}
Functions ¶
This section is empty.
Types ¶
type Checksum ¶
type Checksum struct { // The SHA256 hash of the client state; that is, of the sorted list of all // hashes present in the database. Sha256 []byte `protobuf:"bytes,1,opt,name=sha256,proto3" json:"sha256,omitempty"` }
The expected state of a client's local database.
func (*Checksum) Descriptor ¶
func (*Checksum) ProtoMessage ¶
func (*Checksum) ProtoMessage()
type ClientInfo ¶
type ClientInfo struct { // A client ID that (hopefully) uniquely identifies the client implementation // of the Safe Browsing API. ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId" json:"client_id,omitempty"` // The version of the client implementation. ClientVersion string `protobuf:"bytes,2,opt,name=client_version,json=clientVersion" json:"client_version,omitempty"` }
The client metadata associated with Safe Browsing API requests.
func (*ClientInfo) Descriptor ¶
func (*ClientInfo) Descriptor() ([]byte, []int)
func (*ClientInfo) GetClientId ¶
func (m *ClientInfo) GetClientId() string
func (*ClientInfo) GetClientVersion ¶
func (m *ClientInfo) GetClientVersion() string
func (*ClientInfo) ProtoMessage ¶
func (*ClientInfo) ProtoMessage()
func (*ClientInfo) Reset ¶
func (m *ClientInfo) Reset()
func (*ClientInfo) String ¶
func (m *ClientInfo) String() string
type CompressionType ¶
type CompressionType int32
The ways in which threat entry sets can be compressed.
const ( // Unknown. CompressionType_COMPRESSION_TYPE_UNSPECIFIED CompressionType = 0 // Raw, uncompressed data. CompressionType_RAW CompressionType = 1 // Rice-Golomb encoded data. CompressionType_RICE CompressionType = 2 )
func (CompressionType) EnumDescriptor ¶
func (CompressionType) EnumDescriptor() ([]byte, []int)
func (CompressionType) String ¶
func (x CompressionType) String() string
type FetchThreatListUpdatesRequest ¶
type FetchThreatListUpdatesRequest struct { // The client metadata. Client *ClientInfo `protobuf:"bytes,1,opt,name=client" json:"client,omitempty"` // The requested threat list updates. ListUpdateRequests []*FetchThreatListUpdatesRequest_ListUpdateRequest `protobuf:"bytes,3,rep,name=list_update_requests,json=listUpdateRequests" json:"list_update_requests,omitempty"` }
Describes a Safe Browsing API update request. Clients can request updates for multiple lists in a single request. NOTE: Field index 2 is unused.
func (*FetchThreatListUpdatesRequest) Descriptor ¶
func (*FetchThreatListUpdatesRequest) Descriptor() ([]byte, []int)
func (*FetchThreatListUpdatesRequest) GetClient ¶
func (m *FetchThreatListUpdatesRequest) GetClient() *ClientInfo
func (*FetchThreatListUpdatesRequest) GetListUpdateRequests ¶
func (m *FetchThreatListUpdatesRequest) GetListUpdateRequests() []*FetchThreatListUpdatesRequest_ListUpdateRequest
func (*FetchThreatListUpdatesRequest) ProtoMessage ¶
func (*FetchThreatListUpdatesRequest) ProtoMessage()
func (*FetchThreatListUpdatesRequest) Reset ¶
func (m *FetchThreatListUpdatesRequest) Reset()
func (*FetchThreatListUpdatesRequest) String ¶
func (m *FetchThreatListUpdatesRequest) String() string
type FetchThreatListUpdatesRequest_ListUpdateRequest ¶
type FetchThreatListUpdatesRequest_ListUpdateRequest struct { // The type of threat posed by entries present in the list. ThreatType ThreatType `protobuf:"varint,1,opt,name=threat_type,json=threatType,enum=safebrowsing_proto.ThreatType" json:"threat_type,omitempty"` // The type of platform at risk by entries present in the list. PlatformType PlatformType `` /* 128-byte string literal not displayed */ // The types of entries present in the list. ThreatEntryType ThreatEntryType `` /* 142-byte string literal not displayed */ // The current state of the client for the requested list (the encrypted // ClientState that was sent to the client from the previous update // request). State []byte `protobuf:"bytes,3,opt,name=state,proto3" json:"state,omitempty"` // The constraints associated with this request. Constraints *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints `protobuf:"bytes,4,opt,name=constraints" json:"constraints,omitempty"` }
A single list update request.
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) Descriptor ¶
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) Descriptor() ([]byte, []int)
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) GetConstraints ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetConstraints() *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) GetPlatformType ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetPlatformType() PlatformType
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) GetState ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetState() []byte
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) GetThreatEntryType ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetThreatEntryType() ThreatEntryType
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) GetThreatType ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) GetThreatType() ThreatType
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) ProtoMessage ¶
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) ProtoMessage()
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) Reset ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) Reset()
func (*FetchThreatListUpdatesRequest_ListUpdateRequest) String ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest) String() string
type FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints ¶
type FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints struct { // The maximum size in number of entries. The update will not contain more // entries than this value. This should be a power of 2 between 2**10 and // 2**20. If zero, no update size limit is set. MaxUpdateEntries int32 `protobuf:"varint,1,opt,name=max_update_entries,json=maxUpdateEntries" json:"max_update_entries,omitempty"` // Sets the maximum number of entries that the client is willing to have // in the local database. This should be a power of 2 between 2**10 and // 2**20. If zero, no database size limit is set. MaxDatabaseEntries int32 `protobuf:"varint,2,opt,name=max_database_entries,json=maxDatabaseEntries" json:"max_database_entries,omitempty"` // Requests the list for a specific geographic location. If not set the // server may pick that value based on the user's IP address. Expects ISO // 3166-1 alpha-2 format. Region string `protobuf:"bytes,3,opt,name=region" json:"region,omitempty"` // The compression types supported by the client. SupportedCompressions []CompressionType `` /* 165-byte string literal not displayed */ }
The constraints for this update.
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) Descriptor ¶
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) Descriptor() ([]byte, []int)
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetMaxDatabaseEntries ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetMaxDatabaseEntries() int32
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetMaxUpdateEntries ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetMaxUpdateEntries() int32
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetRegion ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetRegion() string
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetSupportedCompressions ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) GetSupportedCompressions() []CompressionType
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) ProtoMessage ¶
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) ProtoMessage()
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) Reset ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) Reset()
func (*FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) String ¶
func (m *FetchThreatListUpdatesRequest_ListUpdateRequest_Constraints) String() string
type FetchThreatListUpdatesResponse ¶
type FetchThreatListUpdatesResponse struct { // The list updates requested by the clients. ListUpdateResponses []*FetchThreatListUpdatesResponse_ListUpdateResponse `protobuf:"bytes,1,rep,name=list_update_responses,json=listUpdateResponses" json:"list_update_responses,omitempty"` // The minimum duration the client must wait before issuing any update // request. If this field is not set clients may update as soon as they want. MinimumWaitDuration *google_protobuf.Duration `protobuf:"bytes,2,opt,name=minimum_wait_duration,json=minimumWaitDuration" json:"minimum_wait_duration,omitempty"` }
Response type for threat list update requests.
func (*FetchThreatListUpdatesResponse) Descriptor ¶
func (*FetchThreatListUpdatesResponse) Descriptor() ([]byte, []int)
func (*FetchThreatListUpdatesResponse) GetListUpdateResponses ¶
func (m *FetchThreatListUpdatesResponse) GetListUpdateResponses() []*FetchThreatListUpdatesResponse_ListUpdateResponse
func (*FetchThreatListUpdatesResponse) GetMinimumWaitDuration ¶
func (m *FetchThreatListUpdatesResponse) GetMinimumWaitDuration() *google_protobuf.Duration
func (*FetchThreatListUpdatesResponse) ProtoMessage ¶
func (*FetchThreatListUpdatesResponse) ProtoMessage()
func (*FetchThreatListUpdatesResponse) Reset ¶
func (m *FetchThreatListUpdatesResponse) Reset()
func (*FetchThreatListUpdatesResponse) String ¶
func (m *FetchThreatListUpdatesResponse) String() string
type FetchThreatListUpdatesResponse_ListUpdateResponse ¶
type FetchThreatListUpdatesResponse_ListUpdateResponse struct { // The threat type for which data is returned. ThreatType ThreatType `protobuf:"varint,1,opt,name=threat_type,json=threatType,enum=safebrowsing_proto.ThreatType" json:"threat_type,omitempty"` // The format of the threats. ThreatEntryType ThreatEntryType `` /* 142-byte string literal not displayed */ // The platform type for which data is returned. PlatformType PlatformType `` /* 128-byte string literal not displayed */ // The type of response. This may indicate that an action is required by the // client when the response is received. ResponseType FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType `` /* 178-byte string literal not displayed */ // A set of entries to add to a local threat type's list. Repeated to allow // for a combination of compressed and raw data to be sent in a single // response. Additions []*ThreatEntrySet `protobuf:"bytes,5,rep,name=additions" json:"additions,omitempty"` // A set of entries to remove from a local threat type's list. Repeated for // the same reason as above. Removals []*ThreatEntrySet `protobuf:"bytes,6,rep,name=removals" json:"removals,omitempty"` // The new client state, in encrypted format. Opaque to clients. NewClientState []byte `protobuf:"bytes,7,opt,name=new_client_state,json=newClientState,proto3" json:"new_client_state,omitempty"` // The expected SHA256 hash of the client state; that is, of the sorted list // of all hashes present in the database after applying the provided update. // If the client state doesn't match the expected state, the client must // disregard this update and retry later. Checksum *Checksum `protobuf:"bytes,8,opt,name=checksum" json:"checksum,omitempty"` }
An update to an individual list.
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) Descriptor ¶
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) Descriptor() ([]byte, []int)
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetAdditions ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetAdditions() []*ThreatEntrySet
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetChecksum ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetChecksum() *Checksum
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetNewClientState ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetNewClientState() []byte
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetPlatformType ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetPlatformType() PlatformType
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetRemovals ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetRemovals() []*ThreatEntrySet
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetResponseType ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetResponseType() FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetThreatEntryType ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetThreatEntryType() ThreatEntryType
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) GetThreatType ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) GetThreatType() ThreatType
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) ProtoMessage ¶
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) ProtoMessage()
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) Reset ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) Reset()
func (*FetchThreatListUpdatesResponse_ListUpdateResponse) String ¶
func (m *FetchThreatListUpdatesResponse_ListUpdateResponse) String() string
type FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType ¶
type FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType int32
The type of response sent to the client.
const ( // Unknown. FetchThreatListUpdatesResponse_ListUpdateResponse_RESPONSE_TYPE_UNSPECIFIED FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType = 0 // Partial updates are applied to the client's existing local database. FetchThreatListUpdatesResponse_ListUpdateResponse_PARTIAL_UPDATE FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType = 1 // Full updates replace the client's entire local database. This means // that either the client was seriously out-of-date or the client is // believed to be corrupt. FetchThreatListUpdatesResponse_ListUpdateResponse_FULL_UPDATE FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType = 2 )
func (FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType) EnumDescriptor ¶
func (FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType) EnumDescriptor() ([]byte, []int)
func (FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType) String ¶
func (x FetchThreatListUpdatesResponse_ListUpdateResponse_ResponseType) String() string
type FindFullHashesRequest ¶
type FindFullHashesRequest struct { // The client metadata. Client *ClientInfo `protobuf:"bytes,1,opt,name=client" json:"client,omitempty"` // The current client states for each of the client's local threat lists. ClientStates [][]byte `protobuf:"bytes,2,rep,name=client_states,json=clientStates,proto3" json:"client_states,omitempty"` // The lists and hashes to be checked. ThreatInfo *ThreatInfo `protobuf:"bytes,3,opt,name=threat_info,json=threatInfo" json:"threat_info,omitempty"` }
Request to return full hashes matched by the provided hash prefixes.
func (*FindFullHashesRequest) Descriptor ¶
func (*FindFullHashesRequest) Descriptor() ([]byte, []int)
func (*FindFullHashesRequest) GetClient ¶
func (m *FindFullHashesRequest) GetClient() *ClientInfo
func (*FindFullHashesRequest) GetClientStates ¶
func (m *FindFullHashesRequest) GetClientStates() [][]byte
func (*FindFullHashesRequest) GetThreatInfo ¶
func (m *FindFullHashesRequest) GetThreatInfo() *ThreatInfo
func (*FindFullHashesRequest) ProtoMessage ¶
func (*FindFullHashesRequest) ProtoMessage()
func (*FindFullHashesRequest) Reset ¶
func (m *FindFullHashesRequest) Reset()
func (*FindFullHashesRequest) String ¶
func (m *FindFullHashesRequest) String() string
type FindFullHashesResponse ¶
type FindFullHashesResponse struct { // The full hashes that matched the requested prefixes. Matches []*ThreatMatch `protobuf:"bytes,1,rep,name=matches" json:"matches,omitempty"` // The minimum duration the client must wait before issuing any find hashes // request. If this field is not set, clients can issue a request as soon as // they want. MinimumWaitDuration *google_protobuf.Duration `protobuf:"bytes,2,opt,name=minimum_wait_duration,json=minimumWaitDuration" json:"minimum_wait_duration,omitempty"` // For requested entities that did not match the threat list, how long to // cache the response. NegativeCacheDuration *google_protobuf.Duration `protobuf:"bytes,3,opt,name=negative_cache_duration,json=negativeCacheDuration" json:"negative_cache_duration,omitempty"` }
Response type for requests to find full hashes.
func (*FindFullHashesResponse) Descriptor ¶
func (*FindFullHashesResponse) Descriptor() ([]byte, []int)
func (*FindFullHashesResponse) GetMatches ¶
func (m *FindFullHashesResponse) GetMatches() []*ThreatMatch
func (*FindFullHashesResponse) GetMinimumWaitDuration ¶
func (m *FindFullHashesResponse) GetMinimumWaitDuration() *google_protobuf.Duration
func (*FindFullHashesResponse) GetNegativeCacheDuration ¶
func (m *FindFullHashesResponse) GetNegativeCacheDuration() *google_protobuf.Duration
func (*FindFullHashesResponse) ProtoMessage ¶
func (*FindFullHashesResponse) ProtoMessage()
func (*FindFullHashesResponse) Reset ¶
func (m *FindFullHashesResponse) Reset()
func (*FindFullHashesResponse) String ¶
func (m *FindFullHashesResponse) String() string
type FindThreatMatchesRequest ¶
type FindThreatMatchesRequest struct { // The client metadata. Client *ClientInfo `protobuf:"bytes,1,opt,name=client" json:"client,omitempty"` // The lists and entries to be checked for matches. ThreatInfo *ThreatInfo `protobuf:"bytes,2,opt,name=threat_info,json=threatInfo" json:"threat_info,omitempty"` }
Request to check entries against lists.
func (*FindThreatMatchesRequest) Descriptor ¶
func (*FindThreatMatchesRequest) Descriptor() ([]byte, []int)
func (*FindThreatMatchesRequest) GetClient ¶
func (m *FindThreatMatchesRequest) GetClient() *ClientInfo
func (*FindThreatMatchesRequest) GetThreatInfo ¶
func (m *FindThreatMatchesRequest) GetThreatInfo() *ThreatInfo
func (*FindThreatMatchesRequest) ProtoMessage ¶
func (*FindThreatMatchesRequest) ProtoMessage()
func (*FindThreatMatchesRequest) Reset ¶
func (m *FindThreatMatchesRequest) Reset()
func (*FindThreatMatchesRequest) String ¶
func (m *FindThreatMatchesRequest) String() string
type FindThreatMatchesResponse ¶
type FindThreatMatchesResponse struct { // The threat list matches. Matches []*ThreatMatch `protobuf:"bytes,1,rep,name=matches" json:"matches,omitempty"` }
Response type for requests to find threat matches.
func (*FindThreatMatchesResponse) Descriptor ¶
func (*FindThreatMatchesResponse) Descriptor() ([]byte, []int)
func (*FindThreatMatchesResponse) GetMatches ¶
func (m *FindThreatMatchesResponse) GetMatches() []*ThreatMatch
func (*FindThreatMatchesResponse) ProtoMessage ¶
func (*FindThreatMatchesResponse) ProtoMessage()
func (*FindThreatMatchesResponse) Reset ¶
func (m *FindThreatMatchesResponse) Reset()
func (*FindThreatMatchesResponse) String ¶
func (m *FindThreatMatchesResponse) String() string
type ListThreatListsResponse ¶
type ListThreatListsResponse struct { // The lists available for download by the client. ThreatLists []*ThreatListDescriptor `protobuf:"bytes,1,rep,name=threat_lists,json=threatLists" json:"threat_lists,omitempty"` }
A collection of lists available for download by the client.
func (*ListThreatListsResponse) Descriptor ¶
func (*ListThreatListsResponse) Descriptor() ([]byte, []int)
func (*ListThreatListsResponse) GetThreatLists ¶
func (m *ListThreatListsResponse) GetThreatLists() []*ThreatListDescriptor
func (*ListThreatListsResponse) ProtoMessage ¶
func (*ListThreatListsResponse) ProtoMessage()
func (*ListThreatListsResponse) Reset ¶
func (m *ListThreatListsResponse) Reset()
func (*ListThreatListsResponse) String ¶
func (m *ListThreatListsResponse) String() string
type PlatformType ¶
type PlatformType int32
Types of platforms.
const ( // Unknown platform. PlatformType_PLATFORM_TYPE_UNSPECIFIED PlatformType = 0 // Threat posed to Windows. PlatformType_WINDOWS PlatformType = 1 // Threat posed to Linux. PlatformType_LINUX PlatformType = 2 // Threat posed to Android. PlatformType_ANDROID PlatformType = 3 // Threat posed to OSX. PlatformType_OSX PlatformType = 4 // Threat posed to iOS. PlatformType_IOS PlatformType = 5 // Threat posed to at least one of the defined platforms. PlatformType_ANY_PLATFORM PlatformType = 6 // Threat posed to all defined platforms. PlatformType_ALL_PLATFORMS PlatformType = 7 // Threat posed to Chrome. PlatformType_CHROME PlatformType = 8 )
func (PlatformType) EnumDescriptor ¶
func (PlatformType) EnumDescriptor() ([]byte, []int)
func (PlatformType) String ¶
func (x PlatformType) String() string
type RawHashes ¶
type RawHashes struct { // The number of bytes for each prefix encoded below. This field can be // anywhere from 4 (shortest prefix) to 32 (full SHA256 hash). PrefixSize int32 `protobuf:"varint,1,opt,name=prefix_size,json=prefixSize" json:"prefix_size,omitempty"` // The hashes, all concatenated into one long string. Each hash has a prefix // size of |prefix_size| above. Hashes are sorted in lexicographic order. RawHashes []byte `protobuf:"bytes,2,opt,name=raw_hashes,json=rawHashes,proto3" json:"raw_hashes,omitempty"` }
The uncompressed threat entries in hash format of a particular prefix length. Hashes can be anywhere from 4 to 32 bytes in size. A large majority are 4 bytes, but some hashes are lengthened if they collide with the hash of a popular URL.
Used for sending ThreatEntrySet to clients that do not support compression, or when sending non-4-byte hashes to clients that do support compression.
func (*RawHashes) Descriptor ¶
func (*RawHashes) GetPrefixSize ¶
func (*RawHashes) GetRawHashes ¶
func (*RawHashes) ProtoMessage ¶
func (*RawHashes) ProtoMessage()
type RawIndices ¶
type RawIndices struct { // The indices to remove from a lexicographically-sorted local list. Indices []int32 `protobuf:"varint,1,rep,packed,name=indices" json:"indices,omitempty"` }
A set of raw indices to remove from a local list.
func (*RawIndices) Descriptor ¶
func (*RawIndices) Descriptor() ([]byte, []int)
func (*RawIndices) GetIndices ¶
func (m *RawIndices) GetIndices() []int32
func (*RawIndices) ProtoMessage ¶
func (*RawIndices) ProtoMessage()
func (*RawIndices) Reset ¶
func (m *RawIndices) Reset()
func (*RawIndices) String ¶
func (m *RawIndices) String() string
type RiceDeltaEncoding ¶
type RiceDeltaEncoding struct { // The offset of the first entry in the encoded data, or, if only a single // integer was encoded, that single integer's value. FirstValue int64 `protobuf:"varint,1,opt,name=first_value,json=firstValue" json:"first_value,omitempty"` // The Golomb-Rice parameter which is a number between 2 and 28. This field // is missing (that is, zero) if num_entries is zero. RiceParameter int32 `protobuf:"varint,2,opt,name=rice_parameter,json=riceParameter" json:"rice_parameter,omitempty"` // The number of entries that are delta encoded in the encoded data. If only a // single integer was encoded, this will be zero and the single value will be // stored in first_value. NumEntries int32 `protobuf:"varint,3,opt,name=num_entries,json=numEntries" json:"num_entries,omitempty"` // The encoded deltas that are encoded using the Golomb-Rice coder. EncodedData []byte `protobuf:"bytes,4,opt,name=encoded_data,json=encodedData,proto3" json:"encoded_data,omitempty"` }
The Rice-Golomb encoded data. Used for sending compressed 4-byte hashes or compressed removal indices.
func (*RiceDeltaEncoding) Descriptor ¶
func (*RiceDeltaEncoding) Descriptor() ([]byte, []int)
func (*RiceDeltaEncoding) GetEncodedData ¶
func (m *RiceDeltaEncoding) GetEncodedData() []byte
func (*RiceDeltaEncoding) GetFirstValue ¶
func (m *RiceDeltaEncoding) GetFirstValue() int64
func (*RiceDeltaEncoding) GetNumEntries ¶
func (m *RiceDeltaEncoding) GetNumEntries() int32
func (*RiceDeltaEncoding) GetRiceParameter ¶
func (m *RiceDeltaEncoding) GetRiceParameter() int32
func (*RiceDeltaEncoding) ProtoMessage ¶
func (*RiceDeltaEncoding) ProtoMessage()
func (*RiceDeltaEncoding) Reset ¶
func (m *RiceDeltaEncoding) Reset()
func (*RiceDeltaEncoding) String ¶
func (m *RiceDeltaEncoding) String() string
type ThreatEntry ¶
type ThreatEntry struct { // A hash prefix, consisting of the most significant 4-32 bytes of a SHA256 // hash. Hash []byte `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` // A URL. Url string `protobuf:"bytes,2,opt,name=url" json:"url,omitempty"` }
An individual threat; for example, a malicious URL or its hash representation. Only one of these fields should be set.
func (*ThreatEntry) Descriptor ¶
func (*ThreatEntry) Descriptor() ([]byte, []int)
func (*ThreatEntry) GetHash ¶
func (m *ThreatEntry) GetHash() []byte
func (*ThreatEntry) GetUrl ¶
func (m *ThreatEntry) GetUrl() string
func (*ThreatEntry) ProtoMessage ¶
func (*ThreatEntry) ProtoMessage()
func (*ThreatEntry) Reset ¶
func (m *ThreatEntry) Reset()
func (*ThreatEntry) String ¶
func (m *ThreatEntry) String() string
type ThreatEntryMetadata ¶
type ThreatEntryMetadata struct { // The metadata entries. Entries []*ThreatEntryMetadata_MetadataEntry `protobuf:"bytes,1,rep,name=entries" json:"entries,omitempty"` }
The metadata associated with a specific threat entry. The client is expected to know the metadata key/value pairs associated with each threat type.
func (*ThreatEntryMetadata) Descriptor ¶
func (*ThreatEntryMetadata) Descriptor() ([]byte, []int)
func (*ThreatEntryMetadata) GetEntries ¶
func (m *ThreatEntryMetadata) GetEntries() []*ThreatEntryMetadata_MetadataEntry
func (*ThreatEntryMetadata) ProtoMessage ¶
func (*ThreatEntryMetadata) ProtoMessage()
func (*ThreatEntryMetadata) Reset ¶
func (m *ThreatEntryMetadata) Reset()
func (*ThreatEntryMetadata) String ¶
func (m *ThreatEntryMetadata) String() string
type ThreatEntryMetadata_MetadataEntry ¶
type ThreatEntryMetadata_MetadataEntry struct { // The metadata entry key. Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` // The metadata entry value. Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` }
A single metadata entry.
func (*ThreatEntryMetadata_MetadataEntry) Descriptor ¶
func (*ThreatEntryMetadata_MetadataEntry) Descriptor() ([]byte, []int)
func (*ThreatEntryMetadata_MetadataEntry) GetKey ¶
func (m *ThreatEntryMetadata_MetadataEntry) GetKey() []byte
func (*ThreatEntryMetadata_MetadataEntry) GetValue ¶
func (m *ThreatEntryMetadata_MetadataEntry) GetValue() []byte
func (*ThreatEntryMetadata_MetadataEntry) ProtoMessage ¶
func (*ThreatEntryMetadata_MetadataEntry) ProtoMessage()
func (*ThreatEntryMetadata_MetadataEntry) Reset ¶
func (m *ThreatEntryMetadata_MetadataEntry) Reset()
func (*ThreatEntryMetadata_MetadataEntry) String ¶
func (m *ThreatEntryMetadata_MetadataEntry) String() string
type ThreatEntrySet ¶
type ThreatEntrySet struct { // The compression type for the entries in this set. CompressionType CompressionType `` /* 140-byte string literal not displayed */ // The raw SHA256-formatted entries. RawHashes *RawHashes `protobuf:"bytes,2,opt,name=raw_hashes,json=rawHashes" json:"raw_hashes,omitempty"` // The raw removal indices for a local list. RawIndices *RawIndices `protobuf:"bytes,3,opt,name=raw_indices,json=rawIndices" json:"raw_indices,omitempty"` // The encoded 4-byte prefixes of SHA256-formatted entries, using a // Golomb-Rice encoding. RiceHashes *RiceDeltaEncoding `protobuf:"bytes,4,opt,name=rice_hashes,json=riceHashes" json:"rice_hashes,omitempty"` // The encoded local, lexicographically-sorted list indices, using a // Golomb-Rice encoding. Used for sending compressed removal indices. RiceIndices *RiceDeltaEncoding `protobuf:"bytes,5,opt,name=rice_indices,json=riceIndices" json:"rice_indices,omitempty"` }
A set of threats that should be added or removed from a client's local database.
func (*ThreatEntrySet) Descriptor ¶
func (*ThreatEntrySet) Descriptor() ([]byte, []int)
func (*ThreatEntrySet) GetCompressionType ¶
func (m *ThreatEntrySet) GetCompressionType() CompressionType
func (*ThreatEntrySet) GetRawHashes ¶
func (m *ThreatEntrySet) GetRawHashes() *RawHashes
func (*ThreatEntrySet) GetRawIndices ¶
func (m *ThreatEntrySet) GetRawIndices() *RawIndices
func (*ThreatEntrySet) GetRiceHashes ¶
func (m *ThreatEntrySet) GetRiceHashes() *RiceDeltaEncoding
func (*ThreatEntrySet) GetRiceIndices ¶
func (m *ThreatEntrySet) GetRiceIndices() *RiceDeltaEncoding
func (*ThreatEntrySet) ProtoMessage ¶
func (*ThreatEntrySet) ProtoMessage()
func (*ThreatEntrySet) Reset ¶
func (m *ThreatEntrySet) Reset()
func (*ThreatEntrySet) String ¶
func (m *ThreatEntrySet) String() string
type ThreatEntryType ¶
type ThreatEntryType int32
Types of entries that pose threats. Threat lists are collections of entries of a single type.
const ( // Unspecified. ThreatEntryType_THREAT_ENTRY_TYPE_UNSPECIFIED ThreatEntryType = 0 // A URL. ThreatEntryType_URL ThreatEntryType = 1 // An executable program. ThreatEntryType_EXECUTABLE ThreatEntryType = 2 // An IP range. ThreatEntryType_IP_RANGE ThreatEntryType = 3 )
func (ThreatEntryType) EnumDescriptor ¶
func (ThreatEntryType) EnumDescriptor() ([]byte, []int)
func (ThreatEntryType) String ¶
func (x ThreatEntryType) String() string
type ThreatInfo ¶
type ThreatInfo struct { // The threat types to be checked. ThreatTypes []ThreatType `` /* 130-byte string literal not displayed */ // The platform types to be checked. PlatformTypes []PlatformType `` /* 138-byte string literal not displayed */ // The entry types to be checked. ThreatEntryTypes []ThreatEntryType `` /* 152-byte string literal not displayed */ // The threat entries to be checked. ThreatEntries []*ThreatEntry `protobuf:"bytes,3,rep,name=threat_entries,json=threatEntries" json:"threat_entries,omitempty"` }
The information regarding one or more threats that a client submits when checking for matches in threat lists.
func (*ThreatInfo) Descriptor ¶
func (*ThreatInfo) Descriptor() ([]byte, []int)
func (*ThreatInfo) GetPlatformTypes ¶
func (m *ThreatInfo) GetPlatformTypes() []PlatformType
func (*ThreatInfo) GetThreatEntries ¶
func (m *ThreatInfo) GetThreatEntries() []*ThreatEntry
func (*ThreatInfo) GetThreatEntryTypes ¶
func (m *ThreatInfo) GetThreatEntryTypes() []ThreatEntryType
func (*ThreatInfo) GetThreatTypes ¶
func (m *ThreatInfo) GetThreatTypes() []ThreatType
func (*ThreatInfo) ProtoMessage ¶
func (*ThreatInfo) ProtoMessage()
func (*ThreatInfo) Reset ¶
func (m *ThreatInfo) Reset()
func (*ThreatInfo) String ¶
func (m *ThreatInfo) String() string
type ThreatListDescriptor ¶
type ThreatListDescriptor struct { // The threat type posed by the list's entries. ThreatType ThreatType `protobuf:"varint,1,opt,name=threat_type,json=threatType,enum=safebrowsing_proto.ThreatType" json:"threat_type,omitempty"` // The platform type targeted by the list's entries. PlatformType PlatformType `` /* 128-byte string literal not displayed */ // The entry types contained in the list. ThreatEntryType ThreatEntryType `` /* 142-byte string literal not displayed */ }
Describes an individual threat list. A list is defined by three parameters: the type of threat posed, the type of platform targeted by the threat, and the type of entries in the list.
func (*ThreatListDescriptor) Descriptor ¶
func (*ThreatListDescriptor) Descriptor() ([]byte, []int)
func (*ThreatListDescriptor) GetPlatformType ¶
func (m *ThreatListDescriptor) GetPlatformType() PlatformType
func (*ThreatListDescriptor) GetThreatEntryType ¶
func (m *ThreatListDescriptor) GetThreatEntryType() ThreatEntryType
func (*ThreatListDescriptor) GetThreatType ¶
func (m *ThreatListDescriptor) GetThreatType() ThreatType
func (*ThreatListDescriptor) ProtoMessage ¶
func (*ThreatListDescriptor) ProtoMessage()
func (*ThreatListDescriptor) Reset ¶
func (m *ThreatListDescriptor) Reset()
func (*ThreatListDescriptor) String ¶
func (m *ThreatListDescriptor) String() string
type ThreatMatch ¶
type ThreatMatch struct { // The threat type matching this threat. ThreatType ThreatType `protobuf:"varint,1,opt,name=threat_type,json=threatType,enum=safebrowsing_proto.ThreatType" json:"threat_type,omitempty"` // The platform type matching this threat. PlatformType PlatformType `` /* 128-byte string literal not displayed */ // The threat entry type matching this threat. ThreatEntryType ThreatEntryType `` /* 142-byte string literal not displayed */ // The threat matching this threat. Threat *ThreatEntry `protobuf:"bytes,3,opt,name=threat" json:"threat,omitempty"` // Optional metadata associated with this threat. ThreatEntryMetadata *ThreatEntryMetadata `protobuf:"bytes,4,opt,name=threat_entry_metadata,json=threatEntryMetadata" json:"threat_entry_metadata,omitempty"` // The cache lifetime for the returned match. Clients must not cache this // response for more than this duration to avoid false positives. CacheDuration *google_protobuf.Duration `protobuf:"bytes,5,opt,name=cache_duration,json=cacheDuration" json:"cache_duration,omitempty"` }
A match when checking a threat entry in the Safe Browsing threat lists.
func (*ThreatMatch) Descriptor ¶
func (*ThreatMatch) Descriptor() ([]byte, []int)
func (*ThreatMatch) GetCacheDuration ¶
func (m *ThreatMatch) GetCacheDuration() *google_protobuf.Duration
func (*ThreatMatch) GetPlatformType ¶
func (m *ThreatMatch) GetPlatformType() PlatformType
func (*ThreatMatch) GetThreat ¶
func (m *ThreatMatch) GetThreat() *ThreatEntry
func (*ThreatMatch) GetThreatEntryMetadata ¶
func (m *ThreatMatch) GetThreatEntryMetadata() *ThreatEntryMetadata
func (*ThreatMatch) GetThreatEntryType ¶
func (m *ThreatMatch) GetThreatEntryType() ThreatEntryType
func (*ThreatMatch) GetThreatType ¶
func (m *ThreatMatch) GetThreatType() ThreatType
func (*ThreatMatch) ProtoMessage ¶
func (*ThreatMatch) ProtoMessage()
func (*ThreatMatch) Reset ¶
func (m *ThreatMatch) Reset()
func (*ThreatMatch) String ¶
func (m *ThreatMatch) String() string
type ThreatType ¶
type ThreatType int32
Types of threats.
const ( // Unknown. ThreatType_THREAT_TYPE_UNSPECIFIED ThreatType = 0 // Malware threat type. ThreatType_MALWARE ThreatType = 1 // Social engineering threat type. ThreatType_SOCIAL_ENGINEERING ThreatType = 2 // Unwanted software threat type. ThreatType_UNWANTED_SOFTWARE ThreatType = 3 // Potentially harmful application threat type. ThreatType_POTENTIALLY_HARMFUL_APPLICATION ThreatType = 4 )
func (ThreatType) EnumDescriptor ¶
func (ThreatType) EnumDescriptor() ([]byte, []int)
func (ThreatType) String ¶
func (x ThreatType) String() string