diff --git a/CHANGELOG.md b/CHANGELOG.md index 8f9f8d2..f023ad5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,14 @@ All notable changes to LowQuery are documented here. The format follows [Keep a ## [Unreleased] +## [0.5.6] - 2026-11-13 + +### Fixed +- **New versions show up within a minute.** The app checks every minute instead of every 10, and again when the window comes back from the tray. A check that hung (after sleep or a network change) no longer blocks the later ones, a failed background download is not repeated every minute, and checks no longer keep their discarded results in memory. + +### Security +- SQLite 3.54.1, bundled through `rusqlite` 0.41.1: opening a database together with a crafted `-wal` file no longer returns uninitialized page-cache memory (RUSTSEC-2026-0459). + ## [0.5.5] - 2026-11-11 ### Fixed @@ -179,7 +187,8 @@ First public release, with PostgreSQL and Oracle. - Schema browser for tables, views, sequences, routines, packages and columns. - Drafts restored on restart, light and dark themes, and a layout for narrow windows. -[Unreleased]: https://github.com/LowBloat/LowQuery/compare/v0.5.5...HEAD +[Unreleased]: https://github.com/LowBloat/LowQuery/compare/v0.5.6...HEAD +[0.5.6]: https://github.com/LowBloat/LowQuery/compare/v0.5.5...v0.5.6 [0.5.5]: https://github.com/LowBloat/LowQuery/compare/v0.5.4...v0.5.5 [0.5.4]: https://github.com/LowBloat/LowQuery/compare/v0.5.3...v0.5.4 [0.5.3]: https://github.com/LowBloat/LowQuery/compare/v0.5.2...v0.5.3 diff --git a/README.md b/README.md index c884d40..1f5dc03 100644 --- a/README.md +++ b/README.md @@ -84,7 +84,7 @@ The [latest release](https://github.com/LowBloat/LowQuery/releases/latest) inclu gh attestation verify LowQuery--linux-x64.AppImage --repo LowBloat/LowQuery ``` -**Updates.** Installed copies on Windows, macOS, AppImage, `.deb` and `.rpm` update themselves: LowQuery checks for a new release every few minutes and when the window regains focus, downloads it in the background and offers **Restart to update** once it is ready. Updates are signed and verified before installation. `.deb` and `.rpm` installs ask for the administrator password, since dpkg or rpm installs the new package. The Arch package and portable copies are told when a new version is out and link to the download. +**Updates.** Installed copies on Windows, macOS, AppImage, `.deb` and `.rpm` update themselves: LowQuery checks for a new release every minute and when the window comes back, downloads it in the background and offers **Restart to update** once it is ready. Updates are signed and verified before installation. `.deb` and `.rpm` installs ask for the administrator password, since dpkg or rpm installs the new package. The Arch package and portable copies are told when a new version is out and link to the download. **First launch on Windows and macOS.** The installers are not code-signed yet, so the system warns on first launch: diff --git a/package.json b/package.json index eccf5a2..e18cbc1 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "lowquery", - "version": "0.5.5", + "version": "0.5.6", "description": "LowQuery: a lightweight multi-database SQL client (Oracle and PostgreSQL).", "homepage": "https://github.com/LowBloat/LowQuery", "repository": { diff --git a/src-tauri/Cargo.lock b/src-tauri/Cargo.lock index 7036dad..a741557 100644 --- a/src-tauri/Cargo.lock +++ b/src-tauri/Cargo.lock @@ -1154,7 +1154,7 @@ dependencies = [ "libc", "option-ext", "redox_users", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -1345,7 +1345,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -2625,9 +2625,9 @@ dependencies = [ [[package]] name = "libsqlite3-sys" -version = "0.38.2" +version = "0.39.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1d20bef17f513b9b3004532233187769cd072d790971f4e4da0e346eb6401e8" +checksum = "14a5f01b87b92705d07b433c06f96cbc764637d81a0bffb5734ce17cf0f9a2b3" dependencies = [ "cc", "pkg-config", @@ -2663,7 +2663,7 @@ checksum = "f9f8bd3e56ce4dfc153cf470fffbfa98c7620958b312ca5c3a4b8d5181fd13c6" [[package]] name = "lowquery" -version = "0.5.5" +version = "0.5.6" dependencies = [ "aes", "cbc", @@ -2843,7 +2843,7 @@ dependencies = [ "png 0.18.1", "serde", "thiserror 2.0.21", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -4043,9 +4043,9 @@ dependencies = [ [[package]] name = "rusqlite" -version = "0.40.2" +version = "0.41.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f2a97da3e3873c73cb2a2e71b35c40ff95e0b1eefa8d72d8499a6928c3b5b3" +checksum = "da9bba6f3506135e120a6586df05be18b48d18896600646a4bec8f993d91a594" dependencies = [ "bitflags 2.13.2", "fallible-iterator 0.3.0", @@ -4081,7 +4081,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -4139,7 +4139,7 @@ dependencies = [ "security-framework 3.7.0", "security-framework-sys", "webpki-root-certs", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -4689,7 +4689,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c3d1e2c7f27f8d4cb10542a02c49005dbd6e93095799d6f3be745fae9f8fedd4" dependencies = [ "libc", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -5345,7 +5345,7 @@ dependencies = [ "getrandom 0.4.3", "once_cell", "rustix", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -5803,7 +5803,7 @@ dependencies = [ "png 0.18.1", "serde", "thiserror 2.0.21", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -5844,7 +5844,7 @@ checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e" dependencies = [ "memoffset", "tempfile", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -6267,7 +6267,7 @@ version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" dependencies = [ - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] @@ -6302,7 +6302,7 @@ dependencies = [ "objc2-foundation", "objc2-quartz-core", "raw-window-handle", - "windows-sys 0.60.2", + "windows-sys 0.61.2", "windows-version", ] @@ -6683,7 +6683,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7d6f32a0ff4a9f6f01231eb2059cc85479330739333e0e58cadf03b6af2cca10" dependencies = [ "cfg-if", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] diff --git a/src-tauri/Cargo.toml b/src-tauri/Cargo.toml index 6136938..4b00dff 100644 --- a/src-tauri/Cargo.toml +++ b/src-tauri/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "lowquery" -version = "0.5.5" +version = "0.5.6" description = "Lightweight SQL client for multiple databases" authors = ["LowBloat"] license = "AGPL-3.0-only" @@ -50,7 +50,7 @@ redis = { version = "1.7", default-features = false, features = ["aio", "tokio-c # Apache Cassandra: native CQL protocol (v4/v5), TLS through rustls. scylla = { version = "1.9", default-features = false, features = ["rustls-023"] } # SQLite: embedded engine compiled into the app. -rusqlite = { version = "0.40", features = ["bundled", "column_decltype", "column_metadata"] } +rusqlite = { version = "0.41", features = ["bundled", "column_decltype", "column_metadata"] } keyring = { version = "=3.6.3", features = ["apple-native", "windows-native", "sync-secret-service"] } # DBeaver import: credentials-config.json is AES-128-CBC. aes = "0.9" diff --git a/src-tauri/src/drivers/sqlite.rs b/src-tauri/src/drivers/sqlite.rs index 2899062..bf4a9a1 100644 --- a/src-tauri/src/drivers/sqlite.rs +++ b/src-tauri/src/drivers/sqlite.rs @@ -259,7 +259,6 @@ impl LiteSession { } let info = stmt .columns() - .iter() .map(|c| { let decl = c .decl_type() @@ -422,7 +421,6 @@ fn statement( let declared: Vec<(String, Option)> = stmt .columns() - .iter() .map(|c| { ( c.name().to_string(), @@ -654,7 +652,6 @@ fn column_origins(stmt: &Statement<'_>) -> Option {}); +} /** Why an installation cannot update itself, shown next to the download link. */ const MANUAL_HINT: Record = { @@ -26,7 +40,7 @@ const MANUAL_HINT: Record = { /** * Automatic updates from GitHub Releases. The app checks shortly after it - * opens, every few minutes and whenever the window regains focus. A copy that + * opens, every minute and whenever the window comes back. A copy that * can update itself (Windows installer, macOS app, writable AppImage, .deb or * .rpm) downloads the signed update in the background; once it is verified and * ready, the sidebar offers "restart to update", which installs it right away. @@ -73,14 +87,23 @@ class Updates { getVersion().then((v) => (this.currentVersion = v)).catch(() => {}); setTimeout(() => this.check(false), FIRST_CHECK_MS); this.timer = setInterval(() => this.check(false), CHECK_EVERY_MS); - window.addEventListener("focus", () => { + const checkSoon = () => { if (Date.now() - this.lastCheck > FOCUS_GAP_MS) void this.check(false); + }; + window.addEventListener("focus", checkSoon); + // The window can come back from the tray or another desktop without focus. + document.addEventListener("visibilitychange", () => { + if (document.visibilityState === "visible") checkSoon(); }); } /** `interactive`: the user asked, so report "up to date" and errors. */ async check(interactive: boolean): Promise { - if (this.checking || this.downloading || this.installing) return; + if (this.checking || this.downloading || this.installing) { + // Still downloading what was found: show it rather than nothing. + if (interactive && this.available) this.dialogOpen = true; + return; + } this.checking = true; this.lastCheck = Date.now(); if (interactive) this.error = null; @@ -89,18 +112,23 @@ class Updates { // Copies that cannot install still read the AppImage entry to learn // the version and notes. const target = this.policy.target ?? (this.policy.canInstall ? undefined : "linux-x86_64-appimage"); - const update = await check(target ? { target } : undefined); + const update = await check({ timeout: CHECK_TIMEOUT_MS, ...(target ? { target } : {}) }); if (!update) { + discard(this.update); this.update = null; this.available = null; this.ready = false; return; } - // Already downloaded this one: nothing to do until the restart. - if (this.ready && this.available?.version === update.version) { + // Already found this one: nothing to do until the restart. A background + // download that failed is not repeated every minute; installing from + // the dialog downloads it again. + if (this.update && this.available?.version === update.version) { + discard(update); if (interactive) this.dialogOpen = true; return; } + discard(this.update); this.update = update; this.ready = false; this.available = { version: update.version, notes: update.body ?? "" }; @@ -120,13 +148,16 @@ class Updates { let total = 0; let received = 0; try { - await update.download((event) => { - if (event.event === "Started") total = event.data.contentLength ?? 0; - else if (event.event === "Progress") { - received += event.data.chunkLength; - this.progress = total > 0 ? Math.min(1, received / total) : null; - } - }); + await update.download( + (event) => { + if (event.event === "Started") total = event.data.contentLength ?? 0; + else if (event.event === "Progress") { + received += event.data.chunkLength; + this.progress = total > 0 ? Math.min(1, received / total) : null; + } + }, + { timeout: DOWNLOAD_TIMEOUT_MS }, + ); if (this.update === update) this.ready = true; } catch { // The dialog falls back to download-and-install in one go.