This package help you bundle SQLCipher(SQLite3) library to your apps.
He was originally developed to use with SQLite3 with SQLCipher.
To work, SQLCipher needs work with OpenSSL 64 bits libraries (libcrypto-1_1-x64.dll and libssl-1_1-x64.dll).
These libraries are automatically pasted near the main Flutter_program.exe. to be dynamically linked with sqlcipher.dll
You can also paste these two DLLs into a Windows PATH directory of your choice.
Add an override for windows and give it the openSQLCipherOnWindows
function provided by the package:
import 'package:sqlite3/open.dart';
import 'package:sqlcipher_library_windows/sqlcipher_library_windows.dart';
open.overrideFor(OperatingSystem.windows, openSQLCipherOnWindows);
If you encounted some errors at runtime:
- ensure you are on a 64 bit Windows version.
- Use Process Monitor to find details about your error (like a dll not found for example).
Today, this is a package, it could be better to move it to a plugin to avoid embedding DLLs ont other OS projects.
Unfortunately, I'm not familiar with Flutter Windows Plugin and ignore how to create a plugin with my 3 embedded DLLs.
You're welcome to make a pull request.