omega-mv
Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.
Brought by drakestapleton
omega-mv / src / omega_blake3.h
| 1 | /* SPDX-License-Identifier: Apache-2.0 |
| 2 | * Copyright 2026 Drake Stapleton (AIEN / aien-dev) |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | #ifndef OMEGA_BLAKE3_H |
| 18 | #define OMEGA_BLAKE3_H |
| 19 | |
| 20 | /* omega_blake3: BLAKE3 default (unkeyed) hash, 32-byte output, one shot. VC1 stage 4. |
| 21 | * |
| 22 | * Why it exists: an aien-proof EvidenceReceiptV1 id is BLAKE3 over the receipt's canonical |
| 23 | * bytes (aien-protocols specs/evidence-receipt/SUBSET.md section 1), and the resolver must |
| 24 | * recompute that id itself (SPEC 5.1 rule 1). Portable C, no SIMD, no allocation, no state. |
| 25 | * Verified against the official BLAKE3 test vectors (tests/resolve/blake3_vectors.txt, from |
| 26 | * BLAKE3-team/BLAKE3 test_vectors/test_vectors.json, input = 0,1,..,250 repeating). */ |
| 27 | |
| 28 | #include <stddef.h> |
| 29 | #include <stdint.h> |
| 30 | |
| 31 | void omega_blake3_hash(const uint8_t *data, size_t len, uint8_t out[32]); |
| 32 | |
| 33 | #endif /* OMEGA_BLAKE3_H */ |