Skip to content

Commit 3bcd829

Browse files
SecAgg Teammathsjamesb5liadriagasconschoppmp
committed
Initial OSS release of Willow
PiperOrigin-RevId: 820724106 Co-authored-by: James Bell-Clark <jhbell@google.com> Co-authored-by: Baiyu Li <baiyuli@google.com> Co-authored-by: Adria Gascon <adriag@google.com> Co-authored-by: Phillipp Schoppmann <schoppmann@google.com> Co-authored-by: Pierre Tholoniat <ptholoniat@google.com>
1 parent 2022540 commit 3bcd829

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

85 files changed

+17353
-1
lines changed

.bazelrc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# compile with clang on all platforms
2+
build --action_env=CC=clang
3+
build --action_env=CXX=clang++
4+
build --host_action_env=CC=clang
5+
build --host_action_env=CXX=clang++

.github/workflows/presubmit.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# Copyright 2025 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
name: Secure Aggregation
16+
17+
on:
18+
push:
19+
branches: [ "main" ]
20+
pull_request:
21+
branches: [ "main" ]
22+
23+
concurrency:
24+
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
25+
cancel-in-progress: true
26+
27+
jobs:
28+
build:
29+
runs-on:
30+
labels: ubuntu-24.04
31+
steps:
32+
- name: Check out repository code
33+
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # pin@v3
34+
35+
- name: Cache bazel build artifacts
36+
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # pin@v4.2.0
37+
with:
38+
path: |
39+
~/.cache/bazel
40+
key: ${{ runner.os }}-${{ hashFiles('.bazelrc', 'MODULE.bazel') }}
41+
restore-keys: |
42+
${{ runner.os }}-${{ hashFiles('.bazelrc', 'MODULE.bazel') }}
43+
44+
- name: "Run `bazel build`"
45+
run: |
46+
bazel build -c opt //...
47+
48+
- name: "Run `bazel test`"
49+
run: |
50+
bazel test -c opt //...

BUILD

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Copyright 2024 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
load("@rules_license//rules:license.bzl", "license")
16+
17+
package(
18+
default_applicable_licenses = [
19+
],
20+
default_visibility = [":allowlist"],
21+
)
22+
23+
license(
24+
name = "license",
25+
package_name = "secure_aggregation",
26+
)
27+
28+
package_group(
29+
name = "internal",
30+
packages = [
31+
"//shell_wrapper/...",
32+
"//willow/...",
33+
],
34+
)
35+
36+
licenses(["notice"])
37+
38+
exports_files(
39+
["LICENSE"],
40+
)

MODULE.bazel

Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
"Secure Aggregation"
2+
3+
module(
4+
name = "secure_aggregation",
5+
version = "0.0.0",
6+
compatibility_level = 1,
7+
)
8+
9+
bazel_dep(name = "rules_rust", version = "0.65.0")
10+
bazel_dep(name = "rules_cc", version = "0.2.9")
11+
bazel_dep(name = "rules_license", version = "1.0.0")
12+
bazel_dep(name = "protobuf", version = "33.0-rc1")
13+
archive_override(
14+
# Patches protobuf to make the Rust libraries visible. See
15+
# https://github.com/protocolbuffers/protobuf/issues/23866.
16+
module_name = "protobuf",
17+
integrity = "sha256-n7r7YMeWhML9K/XhzBWVMXW30fErl3Hfp2hoxLNy+fs=",
18+
strip_prefix = "protobuf-b53a3ab3602e5863861589daa2bc48232af330ad",
19+
urls = ["https://github.com/google/protobuf/archive/b53a3ab3602e5863861589daa2bc48232af330ad.zip"],
20+
)
21+
22+
bazel_dep(name = "abseil-cpp", version = "20250814.1")
23+
bazel_dep(name = "googletest", version = "1.17.0.bcr.1")
24+
bazel_dep(name = "tink_cc", version = "2.4.0")
25+
bazel_dep(name = "shell-encryption", version = "0.0.0")
26+
archive_override(
27+
module_name = "shell-encryption",
28+
integrity = "sha256-qPgdzLiDGXZwj/p5xOuZRQKvqU/qrS0mI8DLhiBWyi0=",
29+
strip_prefix = "shell-encryption-259ce90fdd021d035d237be3dce5ec5a17ff0367",
30+
urls = [
31+
"https://github.com/google/shell-encryption/archive/259ce90fdd021d035d237be3dce5ec5a17ff0367.zip",
32+
],
33+
)
34+
35+
bazel_dep(name = "cxx.rs", version = "1.0.186")
36+
37+
crate = use_extension("@rules_rust//crate_universe:extensions.bzl", "crate")
38+
crate.spec(
39+
features = [
40+
"alloc",
41+
"default",
42+
"getrandom",
43+
"libc",
44+
"small_rng",
45+
"std",
46+
"std_rng",
47+
],
48+
package = "rand",
49+
version = "0.8.5",
50+
)
51+
crate.spec(
52+
features = [
53+
"anyhow",
54+
],
55+
package = "googletest",
56+
version = "0.14.2",
57+
)
58+
crate.spec(
59+
features = [
60+
"alloc",
61+
"group",
62+
"digest",
63+
"precomputed-tables",
64+
"rand_core",
65+
"zeroize",
66+
"serde",
67+
],
68+
package = "curve25519-dalek",
69+
version = "4.1.3",
70+
)
71+
crate.spec(
72+
features = [
73+
"color",
74+
"default",
75+
"derive",
76+
"env",
77+
"error-context",
78+
"help",
79+
"std",
80+
"string",
81+
"suggestions",
82+
"unstable-ext",
83+
"usage",
84+
"wrap_help",
85+
],
86+
package = "clap",
87+
version = "4.5.38",
88+
)
89+
crate.spec(
90+
features = [],
91+
package = "thiserror",
92+
version = "1.0.69",
93+
)
94+
crate.spec(
95+
features = [
96+
"default",
97+
"std",
98+
],
99+
package = "merlin",
100+
version = "3.0.0",
101+
)
102+
crate.spec(
103+
features = [
104+
"default",
105+
"std",
106+
],
107+
package = "sha3",
108+
version = "0.10.8",
109+
)
110+
crate.from_specs()
111+
use_repo(crate, crate_index = "crates")

0 commit comments

Comments
 (0)