clach04 / puren_tonbo

Plain text notes Tombo (chi) alternative, also supports, ccrypt, GnuPG (OpenPGP, gpg), OpenSSL AES-256-CBC, AES-256 ZIP AE-1/AE-2 and VimCrypt encrypted files. Integrates with VIM. WIP
https://pypi.org/project/puren-tonbo/
GNU Lesser General Public License v2.1
1 stars 0 forks source link

idea - kaitai_struct for file format code #150

Open clach04 opened 1 month ago

clach04 commented 1 month ago

https://github.com/kaitai-io/kaitai_struct

Markor .jenc files maybe a good first try, static version byte size but variable other fields. Enum for version and "Typical TLV implementation (switching types on an expression)" in https://doc.kaitai.io/user_guide.html#valid-values should handle header with eof option for data.

.jenc encryption compatible with https://github.com/gsantner/markor https://gitlab.com/opensource21/jpencconverter V001("PBKDF2WithHmacSHA512", 10000, 256, "AES", 64, "AES/GCM/NoPadding", 32), mirror https://github.com/opensource21/jpencconverter format https://gitlab.com/opensource21/jpencconverter/-/blob/master/src/main/java/de/stanetz/jpencconverter/cryption/JavaPasswordbasedCryption.java

clach04 commented 1 month ago

For now doing raw file-IO in experimental script https://github.com/clach04/jenc-py/blob/wip/jenc_reader.py