Welcome Guest Search | Active Topics | Sign In | Register

Disable Web Security per URL Options
Roei Ben-Harush
Posted: Tuesday, October 16, 2018 9:31:03 AM
Rank: Member
Groups: Member

Joined: 11/13/2015
Posts: 29
Hello,
Is there a way to disable WebSecurity (http --> https and same-origin policy) per URL?
I found the following property:
Code: C#
BrowserOptions.EnableWebSecurity = false

but it looks like a complete on/off setting.
Ideally, there would be an event that my project can subscribe to so we can decide in runtime to allow or block.
eo_support
Posted: Tuesday, October 16, 2018 11:07:47 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,071
Hi,

No. This is not possible. This is a setting per WebView, not per Url.

Thanks!
Roei Ben-Harush
Posted: Tuesday, October 16, 2018 12:15:44 PM
Rank: Member
Groups: Member

Joined: 11/13/2015
Posts: 29
Thanks for the super fast response.
Is this something you can add?

Also, I just turned the setting above to false.
Looks like it still does not allow me to do mixed content calls. Is there a workaround for that?
eo_support
Posted: Tuesday, October 16, 2018 1:47:45 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,071
Hi,

These are settings in the browser engine that we simply exposes it. It is not practical for us to add settings to the browser engine ourselves.

EnableWebSecurity is for same origin policy but it is not for http -> https. We do not have a direct setting for http -> https. You can try to use "--allow-running-insecure-content" command line argument and see if it works for you. You would pass extra command line argument to the browser engine through this property:

https://www.essentialobjects.com/doc/eo.webengine.engineoptions.extracommandlineargs.aspx

If you are not familiar with EngineOptions, you can take a look of this topic:

https://www.essentialobjects.com/doc/webbrowser/advanced/engine.aspx

Thanks!
Roei Ben-Harush
Posted: Wednesday, October 17, 2018 8:28:09 AM
Rank: Member
Groups: Member

Joined: 11/13/2015
Posts: 29
thanks! that solved the issue, though it would be awesome if there would be some kind of a callback to allow my code to decide what should go through and what shouldn't.
thanks again!
eo_support
Posted: Wednesday, October 17, 2018 10:16:33 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,071
You are welcome. Glad to hear that it's working for you.


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.