⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



Mar 18, 2018:

8:38 PM Changeset in webkit [229704] by commit-queue@webkit.org
  • 4 edits in trunk

Unreviewed, rolling out r229689.
https://bugs.webkit.org/show_bug.cgi?id=183735

Causes fast/loader/inner-iframe-loads-data-url-into-parent-on-
unload-crash.html to fail with async delegates (Requested by
cdumez_ on #webkit).

Reverted changeset:

"WebKit.WebsitePoliciesAutoplayQuirks API test times out with
async policy delegates"
https://bugs.webkit.org/show_bug.cgi?id=183702
https://trac.webkit.org/changeset/229689

8:00 PM Changeset in webkit [229703] by Alan Bujtas
  • 7 edits in trunk/Tools

[LayoutReloaded] Remove left/right width/height getters from Layout.Box
https://bugs.webkit.org/show_bug.cgi?id=183734

Reviewed by Antti Koivisto.

...and use Display.Box instead.

  • LayoutReloaded/DisplayTree/Box.js:

(Display.Box.prototype.bottomRight):
(Display.Box.prototype.size):
(Display.Box.prototype.height):
(Display.Box.prototype.width):

  • LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:

(BlockFormattingContext.prototype._computeStaticPosition):
(BlockFormattingContext.prototype._adjustBottomWithFIXME):
(BlockFormattingContext.prototype._computeInFlowPositionedPosition):
(BlockFormattingContext.prototype._computeOutOfFlowPosition):

  • LayoutReloaded/FormattingContext/FloatingContext.js:

(FloatingContext.prototype._positionForClear):
(FloatingContext.prototype._computePositionToAvoidIntrudingFloats):
(FloatingContext.prototype._adjustedFloatingPosition):

  • LayoutReloaded/FormattingContext/FormattingContext.js:

(FormattingContext.prototype.absoluteMarginBox):
(FormattingContext.prototype.absoluteBorderBox):
(FormattingContext.prototype.absolutePaddingBox):
(FormattingContext.prototype.absoluteContentBox):
(FormattingContext.prototype._toAbsolutePosition):
(FormattingContext.prototype._toRootAbsolutePosition):

  • LayoutReloaded/LayoutTree/Box.js:

(Layout.Box.prototype.rect): Deleted.
(Layout.Box.prototype.topLeft): Deleted.
(Layout.Box.prototype.bottomRight): Deleted.

  • LayoutReloaded/Utils.js:

(Utils._dumpBox):
(Utils.mapToContainer): Deleted.

6:28 PM Changeset in webkit [229702] by Alan Bujtas
  • 6 edits in trunk/Tools

[LayoutReloaded] Remove left/right width/height setters from Layout.Box
https://bugs.webkit.org/show_bug.cgi?id=183731

Reviewed by Antti Koivisto.

...and use Display.Box instead.

  • LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:

(BlockFormattingContext.prototype._computeStaticPosition):
(BlockFormattingContext.prototype._computeOutOfFlowWidth):
(BlockFormattingContext.prototype._computeFloatingWidth):
(BlockFormattingContext.prototype._computeInFlowWidth):
(BlockFormattingContext.prototype._computeOutOfFlowHeight):
(BlockFormattingContext.prototype._computeFloatingHeight):
(BlockFormattingContext.prototype._computeInFlowHeight):
(BlockFormattingContext.prototype._computeInFlowPositionedPosition):
(BlockFormattingContext.prototype._computeOutOfFlowPosition):

  • LayoutReloaded/FormattingContext/FloatingContext.js:

(FloatingContext.prototype.computePosition):

  • LayoutReloaded/FormattingContext/FormattingContext.js:

(FormattingContext.prototype._toDisplayBox):
(FormattingContext.prototype._toLayoutBox):

  • LayoutReloaded/Layout.js:

(layout):

  • LayoutReloaded/LayoutTree/Box.js:

(Layout.Box.prototype.setTopLeft): Deleted.
(Layout.Box.prototype.setSize): Deleted.
(Layout.Box.prototype.setWidth): Deleted.
(Layout.Box.prototype.setHeight): Deleted.

9:41 AM Changeset in webkit [229701] by Alan Bujtas
  • 6 edits in trunk/Tools

[LayoutReloaded] Collect out-of-flow positioned boxes for a given formatting context.
https://bugs.webkit.org/show_bug.cgi?id=183730

Reviewed by Antti Koivisto.

Collect and layout out-of-flow positioned boxes as the final step of the formatting context layout.

  • LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:

(BlockFormattingContext.prototype.layout):
(BlockFormattingContext.prototype._placeInFlowPositionedChildren):
(BlockFormattingContext.prototype._layoutOutOfFlowDescendants):
(BlockFormattingContext.prototype._placePositionedDescendants): Deleted.
(BlockFormattingContext.prototype._placeOutOfFlowDescendants): Deleted.

  • LayoutReloaded/FormattingContext/FormattingContext.js:

(FormattingContext.prototype._toAbsolutePosition):
(FormattingContext.prototype._outOfFlowDescendants):
(FormattingContext):

  • LayoutReloaded/LayoutTree/Box.js:

(Layout.Box.prototype.nextInFlowOrFloatSibling):
(Layout.Box.prototype.isDescendantOf):

  • LayoutReloaded/LayoutTree/Container.js:

(Layout.Container.prototype.firstInFlowOrFloatChild):
(Layout.Container.prototype.hasInFlowOrFloatChild):
(Layout.Container.prototype.outOfFlowDescendants):
(Layout.Container):

  • LayoutReloaded/Utils.js:

(Utils.isDescendantOf): Deleted.
(Utils.collectOutOfFlowDescendants): Deleted.

Mar 17, 2018:

10:53 PM Changeset in webkit [229700] by timothy_horton@apple.com
  • 2 edits in trunk/Source/WebCore

Correct redefined fnfErr type
https://bugs.webkit.org/show_bug.cgi?id=183728
<rdar://problem/38590063>

Reviewed by Dan Bernstein.

  • platform/network/cf/FormDataStreamCFNet.cpp:

CFStreamError's error parameter takes a SInt32, not an int.
Make sure our redefinition has a compatible type.

6:12 PM Changeset in webkit [229699] by jiewen_tan@apple.com
  • 29 edits
    4 copies
    6 adds
    1 delete in trunk

[WebAuthN] Implement authenticatorMakeCredential
https://bugs.webkit.org/show_bug.cgi?id=183527
<rdar://problem/35275886>

Reviewed by Brent Fulgham.

Source/WebCore:

This patch does the following few things:
1) It implements the authenticatorMakeCredential logic from the spec: https://www.w3.org/TR/webauthn/#op-make-cred.
2) It tweaks enocding and deocding of PublicKeyCredentialCreationOptions between UIProccess and WebProcess.
3) It soft links LocalAuthentication.Framework to WebCore, which was linked to WebKit.
4) It creates SPI header for DeviceIdentity.Framework, and provides stubs to link it to WebCore.

Here is a detailed explanantion of 1):

  1. A helper class called LocalAuthenticator is crafted to represent Apple platform attached authenticator, i.e.

the devices themselves. All operations are currently restricted to iOS at this moment as macOS lacks attestation
support.

  1. To do testing, this helper class is then moved from WebKit to WebCore even though all operations can only happens

in the UIProcess. We currently lack the ability to pretend a https environment in TestWebKitAPI which is required by
the WebAuthN API, and thus it is moved to WebCore to perform unit tesing flavor API tests. This is not enough as it
can't test message exchange between the UI and Web processes. We will address this in a subsequent patch.

  1. More on testing: The attestation process is abstracted into a protected method such that the testing enviroment can

override it with self attestation as network access is restricted in the WebKit testing enviroment. Also, swizzlers of
LocalAuthentication API are provided to override the behavoir of LAContext.

  1. More on testing: The actual Apple attestation can only happen in real device and with network access, therefore

it can only be covered by manual tests at this moment.

  1. Back to LocalAuthenticator, it currently has two public methods:

5.1. makeCredential(): This method is the one does all the magic.
+ It first checks some parameters.
+ It then invokes LAContext to get user consent.
+ It then talks to Apple Attestation Privacy CA to do attestations.
+ It then stores necessary information into the Keychain.
+ Finally it generates the attestation object.
5.2 isAvailable():
To check if a LocalAuthenticator is available or not.

  1. Even though files are of .mm format, they are written in a way that mixes NS, CF and C++ types. Here is the rule:

6.1 Use CF type only if it is requested by APIs.
6.2 Use NS type to manipulate all Objc objects.
6.3 Use C++ otherwise.

Covered by API tests.

  • Configurations/WebCore.xcconfig:
  • Modules/credentialmanagement/CredentialsMessenger.cpp:

(WebCore::getIdFromAttestationObject): Deleted.
Decoding attestation object is tedious. UIProcess will instead return credential ID and attestation object
at the same time. Therefore, this method is removed.

  • Modules/credentialmanagement/CredentialsMessenger.h:

(WebCore::CreationReturnBundle::CreationReturnBundle): Deleted.
(WebCore::AssertionReturnBundle::AssertionReturnBundle): Deleted.

  • Modules/webauthn/COSEConstants.h: Copied from Source/WebCore/Modules/webauthn/PublicKeyCredentialType.h.
  • Modules/webauthn/PublicKeyCredentialCreationOptions.h:

(WebCore::PublicKeyCredentialCreationOptions::isolatedPartialCopyPtr const):
(WebCore::PublicKeyCredentialCreationOptions::Parameters::encode const):
(WebCore::PublicKeyCredentialCreationOptions::Parameters::decode):
(WebCore::PublicKeyCredentialCreationOptions::encode const):
(WebCore::PublicKeyCredentialCreationOptions::decode):

  • Modules/webauthn/PublicKeyCredentialDescriptor.h:

(WebCore::PublicKeyCredentialDescriptor::encode const):
(WebCore::PublicKeyCredentialDescriptor::decode):

  • Modules/webauthn/PublicKeyCredentialType.h:
  • Modules/webauthn/cocoa/LocalAuthenticator.h: Copied from Source/WebCore/Modules/webauthn/PublicKeyCredentialCreationOptions.h.
  • Modules/webauthn/cocoa/LocalAuthenticator.mm: Added.

(WebCore::LocalAuthenticatorInternal::freePtrs):
(WebCore::LocalAuthenticator::makeCredential const):
(WebCore::LocalAuthenticator::isAvailable const):
(WebCore::LocalAuthenticator::issueClientCertificate const):

  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:
  • platform/cocoa/LocalAuthenticationSoftLink.h: Copied from Source/WebCore/Modules/webauthn/PublicKeyCredentialType.h.
  • platform/cocoa/LocalAuthenticationSoftLink.mm: Added.
  • testing/MockCredentialsMessenger.cpp:

(WebCore::MockCredentialsMessenger::setCreationReturnBundle):
(WebCore::MockCredentialsMessenger::makeCredential):
(WebCore::MockCredentialsMessenger::makeCredentialReply):
(WebCore::MockCredentialsMessenger::setAttestationObject): Deleted.

  • testing/MockCredentialsMessenger.h:
  • testing/MockCredentialsMessenger.idl:

Source/WebCore/PAL:

  • PAL.xcodeproj/project.pbxproj:
  • pal/spi/cocoa/DeviceIdentitySPI.h: Copied from Source/WebKit/UIProcess/CredentialManagement/WebCredentialsMessengerProxy.h.

Source/WebKit:

  • UIProcess/CredentialManagement/WebCredentialsMessengerProxy.cpp:

(WebKit::WebCredentialsMessengerProxy::WebCredentialsMessengerProxy):
(WebKit::WebCredentialsMessengerProxy::makeCredential):
(WebKit::WebCredentialsMessengerProxy::getAssertion):
(WebKit::WebCredentialsMessengerProxy::isUserVerifyingPlatformAuthenticatorAvailable):
(WebKit::WebCredentialsMessengerProxy::exceptionReply):
(WebKit::WebCredentialsMessengerProxy::makeCredentialReply):

  • UIProcess/CredentialManagement/WebCredentialsMessengerProxy.h:
  • UIProcess/CredentialManagement/WebCredentialsMessengerProxy.messages.in:
  • UIProcess/CredentialManagement/cocoa/WebCredentialsMessengerProxyCocoa.mm: Removed.
  • WebKit.xcodeproj/project.pbxproj:
  • WebProcess/CredentialManagement/WebCredentialsMessenger.cpp:

(WebKit::WebCredentialsMessenger::makeCredential):
(WebKit::WebCredentialsMessenger::makeCredentialReply):

  • WebProcess/CredentialManagement/WebCredentialsMessenger.h:
  • WebProcess/CredentialManagement/WebCredentialsMessenger.messages.in:

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/ios/LocalAuthenticator.mm: Added.

(TestWebKitAPI::getTestKey):
(TestWebKitAPI::cleanUpKeychain):
(TestWebKitAPI::LACantEvaluatePolicySwizzler::LACantEvaluatePolicySwizzler):
(TestWebKitAPI::LACantEvaluatePolicySwizzler::cantEvaluatePolicy):
(TestWebKitAPI::LACanEvaluatePolicySwizzler::LACanEvaluatePolicySwizzler):
(TestWebKitAPI::LACanEvaluatePolicySwizzler::canEvaluatePolicy):
(TestWebKitAPI::LAEvaluatePolicyFailedSwizzler::LAEvaluatePolicyFailedSwizzler):
(TestWebKitAPI::LAEvaluatePolicyFailedSwizzler::evaluatePolicyFailed):
(TestWebKitAPI::LAEvaluatePolicyPassedSwizzler::LAEvaluatePolicyPassedSwizzler):
(TestWebKitAPI::LAEvaluatePolicyPassedSwizzler::evaluatePolicyPassed):
(TestWebKitAPI::TestLocalAuthenticator::setFailureFlag):
(TestWebKitAPI::TEST):

WebKitLibraries:

  • WebKitPrivateFrameworkStubs/iOS/11/DeviceIdentity.framework/DeviceIdentity.tbd: Added.

LayoutTests:

  • http/wpt/credential-management/credentialscontainer-store-basics.https.html:
  • http/wpt/webauthn/idl.https.html:
  • http/wpt/webauthn/public-key-credential-create-success.https.html:
5:24 PM Changeset in webkit [229698] by Alan Bujtas
  • 3 edits
    3 adds in trunk/Tools

[LayoutReloaded] BlockFormattingContext::placePositionedDescendants takes care of both in- and out-of-flow placement
https://bugs.webkit.org/show_bug.cgi?id=183727

Reviewed by Antti Koivisto.

  • LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:

(BlockFormattingContext.prototype.layout):
(BlockFormattingContext.prototype._placePositionedDescendants):
(BlockFormattingContext.prototype._placeInFlowPositionedChildren):
(BlockFormattingContext.prototype._placeOutOfFlowDescendants):

  • LayoutReloaded/test/absolute-position-when-containing-block-is-not-in-the-formatting-context.html: Added.
  • LayoutReloaded/test/absolute-position-when-containing-block-is-not-in-the-formatting-context2.html: Added.
  • LayoutReloaded/test/index.html:
  • LayoutReloaded/test/relative-position-when-containing-block-is-not-in-the-formatting-context.html: Added.
3:35 PM Changeset in webkit [229697] by dbates@webkit.org
  • 3 edits in trunk/Source/WebKit

Tests fail in messages_unittest.py
https://bugs.webkit.org/show_bug.cgi?id=183725

Partial revert of r222113. The messages generator machinery does not know when
it is sufficient to emit an include for wtf/Forward.h as opposed to a concrete
header.

  • Scripts/webkit/LegacyMessages-expected.h:
  • Scripts/webkit/Messages-expected.h:
1:49 PM Changeset in webkit [229696] by Alan Bujtas
  • 5 edits in trunk/Tools

[LayoutReloaded] Ensure that positioning happens within the formatting context
https://bugs.webkit.org/show_bug.cgi?id=183722

Reviewed by Antti Koivisto.

All sizing and positioning need to happen in the formatting context that the box lives in
including the final position of in- and out-of-flow descendants.

  • LayoutReloaded/FormattingContext/BlockFormatting/BlockFormattingContext.js:

(BlockFormattingContext.prototype.layout):
(BlockFormattingContext.prototype._placeInFlowPositionedChildren):

  • LayoutReloaded/LayoutTree/Box.js:

(Layout.Box.prototype.establishesBlockFormattingContext):
(Layout.Box.prototype.isPositioned):
(Layout.Box.prototype.isRelativelyPositioned):
(Layout.Box.prototype.isAbsolutelyPositioned):
(Layout.Box.prototype.isOutOfFlowPositioned):
(Layout.Box.prototype.containingBlock):
(Layout.Box.prototype.isRelativePositioned): Deleted.
(Layout.Box.prototype.isAbsolutePositioned): Deleted.

  • LayoutReloaded/Utils.js:

(Utils.isRelativelyPositioned):
(Utils.isAbsolutelyPositioned):
(Utils.isRelativePositioned): Deleted.
(Utils.isAbsolutePositioned): Deleted.

  • LayoutReloaded/misc/headers/Box.h:
Note: See TracTimeline for information about the timeline view.