fix(sql): update sqlx to 0.9 to fix cargo audit (#3815)

* fix(sql): update sqlx to 0.9 to fix cargo audit

cargo audit fails on RUSTSEC-2026-0459: the SQLite bundled by
libsqlite3-sys 0.30 is affected by CVE-2026-119375. Only sqlx 0.9.1
accepts the fixed libsqlite3-sys (>=0.39), and it requires Rust 1.94.

- update sqlx to 0.9.1 and libsqlite3-sys to 0.40. The removed
  runtime-tokio-rustls feature is replaced by runtime-tokio +
  tls-rustls-ring-webpki, which is what it enabled before, and mysql
  now enables mysql-rsa to keep RSA password auth
- wrap frontend-provided queries in AssertSqlSafe (values are still
  bound parameters) and convert migrations with into_sql_str
- bump the workspace MSRV and CI toolchains to 1.94
- ignore RUSTSEC-2026-0387 (crypto-bigint timing), which stronghold
  pulls in through iota-crypto -> k256 0.13 with no fixed release

Tested clippy, tests and doc tests of the sql plugin on Linux with
the sqlite, mysql and postgres features, on 1.94 and stable. Not
tested against real MySQL/Postgres servers or on mobile.

* update change file [skip ci]

* Update .changes/sql-sqlx-0.9.md [skip ci]

Co-authored-by: Fabian-Lars <30730186+FabianLars@users.noreply.github.com>

* update change file [skip ci]

---------

Co-authored-by: Fabian-Lars <30730186+FabianLars@users.noreply.github.com>
This commit is contained in:
Lucas Fernandes NogueiraandFabian-Lars authored and GitHub committed 2026-11-28 06:47:11 -03:00
1 parent 4140767e22
commit a83704743c
40 files changed
+461 -319

No files matched your search

+3
View File
@@ -2,4 +2,7 @@
ignore = [
# rsa Marvin Attack
"RUSTSEC-2023-0071",
# crypto-bigint timing variability, pulled in by stronghold through iota-crypto -> k256 0.13,
# which has no release on a fixed crypto-bigint
"RUSTSEC-2026-0387",
]
+61
View File
@@ -0,0 +1,61 @@
---
"autostart": minor
"autostart-js": minor
"barcode-scanner": minor
"barcode-scanner-js": minor
"biometric": minor
"biometric-js": minor
"cli": minor
"cli-js": minor
"clipboard-manager": minor
"clipboard-manager-js": minor
"deep-link": minor
"deep-link-js": minor
"fs": minor
"fs-js": minor
"dialog": minor
"dialog-js": minor
"geolocation": minor
"geolocation-js": minor
"global-shortcut": minor
"global-shortcut-js": minor
"opener": minor
"opener-js": minor
"haptics": minor
"haptics-js": minor
"http": minor
"http-js": minor
"localhost": minor
"log": minor
"log-js": minor
"nfc": minor
"nfc-js": minor
"notification": minor
"notification-js": minor
"os": minor
"os-js": minor
"persisted-scope": minor
"positioner": minor
"positioner-js": minor
"process": minor
"process-js": minor
"shell": minor
"shell-js": minor
"single-instance": minor
"sql": minor
"sql-js": minor
"store": minor
"store-js": minor
"stronghold": minor
"stronghold-js": minor
"updater": minor
"updater-js": minor
"upload": minor
"upload-js": minor
"websocket": minor
"websocket-js": minor
"window-state": minor
"window-state-js": minor
---
Update MSRV to 1.94.
+6
View File
@@ -0,0 +1,6 @@
---
sql: minor
sql-js: minor
---
**Breaking Change:** Updated `sqlx` to 0.9, which brings in a SQLite release fixing CVE-2026-119375 (RUSTSEC-2026-0459).
+1 -1
View File
@@ -34,7 +34,7 @@ jobs:
steps:
- uses: actions/checkout@v7
- uses: dtolnay/rust-toolchain@1.90
- uses: dtolnay/rust-toolchain@1.94
- uses: ./.github/actions/setup-pnpm
+1 -1
View File
@@ -115,7 +115,7 @@ jobs:
# the deep-link tests drive the real XDG tools
sudo apt-get install -y xdg-utils desktop-file-utils
- uses: dtolnay/rust-toolchain@1.90
- uses: dtolnay/rust-toolchain@1.94
with:
targets: ${{ matrix.platform.target }}
Generated
+338 -276
View File
File diff suppressed because it is too large. Load diff
+1 -1
View File
@@ -29,7 +29,7 @@ zbus = "5.9"
edition = "2024"
authors = ["Tauri Programme within The Commons Conservancy"]
license = "Apache-2.0 OR MIT"
rust-version = "1.90"
rust-version = "1.94"
repository = "https://github.com/tauri-apps/plugins-workspace"
# default to small, optimized release binaries
+1 -1
View File
@@ -1,6 +1,6 @@
# Official Tauri Plugins
This repo and all plugins require a Rust version of at least **1.90**
This repo and all plugins require a Rust version of at least **1.94**
## Plugins Found Here
+1 -1
View File
@@ -12,7 +12,7 @@ Automatically launch your application at startup.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Parse arguments from your Command Line Interface.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Read and write to the system clipboard.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Set your Tauri application as the default handler for an URL.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
@@ -6,7 +6,7 @@ authors = ["you"]
license = ""
repository = ""
edition = "2024"
rust-version = "1.90"
rust-version = "1.94"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
+1 -1
View File
@@ -12,7 +12,7 @@ Native system dialogs for opening and saving files along with message dialogs.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Access the file system.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ This plugin provides APIs for getting and tracking the device's current position
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Register global shortcuts.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -14,7 +14,7 @@ There are no standards/requirements for vibration support on Android, so the `fe
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Access the HTTP client written in Rust.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -14,7 +14,7 @@ Expose your apps assets through a localhost server instead of the default custom
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Configurable logging for your Tauri app.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Send message notifications (brief auto-expiring OS window element) to your user.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Read information about the operating system.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Save filesystem and asset scopes and restore them when the app is reopened.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -14,7 +14,7 @@ This plugin is a port of [electron-positioner](https://github.com/jenslind/elect
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ This plugin provides APIs to access the current process. To spawn child processe
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Access the system shell. Allows you to spawn child processes and manage files an
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Ensure a single instance of your tauri app is running.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
@@ -5,7 +5,7 @@ description = "A Tauri App"
authors = ["You"]
repository = ""
edition = "2024"
rust-version = "1.90"
rust-version = "1.94"
[dependencies]
serde = { workspace = true }
+12 -3
View File
@@ -36,7 +36,12 @@ tauri = { workspace = true }
log = { workspace = true }
thiserror = { workspace = true }
futures-core = "0.3"
sqlx = { version = "0.8", features = ["json", "time", "uuid", "rust_decimal"] }
sqlx = { version = "0.9.1", features = [
"json",
"time",
"uuid",
"rust_decimal",
] }
rust_decimal = "1"
time = "0.3"
tokio = { version = "1", features = ["sync"] }
@@ -45,6 +50,10 @@ uuid = "1"
[features]
sqlite = ["sqlx/sqlite", "sqlx/runtime-tokio"]
mysql = ["sqlx/mysql", "sqlx/runtime-tokio-rustls"]
postgres = ["sqlx/postgres", "sqlx/runtime-tokio-rustls"]
mysql = ["sqlx/mysql-rsa", "sqlx/runtime-tokio", "sqlx/tls-rustls-ring-webpki"]
postgres = [
"sqlx/postgres",
"sqlx/runtime-tokio",
"sqlx/tls-rustls-ring-webpki",
]
# TODO: bundled-cipher etc
+1 -1
View File
@@ -12,7 +12,7 @@ Interface with SQL databases through [sqlx](https://github.com/launchbadge/sqlx)
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+2 -1
View File
@@ -29,6 +29,7 @@ pub use wrapper::DbPool;
use futures_core::future::BoxFuture;
use serde::{Deserialize, Serialize};
use sqlx::{
SqlSafeStr,
error::BoxDynError,
migrate::{Migration as SqlxMigration, MigrationSource, MigrationType, Migrator},
};
@@ -125,7 +126,7 @@ impl MigrationSource<'static> for MigrationList {
migration.version,
migration.description.into(),
migration.kind.into(),
migration.sql.into(),
migration.sql.into_sql_str(),
false,
));
}
+6 -6
View File
@@ -160,7 +160,7 @@ impl DbPool {
Ok(match self {
#[cfg(feature = "sqlite")]
DbPool::Sqlite(pool) => {
let mut query = sqlx::query(&_query);
let mut query = sqlx::query(sqlx::AssertSqlSafe(_query));
for value in _values {
if value.is_null() {
query = query.bind(None::<JsonValue>);
@@ -180,7 +180,7 @@ impl DbPool {
}
#[cfg(feature = "mysql")]
DbPool::MySql(pool) => {
let mut query = sqlx::query(&_query);
let mut query = sqlx::query(sqlx::AssertSqlSafe(_query));
for value in _values {
if value.is_null() {
query = query.bind(None::<JsonValue>);
@@ -200,7 +200,7 @@ impl DbPool {
}
#[cfg(feature = "postgres")]
DbPool::Postgres(pool) => {
let mut query = sqlx::query(&_query);
let mut query = sqlx::query(sqlx::AssertSqlSafe(_query));
for value in _values {
if value.is_null() {
query = query.bind(None::<JsonValue>);
@@ -228,7 +228,7 @@ impl DbPool {
Ok(match self {
#[cfg(feature = "sqlite")]
DbPool::Sqlite(pool) => {
let mut query = sqlx::query(&_query);
let mut query = sqlx::query(sqlx::AssertSqlSafe(_query));
for value in _values {
if value.is_null() {
query = query.bind(None::<JsonValue>);
@@ -258,7 +258,7 @@ impl DbPool {
}
#[cfg(feature = "mysql")]
DbPool::MySql(pool) => {
let mut query = sqlx::query(&_query);
let mut query = sqlx::query(sqlx::AssertSqlSafe(_query));
for value in _values {
if value.is_null() {
query = query.bind(None::<JsonValue>);
@@ -288,7 +288,7 @@ impl DbPool {
}
#[cfg(feature = "postgres")]
DbPool::Postgres(pool) => {
let mut query = sqlx::query(&_query);
let mut query = sqlx::query(sqlx::AssertSqlSafe(_query));
for value in _values {
if value.is_null() {
query = query.bind(None::<JsonValue>);
+1 -1
View File
@@ -12,7 +12,7 @@ Simple, persistent key-value store.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Store secrets and keys using the [IOTA Stronghold](https://github.com/iotaledger
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ In-app updates for Tauri applications.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -13,7 +13,7 @@ Download files from a remote HTTP server to disk.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Open a WebSocket connection using a Rust client in JS.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.
+1 -1
View File
@@ -12,7 +12,7 @@ Save window positions and sizes and restore them when the app is reopened.
## Install
_This plugin requires a Rust version of at least **1.90**_
_This plugin requires a Rust version of at least **1.94**_
There are three general methods of installation that we can recommend.