1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
// Copyright 2026 WritersLogic. All rights reserved.
// Licensed under the Apache License, Version 2.0 or the MIT license,
// at your option.
//! C2PA manifest embedding and hard binding for WebVTT subtitle and caption
//! files.
//!
//! WebVTT is a structured text format, so a C2PA Manifest Store is associated
//! with it using the fixed ASCII armour delimiters
//! (`-----BEGIN C2PA MANIFEST-----` / `-----END C2PA MANIFEST-----`) inside a
//! single-line `NOTE` comment placed immediately after the `WEBVTT` signature,
//! as specified by the C2PA structured text embedding section. Placement after
//! the signature (rather than at the start of the file) is what makes this
//! WebVTT-specific: the `WEBVTT` line is a reserved header that must come first.
//!
//! ```text
//! WEBVTT
//!
//! NOTE -----BEGIN C2PA MANIFEST----- https://example.com/m.c2pa -----END C2PA MANIFEST-----
//!
//! 00:00:00.000 --> 00:00:05.000
//! Hello world
//! ```
//!
//! # Scope relative to `c2pa-structured-text`
//!
//! `c2pa-structured-text` implements the general structured text embedding
//! method and lists WebVTT as one comment style. This crate is the **canonical
//! WebVTT implementation**: the general method's "prepend a comment line" rule
//! would place the block before the `WEBVTT` signature and produce an invalid
//! file, and the hard binding needs WebVTT-aware placement. `c2pa-structured-text`
//! documents the WebVTT delimiter but defers correct placement and hard binding
//! here.
//!
//! # Hard binding
//!
//! See [`binding`] for the byte-exact `c2pa.hash.data` data hash and the single
//! exclusion range covering the manifest block.
//!
//! # Validation
//!
//! See [`bridge`] for extracting the manifest store and delegating
//! signature/trust/assertion validation to the official C2PA SDK.
//!
//! # Features
//!
//! - `hash` (default): `sha2`-backed [`binding::compute_data_hash`] /
//! [`binding::verify_data_hash`]. Disable with `default-features = false` for
//! a zero-dependency embed/extract build.
//! - `c2pa` (off by default): the [`bridge::validate`] delegation to c2pa-rs.
pub use ;
pub use ;
pub use ;
pub use Error;
pub use ;
pub use ;