blob: 7ed5bc7c954850d3cfd9767f14ee4e5b0ed82863 [file] [log] [blame]
Amin Hassanic3e6b532017-03-07 17:47:25 -08001// Copyright 2017 The Chromium OS Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5syntax = "proto3";
6
Amin Hassani7074da62017-09-30 17:14:06 -07007package puffin.metadata;
Amin Hassanic3e6b532017-03-07 17:47:25 -08008option optimize_for = LITE_RUNTIME;
9
Amin Hassani7074da62017-09-30 17:14:06 -070010message BitExtent {
Amin Hassanic3e6b532017-03-07 17:47:25 -080011 uint64 offset = 1;
12 uint64 length = 2;
13}
14
15message StreamInfo {
Amin Hassani7074da62017-09-30 17:14:06 -070016 repeated BitExtent deflates = 1;
17 repeated BitExtent puffs = 2;
Amin Hassanic3e6b532017-03-07 17:47:25 -080018 uint64 puff_length = 3;
19}
20
21message PatchHeader {
Tianjie24d989f2021-07-23 16:10:55 -070022 enum PatchType {
23 BSDIFF = 0;
24 ZUCCHINI = 1;
25 }
26
Amin Hassanic3e6b532017-03-07 17:47:25 -080027 int32 version = 1;
28 StreamInfo src = 2;
29 StreamInfo dst = 3;
30 // The bsdiff patch is installed right after this protobuf.
Tianjie24d989f2021-07-23 16:10:55 -070031
32 PatchType type = 4;
Amin Hassanic3e6b532017-03-07 17:47:25 -080033}