Repository navigation
Is there a way to support encryption via SQLite3MultipleCiphers when using OPFSCoopSyncVFS? #308
|
OPFSCoopSyncVFS works great for my usecase of offline-first the only nice to have will be encryption since db files sit in OPFS unencrypted so I thought of doing a custom build using sqwab and SQLite3MultipleCiphers with these make arguments:
It does build and I can use in my app but as soon as I use the encryption related features like the |
Replies: 2 comments 3 replies
|
I have never tried to use SQLite3MultipleCiphers in any context, but it looks like this particular error message occurs when the SQLite3MultipleCiphers VFS can't be found in SQLite's VFS stack. My guess is that you are not instantiating your wa-sqlite VFS in such a way that it also includes SQLite3MultipleCiphers. Perhaps SQLite3MultipleCiphers is looking for something in the primary wa-sqlite VFS that it isn't finding, but I think it probably would produce an error earlier if that were the case. So my guess is that this is a VFS initialization error in your code. Now whether OPFSCoopSyncVFS (or any wa-sqlite sample VFS) will work with SQLite3MultipleCiphers is an open question AFAIK. I don't think that OPFSCoopSyncVFS peeks into the database header or page data (as other sample VFS do) so that won't be a problem, but it does purposely return some errors to handle asynchronous operations which may or may not cause problems for SQLite3MultipleCiphers. |
|
I see this is resolved, but thought it was worth sharing the fork of I added some demos and has the finished build if anybody wants to use those directly or reference. |
I have never tried to use SQLite3MultipleCiphers in any context, but it looks like this particular error message occurs when the SQLite3MultipleCiphers VFS can't be found in SQLite's VFS stack. My guess is that you are not instantiating your wa-sqlite VFS in such a way that it also includes SQLite3MultipleCiphers. Perhaps SQLite3MultipleCiphers is looking for something in the primary wa-sqlite VFS that it isn't finding, but I think it probably would produce an error earlier if that were the case. So my guess is that this is a VFS initialization error in your code.
Now whether OPFSCoopSyncVFS (or any wa-sqlite sample VFS) will work with SQLite3MultipleCiphers is an open question AFAIK. I d…