Upgrade opa-wasm to 0.2.0 to upgrade wasmtime

This fixes a bunch of RUSTSEC advisories, see https://github.com/element-hq/matrix-authentication-service/issues/5621
This commit is contained in:
Letro Bot
2026-04-13 18:10:19 +02:00
parent cda3259cd9
commit 9a5b5b811b
3 changed files with 188 additions and 147 deletions

View File

@@ -30,7 +30,7 @@ pub enum LoadError {
Read(#[from] tokio::io::Error),
#[error("failed to create WASM engine")]
Engine(#[source] anyhow::Error),
Engine(#[source] opa_wasm::wasmtime::Error),
#[error("module compilation task crashed")]
CompilationTask(#[from] tokio::task::JoinError),
@@ -229,7 +229,6 @@ impl PolicyFactory {
entrypoints: Entrypoints,
) -> Result<Self, LoadError> {
let mut config = Config::default();
config.async_support(true);
config.cranelift_opt_level(OptLevel::SpeedAndSize);
let engine = Engine::new(&config).map_err(LoadError::Engine)?;