WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 154837
Modern IDB: WebKit 2 IPC layer easily confused about multiple web processes being connected
https://bugs.webkit.org/show_bug.cgi?id=154837
Summary
Modern IDB: WebKit 2 IPC layer easily confused about multiple web processes b...
Brady Eidson
Reported
2016-02-29 14:23:49 PST
Modern IDB: WebKit 2 IPC layer easily confused about multiple web processes being connected Can result in weird behavior, including (most obviously) ASSERTs in debug builds. <
rdar://problem/24857351
>
Attachments
Patch v1
(22.86 KB, patch)
2016-02-29 14:26 PST
,
Brady Eidson
achristensen
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Brady Eidson
Comment 1
2016-02-29 14:26:40 PST
Created
attachment 272518
[details]
Patch v1
Alex Christensen
Comment 2
2016-02-29 14:50:55 PST
Comment on
attachment 272518
[details]
Patch v1 View in context:
https://bugs.webkit.org/attachment.cgi?id=272518&action=review
> Source/WebKit2/DatabaseProcess/DatabaseToWebProcessConnection.cpp:99 > +static uint64_t generateConnectionToServerIdentifier()
It makes sense to have this in the DatabaseProcess. Do we have any protection against invalid identifiers being used if the DatabaseProcess crashes?
> Source/WebKit2/WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.cpp:62 > + m_isOpenInServer = sendSync(Messages::DatabaseToWebProcessConnection::EstablishIDBConnectionToServer(), m_identifier);
Why can't we send asynchronously?
Brady Eidson
Comment 3
2016-02-29 15:00:19 PST
(In reply to
comment #2
)
> Comment on
attachment 272518
[details]
> Patch v1 > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=272518&action=review
> > > Source/WebKit2/DatabaseProcess/DatabaseToWebProcessConnection.cpp:99 > > +static uint64_t generateConnectionToServerIdentifier() > > It makes sense to have this in the DatabaseProcess. Do we have any > protection against invalid identifiers being used if the DatabaseProcess > crashes?
DatabaseProcess goes away, all related objects in the web process are invalidated.
> > Source/WebKit2/WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.cpp:62 > > + m_isOpenInServer = sendSync(Messages::DatabaseToWebProcessConnection::EstablishIDBConnectionToServer(), m_identifier); > > Why can't we send asynchronously?
New connections can start queuing up operations in the WebProcess via javascript immediately. This is at most one sync message per tab without any complicated/long-running work behind it. NBD.
Alex Christensen
Comment 4
2016-02-29 15:08:05 PST
Comment on
attachment 272518
[details]
Patch v1 View in context:
https://bugs.webkit.org/attachment.cgi?id=272518&action=review
>>> Source/WebKit2/DatabaseProcess/DatabaseToWebProcessConnection.cpp:99 >>> +static uint64_t generateConnectionToServerIdentifier() >> >> It makes sense to have this in the DatabaseProcess. Do we have any protection against invalid identifiers being used if the DatabaseProcess crashes? > > DatabaseProcess goes away, all related objects in the web process are invalidated.
It makes sense to have this in the DatabaseProcess. Do we have any protection against invalid identifiers being used if the DatabaseProcess crashes?
>>> Source/WebKit2/WebProcess/Databases/IndexedDB/WebIDBConnectionToServer.cpp:62 >>> + m_isOpenInServer = sendSync(Messages::DatabaseToWebProcessConnection::EstablishIDBConnectionToServer(), m_identifier); >> >> Why can't we send asynchronously? > > New connections can start queuing up operations in the WebProcess via javascript immediately. > > This is at most one sync message per tab without any complicated/long-running work behind it. NBD.
Why can't we send asynchronously?
Brady Eidson
Comment 5
2016-02-29 15:13:48 PST
http://trac.webkit.org/changeset/197372
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug