c2pa-rs icon indicating copy to clipboard operation
c2pa-rs copied to clipboard

Add file mimetype detection to core Rust SDK

Open tmathern opened this issue 6 months ago • 1 comments

Mimetype detection is more an art than a science, as it involves guessing the correct mimetype for a file.

Some languages (like Python) attempt to guess the mimetype for files by looking at the filepath extension, but this can fail in two ways:

  • when there is no extension
  • when the extension lookup matches the wrong type (eg. https://github.com/contentauth/c2pa-python/pull/151)

The ask would be to move down that detection to the Rust SDK, to ensure all bound languages (eg. C++/Python) use at least the same logic, and not language-specific logics/adaptations.

tmathern avatar Aug 28 '25 23:08 tmathern

:white_check_mark: Jira issue https://jira.corp.adobe.com/browse/CAI-10466 is successfully created for this GitHub issue.

github-jira-sync-bot avatar Dec 18 '25 00:12 github-jira-sync-bot