Skip to content

Commit 98101cb

Browse files
authored
fix(core): allow any headers on custom protocol IPC (#9561)
1 parent 68c39b8 commit 98101cb

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

.changes/ipc-allow-headers.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tauri": patch:bug
3+
---
4+
5+
Allow any headers on the IPC custom protocol.

core/tauri/src/ipc/protocol.rs

+2-4
Original file line numberDiff line numberDiff line change
@@ -137,10 +137,8 @@ pub fn get<R: Runtime>(manager: Arc<AppManager<R>>, label: String) -> UriSchemeP
137137

138138
Method::OPTIONS => {
139139
let mut r = http::Response::new(Vec::new().into());
140-
r.headers_mut().insert(
141-
ACCESS_CONTROL_ALLOW_HEADERS,
142-
HeaderValue::from_static("Content-Type, Tauri-Callback, Tauri-Error, Tauri-Channel-Id"),
143-
);
140+
r.headers_mut()
141+
.insert(ACCESS_CONTROL_ALLOW_HEADERS, HeaderValue::from_static("*"));
144142
respond(r);
145143
}
146144

0 commit comments

Comments
 (0)