Bug Description:
When a bndb is extracted from a container (e.g. a .zip) it is deserialized into SQLite in-memory with SQLITE_DESERIALIZE_READONLY. If the bndb is from an older Binary Ninja version that
requires a schema upgrade, UpdateSchema then tries to write to that read-only handle and the load aborts with attempt to write a readonly database. Direct on-disk loads of the same bndb upgrade and open fine. The failure is specific to the container-extracted path.
Steps To Reproduce:
- Take an older bndb (e.g. one produced by Binary Ninja v1.0.730).
- Place it inside a zip archive.
- Open the zip in Binary Ninja so the container extraction path runs.
** Expected Behavior **
The bndb is upgraded in memory and opens normally, just like the on-disk case. Persistence to the original container is not required.
Bug Description:
When a bndb is extracted from a container (e.g. a .zip) it is deserialized into SQLite in-memory with SQLITE_DESERIALIZE_READONLY. If the bndb is from an older Binary Ninja version that
requires a schema upgrade, UpdateSchema then tries to write to that read-only handle and the load aborts with attempt to write a readonly database. Direct on-disk loads of the same bndb upgrade and open fine. The failure is specific to the container-extracted path.
Steps To Reproduce:
** Expected Behavior **
The bndb is upgraded in memory and opens normally, just like the on-disk case. Persistence to the original container is not required.