Google Cloud Web Risk V1beta1 Client - Class RawHashes (1.4.4)

Reference documentation and code samples for the Google Cloud Web Risk V1beta1 Client class RawHashes.

The uncompressed threat entries in hash format.

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 URI. Used for sending ThreatEntryAdditons to clients that do not support compression, or when sending non-4-byte hashes to clients that do support compression.

Generated from protobuf message google.cloud.webrisk.v1beta1.RawHashes

Namespace

Google \ Cloud \ WebRisk \ V1beta1

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ prefix_size int

The number of bytes for each prefix encoded below. This field can be anywhere from 4 (shortest prefix) to 32 (full SHA256 hash).

↳ raw_hashes string

The hashes, in binary format, concatenated into one long string. Hashes are sorted in lexicographic order. For JSON API users, hashes are base64-encoded.

getPrefixSize

The number of bytes for each prefix encoded below. This field can be anywhere from 4 (shortest prefix) to 32 (full SHA256 hash).

Returns
TypeDescription
int

setPrefixSize

The number of bytes for each prefix encoded below. This field can be anywhere from 4 (shortest prefix) to 32 (full SHA256 hash).

Parameter
NameDescription
var int
Returns
TypeDescription
$this

getRawHashes

The hashes, in binary format, concatenated into one long string. Hashes are sorted in lexicographic order. For JSON API users, hashes are base64-encoded.

Returns
TypeDescription
string

setRawHashes

The hashes, in binary format, concatenated into one long string. Hashes are sorted in lexicographic order. For JSON API users, hashes are base64-encoded.

Parameter
NameDescription
var string
Returns
TypeDescription
$this