Closed
Description
I was updating my project's sqleet to 3.30.0 and noticed that the sqlite3_rekey function was no longer able to rekey my database. I was getting SQLITE_MISUSE back when attempting to rekey the database.
Dug around a bit and haven't been able to find the cause of the issue, but I have also found that the example in your readme no longer works:
buchmanj@Accio ~/D/sqleet-v0.30.0> hexdump -C test.sqlite
00000000 53 51 4c 69 74 65 20 66 6f 72 6d 61 74 20 33 00 |SQLite format 3.|
00000010 10 00 01 01 00 40 20 20 00 00 00 01 00 00 00 02 |.....@ ........|
00000020 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 04 |................|
00000030 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 |................|
00000040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 |................|
00000060 00 2e 3b f0 0d 00 00 00 01 0f d4 00 0f d4 00 00 |..;.............|
00000070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00000fd0 00 00 00 00 2a 01 06 17 15 15 01 39 74 61 62 6c |....*......9tabl|
00000fe0 65 74 65 73 74 74 65 73 74 02 43 52 45 41 54 45 |etesttest.CREATE|
00000ff0 20 54 41 42 4c 45 20 74 65 73 74 20 28 69 64 29 | TABLE test (id)|
00001000 0d 00 00 00 00 10 00 00 00 00 00 00 00 00 00 00 |................|
00001010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00002000
buchmanj@Accio ~/D/sqleet-v0.30.0> ./sqleet test.sqlite
SQLite version 3.30.0 2019-10-04 15:03:17
Enter ".help" for usage hints.
sqlite> PRAGMA rekey='swordfish';
sqlite> .quit
buchmanj@Accio ~/D/sqleet-v0.30.0> hexdump -C test.sqlite
00000000 53 51 4c 69 74 65 20 66 6f 72 6d 61 74 20 33 00 |SQLite format 3.|
00000010 10 00 01 01 00 40 20 20 00 00 00 01 00 00 00 02 |.....@ ........|
00000020 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 04 |................|
00000030 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 |................|
00000040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 |................|
00000060 00 2e 3b f0 0d 00 00 00 01 0f d4 00 0f d4 00 00 |..;.............|
00000070 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00000fd0 00 00 00 00 2a 01 06 17 15 15 01 39 74 61 62 6c |....*......9tabl|
00000fe0 65 74 65 73 74 74 65 73 74 02 43 52 45 41 54 45 |etesttest.CREATE|
00000ff0 20 54 41 42 4c 45 20 74 65 73 74 20 28 69 64 29 | TABLE test (id)|
00001000 0d 00 00 00 00 10 00 00 00 00 00 00 00 00 00 00 |................|
00001010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00002000
buchmanj@Accio ~/D/sqleet-v0.30.0>
Am I doing something wrong?
Metadata
Metadata
Assignees
Labels
No labels