evo_django_kits
Awesome evo_django_kits created by maycuatroi
Install it from PyPI
pip install evo-django-kits
Usage
from evo_django_kits import BaseClass
from evo_django_kits import base_function
BaseClass().base_method()
base_function()
$ python -m evo_django_kits
#or
$ evo_django_kits
Development
Read the CONTRIBUTING.md file.
PNG Data Extractor
This repository contains tools to extract and analyze data from PNG files, with special focus on extracting C2PA (Content Authenticity Initiative) metadata that may be embedded in images generated by AI systems like ChatGPT.
Background
PNG files contain structured data in "chunks". In addition to standard PNG chunks, some AI-generated images contain C2PA metadata which provides provenance information. This metadata is often stored in text chunks (tEXt or iTXt) or in JUMBF (JPEG Universal Metadata Box Format) containers.
Tools Included
This repository includes several Python scripts for analyzing PNG files:
- png_data_extractor.py - Extracts standard PNG chunks and basic metadata
- c2pa_extractor.py - Focuses on extracting C2PA/CAI specific metadata
- extract_binary_data.py - Analyzes binary patterns looking for JUMBF boxes and signature patterns
- analyze_png.py - Combined tool that uses all three approaches
Requirements
- Python 3.6+
- No external dependencies (only standard library modules)
Usage
Analyze a PNG file with all tools at once:
python analyze_png.py path/to/your/image.png
This will generate several JSON files with analysis results:
image.png_analysis.json- Standard PNG chunk analysisimage.png_c2pa.json- C2PA metadata analysisimage.png_binary.json- Binary pattern analysisimage.png_combined.json- Combined analysis
Save output to a specific directory:
python analyze_png.py path/to/your/image.png -o output_directory
Print only a summary without saving files:
python analyze_png.py path/to/your/image.png -s
Using individual tools:
You can also use each tool separately:
python png_data_extractor.py path/to/your/image.png
python c2pa_extractor.py path/to/your/image.png
python extract_binary_data.py path/to/your/image.png
What Data Is Extracted
These tools extract:
-
Standard PNG Information
- All PNG chunks with their types, lengths, and data
- Basic image information (dimensions, color type, bit depth)
- Contents of text chunks
-
C2PA/CAI Metadata
- Claim generators and assertions
- AI model information
- Digital source type
- URNs and other identifier information
- Signature data
-
Binary Analysis
- JUMBF box structures
- Content provenance signatures
- ASCII strings related to C2PA/CAI
Example Output
The summary output looks like:
============================================================
PNG ANALYSIS SUMMARY FOR: example.png
============================================================
File size: 12345 bytes
PNG Chunks: 8
- IHDR: 1
- tEXt: 2
- iTXt: 1
- IDAT: 3
- IEND: 1
C2PA Data:
- C2PA metadata entries: 3
- Claims found: 1
- Assertions found: 2
- AI Generated: Yes
- AI Model: ChatGPT
Binary Analysis:
- JUMBF boxes found: 5
- C2PA signatures found: 3
- Relevant strings found: 12
============================================================
For detailed information, check the generated JSON files.
============================================================
Understanding the Results
For detailed analysis, check the generated JSON files which contain all extracted information. The C2PA/CAI metadata can help verify:
- If an image was generated by AI
- Which AI model generated it
- When it was created
- Other provenance and authenticity information
License
MIT
Metadata
Release files for evo-django-kits 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| evo_django_kits-0.1.2.tar.gz | 16.3 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| evo_django_kits-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 33.9 kB
Release files / evo_django_kits-0.1.2.tar.gz
| Download URL | evo_django_kits-0.1.2.tar.gz |
|---|---|
| Size | 16.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f8b40221510323860e690e91f136f15357f6afb179c386491d835f4d2ec8de71
|
|
BLAKE2b-256 checksum How to use checksums |
af40a3f1dec829adbc82058334432a403bc595c5f475a3f3fcb6daba66cc7d38
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.12
|
Release files / evo_django_kits-0.1.2-py3-none-any.whl
| Download URL | evo_django_kits-0.1.2-py3-none-any.whl |
|---|---|
| Size | 17.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f08419405bcc9e081155a0fa1346a98d8a3d2147c54434a0558d0c4af66cbbe2
|
|
BLAKE2b-256 checksum How to use checksums |
a5427244b03779e0eaafcba6c486569fda626a813522fe1963c4634b9f147994
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.12
|
Security for evo-django-kits 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.