|
Arachne 1.0
Arachne - the perpetual stitcher of Wikidata entities.
|
Namespaces | |
| namespace | anonymous_namespace{crypto.cpp} |
Classes | |
| class | sha256_hasher |
Typedefs | |
| using | sha256_digest = std::array<std::byte, 32> |
Functions | |
| std::string | sha256 (std::span< const std::byte > bytes) |
| std::string | sha256 (std::string_view bytes) |
| std::string | sha256_file (const std::filesystem::path &path) |
| std::string | sha256_string (std::string_view bytes) |
| bool | is_safe_relative_artifact_ref (std::string_view artifact_ref) noexcept |
| std::filesystem::path | safe_artifact_path (const std::filesystem::path &root, std::string_view artifact_ref) |
| using arachne::crypto::sha256_digest = std::array<std::byte, 32> |
Definition at line 14 of file crypto.hpp.
|
nodiscardnoexcept |
Return true only for a portable, non-empty relative artifact reference. Backslashes, absolute paths, empty components, and dot components are rejected so a reference has the same meaning on POSIX and Windows.
Definition at line 249 of file crypto.cpp.
|
nodiscard |
Join a validated artifact reference to a root. This is a lexical safety primitive; callers that write files must additionally reject symlinked directory components.
Definition at line 302 of file crypto.cpp.
|
nodiscard |
Return the lowercase hexadecimal SHA-256 digest of arbitrary bytes.
Definition at line 209 of file crypto.cpp.
References arachne::crypto::sha256_hasher::finish_hex().
Referenced by arachne::pheidippides::anonymous_namespace{transport.cpp}::artifact_id_for(), arachne::ariadne::candidate_planner::build(), arachne::ariadne::viewer_builder::build_site(), arachne::ariadne::anonymous_namespace{viewer.cpp}::edge_id(), arachne::ariadne::candidate_planner::enrichment_fetch_plan(), arachne::coordination::operational_ledger::intake(), arachne::penelope::anonymous_namespace{store.cpp}::make_staging_directory(), anonymous_namespace{main.cpp}::policy_configuration_hash(), arachne::ariadne::viewer_builder::project(), arachne::ariadne::anonymous_namespace{candidates.cpp}::publish_immutable_file(), arachne::pheidippides::anonymous_namespace{hardened_transport.cpp}::request_cache_key(), arachne::pheidippides::anonymous_namespace{transport.cpp}::retry_delay(), sha256_string(), anonymous_namespace{main.cpp}::wikidata_point_fetch_request(), arachne::penelope::anonymous_namespace{store.cpp}::write_active_id(), arachne::ariadne::anonymous_namespace{viewer.cpp}::write_immutable_file(), arachne::ariadne::candidate_planner::write_plan(), and arachne::ariadne::viewer_builder::write_projection().


|
nodiscard |
Return the lowercase hexadecimal SHA-256 digest of a byte string.
Definition at line 215 of file crypto.cpp.
References arachne::crypto::sha256_hasher::finish_hex().

|
nodiscard |
Stream a file in binary mode and return its lowercase SHA-256 digest.
Definition at line 221 of file crypto.cpp.
References arachne::crypto::sha256_hasher::finish_hex().
Referenced by anonymous_namespace{main.cpp}::command_candidate_rebuild(), arachne::penelope::store::export_jsonl(), arachne::coordination::anonymous_namespace{coordinator.cpp}::fingerprint_regular_file(), arachne::ariadne::anonymous_namespace{candidates.cpp}::publish_immutable_file(), arachne::penelope::store::replace_candidate_snapshot(), anonymous_namespace{main.cpp}::resolve_snapshot_export(), arachne::pheidippides::anonymous_namespace{hardened_transport.cpp}::safe_cached_file(), arachne::penelope::anonymous_namespace{store.cpp}::snapshot_from_directory(), anonymous_namespace{main.cpp}::verify_external_source_snapshot(), anonymous_namespace{main.cpp}::write_graph_run_manifest(), and arachne::ariadne::anonymous_namespace{viewer.cpp}::write_immutable_file().


|
inlinenodiscard |
Compatibility spelling used by early Penelope code.
Definition at line 50 of file crypto.hpp.
References sha256().
