myl7/fss
1.1.0
Function secret sharing (FSS) primitives including distributed point/comparison function (DPF/DCF)
Loading...
Searching...
No Matches
hash.cuh
Go to the documentation of this file.
1
// SPDX-License-Identifier: Apache-2.0
8
#pragma once
9
#include <cuda_runtime.h>
10
#include <cuda/std/array>
11
#include <cuda/std/span>
12
#include <cuda/std/tuple>
13
#include <concepts>
14
18
template
<
typename
Hash>
19
concept
Hashable
=
requires
(Hash hash, cuda::std::span<const int4, 4> msg) {
20
{ hash.Hash(msg) } -> std::same_as<cuda::std::array<int4, 2>>;
21
};
22
26
template
<
typename
Hash>
27
concept
XorHashable
=
requires
(Hash hash, cuda::std::tuple<int4, const int4> msg) {
28
{ hash.Hash(msg) } -> std::same_as<cuda::std::array<int4, 4>>;
29
};
Hashable
Collision-resistant hash interface.
Definition
hash.cuh:19
XorHashable
Collision-resistant and XOR-collision-resistant hash interface.
Definition
hash.cuh:27
include
fss
hash.cuh
Generated by
1.9.8