Comments (4)
Are you using astilectron
in go-astilectron
?
from astilectron.
Yes, in go-astilectron
. The function in js that is triggering the navigation event is a callback function from google recaptcha. It's not possible for me to overwrite the captacha rendering.
An example js snippet would be:
function execute() {
window.location ="appidentifier://token"
}
setTimeout(execute, 1000);
And this should go to window.location='http://" + config.ServerHost + ":" + config.ServerPort + "/?token=" + e.URLNew
but maybe i should open this issue in go-astilectron
.
from astilectron.
This is a tricky one, since right now there's no way in js astilectron
to send a message and wait for its response before continuing js execution. Which is what would be needed:
- in
will-navigate
, callgo-astilectron
to see whether we need to redirect this request - based on
go-astilectron
, callevent.preventDefault()
and updatewindow.location
manually if we need a redirection
I don't have a proper answer for you right now, I'd have to think about it.
from astilectron.
I found another way, because i needed to circumvent the situation. I replace the original js with my own js that I have sideloaded. Then i reinitialize the captcha and finally i have the captcha on the correct domain and i can get the token and everyone is happy. Not a good solution in my eyes because it shows how sensible electron is, because i can do whatever i want and break sandboxing and browser security.
from astilectron.
Related Issues (20)
- New release version v0.28.0 doesn't contain the latest commit a60d2863d94aea91dde9bb4833b5d9eb86c7cf7c HOT 2
- Versioning of the application HOT 4
- Electron version 4.0.1 does not have method named "app.makeSingleInstance" HOT 2
- Invalid Electron cache path HOT 1
- File Dialogs and Notifications HOT 2
- Printing HOT 1
- Forwarding Electron BrowserWindow to js code HOT 3
- State changes are not working properly with Astilectron + Angular HOT 1
- [Bug] lastWindow is always null in main.js
- Support wss:// as binding address HOT 3
- Use second-instance, if lastWindow destroy, crash: Object has been destroyed HOT 4
- Ask - Hot Reload
- `package.json`'s `version` field isn't up to date HOT 3
- using astilectron with vue, error by not define
- app.setAsDefaultProtocolClient(protocol[, path, args]) HOT 3
- Guidance on extending Go <-> Electron Interop HOT 2
- Exposing Dialog HOT 7
- Type generation of structs HOT 2
- astilectron-bundler -v stuck
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 astilectron.