Comments (3)
Root Cause
CAI module treats non-CAI data as CAI metadata and tries to parse it.
Analysis
Currently, the CAI module finds the CAI metadata (APP11 Marker Segments if more precisely) only by searching the 0xFFEB
which represents the APP11 Marker.
Under this condition, any data identical to 0xFFEB
will be treated as the beginning of a CAI metadata.
Solution
Method 1: Workaround (I will go in this way because of resource constraint)
Checking both the App11 Marker and the CI
parameter can be a quick workaround. It's a workaround because it only reduces the probability to treat non-CAI data as CAI metadata.
Method 2: Root cause solution
To my best knowledge, to fix this issue completely, we need to find all the starting points of the Marker Segments between SOI
and DQT
and only parse the APP11 Marker Segments.
from pyc2pa.
Testing image information
$ file scott.jpg
scott.jpg: JPEG image data, Exif standard: [TIFF image data, little-endian, direntries=12, height=3024, manufacturer=samsung, model=SM-N9810, orientation=upper-right, xresolution=210, yresolution=218, resolutionunit=2, software=N9810ZSU1ATI4, datetime=2020:10:24 15:03:33, width=4032], baseline, precision 8, 4032x3024, components 3
from pyc2pa.
The workaround seems to work (although with known issue #15)
$ sha256sum scott*
47e148074e9a3f658119c82e1a2e5aebb148a2a3864f6a1e4d1f58a4bd31a0ee scott-cai-cai-cai.jpg
55146f1665fa84fe2a76d13772f7f83ea02a188cde68a047cb9acd2e28005d90 scott.jpg
bfd0c280dfa195a0e8468a0f0d1d6beecb652a70cf591c19187d0c5166cef6a8 scott-thumbnail.jpg
from pyc2pa.
Related Issues (17)
- Doing multi-injection multiple times causes the injected image to be corrupted HOT 18
- JSON parsing function's results keep growing in memory HOT 1
- Can not support using copy of raw photo as thumbnail for some photos HOT 1
- Fail to pass signature verification HOT 6
- Asset Repository HOT 3
- Incorrect UUIDs HOT 2
- System Dependency Issue
- import libexiv2python doesn't work on macOS HOT 2
- C2PA hello world example cannot work HOT 1
- CAI verification website does not list C2PA Information from test image HOT 1
- Unable to install c2pa on a MacOS HOT 2
- Fail to parse the generated CAI data HOT 2
- feature-support-c2pa-photo nor main follow the latest spec
- Support multiple Claims HOT 3
- Support Assertion hash validation HOT 5
- pycrypto outdated & missing endesive library
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyc2pa.