Credentio

C++ libraries to support validation and generation of C2PA Content Credentials (https://c2pa.org/).

NOTE: We are actively developing this project and may introduce breaking changes without notice.

Supported Media Formats

The library supports C2PA provenance extraction and validation for files with the following extensions:

CategoryExtensions
Image.avif, .dng, .gif, .heic, .heif, .jpeg, .jpg, .png, .tif, .tiff, .webp
Video/Audio.avi, .m4a, .mov, .mp3, .mp4, .wav, .flac
Document.pdf, .docx, .pptx, .xlsx

Prerequisites

  • Clang
  • Bazel
  • Git

Dependencies

Quickstart

Credentio includes a fast standalone command-line tool for inspecting and verifying C2PA metadata embedded in media assets.

Building the CLI

bazel build tools:c2pa_validate

Validating with Trust Anchors

You can validate assets against specific PEM-encoded trust anchors for claim signers and Time Stamping Authorities (TSA):

bazel run tools:c2pa_validate -- \
  --asset=/path/to/asset.jpg \
  --claim_signer_trust=/path/to/claim_signer_trust_anchors.pem \
  --tsa_trust=/path/to/tsa_trust_anchors.pem

Note on Trust Lists: Credentio does not distribute or provide trust anchor lists. You can obtain the latest official C2PA trust lists from the C2PA organization on GitHub (https://github.com/c2pa-org/conformance-public/tree/main/trust-list).

Building & Testing

To build the entire project:

bazel build ...

To execute all unit tests:

bazel test ...

Support & Releases

Credentio recommends that users live-at-head (updating to the latest commit on the main branch as often as possible). We are actively developing this project and may introduce breaking changes without notice.

License & Disclaimer

Credentio is licensed under the terms of the Apache 2.0 License. See LICENSE for more information.

Disclaimer

This is not an officially supported Google product. This project is not eligible for the Google Open Source Software Vulnerability Rewards Program.

Contact

For questions, feedback, or inquiries, please contact: credentio-team@google.com.