[Webkit-unassigned] [Bug 65611] New: Add firstPartyOrigin parameter to WebStorageNamespace::createStorageArea

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Aug 3 05:26:27 PDT 2011


           Summary: Add firstPartyOrigin parameter to
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Unspecified
        OS/Version: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: WebCore Misc.
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: marja at chromium.org
                CC: jochen at chromium.org

In Chrome, we'd like to grant scripts the right to use permanent or session-only localStorage based on their origin and the first-party origin of the page.

For this, we'd need to modify the signature of WebStorageNamespace::createStorageArea():

virtual WebStorageArea* createStorageArea(const WebString& origin) = 0;

We'd like to have:
virtual WebStorageArea* createStorageArea(const WebString& origin, const WebString& firstPartyOrigin) = 0;

I'd like to carry out the modifications in the following order:

1) Modifications in WebKit
- Add the two-parameter version of WebStorageNamespace::createStorageArea, provide an implementation (in WebStoragenamespaceImpl.cpp) which just delegates to the one-parameter version.
- Provide an implementation to the one-parameter version of WebStorageNamespace::createStorageArea which just delegates to the two-parameter version. This way it's enough if a subclass implements either the one-parameter version or the two-parameter version.
- Add the second parameter to StorageNamespace::storageArea(), StorageNamespaceImpl::storageArea(), StorageNamespaceProxy::storageArea() and WebStorageNamespaceImpl::createStorageArea().
- Modify DOMWindow to use the two-parameter version of storageArea().

2) Modifications in Chromium
- Modify the RendererWebStorageNamespaceImpl (inherits WebStorageNamespace) to overwrite the two-parameter version of createStorageArea instead of the one-parameter version.

3) Modifications in WebKit
- Remove the one-parameter version of WebStorageNamespace::createStorageArea, make the two-parameter version pure virtual and remove the implementation.

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list