Comments (3)
The browser is sending an OPTIONS (preflight) request because whatever code that's making the request isn't satisfying the requirements to avoid a preflight request. See here:
https://stackoverflow.com/questions/42168773/how-to-resolve-preflight-is-invalid-redirect-in-cors
Basically,
- The http method must be GET, HEAD, or POST
- The only headers you can set are Accept, Accept-Language, Content-Language, Content-Type, DPR, Downlink, Save-Data, Viewport-Width, or Width
- The Content-Type request header must be application/x-www-form-urlencoded, multipart/form-data, or text/plain
Resource Override can change request headers, although in this case, chrome seems to filter out the request automatically (probably so extensions can't change them because it's a security issue). If you need to use certain headers or an uncommon http method then I'm not sure there's much you can do. I suppose you could redirect the script that's causing the request to your own script so you can just make the request to the correct url from the beginning.
Let me know if you find a way around this, as odds don't look too good for a solution.
from resourceoverride.
It's a minified script on a third-party app that I don't control. Additionally, asset names are obfuscated and change often.
from resourceoverride.
That sounds rough... You might need something higher calibur like a system wide proxy. Maybe https://www.charlesproxy.com/documentation/tools/rewrite/
I'm not sure it's possible to do what you need through a chrome extension. Let me know if you figure out a way though.
from resourceoverride.
Related Issues (20)
- Resource Override doesn't work on Chrome 84 (workaround: Source > Filesystem) HOT 4
- Override File with dynamic names HOT 4
- Feature request: add script/stylesheet from URL
- Not working on Edges v89.0.774.77, but adding extension like Adblock Plus, it will work, I don't know why.
- ResourceOverride not working on firefox HOT 2
- How do I embed an MP3 file in raw text?
- Improvements that can be added - RegexReplacer + cloud sync (Forked and fully working version is available with all code)
- Refused to load the script because it violates the following Content Security Policy directive HOT 3
- Ability to add URL -> File rule from local file directory HOT 1
- Header rules can not be handled in the second or later tab groups HOT 1
- Using Resource Override to override a JavaScript file that is loaded as a SharedWorker doesn't work
- Dark theme (again)
- Configuration disappear HOT 1
- Excuse me HOT 3
- Add new rule: Add JS/CSS file From URL HOT 1
- Bug: URL -> File does not work HOT 2
- Can this work with Vite projects?
- Header Host override
- manifest_version 3
- Options button doesn't work HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from resourceoverride.