mirror of
https://github.com/tauri-apps/plugins-workspace.git
synced 2026-09-22 21:30:44 +02:00
refactor(http)!: always enforce the scope on redirects (#3600)
* refactor(http)!: always enforce the scope on redirects Removes the `scopeRedirects` option (and the `Config` struct with it) that was added as an opt-in in 2.7.0. Every hop of a redirect chain is now checked against the URL scope, so a server on an allowed origin can no longer redirect the request to a URL the scope denies. `tauri_plugin_http::init()` returns `TauriPlugin<R>` again. * chore(http): compile without warnings when the cookies feature is disabled
This commit is contained in:
@@ -77,9 +77,8 @@ export interface ClientOptions {
|
||||
* Defines the maximum number of redirects the client should follow.
|
||||
* If set to 0, no redirects will be followed.
|
||||
*
|
||||
* When the `scopeRedirects` plugin configuration is enabled, every redirect must
|
||||
* also be allowed by the configured scope, otherwise the request fails
|
||||
* instead of being followed.
|
||||
* Every redirect must also be allowed by the configured scope,
|
||||
* otherwise the request fails instead of being followed.
|
||||
*/
|
||||
maxRedirections?: number
|
||||
/** Timeout in milliseconds */
|
||||
|
||||
Reference in New Issue
Block a user