// Copyright 2016 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
syntax = "proto2";
import "safebrowsing.proto";
option optimize_for = LITE_RUNTIME;
package safe_browsing;
message HashFile {
// The size of hash prefixes stored in this file.
optional int32 prefix_size = 1;
// The file extension of this file. This extension should be added to the end
// of the store path.
optional string extension = 2;
// A list of offsets into the hash prefix file which can be used to optimize
// checks.
repeated uint32 offsets = 3;
// The total size of the file.
optional uint64 file_size = 4;
}
// The message that's serialized to disk when a store update is processed.
message V4StoreFileFormat {
// The magic number to identify this file as a SafeBrowsing hash-prefix file.
// https://en.wikipedia.org/wiki/Magic_number_(programming)
// Its value is 0x600D71FE
optional uint32 magic_number = 1;
// Identifies the version of the file format.
// Version 9 with PVer4 is very different from earlier versions.
optional uint32 version_number = 2;
// Information about the store and the hash-prefix updates.
optional FetchThreatListUpdatesResponse.ListUpdateResponse
list_update_response = 3;
// Information on hashes stored in separate files.
repeated HashFile hash_files = 4;
}