How to enable window.openDatabase on custom Scheme?

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

How to enable window.openDatabase on custom Scheme?

Postby blackknife » Mon Aug 26, 2019 8:15 pm

When I call window.openDatabase on my custom scheme, I get following exception:

VM106:1 Uncaught DOMException: Failed to execute 'openDatabase' on 'Window': Access to the WebDatabase API is denied in this context.

The operation can run on scheme is not custom.
How to enable it?
blackknife
Techie
 
Posts: 30
Joined: Sun Apr 14, 2019 11:53 pm

Re: How to enable window.openDatabase on custom Scheme?

Postby Czarek » Tue Aug 27, 2019 1:30 am

Are you running the code from a sandboxed iframe or from a data: URL? Ref: https://cs.chromium.org/chromium/src/th ... &g=0&l=244
Maintainer of the CEF Python, PHP Desktop and CEF C API projects. My LinkedIn.
User avatar
Czarek
Virtuoso
 
Posts: 1927
Joined: Sun Nov 06, 2011 2:12 am

Re: How to enable window.openDatabase on custom Scheme?

Postby blackknife » Tue Aug 27, 2019 4:01 am

Czarek wrote:Are you running the code from a sandboxed iframe or from a data: URL? Ref: https://cs.chromium.org/chromium/src/th ... &g=0&l=244


1. I use --disable-web-security start cef and The child process.
2. I don't use iframe and sandboxed to running the code.
blackknife
Techie
 
Posts: 30
Joined: Sun Apr 14, 2019 11:53 pm

Re: How to enable window.openDatabase on custom Scheme?

Postby Czarek » Tue Aug 27, 2019 10:09 am

Can you reproduce the issue with ceftests scheme hander? See https://github.com/chromiumembedded/cef ... nittest.cc
Maintainer of the CEF Python, PHP Desktop and CEF C API projects. My LinkedIn.
User avatar
Czarek
Virtuoso
 
Posts: 1927
Joined: Sun Nov 06, 2011 2:12 am

Re: How to enable window.openDatabase on custom Scheme?

Postby blackknife » Wed Aug 28, 2019 8:49 pm

Czarek wrote:Can you reproduce the issue with ceftests scheme hander? See https://github.com/chromiumembedded/cef ... nittest.cc

All right,I will add the unit test, but I must to do something at the moment.
blackknife
Techie
 
Posts: 30
Joined: Sun Apr 14, 2019 11:53 pm


Return to Support Forum

Who is online

Users browsing this forum: Google [Bot] and 98 guests