WEBVTT
Kind: captions
Language: en

00:00:00.040 --> 00:00:03.070 align:start position:0%
 
on<00:00:00.160><c> July</c><00:00:00.440><c> 24th</c><00:00:00.960><c> 2023</c><00:00:01.880><c> Apple</c><00:00:02.159><c> released</c><00:00:02.600><c> iOS</c>

00:00:03.070 --> 00:00:03.080 align:start position:0%
on July 24th 2023 Apple released iOS
 

00:00:03.080 --> 00:00:06.829 align:start position:0%
on July 24th 2023 Apple released iOS
16.6<00:00:04.080><c> and</c><00:00:04.240><c> Mac</c><00:00:04.480><c> OS</c><00:00:04.799><c> 13.5</c><00:00:05.640><c> to</c><00:00:05.759><c> the</c><00:00:05.920><c> public</c><00:00:06.720><c> these</c>

00:00:06.829 --> 00:00:06.839 align:start position:0%
16.6 and Mac OS 13.5 to the public these
 

00:00:06.839 --> 00:00:08.629 align:start position:0%
16.6 and Mac OS 13.5 to the public these
two<00:00:07.000><c> software</c><00:00:07.359><c> updates</c><00:00:07.680><c> included</c><00:00:08.200><c> patches</c>

00:00:08.629 --> 00:00:08.639 align:start position:0%
two software updates included patches
 

00:00:08.639 --> 00:00:10.709 align:start position:0%
two software updates included patches
for<00:00:08.880><c> multiple</c><00:00:09.280><c> security</c><00:00:09.719><c> vulnerabilities</c>

00:00:10.709 --> 00:00:10.719 align:start position:0%
for multiple security vulnerabilities
 

00:00:10.719 --> 00:00:15.669 align:start position:0%
for multiple security vulnerabilities
one<00:00:10.880><c> of</c><00:00:11.040><c> these</c><00:00:11.280><c> being</c><00:00:11.759><c> cve</c><00:00:12.839><c> 2023</c><00:00:14.240><c> 38600</c><00:00:15.240><c> a</c><00:00:15.400><c> bug</c>

00:00:15.669 --> 00:00:15.679 align:start position:0%
one of these being cve 2023 38600 a bug
 

00:00:15.679 --> 00:00:17.990 align:start position:0%
one of these being cve 2023 38600 a bug
in<00:00:16.000><c> web</c><00:00:16.240><c> kit</c><00:00:16.480><c> potentially</c><00:00:16.880><c> leading</c><00:00:17.240><c> to</c><00:00:17.520><c> arbit</c>

00:00:17.990 --> 00:00:18.000 align:start position:0%
in web kit potentially leading to arbit
 

00:00:18.000 --> 00:00:20.390 align:start position:0%
in web kit potentially leading to arbit
code<00:00:18.400><c> execution</c><00:00:19.400><c> on</c><00:00:19.600><c> October</c><00:00:19.920><c> of</c><00:00:20.039><c> the</c><00:00:20.199><c> same</c>

00:00:20.390 --> 00:00:20.400 align:start position:0%
code execution on October of the same
 

00:00:20.400 --> 00:00:22.150 align:start position:0%
code execution on October of the same
year<00:00:20.680><c> zero</c><00:00:21.039><c> day</c><00:00:21.199><c> initiative</c><00:00:21.680><c> published</c><00:00:22.000><c> a</c>

00:00:22.150 --> 00:00:22.160 align:start position:0%
year zero day initiative published a
 

00:00:22.160 --> 00:00:24.109 align:start position:0%
year zero day initiative published a
blog<00:00:22.400><c> post</c><00:00:22.640><c> containing</c><00:00:22.960><c> a</c><00:00:23.119><c> POC</c><00:00:23.519><c> for</c><00:00:23.680><c> the</c><00:00:23.800><c> bug</c>

00:00:24.109 --> 00:00:24.119 align:start position:0%
blog post containing a POC for the bug
 

00:00:24.119 --> 00:00:25.950 align:start position:0%
blog post containing a POC for the bug
as<00:00:24.199><c> well</c><00:00:24.320><c> as</c><00:00:24.439><c> a</c><00:00:24.519><c> technical</c><00:00:24.880><c> breakdown</c><00:00:25.680><c> and</c><00:00:25.760><c> so</c>

00:00:25.950 --> 00:00:25.960 align:start position:0%
as well as a technical breakdown and so
 

00:00:25.960 --> 00:00:27.109 align:start position:0%
as well as a technical breakdown and so
in<00:00:26.119><c> this</c><00:00:26.240><c> video</c><00:00:26.439><c> we're</c><00:00:26.560><c> going</c><00:00:26.640><c> to</c><00:00:26.720><c> be</c><00:00:26.840><c> taking</c><00:00:27.000><c> a</c>

00:00:27.109 --> 00:00:27.119 align:start position:0%
in this video we're going to be taking a
 

00:00:27.119 --> 00:00:29.310 align:start position:0%
in this video we're going to be taking a
look<00:00:27.320><c> at</c><00:00:27.439><c> that</c><00:00:27.599><c> POC</c><00:00:28.080><c> code</c><00:00:28.400><c> and</c><00:00:28.840><c> understanding</c>

00:00:29.310 --> 00:00:29.320 align:start position:0%
look at that POC code and understanding
 

00:00:29.320 --> 00:00:30.589 align:start position:0%
look at that POC code and understanding
how<00:00:29.439><c> the</c><00:00:29.560><c> bug</c><00:00:29.759><c> works</c>

00:00:30.589 --> 00:00:30.599 align:start position:0%
how the bug works
 

00:00:30.599 --> 00:00:32.470 align:start position:0%
how the bug works
webkit<00:00:31.039><c> is</c><00:00:31.119><c> an</c><00:00:31.279><c> open</c><00:00:31.519><c> source</c><00:00:31.840><c> browser</c><00:00:32.160><c> engine</c>

00:00:32.470 --> 00:00:32.480 align:start position:0%
webkit is an open source browser engine
 

00:00:32.480 --> 00:00:35.229 align:start position:0%
webkit is an open source browser engine
used<00:00:32.759><c> on</c><00:00:32.920><c> Mac</c><00:00:33.120><c> OS</c><00:00:33.399><c> and</c><00:00:33.600><c> iOS</c><00:00:34.280><c> in</c><00:00:34.440><c> their</c><00:00:34.680><c> native</c>

00:00:35.229 --> 00:00:35.239 align:start position:0%
used on Mac OS and iOS in their native
 

00:00:35.239 --> 00:00:37.430 align:start position:0%
used on Mac OS and iOS in their native
Safari<00:00:35.680><c> browser</c><00:00:36.559><c> so</c><00:00:36.760><c> every</c><00:00:36.879><c> time</c><00:00:37.000><c> you</c><00:00:37.120><c> load</c><00:00:37.320><c> a</c>

00:00:37.430 --> 00:00:37.440 align:start position:0%
Safari browser so every time you load a
 

00:00:37.440 --> 00:00:40.229 align:start position:0%
Safari browser so every time you load a
web<00:00:37.640><c> page</c><00:00:37.960><c> on</c><00:00:38.120><c> your</c><00:00:38.320><c> iPhone</c><00:00:38.680><c> in</c><00:00:38.879><c> Safari</c><00:00:39.680><c> webkit</c>

00:00:40.229 --> 00:00:40.239 align:start position:0%
web page on your iPhone in Safari webkit
 

00:00:40.239 --> 00:00:41.910 align:start position:0%
web page on your iPhone in Safari webkit
is<00:00:40.440><c> powering</c><00:00:40.879><c> the</c><00:00:41.000><c> rendering</c><00:00:41.399><c> of</c><00:00:41.559><c> that</c><00:00:41.719><c> web</c>

00:00:41.910 --> 00:00:41.920 align:start position:0%
is powering the rendering of that web
 

00:00:41.920 --> 00:00:44.270 align:start position:0%
is powering the rendering of that web
page<00:00:42.440><c> and</c><00:00:42.600><c> the</c><00:00:42.760><c> JavaScript</c><00:00:43.320><c> execution</c>

00:00:44.270 --> 00:00:44.280 align:start position:0%
page and the JavaScript execution
 

00:00:44.280 --> 00:00:46.350 align:start position:0%
page and the JavaScript execution
JavaScript<00:00:44.840><c> core</c><00:00:45.280><c> is</c><00:00:45.399><c> a</c><00:00:45.600><c> sub</c><00:00:45.960><c> component</c>

00:00:46.350 --> 00:00:46.360 align:start position:0%
JavaScript core is a sub component
 

00:00:46.360 --> 00:00:48.189 align:start position:0%
JavaScript core is a sub component
within<00:00:46.640><c> webkit</c><00:00:47.440><c> that</c><00:00:47.640><c> provides</c><00:00:48.039><c> the</c>

00:00:48.189 --> 00:00:48.199 align:start position:0%
within webkit that provides the
 

00:00:48.199 --> 00:00:49.990 align:start position:0%
within webkit that provides the
JavaScript<00:00:48.840><c> execution</c><00:00:49.280><c> environment</c><00:00:49.719><c> and</c><00:00:49.840><c> is</c>

00:00:49.990 --> 00:00:50.000 align:start position:0%
JavaScript execution environment and is
 

00:00:50.000 --> 00:00:51.430 align:start position:0%
JavaScript execution environment and is
responsible<00:00:50.440><c> for</c><00:00:50.719><c> interpreting</c><00:00:51.320><c> the</c>

00:00:51.430 --> 00:00:51.440 align:start position:0%
responsible for interpreting the
 

00:00:51.440 --> 00:00:54.029 align:start position:0%
responsible for interpreting the
JavaScript<00:00:51.920><c> code</c><00:00:52.120><c> that</c><00:00:52.239><c> runs</c><00:00:52.640><c> on</c><00:00:52.879><c> web</c><00:00:53.120><c> pages</c>

00:00:54.029 --> 00:00:54.039 align:start position:0%
JavaScript code that runs on web pages
 

00:00:54.039 --> 00:00:55.869 align:start position:0%
JavaScript code that runs on web pages
JavaScript<00:00:54.559><c> engines</c><00:00:54.920><c> in</c><00:00:55.079><c> general</c><00:00:55.399><c> are</c><00:00:55.600><c> highly</c>

00:00:55.869 --> 00:00:55.879 align:start position:0%
JavaScript engines in general are highly
 

00:00:55.879 --> 00:00:57.750 align:start position:0%
JavaScript engines in general are highly
complex<00:00:56.239><c> pieces</c><00:00:56.480><c> of</c><00:00:56.680><c> software</c><00:00:57.399><c> as</c><00:00:57.520><c> you</c><00:00:57.600><c> can</c>

00:00:57.750 --> 00:00:57.760 align:start position:0%
complex pieces of software as you can
 

00:00:57.760 --> 00:00:58.950 align:start position:0%
complex pieces of software as you can
imagine<00:00:58.079><c> they</c><00:00:58.239><c> have</c><00:00:58.320><c> to</c><00:00:58.440><c> be</c><00:00:58.559><c> capable</c><00:00:58.840><c> of</c>

00:00:58.950 --> 00:00:58.960 align:start position:0%
imagine they have to be capable of
 

00:00:58.960 --> 00:01:00.910 align:start position:0%
imagine they have to be capable of
executing<00:00:59.480><c> huge</c><00:00:59.680><c> amount</c><00:01:00.160><c> of</c><00:01:00.280><c> arbitrary</c>

00:01:00.910 --> 00:01:00.920 align:start position:0%
executing huge amount of arbitrary
 

00:01:00.920 --> 00:01:02.950 align:start position:0%
executing huge amount of arbitrary
JavaScript<00:01:01.440><c> code</c><00:01:01.960><c> in</c><00:01:02.079><c> an</c><00:01:02.320><c> efficient</c><00:01:02.719><c> and</c>

00:01:02.950 --> 00:01:02.960 align:start position:0%
JavaScript code in an efficient and
 

00:01:02.960 --> 00:01:05.149 align:start position:0%
JavaScript code in an efficient and
secure<00:01:03.359><c> Manner</c><00:01:04.040><c> and</c><00:01:04.239><c> just</c><00:01:04.400><c> like</c><00:01:04.559><c> all</c><00:01:04.760><c> software</c>

00:01:05.149 --> 00:01:05.159 align:start position:0%
secure Manner and just like all software
 

00:01:05.159 --> 00:01:07.270 align:start position:0%
secure Manner and just like all software
projects<00:01:05.680><c> they</c><00:01:05.840><c> are</c><00:01:06.080><c> prone</c><00:01:06.360><c> to</c><00:01:06.560><c> bugs</c><00:01:06.880><c> and</c>

00:01:07.270 --> 00:01:07.280 align:start position:0%
projects they are prone to bugs and
 

00:01:07.280 --> 00:01:09.149 align:start position:0%
projects they are prone to bugs and
crashes<00:01:08.280><c> the</c><00:01:08.400><c> following</c><00:01:08.680><c> snippet</c><00:01:09.040><c> of</c>

00:01:09.149 --> 00:01:09.159 align:start position:0%
crashes the following snippet of
 

00:01:09.159 --> 00:01:11.109 align:start position:0%
crashes the following snippet of
JavaScript<00:01:09.680><c> code</c><00:01:10.040><c> is</c><00:01:10.159><c> the</c><00:01:10.320><c> POC</c><00:01:10.880><c> that's</c>

00:01:11.109 --> 00:01:11.119 align:start position:0%
JavaScript code is the POC that's
 

00:01:11.119 --> 00:01:12.670 align:start position:0%
JavaScript code is the POC that's
capable<00:01:11.479><c> of</c><00:01:11.600><c> triggering</c><00:01:12.080><c> this</c><00:01:12.320><c> specific</c>

00:01:12.670 --> 00:01:12.680 align:start position:0%
capable of triggering this specific
 

00:01:12.680 --> 00:01:14.910 align:start position:0%
capable of triggering this specific
webkit<00:01:13.159><c> bug</c><00:01:13.840><c> these</c><00:01:14.000><c> few</c><00:01:14.200><c> short</c><00:01:14.479><c> lines</c><00:01:14.759><c> of</c>

00:01:14.910 --> 00:01:14.920 align:start position:0%
webkit bug these few short lines of
 

00:01:14.920 --> 00:01:17.350 align:start position:0%
webkit bug these few short lines of
JavaScript<00:01:15.840><c> are</c><00:01:16.119><c> able</c><00:01:16.360><c> to</c><00:01:16.560><c> trigger</c><00:01:16.880><c> a</c><00:01:17.000><c> subtle</c>

00:01:17.350 --> 00:01:17.360 align:start position:0%
JavaScript are able to trigger a subtle
 

00:01:17.360 --> 00:01:19.550 align:start position:0%
JavaScript are able to trigger a subtle
bug<00:01:17.640><c> within</c><00:01:17.880><c> the</c><00:01:18.000><c> JavaScript</c><00:01:18.479><c> C</c><00:01:18.720><c> engine</c><00:01:19.439><c> that</c>

00:01:19.550 --> 00:01:19.560 align:start position:0%
bug within the JavaScript C engine that
 

00:01:19.560 --> 00:01:21.950 align:start position:0%
bug within the JavaScript C engine that
leads<00:01:19.880><c> to</c><00:01:20.159><c> memory</c><00:01:20.479><c> corruption</c><00:01:21.000><c> on</c><00:01:21.119><c> the</c><00:01:21.280><c> Heap</c>

00:01:21.950 --> 00:01:21.960 align:start position:0%
leads to memory corruption on the Heap
 

00:01:21.960 --> 00:01:24.109 align:start position:0%
leads to memory corruption on the Heap
which<00:01:22.119><c> can</c><00:01:22.320><c> then</c><00:01:22.479><c> be</c><00:01:22.640><c> used</c><00:01:23.240><c> theoretically</c><00:01:23.960><c> to</c>

00:01:24.109 --> 00:01:24.119 align:start position:0%
which can then be used theoretically to
 

00:01:24.119 --> 00:01:26.230 align:start position:0%
which can then be used theoretically to
gain<00:01:24.320><c> arbitary</c><00:01:24.720><c> code</c><00:01:24.960><c> execution</c><00:01:25.840><c> so</c><00:01:26.000><c> how</c><00:01:26.079><c> does</c>

00:01:26.230 --> 00:01:26.240 align:start position:0%
gain arbitary code execution so how does
 

00:01:26.240 --> 00:01:27.310 align:start position:0%
gain arbitary code execution so how does
this<00:01:26.400><c> work</c><00:01:26.640><c> we're</c><00:01:26.759><c> going</c><00:01:26.880><c> to</c><00:01:26.960><c> look</c><00:01:27.119><c> through</c>

00:01:27.310 --> 00:01:27.320 align:start position:0%
this work we're going to look through
 

00:01:27.320 --> 00:01:28.910 align:start position:0%
this work we're going to look through
this<00:01:27.479><c> line</c><00:01:27.720><c> by</c><00:01:27.960><c> line</c><00:01:28.280><c> but</c><00:01:28.400><c> feel</c><00:01:28.560><c> free</c><00:01:28.759><c> to</c>

00:01:28.910 --> 00:01:28.920 align:start position:0%
this line by line but feel free to
 

00:01:28.920 --> 00:01:30.230 align:start position:0%
this line by line but feel free to
re-watch<00:01:29.320><c> this</c><00:01:29.479><c> part</c><00:01:29.600><c> of</c><00:01:29.640><c> the</c><00:01:29.720><c> video</c><00:01:29.880><c> video</c><00:01:30.119><c> as</c>

00:01:30.230 --> 00:01:30.240 align:start position:0%
re-watch this part of the video video as
 

00:01:30.240 --> 00:01:31.590 align:start position:0%
re-watch this part of the video video as
many<00:01:30.439><c> times</c><00:01:30.640><c> as</c><00:01:30.720><c> it</c><00:01:30.840><c> takes</c><00:01:31.079><c> to</c><00:01:31.479><c> understand</c>

00:01:31.590 --> 00:01:31.600 align:start position:0%
many times as it takes to understand
 

00:01:31.600 --> 00:01:33.109 align:start position:0%
many times as it takes to understand
what's<00:01:31.799><c> going</c><00:01:31.960><c> on</c><00:01:32.159><c> here</c><00:01:32.560><c> as</c><00:01:32.680><c> it</c><00:01:32.759><c> may</c><00:01:32.920><c> be</c><00:01:33.000><c> hard</c>

00:01:33.109 --> 00:01:33.119 align:start position:0%
what's going on here as it may be hard
 

00:01:33.119 --> 00:01:34.429 align:start position:0%
what's going on here as it may be hard
to<00:01:33.240><c> wrap</c><00:01:33.439><c> this</c><00:01:33.520><c> around</c><00:01:33.720><c> your</c><00:01:33.880><c> head</c><00:01:34.040><c> the</c><00:01:34.200><c> first</c>

00:01:34.429 --> 00:01:34.439 align:start position:0%
to wrap this around your head the first
 

00:01:34.439 --> 00:01:36.429 align:start position:0%
to wrap this around your head the first
watch<00:01:35.040><c> we</c><00:01:35.159><c> start</c><00:01:35.360><c> on</c><00:01:35.479><c> the</c><00:01:35.640><c> first</c><00:01:35.880><c> line</c><00:01:36.240><c> by</c>

00:01:36.429 --> 00:01:36.439 align:start position:0%
watch we start on the first line by
 

00:01:36.439 --> 00:01:38.950 align:start position:0%
watch we start on the first line by
creating<00:01:36.920><c> a</c><00:01:37.079><c> new</c><00:01:37.360><c> array</c><00:01:37.720><c> buffer</c><00:01:38.159><c> object</c><00:01:38.840><c> and</c>

00:01:38.950 --> 00:01:38.960 align:start position:0%
creating a new array buffer object and
 

00:01:38.960 --> 00:01:41.670 align:start position:0%
creating a new array buffer object and
storing<00:01:39.439><c> this</c><00:01:39.600><c> in</c><00:01:39.720><c> the</c><00:01:39.880><c> constant</c><00:01:40.360><c> AB</c><00:01:41.240><c> we</c><00:01:41.439><c> pass</c>

00:01:41.670 --> 00:01:41.680 align:start position:0%
storing this in the constant AB we pass
 

00:01:41.680 --> 00:01:44.310 align:start position:0%
storing this in the constant AB we pass
the<00:01:41.880><c> size</c><00:01:42.479><c> hex</c><00:01:42.799><c> 1000</c><00:01:43.520><c> as</c><00:01:43.640><c> the</c><00:01:43.759><c> length</c><00:01:44.079><c> of</c><00:01:44.200><c> the</c>

00:01:44.310 --> 00:01:44.320 align:start position:0%
the size hex 1000 as the length of the
 

00:01:44.320 --> 00:01:47.670 align:start position:0%
the size hex 1000 as the length of the
array<00:01:45.000><c> buffer</c><00:01:46.000><c> according</c><00:01:46.280><c> to</c><00:01:46.439><c> the</c><00:01:46.560><c> JS</c><00:01:46.960><c> docs</c><00:01:47.520><c> an</c>

00:01:47.670 --> 00:01:47.680 align:start position:0%
array buffer according to the JS docs an
 

00:01:47.680 --> 00:01:49.230 align:start position:0%
array buffer according to the JS docs an
array<00:01:47.960><c> buffer</c><00:01:48.320><c> is</c><00:01:48.399><c> an</c><00:01:48.600><c> object</c><00:01:48.880><c> used</c><00:01:49.119><c> to</c>

00:01:49.230 --> 00:01:49.240 align:start position:0%
array buffer is an object used to
 

00:01:49.240 --> 00:01:51.709 align:start position:0%
array buffer is an object used to
represent<00:01:49.640><c> raw</c><00:01:50.079><c> binary</c><00:01:50.479><c> data</c><00:01:51.240><c> so</c><00:01:51.439><c> in</c><00:01:51.560><c> other</c>

00:01:51.709 --> 00:01:51.719 align:start position:0%
represent raw binary data so in other
 

00:01:51.719 --> 00:01:53.550 align:start position:0%
represent raw binary data so in other
words<00:01:52.000><c> this</c><00:01:52.119><c> is</c><00:01:52.320><c> kind</c><00:01:52.439><c> of</c><00:01:52.680><c> like</c><00:01:53.079><c> some</c><00:01:53.320><c> kind</c><00:01:53.439><c> of</c>

00:01:53.550 --> 00:01:53.560 align:start position:0%
words this is kind of like some kind of
 

00:01:53.560 --> 00:01:56.709 align:start position:0%
words this is kind of like some kind of
arbitary<00:01:54.040><c> allocation</c><00:01:55.040><c> of</c><00:01:55.200><c> an</c><00:01:55.360><c> arbitrary</c><00:01:55.920><c> size</c>

00:01:56.709 --> 00:01:56.719 align:start position:0%
arbitary allocation of an arbitrary size
 

00:01:56.719 --> 00:01:58.429 align:start position:0%
arbitary allocation of an arbitrary size
just<00:01:56.880><c> like</c><00:01:57.039><c> a</c><00:01:57.159><c> maloc</c><00:01:57.600><c> core</c><00:01:57.920><c> on</c><00:01:58.039><c> the</c><00:01:58.159><c> Heap</c>

00:01:58.429 --> 00:01:58.439 align:start position:0%
just like a maloc core on the Heap
 

00:01:58.439 --> 00:02:00.429 align:start position:0%
just like a maloc core on the Heap
essentially<00:01:59.119><c> a</c><00:01:59.280><c> Ru</c><00:01:59.600><c> for</c><00:01:59.880><c> objects</c><00:02:00.159><c> aren't</c>

00:02:00.429 --> 00:02:00.439 align:start position:0%
essentially a Ru for objects aren't
 

00:02:00.439 --> 00:02:02.749 align:start position:0%
essentially a Ru for objects aren't
typically<00:02:00.840><c> resizable</c><00:02:01.719><c> but</c><00:02:01.880><c> in</c><00:02:02.039><c> this</c><00:02:02.240><c> case</c><00:02:02.520><c> we</c>

00:02:02.749 --> 00:02:02.759 align:start position:0%
typically resizable but in this case we
 

00:02:02.759 --> 00:02:04.630 align:start position:0%
typically resizable but in this case we
pass<00:02:03.039><c> a</c><00:02:03.240><c> second</c><00:02:03.560><c> argument</c><00:02:04.200><c> which</c><00:02:04.320><c> is</c><00:02:04.439><c> an</c>

00:02:04.630 --> 00:02:04.640 align:start position:0%
pass a second argument which is an
 

00:02:04.640 --> 00:02:07.749 align:start position:0%
pass a second argument which is an
object<00:02:05.119><c> containing</c><00:02:05.600><c> the</c><00:02:05.759><c> key</c><00:02:06.399><c> Max</c><00:02:06.719><c> BTE</c><00:02:07.000><c> length</c>

00:02:07.749 --> 00:02:07.759 align:start position:0%
object containing the key Max BTE length
 

00:02:07.759 --> 00:02:09.190 align:start position:0%
object containing the key Max BTE length
and<00:02:08.039><c> this</c><00:02:08.280><c> actually</c><00:02:08.599><c> according</c><00:02:08.879><c> to</c><00:02:09.000><c> the</c>

00:02:09.190 --> 00:02:09.200 align:start position:0%
and this actually according to the
 

00:02:09.200 --> 00:02:11.750 align:start position:0%
and this actually according to the
documentation<00:02:10.200><c> makes</c><00:02:10.479><c> the</c><00:02:10.640><c> array</c><00:02:10.959><c> buffer</c>

00:02:11.750 --> 00:02:11.760 align:start position:0%
documentation makes the array buffer
 

00:02:11.760 --> 00:02:13.750 align:start position:0%
documentation makes the array buffer
resizable<00:02:12.760><c> this</c><00:02:12.840><c> will</c><00:02:13.000><c> be</c><00:02:13.160><c> important</c><00:02:13.520><c> later</c>

00:02:13.750 --> 00:02:13.760 align:start position:0%
resizable this will be important later
 

00:02:13.760 --> 00:02:16.110 align:start position:0%
resizable this will be important later
on<00:02:14.720><c> array</c><00:02:15.000><c> buffers</c><00:02:15.480><c> themselves</c><00:02:15.720><c> are</c><00:02:15.920><c> just</c>

00:02:16.110 --> 00:02:16.120 align:start position:0%
on array buffers themselves are just
 

00:02:16.120 --> 00:02:18.270 align:start position:0%
on array buffers themselves are just
blocks<00:02:16.440><c> of</c><00:02:16.640><c> binary</c><00:02:17.000><c> data</c><00:02:17.720><c> but</c><00:02:17.840><c> in</c><00:02:17.920><c> order</c><00:02:18.120><c> to</c>

00:02:18.270 --> 00:02:18.280 align:start position:0%
blocks of binary data but in order to
 

00:02:18.280 --> 00:02:20.390 align:start position:0%
blocks of binary data but in order to
actually<00:02:18.519><c> be</c><00:02:18.680><c> used</c><00:02:19.319><c> we</c><00:02:19.440><c> need</c><00:02:19.599><c> a</c><00:02:19.760><c> second</c><00:02:20.120><c> object</c>

00:02:20.390 --> 00:02:20.400 align:start position:0%
actually be used we need a second object
 

00:02:20.400 --> 00:02:22.390 align:start position:0%
actually be used we need a second object
known<00:02:20.599><c> as</c><00:02:20.720><c> a</c><00:02:20.879><c> data</c><00:02:21.160><c> view</c><00:02:21.440><c> object</c><00:02:21.959><c> which</c><00:02:22.120><c> allows</c>

00:02:22.390 --> 00:02:22.400 align:start position:0%
known as a data view object which allows
 

00:02:22.400 --> 00:02:24.589 align:start position:0%
known as a data view object which allows
us<00:02:22.519><c> to</c><00:02:22.720><c> interpret</c><00:02:23.239><c> the</c><00:02:23.400><c> binary</c><00:02:23.760><c> data</c><00:02:24.280><c> behind</c>

00:02:24.589 --> 00:02:24.599 align:start position:0%
us to interpret the binary data behind
 

00:02:24.599 --> 00:02:26.869 align:start position:0%
us to interpret the binary data behind
the<00:02:24.720><c> array</c><00:02:25.000><c> buffer</c><00:02:25.720><c> as</c><00:02:25.920><c> some</c><00:02:26.200><c> specific</c><00:02:26.640><c> data</c>

00:02:26.869 --> 00:02:26.879 align:start position:0%
the array buffer as some specific data
 

00:02:26.879 --> 00:02:28.910 align:start position:0%
the array buffer as some specific data
format<00:02:27.840><c> we</c><00:02:27.959><c> can</c><00:02:28.040><c> use</c><00:02:28.239><c> multiple</c><00:02:28.640><c> different</c>

00:02:28.910 --> 00:02:28.920 align:start position:0%
format we can use multiple different
 

00:02:28.920 --> 00:02:30.270 align:start position:0%
format we can use multiple different
objects<00:02:29.239><c> for</c><00:02:29.400><c> this</c><00:02:29.519><c> but</c><00:02:29.640><c> in</c><00:02:29.720><c> this</c><00:02:29.959><c> this</c><00:02:30.120><c> case</c>

00:02:30.270 --> 00:02:30.280 align:start position:0%
objects for this but in this this case
 

00:02:30.280 --> 00:02:33.589 align:start position:0%
objects for this but in this this case
we<00:02:30.400><c> are</c><00:02:30.519><c> using</c><00:02:30.840><c> a</c><00:02:31.040><c> uint</c><00:02:31.400><c> 8</c><00:02:32.080><c> array</c><00:02:33.080><c> we</c><00:02:33.239><c> create</c><00:02:33.519><c> a</c>

00:02:33.589 --> 00:02:33.599 align:start position:0%
we are using a uint 8 array we create a
 

00:02:33.599 --> 00:02:35.830 align:start position:0%
we are using a uint 8 array we create a
new<00:02:33.760><c> u8</c><00:02:34.280><c> array</c><00:02:34.840><c> and</c><00:02:35.040><c> pass</c><00:02:35.239><c> in</c><00:02:35.440><c> the</c><00:02:35.560><c> array</c>

00:02:35.830 --> 00:02:35.840 align:start position:0%
new u8 array and pass in the array
 

00:02:35.840 --> 00:02:38.150 align:start position:0%
new u8 array and pass in the array
buffer<00:02:36.519><c> to</c><00:02:36.720><c> the</c><00:02:36.879><c> initializer</c><00:02:37.519><c> and</c><00:02:37.640><c> store</c><00:02:38.000><c> this</c>

00:02:38.150 --> 00:02:38.160 align:start position:0%
buffer to the initializer and store this
 

00:02:38.160 --> 00:02:41.190 align:start position:0%
buffer to the initializer and store this
in<00:02:38.400><c> u8</c><00:02:39.239><c> this</c><00:02:39.400><c> u8</c><00:02:39.760><c> array</c><00:02:40.200><c> is</c><00:02:40.360><c> now</c><00:02:40.720><c> allowing</c><00:02:41.080><c> us</c>

00:02:41.190 --> 00:02:41.200 align:start position:0%
in u8 this u8 array is now allowing us
 

00:02:41.200 --> 00:02:42.830 align:start position:0%
in u8 this u8 array is now allowing us
to<00:02:41.360><c> read</c><00:02:41.560><c> and</c><00:02:41.760><c> write</c><00:02:42.000><c> to</c><00:02:42.120><c> the</c><00:02:42.239><c> underlying</c>

00:02:42.830 --> 00:02:42.840 align:start position:0%
to read and write to the underlying
 

00:02:42.840 --> 00:02:44.790 align:start position:0%
to read and write to the underlying
array<00:02:43.159><c> buffer</c><00:02:43.760><c> which</c><00:02:43.879><c> is</c><00:02:44.040><c> basically</c><00:02:44.400><c> used</c><00:02:44.680><c> as</c>

00:02:44.790 --> 00:02:44.800 align:start position:0%
array buffer which is basically used as
 

00:02:44.800 --> 00:02:47.509 align:start position:0%
array buffer which is basically used as
the<00:02:44.959><c> backend</c><00:02:45.400><c> data</c><00:02:45.680><c> store</c><00:02:46.120><c> for</c><00:02:46.400><c> this</c><00:02:46.560><c> array</c>

00:02:47.509 --> 00:02:47.519 align:start position:0%
the backend data store for this array
 

00:02:47.519 --> 00:02:49.869 align:start position:0%
the backend data store for this array
next<00:02:47.720><c> we</c><00:02:47.920><c> Define</c><00:02:48.280><c> a</c><00:02:48.440><c> new</c><00:02:48.680><c> JavaScript</c><00:02:49.239><c> function</c>

00:02:49.869 --> 00:02:49.879 align:start position:0%
next we Define a new JavaScript function
 

00:02:49.879 --> 00:02:51.910 align:start position:0%
next we Define a new JavaScript function
named<00:02:50.239><c> callback</c><00:02:51.040><c> and</c><00:02:51.200><c> this</c><00:02:51.360><c> function</c><00:02:51.680><c> does</c>

00:02:51.910 --> 00:02:51.920 align:start position:0%
named callback and this function does
 

00:02:51.920 --> 00:02:54.550 align:start position:0%
named callback and this function does
two<00:02:52.159><c> things</c><00:02:52.560><c> first</c><00:02:52.760><c> of</c><00:02:52.879><c> all</c><00:02:53.360><c> it</c><00:02:53.519><c> calls</c><00:02:54.040><c> resize</c>

00:02:54.550 --> 00:02:54.560 align:start position:0%
two things first of all it calls resize
 

00:02:54.560 --> 00:02:56.350 align:start position:0%
two things first of all it calls resize
with<00:02:54.680><c> an</c><00:02:54.800><c> argument</c><00:02:55.120><c> of</c><00:02:55.319><c> zero</c><00:02:55.800><c> on</c><00:02:55.920><c> the</c><00:02:56.080><c> array</c>

00:02:56.350 --> 00:02:56.360 align:start position:0%
with an argument of zero on the array
 

00:02:56.360 --> 00:02:59.830 align:start position:0%
with an argument of zero on the array
buffer<00:02:57.159><c> and</c><00:02:57.280><c> then</c><00:02:57.400><c> it</c><00:02:57.519><c> simply</c><00:02:58.080><c> returns</c><00:02:58.840><c> zero</c>

00:02:59.830 --> 00:02:59.840 align:start position:0%
buffer and then it simply returns zero
 

00:02:59.840 --> 00:03:01.589 align:start position:0%
buffer and then it simply returns zero
note<00:03:00.040><c> that</c><00:03:00.159><c> the</c><00:03:00.280><c> JavaScript</c><00:03:00.840><c> function</c>

00:03:01.589 --> 00:03:01.599 align:start position:0%
note that the JavaScript function
 

00:03:01.599 --> 00:03:03.509 align:start position:0%
note that the JavaScript function
callback<00:03:02.200><c> has</c><00:03:02.319><c> not</c><00:03:02.480><c> yet</c><00:03:02.640><c> been</c><00:03:02.879><c> executed</c><00:03:03.360><c> but</c>

00:03:03.509 --> 00:03:03.519 align:start position:0%
callback has not yet been executed but
 

00:03:03.519 --> 00:03:06.350 align:start position:0%
callback has not yet been executed but
rather<00:03:03.840><c> defined</c><00:03:04.319><c> for</c><00:03:04.640><c> later</c><00:03:05.040><c> use</c><00:03:05.920><c> finally</c><00:03:06.239><c> we</c>

00:03:06.350 --> 00:03:06.360 align:start position:0%
rather defined for later use finally we
 

00:03:06.360 --> 00:03:09.470 align:start position:0%
rather defined for later use finally we
have<00:03:06.440><c> a</c><00:03:06.599><c> call</c><00:03:06.879><c> to</c><00:03:07.280><c> copy</c><00:03:07.560><c> within</c><00:03:08.159><c> on</c><00:03:08.319><c> the</c><00:03:08.440><c> un8</c>

00:03:09.470 --> 00:03:09.480 align:start position:0%
have a call to copy within on the un8
 

00:03:09.480 --> 00:03:12.070 align:start position:0%
have a call to copy within on the un8
array<00:03:10.480><c> it</c><00:03:10.599><c> takes</c><00:03:10.879><c> two</c><00:03:11.080><c> arguments</c><00:03:11.720><c> first</c><00:03:11.920><c> of</c>

00:03:12.070 --> 00:03:12.080 align:start position:0%
array it takes two arguments first of
 

00:03:12.080 --> 00:03:14.550 align:start position:0%
array it takes two arguments first of
which<00:03:12.239><c> we</c><00:03:12.400><c> pass</c><00:03:12.640><c> in</c><00:03:12.879><c> HEX</c><00:03:13.159><c> 20</c><00:03:13.959><c> second</c><00:03:14.200><c> of</c><00:03:14.360><c> which</c>

00:03:14.550 --> 00:03:14.560 align:start position:0%
which we pass in HEX 20 second of which
 

00:03:14.560 --> 00:03:17.670 align:start position:0%
which we pass in HEX 20 second of which
we<00:03:14.720><c> pass</c><00:03:14.959><c> an</c><00:03:15.200><c> object</c><00:03:15.840><c> with</c><00:03:16.080><c> the</c><00:03:16.239><c> key</c><00:03:16.640><c> value</c><00:03:17.000><c> of</c>

00:03:17.670 --> 00:03:17.680 align:start position:0%
we pass an object with the key value of
 

00:03:17.680 --> 00:03:19.509 align:start position:0%
we pass an object with the key value of
Po<00:03:17.959><c> into</c><00:03:18.159><c> to</c><00:03:18.400><c> our</c><00:03:18.640><c> callback</c><00:03:19.080><c> function</c><00:03:19.400><c> that</c>

00:03:19.509 --> 00:03:19.519 align:start position:0%
Po into to our callback function that
 

00:03:19.519 --> 00:03:21.589 align:start position:0%
Po into to our callback function that
was<00:03:19.680><c> previously</c><00:03:20.159><c> defined</c><00:03:20.799><c> the</c><00:03:20.959><c> copy</c><00:03:21.200><c> within</c>

00:03:21.589 --> 00:03:21.599 align:start position:0%
was previously defined the copy within
 

00:03:21.599 --> 00:03:23.350 align:start position:0%
was previously defined the copy within
function<00:03:22.159><c> copies</c><00:03:22.480><c> part</c><00:03:22.640><c> of</c><00:03:22.799><c> this</c><00:03:22.920><c> array</c><00:03:23.200><c> to</c>

00:03:23.350 --> 00:03:23.360 align:start position:0%
function copies part of this array to
 

00:03:23.360 --> 00:03:25.630 align:start position:0%
function copies part of this array to
another<00:03:23.799><c> location</c><00:03:24.200><c> in</c><00:03:24.319><c> the</c><00:03:24.480><c> same</c><00:03:24.680><c> array</c><00:03:25.319><c> and</c>

00:03:25.630 --> 00:03:25.640 align:start position:0%
another location in the same array and
 

00:03:25.640 --> 00:03:27.350 align:start position:0%
another location in the same array and
returns<00:03:25.959><c> this</c><00:03:26.120><c> array</c><00:03:26.440><c> without</c><00:03:26.680><c> modifying</c><00:03:27.159><c> its</c>

00:03:27.350 --> 00:03:27.360 align:start position:0%
returns this array without modifying its
 

00:03:27.360 --> 00:03:29.589 align:start position:0%
returns this array without modifying its
length<00:03:28.120><c> so</c><00:03:28.280><c> if</c><00:03:28.360><c> we</c><00:03:28.519><c> take</c><00:03:28.640><c> an</c><00:03:28.840><c> example</c><00:03:29.280><c> here</c><00:03:29.439><c> of</c>

00:03:29.589 --> 00:03:29.599 align:start position:0%
length so if we take an example here of
 

00:03:29.599 --> 00:03:32.830 align:start position:0%
length so if we take an example here of
an<00:03:29.799><c> array</c><00:03:30.400><c> containing</c><00:03:30.959><c> integers</c><00:03:31.439><c> 1</c><00:03:31.680><c> 2</c><00:03:31.879><c> 3</c><00:03:32.080><c> 4</c><00:03:32.319><c> 5</c><00:03:32.560><c> 6</c>

00:03:32.830 --> 00:03:32.840 align:start position:0%
an array containing integers 1 2 3 4 5 6
 

00:03:32.840 --> 00:03:35.630 align:start position:0%
an array containing integers 1 2 3 4 5 6
7<00:03:33.480><c> and</c><00:03:33.599><c> we</c><00:03:33.760><c> call</c><00:03:34.040><c> Copy</c><00:03:34.360><c> within</c><00:03:35.120><c> the</c><00:03:35.319><c> first</c>

00:03:35.630 --> 00:03:35.640 align:start position:0%
7 and we call Copy within the first
 

00:03:35.640 --> 00:03:38.470 align:start position:0%
7 and we call Copy within the first
argument<00:03:36.560><c> is</c><00:03:36.959><c> the</c><00:03:37.319><c> index</c><00:03:37.760><c> so</c><00:03:37.879><c> we</c><00:03:37.959><c> want</c><00:03:38.040><c> to</c><00:03:38.200><c> copy</c>

00:03:38.470 --> 00:03:38.480 align:start position:0%
argument is the index so we want to copy
 

00:03:38.480 --> 00:03:40.789 align:start position:0%
argument is the index so we want to copy
items<00:03:38.879><c> to</c><00:03:39.439><c> and</c><00:03:39.599><c> the</c><00:03:39.720><c> second</c><00:03:40.000><c> argument</c><00:03:40.640><c> is</c>

00:03:40.789 --> 00:03:40.799 align:start position:0%
items to and the second argument is
 

00:03:40.799 --> 00:03:42.550 align:start position:0%
items to and the second argument is
where<00:03:40.920><c> we're</c><00:03:41.080><c> going</c><00:03:41.159><c> to</c><00:03:41.319><c> start</c><00:03:41.640><c> from</c><00:03:42.360><c> so</c>

00:03:42.550 --> 00:03:42.560 align:start position:0%
where we're going to start from so
 

00:03:42.560 --> 00:03:44.149 align:start position:0%
where we're going to start from so
essentially<00:03:42.920><c> in</c><00:03:43.040><c> this</c><00:03:43.200><c> case</c><00:03:43.439><c> it</c><00:03:43.519><c> would</c><00:03:43.720><c> move</c>

00:03:44.149 --> 00:03:44.159 align:start position:0%
essentially in this case it would move
 

00:03:44.159 --> 00:03:47.949 align:start position:0%
essentially in this case it would move
everything<00:03:45.159><c> from</c><00:03:45.879><c> index0</c><00:03:46.879><c> to</c><00:03:47.200><c> index</c><00:03:47.599><c> starting</c>

00:03:47.949 --> 00:03:47.959 align:start position:0%
everything from index0 to index starting
 

00:03:47.959 --> 00:03:49.429 align:start position:0%
everything from index0 to index starting
at<00:03:48.159><c> one</c><00:03:48.599><c> and</c><00:03:48.680><c> then</c><00:03:48.799><c> we're</c><00:03:48.959><c> left</c><00:03:49.159><c> with</c><00:03:49.319><c> the</c>

00:03:49.429 --> 00:03:49.439 align:start position:0%
at one and then we're left with the
 

00:03:49.439 --> 00:03:52.190 align:start position:0%
at one and then we're left with the
following<00:03:50.000><c> array</c><00:03:50.480><c> in</c><00:03:50.599><c> our</c><00:03:50.799><c> JavaScript</c><00:03:51.319><c> PC</c><00:03:52.040><c> the</c>

00:03:52.190 --> 00:03:52.200 align:start position:0%
following array in our JavaScript PC the
 

00:03:52.200 --> 00:03:55.149 align:start position:0%
following array in our JavaScript PC the
first<00:03:52.480><c> argument</c><00:03:52.840><c> we</c><00:03:53.000><c> use</c><00:03:53.319><c> is</c><00:03:53.760><c> he20</c><00:03:54.760><c> which</c><00:03:54.879><c> is</c><00:03:54.959><c> a</c>

00:03:55.149 --> 00:03:55.159 align:start position:0%
first argument we use is he20 which is a
 

00:03:55.159 --> 00:03:57.309 align:start position:0%
first argument we use is he20 which is a
simple<00:03:55.519><c> integer</c><00:03:55.959><c> value</c><00:03:56.680><c> however</c><00:03:56.879><c> the</c><00:03:57.000><c> second</c>

00:03:57.309 --> 00:03:57.319 align:start position:0%
simple integer value however the second
 

00:03:57.319 --> 00:03:59.309 align:start position:0%
simple integer value however the second
argument<00:03:57.760><c> is</c><00:03:57.920><c> not</c><00:03:58.079><c> an</c><00:03:58.239><c> integer</c><00:03:58.599><c> value</c><00:03:59.159><c> but</c>

00:03:59.309 --> 00:03:59.319 align:start position:0%
argument is not an integer value but
 

00:03:59.319 --> 00:04:02.589 align:start position:0%
argument is not an integer value but
rather<00:04:00.000><c> object</c><00:04:00.599><c> with</c><00:04:00.799><c> the</c><00:04:01.000><c> key</c><00:04:01.560><c> value</c><00:04:01.920><c> of</c>

00:04:02.589 --> 00:04:02.599 align:start position:0%
rather object with the key value of
 

00:04:02.599 --> 00:04:04.390 align:start position:0%
rather object with the key value of
pointing<00:04:03.040><c> to</c><00:04:03.280><c> the</c><00:04:03.480><c> previously</c><00:04:03.959><c> defined</c>

00:04:04.390 --> 00:04:04.400 align:start position:0%
pointing to the previously defined
 

00:04:04.400 --> 00:04:06.750 align:start position:0%
pointing to the previously defined
callback<00:04:05.159><c> function</c><00:04:06.159><c> this</c><00:04:06.319><c> means</c><00:04:06.560><c> that</c>

00:04:06.750 --> 00:04:06.760 align:start position:0%
callback function this means that
 

00:04:06.760 --> 00:04:08.550 align:start position:0%
callback function this means that
actually<00:04:07.040><c> internally</c><00:04:07.840><c> to</c><00:04:08.040><c> retrieve</c><00:04:08.400><c> the</c>

00:04:08.550 --> 00:04:08.560 align:start position:0%
actually internally to retrieve the
 

00:04:08.560 --> 00:04:10.550 align:start position:0%
actually internally to retrieve the
value<00:04:08.959><c> the</c><00:04:09.120><c> Callback</c><00:04:09.599><c> function</c><00:04:10.200><c> must</c><00:04:10.400><c> be</c>

00:04:10.550 --> 00:04:10.560 align:start position:0%
value the Callback function must be
 

00:04:10.560 --> 00:04:13.589 align:start position:0%
value the Callback function must be
first<00:04:10.920><c> invoked</c><00:04:11.680><c> and</c><00:04:11.840><c> its</c><00:04:12.159><c> return</c><00:04:12.400><c> value</c><00:04:12.680><c> used</c>

00:04:13.589 --> 00:04:13.599 align:start position:0%
first invoked and its return value used
 

00:04:13.599 --> 00:04:15.030 align:start position:0%
first invoked and its return value used
as<00:04:13.680><c> you</c><00:04:13.799><c> may</c><00:04:13.920><c> have</c><00:04:14.040><c> guessed</c><00:04:14.319><c> by</c><00:04:14.480><c> this</c><00:04:14.599><c> point</c>

00:04:15.030 --> 00:04:15.040 align:start position:0%
as you may have guessed by this point
 

00:04:15.040 --> 00:04:17.349 align:start position:0%
as you may have guessed by this point
the<00:04:15.200><c> ab.</c><00:04:15.799><c> resize</c><00:04:16.280><c> call</c><00:04:16.759><c> that</c><00:04:16.880><c> is</c><00:04:17.000><c> within</c><00:04:17.239><c> the</c>

00:04:17.349 --> 00:04:17.359 align:start position:0%
the ab. resize call that is within the
 

00:04:17.359 --> 00:04:19.110 align:start position:0%
the ab. resize call that is within the
Callback<00:04:17.840><c> function</c><00:04:18.280><c> is</c><00:04:18.400><c> going</c><00:04:18.519><c> to</c><00:04:18.600><c> be</c><00:04:18.720><c> a</c><00:04:18.880><c> key</c>

00:04:19.110 --> 00:04:19.120 align:start position:0%
Callback function is going to be a key
 

00:04:19.120 --> 00:04:21.110 align:start position:0%
Callback function is going to be a key
part<00:04:19.359><c> of</c><00:04:19.519><c> this</c><00:04:19.720><c> bug</c><00:04:20.280><c> so</c><00:04:20.400><c> let's</c><00:04:20.600><c> see</c><00:04:20.759><c> how</c><00:04:20.919><c> this</c>

00:04:21.110 --> 00:04:21.120 align:start position:0%
part of this bug so let's see how this
 

00:04:21.120 --> 00:04:23.110 align:start position:0%
part of this bug so let's see how this
actually<00:04:21.400><c> plays</c><00:04:21.639><c> out</c><00:04:21.840><c> in</c><00:04:22.040><c> practice</c><00:04:22.680><c> I'm</c><00:04:22.800><c> using</c>

00:04:23.110 --> 00:04:23.120 align:start position:0%
actually plays out in practice I'm using
 

00:04:23.120 --> 00:04:25.629 align:start position:0%
actually plays out in practice I'm using
UTM<00:04:23.600><c> on</c><00:04:23.800><c> Mac</c><00:04:23.960><c> OS</c><00:04:24.320><c> here</c><00:04:24.720><c> to</c><00:04:24.960><c> actually</c><00:04:25.240><c> install</c>

00:04:25.629 --> 00:04:25.639 align:start position:0%
UTM on Mac OS here to actually install
 

00:04:25.639 --> 00:04:27.350 align:start position:0%
UTM on Mac OS here to actually install
the<00:04:25.759><c> older</c><00:04:26.120><c> version</c><00:04:26.479><c> of</c><00:04:26.639><c> Mac</c><00:04:26.800><c> OS</c><00:04:27.040><c> so</c><00:04:27.160><c> we</c><00:04:27.240><c> can</c>

00:04:27.350 --> 00:04:27.360 align:start position:0%
the older version of Mac OS so we can
 

00:04:27.360 --> 00:04:29.430 align:start position:0%
the older version of Mac OS so we can
run<00:04:27.560><c> the</c><00:04:27.680><c> vulnerable</c><00:04:28.160><c> version</c><00:04:28.720><c> of</c><00:04:28.919><c> JavaScript</c>

00:04:29.430 --> 00:04:29.440 align:start position:0%
run the vulnerable version of JavaScript
 

00:04:29.440 --> 00:04:31.510 align:start position:0%
run the vulnerable version of JavaScript
core<00:04:29.840><c> within</c><00:04:30.080><c> Safari</c><00:04:30.800><c> you</c><00:04:30.919><c> can</c><00:04:31.080><c> also</c><00:04:31.320><c> just</c>

00:04:31.510 --> 00:04:31.520 align:start position:0%
core within Safari you can also just
 

00:04:31.520 --> 00:04:34.510 align:start position:0%
core within Safari you can also just
download<00:04:32.320><c> JavaScript</c><00:04:32.880><c> core</c><00:04:33.520><c> from</c><00:04:33.840><c> GitHub</c><00:04:34.320><c> and</c>

00:04:34.510 --> 00:04:34.520 align:start position:0%
download JavaScript core from GitHub and
 

00:04:34.520 --> 00:04:36.310 align:start position:0%
download JavaScript core from GitHub and
actually<00:04:35.000><c> check</c><00:04:35.240><c> out</c><00:04:35.440><c> to</c><00:04:35.639><c> the</c><00:04:35.759><c> vulnerable</c>

00:04:36.310 --> 00:04:36.320 align:start position:0%
actually check out to the vulnerable
 

00:04:36.320 --> 00:04:38.070 align:start position:0%
actually check out to the vulnerable
commit<00:04:36.759><c> either</c><00:04:37.039><c> way</c><00:04:37.199><c> will</c><00:04:37.400><c> work</c><00:04:37.800><c> so</c><00:04:37.919><c> when</c>

00:04:38.070 --> 00:04:38.080 align:start position:0%
commit either way will work so when
 

00:04:38.080 --> 00:04:39.909 align:start position:0%
commit either way will work so when
executing<00:04:38.479><c> the</c><00:04:38.560><c> javascrip</c><00:04:39.080><c> code</c><00:04:39.600><c> everything</c>

00:04:39.909 --> 00:04:39.919 align:start position:0%
executing the javascrip code everything
 

00:04:39.919 --> 00:04:42.510 align:start position:0%
executing the javascrip code everything
is<00:04:40.080><c> fine</c><00:04:40.400><c> up</c><00:04:40.560><c> until</c><00:04:41.000><c> the</c><00:04:41.199><c> final</c><00:04:41.560><c> line</c><00:04:42.039><c> the</c><00:04:42.199><c> call</c>

00:04:42.510 --> 00:04:42.520 align:start position:0%
is fine up until the final line the call
 

00:04:42.520 --> 00:04:45.390 align:start position:0%
is fine up until the final line the call
to<00:04:42.800><c> copy</c><00:04:43.120><c> within</c><00:04:44.120><c> internally</c><00:04:44.720><c> copy</c><00:04:45.000><c> within</c>

00:04:45.390 --> 00:04:45.400 align:start position:0%
to copy within internally copy within
 

00:04:45.400 --> 00:04:47.629 align:start position:0%
to copy within internally copy within
calls<00:04:45.800><c> into</c><00:04:46.240><c> generic</c><00:04:46.720><c> typed</c><00:04:47.039><c> array</c><00:04:47.320><c> view</c>

00:04:47.629 --> 00:04:47.639 align:start position:0%
calls into generic typed array view
 

00:04:47.639 --> 00:04:50.230 align:start position:0%
calls into generic typed array view
Proto<00:04:48.039><c> Funk</c><00:04:48.320><c> copy</c><00:04:48.600><c> within</c><00:04:49.240><c> which</c><00:04:49.360><c> is</c><00:04:49.479><c> a</c><00:04:49.560><c> C++</c>

00:04:50.230 --> 00:04:50.240 align:start position:0%
Proto Funk copy within which is a C++
 

00:04:50.240 --> 00:04:52.110 align:start position:0%
Proto Funk copy within which is a C++
function<00:04:50.720><c> within</c><00:04:51.000><c> JavaScript</c><00:04:51.520><c> core</c><00:04:51.960><c> this</c>

00:04:52.110 --> 00:04:52.120 align:start position:0%
function within JavaScript core this
 

00:04:52.120 --> 00:04:53.670 align:start position:0%
function within JavaScript core this
function<00:04:52.440><c> first</c><00:04:52.680><c> gets</c><00:04:52.960><c> the</c><00:04:53.080><c> length</c><00:04:53.400><c> of</c><00:04:53.479><c> the</c>

00:04:53.670 --> 00:04:53.680 align:start position:0%
function first gets the length of the
 

00:04:53.680 --> 00:04:55.510 align:start position:0%
function first gets the length of the
array<00:04:53.919><c> buffer</c><00:04:54.400><c> which</c><00:04:54.520><c> at</c><00:04:54.680><c> this</c><00:04:54.800><c> point</c><00:04:55.039><c> is</c><00:04:55.240><c> hex</c>

00:04:55.510 --> 00:04:55.520 align:start position:0%
array buffer which at this point is hex
 

00:04:55.520 --> 00:04:57.310 align:start position:0%
array buffer which at this point is hex
1000<00:04:56.120><c> and</c><00:04:56.240><c> stores</c><00:04:56.520><c> it</c><00:04:56.600><c> in</c><00:04:56.720><c> the</c><00:04:56.800><c> variable</c>

00:04:57.310 --> 00:04:57.320 align:start position:0%
1000 and stores it in the variable
 

00:04:57.320 --> 00:04:59.230 align:start position:0%
1000 and stores it in the variable
length<00:04:58.320><c> and</c><00:04:58.400><c> then</c><00:04:58.520><c> it</c><00:04:58.639><c> gets</c><00:04:58.840><c> each</c><00:04:59.000><c> of</c><00:04:59.120><c> the</c>

00:04:59.230 --> 00:04:59.240 align:start position:0%
length and then it gets each of the
 

00:04:59.240 --> 00:05:01.310 align:start position:0%
length and then it gets each of the
arguments<00:04:59.880><c> passed</c><00:05:00.120><c> into</c><00:05:00.360><c> the</c><00:05:00.479><c> function</c><00:05:01.160><c> by</c>

00:05:01.310 --> 00:05:01.320 align:start position:0%
arguments passed into the function by
 

00:05:01.320 --> 00:05:03.390 align:start position:0%
arguments passed into the function by
reading<00:05:01.720><c> them</c><00:05:01.919><c> off</c><00:05:02.039><c> of</c><00:05:02.160><c> the</c><00:05:02.280><c> call</c><00:05:02.560><c> frame</c><00:05:03.240><c> and</c>

00:05:03.390 --> 00:05:03.400 align:start position:0%
reading them off of the call frame and
 

00:05:03.400 --> 00:05:05.310 align:start position:0%
reading them off of the call frame and
using<00:05:03.720><c> the</c><00:05:03.880><c> function</c><00:05:04.360><c> argument</c><00:05:04.840><c> clamped</c>

00:05:05.310 --> 00:05:05.320 align:start position:0%
using the function argument clamped
 

00:05:05.320 --> 00:05:07.870 align:start position:0%
using the function argument clamped
index<00:05:05.880><c> from</c><00:05:06.080><c> start</c><00:05:06.360><c> or</c><00:05:06.560><c> end</c><00:05:07.320><c> for</c><00:05:07.479><c> the</c><00:05:07.680><c> first</c>

00:05:07.870 --> 00:05:07.880 align:start position:0%
index from start or end for the first
 

00:05:07.880 --> 00:05:09.230 align:start position:0%
index from start or end for the first
argument<00:05:08.280><c> since</c><00:05:08.520><c> this</c><00:05:08.639><c> is</c><00:05:08.720><c> an</c><00:05:08.880><c> integer</c>

00:05:09.230 --> 00:05:09.240 align:start position:0%
argument since this is an integer
 

00:05:09.240 --> 00:05:11.310 align:start position:0%
argument since this is an integer
literal<00:05:09.880><c> the</c><00:05:10.039><c> value</c><00:05:10.320><c> is</c><00:05:10.479><c> simply</c><00:05:10.840><c> retrieved</c>

00:05:11.310 --> 00:05:11.320 align:start position:0%
literal the value is simply retrieved
 

00:05:11.320 --> 00:05:14.110 align:start position:0%
literal the value is simply retrieved
and<00:05:11.639><c> returned</c><00:05:12.240><c> by</c><00:05:12.400><c> calling</c><00:05:12.919><c> value</c><00:05:13.320><c> dot</c><00:05:13.639><c> as</c><00:05:13.840><c> in</c>

00:05:14.110 --> 00:05:14.120 align:start position:0%
and returned by calling value dot as in
 

00:05:14.120 --> 00:05:16.670 align:start position:0%
and returned by calling value dot as in
32<00:05:15.000><c> for</c><00:05:15.160><c> the</c><00:05:15.240><c> second</c><00:05:15.520><c> argument</c><00:05:16.039><c> however</c><00:05:16.520><c> the</c>

00:05:16.670 --> 00:05:16.680 align:start position:0%
32 for the second argument however the
 

00:05:16.680 --> 00:05:18.350 align:start position:0%
32 for the second argument however the
value<00:05:16.919><c> needs</c><00:05:17.120><c> to</c><00:05:17.240><c> be</c><00:05:17.400><c> retrieved</c><00:05:18.039><c> with</c><00:05:18.160><c> the</c>

00:05:18.350 --> 00:05:18.360 align:start position:0%
value needs to be retrieved with the
 

00:05:18.360 --> 00:05:21.270 align:start position:0%
value needs to be retrieved with the
call<00:05:18.800><c> to</c><00:05:19.160><c> two</c><00:05:19.479><c> integer</c><00:05:19.919><c> or</c><00:05:20.160><c> Infinity</c><00:05:21.080><c> which</c>

00:05:21.270 --> 00:05:21.280 align:start position:0%
call to two integer or Infinity which
 

00:05:21.280 --> 00:05:23.469 align:start position:0%
call to two integer or Infinity which
internally<00:05:21.880><c> will</c><00:05:22.080><c> invoke</c><00:05:22.639><c> the</c><00:05:22.919><c> value</c><00:05:23.280><c> of</c>

00:05:23.469 --> 00:05:23.479 align:start position:0%
internally will invoke the value of
 

00:05:23.479 --> 00:05:25.350 align:start position:0%
internally will invoke the value of
callback<00:05:23.960><c> function</c><00:05:24.440><c> and</c><00:05:24.680><c> execute</c><00:05:25.120><c> our</c>

00:05:25.350 --> 00:05:25.360 align:start position:0%
callback function and execute our
 

00:05:25.360 --> 00:05:27.189 align:start position:0%
callback function and execute our
callback<00:05:25.800><c> JavaScript</c><00:05:26.319><c> function</c><00:05:26.880><c> once</c><00:05:27.080><c> this</c>

00:05:27.189 --> 00:05:27.199 align:start position:0%
callback JavaScript function once this
 

00:05:27.199 --> 00:05:29.909 align:start position:0%
callback JavaScript function once this
is<00:05:27.520><c> returned</c><00:05:28.080><c> we</c><00:05:28.199><c> will</c><00:05:28.400><c> have</c><00:05:28.560><c> a</c><00:05:28.720><c> two</c><00:05:29.080><c> value</c><00:05:29.400><c> of</c>

00:05:29.909 --> 00:05:29.919 align:start position:0%
is returned we will have a two value of
 

00:05:29.919 --> 00:05:32.870 align:start position:0%
is returned we will have a two value of
hex2<00:05:30.680><c> from</c><00:05:30.880><c> the</c><00:05:31.039><c> integer</c><00:05:31.440><c> literal</c><00:05:32.360><c> and</c><00:05:32.440><c> a</c><00:05:32.560><c> from</c>

00:05:32.870 --> 00:05:32.880 align:start position:0%
hex2 from the integer literal and a from
 

00:05:32.880 --> 00:05:35.230 align:start position:0%
hex2 from the integer literal and a from
value<00:05:33.199><c> of</c><00:05:33.440><c> zero</c><00:05:34.080><c> but</c><00:05:34.280><c> with</c><00:05:34.440><c> the</c><00:05:34.600><c> added</c><00:05:34.960><c> side</c>

00:05:35.230 --> 00:05:35.240 align:start position:0%
value of zero but with the added side
 

00:05:35.240 --> 00:05:37.390 align:start position:0%
value of zero but with the added side
effect<00:05:35.520><c> of</c><00:05:35.639><c> the</c><00:05:35.800><c> array</c><00:05:36.120><c> buffer</c><00:05:36.880><c> having</c><00:05:37.160><c> been</c>

00:05:37.390 --> 00:05:37.400 align:start position:0%
effect of the array buffer having been
 

00:05:37.400 --> 00:05:40.390 align:start position:0%
effect of the array buffer having been
resized<00:05:38.319><c> down</c><00:05:38.479><c> to</c><00:05:38.759><c> zero</c><00:05:39.479><c> the</c><00:05:39.639><c> ability</c><00:05:40.039><c> to</c><00:05:40.199><c> use</c>

00:05:40.390 --> 00:05:40.400 align:start position:0%
resized down to zero the ability to use
 

00:05:40.400 --> 00:05:42.309 align:start position:0%
resized down to zero the ability to use
a<00:05:40.560><c> callback</c><00:05:41.000><c> function</c><00:05:41.360><c> in</c><00:05:41.520><c> this</c><00:05:41.720><c> way</c><00:05:42.120><c> to</c>

00:05:42.309 --> 00:05:42.319 align:start position:0%
a callback function in this way to
 

00:05:42.319 --> 00:05:44.350 align:start position:0%
a callback function in this way to
modify<00:05:42.759><c> the</c><00:05:42.880><c> source</c><00:05:43.240><c> array</c><00:05:43.639><c> during</c><00:05:43.919><c> the</c><00:05:44.080><c> copy</c>

00:05:44.350 --> 00:05:44.360 align:start position:0%
modify the source array during the copy
 

00:05:44.360 --> 00:05:46.270 align:start position:0%
modify the source array during the copy
operation<00:05:45.160><c> is</c><00:05:45.319><c> not</c><00:05:45.520><c> in</c><00:05:45.759><c> itself</c><00:05:46.160><c> a</c>

00:05:46.270 --> 00:05:46.280 align:start position:0%
operation is not in itself a
 

00:05:46.280 --> 00:05:48.070 align:start position:0%
operation is not in itself a
vulnerability<00:05:47.280><c> there</c><00:05:47.400><c> could</c><00:05:47.560><c> be</c><00:05:47.720><c> perfectly</c>

00:05:48.070 --> 00:05:48.080 align:start position:0%
vulnerability there could be perfectly
 

00:05:48.080 --> 00:05:50.189 align:start position:0%
vulnerability there could be perfectly
legiate<00:05:48.560><c> reasons</c><00:05:48.919><c> for</c><00:05:49.080><c> this</c><00:05:49.199><c> to</c><00:05:49.440><c> occur</c><00:05:50.000><c> in</c>

00:05:50.189 --> 00:05:50.199 align:start position:0%
legiate reasons for this to occur in
 

00:05:50.199 --> 00:05:52.230 align:start position:0%
legiate reasons for this to occur in
real<00:05:50.440><c> world</c><00:05:50.840><c> JavaScript</c><00:05:51.360><c> execution</c><00:05:51.960><c> so</c><00:05:52.120><c> the</c>

00:05:52.230 --> 00:05:52.240 align:start position:0%
real world JavaScript execution so the
 

00:05:52.240 --> 00:05:54.110 align:start position:0%
real world JavaScript execution so the
webkit<00:05:52.639><c> developers</c><00:05:53.120><c> are</c><00:05:53.280><c> already</c><00:05:53.680><c> aware</c><00:05:53.919><c> of</c>

00:05:54.110 --> 00:05:54.120 align:start position:0%
webkit developers are already aware of
 

00:05:54.120 --> 00:05:56.189 align:start position:0%
webkit developers are already aware of
this<00:05:54.759><c> and</c><00:05:54.880><c> they</c><00:05:55.000><c> do</c><00:05:55.199><c> attempt</c><00:05:55.440><c> to</c><00:05:55.639><c> implement</c><00:05:56.039><c> a</c>

00:05:56.189 --> 00:05:56.199 align:start position:0%
this and they do attempt to implement a
 

00:05:56.199 --> 00:05:58.590 align:start position:0%
this and they do attempt to implement a
check<00:05:56.720><c> and</c><00:05:56.880><c> fix</c><00:05:57.160><c> for</c><00:05:57.360><c> this</c><00:05:57.520><c> specific</c><00:05:57.880><c> scenario</c>

00:05:58.590 --> 00:05:58.600 align:start position:0%
check and fix for this specific scenario
 

00:05:58.600 --> 00:06:00.110 align:start position:0%
check and fix for this specific scenario
JavaScript<00:05:59.080><c> core</c><00:05:59.319><c> recog</c><00:05:59.600><c> recognizes</c><00:06:00.000><c> that</c>

00:06:00.110 --> 00:06:00.120 align:start position:0%
JavaScript core recog recognizes that
 

00:06:00.120 --> 00:06:02.110 align:start position:0%
JavaScript core recog recognizes that
the<00:06:00.199><c> length</c><00:06:00.520><c> has</c><00:06:00.720><c> changed</c><00:06:01.160><c> in</c><00:06:01.319><c> this</c><00:06:01.520><c> case</c><00:06:02.000><c> and</c>

00:06:02.110 --> 00:06:02.120 align:start position:0%
the length has changed in this case and
 

00:06:02.120 --> 00:06:04.150 align:start position:0%
the length has changed in this case and
it<00:06:02.240><c> does</c><00:06:02.440><c> update</c><00:06:02.800><c> it</c><00:06:03.000><c> accordingly</c><00:06:03.520><c> to</c><00:06:03.720><c> reflect</c>

00:06:04.150 --> 00:06:04.160 align:start position:0%
it does update it accordingly to reflect
 

00:06:04.160 --> 00:06:06.950 align:start position:0%
it does update it accordingly to reflect
the<00:06:04.319><c> new</c><00:06:04.960><c> array</c><00:06:05.319><c> length</c><00:06:05.639><c> of</c><00:06:05.840><c> zero</c><00:06:06.440><c> JavaScript</c>

00:06:06.950 --> 00:06:06.960 align:start position:0%
the new array length of zero JavaScript
 

00:06:06.960 --> 00:06:08.870 align:start position:0%
the new array length of zero JavaScript
core<00:06:07.240><c> then</c><00:06:07.400><c> also</c><00:06:07.720><c> attempts</c><00:06:08.080><c> to</c><00:06:08.199><c> check</c><00:06:08.680><c> that</c>

00:06:08.870 --> 00:06:08.880 align:start position:0%
core then also attempts to check that
 

00:06:08.880 --> 00:06:10.629 align:start position:0%
core then also attempts to check that
the<00:06:09.039><c> amount</c><00:06:09.280><c> of</c><00:06:09.440><c> elements</c><00:06:09.759><c> to</c><00:06:09.880><c> be</c><00:06:10.080><c> copied</c>

00:06:10.629 --> 00:06:10.639 align:start position:0%
the amount of elements to be copied
 

00:06:10.639 --> 00:06:12.990 align:start position:0%
the amount of elements to be copied
still<00:06:10.919><c> fits</c><00:06:11.360><c> within</c><00:06:11.599><c> the</c><00:06:11.720><c> array</c><00:06:12.080><c> bounds</c><00:06:12.720><c> since</c>

00:06:12.990 --> 00:06:13.000 align:start position:0%
still fits within the array bounds since
 

00:06:13.000 --> 00:06:14.870 align:start position:0%
still fits within the array bounds since
obviously<00:06:13.280><c> it</c><00:06:13.400><c> could</c><00:06:13.479><c> have</c><00:06:13.599><c> shrunk</c><00:06:14.319><c> and</c><00:06:14.560><c> the</c>

00:06:14.870 --> 00:06:14.880 align:start position:0%
obviously it could have shrunk and the
 

00:06:14.880 --> 00:06:17.150 align:start position:0%
obviously it could have shrunk and the
amount<00:06:15.280><c> that</c><00:06:15.400><c> would</c><00:06:15.599><c> be</c><00:06:15.759><c> copied</c><00:06:16.280><c> could</c><00:06:16.599><c> exceed</c>

00:06:17.150 --> 00:06:17.160 align:start position:0%
amount that would be copied could exceed
 

00:06:17.160 --> 00:06:19.390 align:start position:0%
amount that would be copied could exceed
this<00:06:17.400><c> array</c><00:06:17.720><c> bounds</c><00:06:18.360><c> the</c><00:06:18.479><c> count</c><00:06:18.800><c> variable</c><00:06:19.240><c> was</c>

00:06:19.390 --> 00:06:19.400 align:start position:0%
this array bounds the count variable was
 

00:06:19.400 --> 00:06:21.430 align:start position:0%
this array bounds the count variable was
originally<00:06:19.880><c> set</c><00:06:20.479><c> as</c><00:06:20.639><c> the</c><00:06:20.759><c> amount</c><00:06:20.960><c> of</c><00:06:21.080><c> elements</c>

00:06:21.430 --> 00:06:21.440 align:start position:0%
originally set as the amount of elements
 

00:06:21.440 --> 00:06:23.230 align:start position:0%
originally set as the amount of elements
being<00:06:21.680><c> copied</c><00:06:22.120><c> which</c><00:06:22.240><c> was</c><00:06:22.479><c> calculated</c><00:06:23.080><c> by</c>

00:06:23.230 --> 00:06:23.240 align:start position:0%
being copied which was calculated by
 

00:06:23.240 --> 00:06:25.550 align:start position:0%
being copied which was calculated by
taking<00:06:23.759><c> the</c><00:06:23.960><c> length</c><00:06:24.240><c> of</c><00:06:24.360><c> the</c><00:06:24.479><c> array</c><00:06:25.120><c> initially</c>

00:06:25.550 --> 00:06:25.560 align:start position:0%
taking the length of the array initially
 

00:06:25.560 --> 00:06:28.790 align:start position:0%
taking the length of the array initially
hex<00:06:25.840><c> 1000</c><00:06:26.720><c> and</c><00:06:26.880><c> subtracting</c><00:06:27.680><c> hex</c><00:06:27.960><c> 20</c><00:06:28.520><c> we</c><00:06:28.639><c> were</c>

00:06:28.790 --> 00:06:28.800 align:start position:0%
hex 1000 and subtracting hex 20 we were
 

00:06:28.800 --> 00:06:31.629 align:start position:0%
hex 1000 and subtracting hex 20 we were
left<00:06:29.039><c> with</c><00:06:29.240><c> f</c><00:06:29.599><c> e0</c><00:06:30.360><c> as</c><00:06:30.520><c> the</c><00:06:30.680><c> count</c><00:06:30.960><c> value</c>

00:06:31.629 --> 00:06:31.639 align:start position:0%
left with f e0 as the count value
 

00:06:31.639 --> 00:06:32.909 align:start position:0%
left with f e0 as the count value
however<00:06:31.880><c> after</c><00:06:32.080><c> the</c><00:06:32.199><c> length</c><00:06:32.440><c> of</c><00:06:32.560><c> the</c><00:06:32.639><c> array</c>

00:06:32.909 --> 00:06:32.919 align:start position:0%
however after the length of the array
 

00:06:32.919 --> 00:06:34.909 align:start position:0%
however after the length of the array
has<00:06:33.080><c> changed</c><00:06:33.880><c> the</c><00:06:34.000><c> code</c><00:06:34.319><c> now</c><00:06:34.479><c> tries</c><00:06:34.720><c> to</c>

00:06:34.909 --> 00:06:34.919 align:start position:0%
has changed the code now tries to
 

00:06:34.919 --> 00:06:37.790 align:start position:0%
has changed the code now tries to
recalculate<00:06:35.720><c> the</c><00:06:35.880><c> new</c><00:06:36.360><c> value</c><00:06:36.840><c> for</c><00:06:37.080><c> count</c><00:06:37.680><c> we</c>

00:06:37.790 --> 00:06:37.800 align:start position:0%
recalculate the new value for count we
 

00:06:37.800 --> 00:06:40.270 align:start position:0%
recalculate the new value for count we
take<00:06:37.960><c> the</c><00:06:38.120><c> new</c><00:06:38.400><c> length</c><00:06:39.199><c> and</c><00:06:39.360><c> we</c><00:06:39.520><c> subtract</c><00:06:40.080><c> from</c>

00:06:40.270 --> 00:06:40.280 align:start position:0%
take the new length and we subtract from
 

00:06:40.280 --> 00:06:42.830 align:start position:0%
take the new length and we subtract from
it<00:06:40.599><c> the</c><00:06:40.759><c> greater</c><00:06:41.199><c> of</c><00:06:41.440><c> the</c><00:06:41.599><c> two</c><00:06:41.800><c> or</c><00:06:42.039><c> from</c><00:06:42.360><c> index</c>

00:06:42.830 --> 00:06:42.840 align:start position:0%
it the greater of the two or from index
 

00:06:42.840 --> 00:06:44.589 align:start position:0%
it the greater of the two or from index
that<00:06:42.960><c> we're</c><00:06:43.120><c> using</c><00:06:43.400><c> in</c><00:06:43.520><c> the</c><00:06:43.639><c> array</c><00:06:44.319><c> obviously</c>

00:06:44.589 --> 00:06:44.599 align:start position:0%
that we're using in the array obviously
 

00:06:44.599 --> 00:06:47.150 align:start position:0%
that we're using in the array obviously
in<00:06:44.720><c> our</c><00:06:44.960><c> case</c><00:06:45.199><c> we</c><00:06:45.319><c> have</c><00:06:45.440><c> a</c><00:06:45.639><c> length</c><00:06:46.000><c> set</c><00:06:46.280><c> to</c><00:06:46.560><c> zero</c>

00:06:47.150 --> 00:06:47.160 align:start position:0%
in our case we have a length set to zero
 

00:06:47.160 --> 00:06:49.189 align:start position:0%
in our case we have a length set to zero
and<00:06:47.280><c> we're</c><00:06:47.479><c> subtracting</c><00:06:48.120><c> a</c><00:06:48.319><c> value</c><00:06:48.720><c> from</c><00:06:48.880><c> it</c>

00:06:49.189 --> 00:06:49.199 align:start position:0%
and we're subtracting a value from it
 

00:06:49.199 --> 00:06:51.110 align:start position:0%
and we're subtracting a value from it
this<00:06:49.280><c> leads</c><00:06:49.560><c> to</c><00:06:49.759><c> a</c><00:06:49.960><c> very</c><00:06:50.240><c> obvious</c><00:06:50.720><c> integer</c>

00:06:51.110 --> 00:06:51.120 align:start position:0%
this leads to a very obvious integer
 

00:06:51.120 --> 00:06:53.230 align:start position:0%
this leads to a very obvious integer
underflow<00:06:51.919><c> since</c><00:06:52.120><c> there's</c><00:06:52.360><c> no</c><00:06:52.639><c> check</c><00:06:53.080><c> to</c>

00:06:53.230 --> 00:06:53.240 align:start position:0%
underflow since there's no check to
 

00:06:53.240 --> 00:06:54.710 align:start position:0%
underflow since there's no check to
ensure<00:06:53.680><c> that</c><00:06:53.800><c> we're</c><00:06:53.960><c> not</c><00:06:54.120><c> subtracting</c>

00:06:54.710 --> 00:06:54.720 align:start position:0%
ensure that we're not subtracting
 

00:06:54.720 --> 00:06:57.150 align:start position:0%
ensure that we're not subtracting
something<00:06:55.120><c> greater</c><00:06:55.440><c> than</c><00:06:55.599><c> the</c><00:06:56.000><c> length</c><00:06:57.000><c> what</c>

00:06:57.150 --> 00:06:57.160 align:start position:0%
something greater than the length what
 

00:06:57.160 --> 00:06:59.270 align:start position:0%
something greater than the length what
happens<00:06:57.479><c> is</c><00:06:57.599><c> we</c><00:06:57.759><c> use</c><00:06:58.039><c> zero</c><00:06:58.400><c> we</c><00:06:58.560><c> subtract</c><00:06:59.039><c> hex</c>

00:06:59.270 --> 00:06:59.280 align:start position:0%
happens is we use zero we subtract hex
 

00:06:59.280 --> 00:07:00.230 align:start position:0%
happens is we use zero we subtract hex
20

00:07:00.230 --> 00:07:00.240 align:start position:0%
20
 

00:07:00.240 --> 00:07:02.270 align:start position:0%
20
and<00:07:00.400><c> we're</c><00:07:00.599><c> left</c><00:07:00.879><c> with</c><00:07:01.039><c> a</c><00:07:01.199><c> count</c><00:07:01.479><c> value</c><00:07:01.800><c> of</c><00:07:01.960><c> a</c>

00:07:02.270 --> 00:07:02.280 align:start position:0%
and we're left with a count value of a
 

00:07:02.280 --> 00:07:04.790 align:start position:0%
and we're left with a count value of a
very<00:07:02.560><c> very</c><00:07:02.800><c> large</c><00:07:03.080><c> integer</c><00:07:03.919><c> lots</c><00:07:04.080><c> of</c><00:07:04.240><c> fs</c><00:07:04.639><c> and</c>

00:07:04.790 --> 00:07:04.800 align:start position:0%
very very large integer lots of fs and
 

00:07:04.800 --> 00:07:07.150 align:start position:0%
very very large integer lots of fs and
then<00:07:05.039><c> e</c><00:07:05.319><c> z</c><00:07:05.599><c> at</c><00:07:05.720><c> the</c><00:07:05.840><c> end</c><00:07:06.280><c> the</c><00:07:06.440><c> JavaScript</c><00:07:06.879><c> core</c>

00:07:07.150 --> 00:07:07.160 align:start position:0%
then e z at the end the JavaScript core
 

00:07:07.160 --> 00:07:09.430 align:start position:0%
then e z at the end the JavaScript core
code<00:07:07.599><c> fails</c><00:07:07.919><c> to</c><00:07:08.080><c> notice</c><00:07:08.520><c> this</c><00:07:09.039><c> and</c><00:07:09.199><c> is</c>

00:07:09.430 --> 00:07:09.440 align:start position:0%
code fails to notice this and is
 

00:07:09.440 --> 00:07:11.430 align:start position:0%
code fails to notice this and is
actually<00:07:09.840><c> at</c><00:07:10.000><c> this</c><00:07:10.199><c> point</c><00:07:10.720><c> satisfied</c><00:07:11.280><c> to</c>

00:07:11.430 --> 00:07:11.440 align:start position:0%
actually at this point satisfied to
 

00:07:11.440 --> 00:07:13.990 align:start position:0%
actually at this point satisfied to
continue<00:07:11.840><c> on</c><00:07:12.280><c> with</c><00:07:12.479><c> the</c><00:07:12.680><c> m</c><00:07:13.000><c> move</c><00:07:13.319><c> call</c><00:07:13.879><c> which</c>

00:07:13.990 --> 00:07:14.000 align:start position:0%
continue on with the m move call which
 

00:07:14.000 --> 00:07:15.909 align:start position:0%
continue on with the m move call which
will<00:07:14.199><c> carry</c><00:07:14.440><c> out</c><00:07:14.639><c> the</c><00:07:14.840><c> actual</c><00:07:15.160><c> memory</c><00:07:15.639><c> copy</c>

00:07:15.909 --> 00:07:15.919 align:start position:0%
will carry out the actual memory copy
 

00:07:15.919 --> 00:07:17.749 align:start position:0%
will carry out the actual memory copy
operation<00:07:16.599><c> when</c><00:07:16.720><c> we</c><00:07:16.919><c> reach</c><00:07:17.160><c> the</c><00:07:17.280><c> men</c><00:07:17.520><c> move</c>

00:07:17.749 --> 00:07:17.759 align:start position:0%
operation when we reach the men move
 

00:07:17.759 --> 00:07:19.589 align:start position:0%
operation when we reach the men move
call<00:07:18.440><c> what</c><00:07:18.560><c> is</c><00:07:18.720><c> actually</c><00:07:18.960><c> happening</c><00:07:19.319><c> is</c><00:07:19.440><c> we're</c>

00:07:19.589 --> 00:07:19.599 align:start position:0%
call what is actually happening is we're
 

00:07:19.599 --> 00:07:24.710 align:start position:0%
call what is actually happening is we're
doing<00:07:19.960><c> a</c><00:07:20.280><c> large</c><00:07:20.720><c> copy</c><00:07:21.479><c> with</c><00:07:21.639><c> a</c><00:07:21.919><c> size</c><00:07:22.360><c> of</c><00:07:22.919><c> FFF</c><00:07:23.919><c> e0</c>

00:07:24.710 --> 00:07:24.720 align:start position:0%
doing a large copy with a size of FFF e0
 

00:07:24.720 --> 00:07:26.350 align:start position:0%
doing a large copy with a size of FFF e0
this<00:07:24.840><c> obviously</c><00:07:25.160><c> causes</c><00:07:25.520><c> a</c><00:07:25.639><c> huge</c><00:07:25.840><c> overflow</c><00:07:26.240><c> on</c>

00:07:26.350 --> 00:07:26.360 align:start position:0%
this obviously causes a huge overflow on
 

00:07:26.360 --> 00:07:28.710 align:start position:0%
this obviously causes a huge overflow on
the<00:07:26.440><c> Heap</c><00:07:27.080><c> and</c><00:07:27.360><c> webkit</c><00:07:27.840><c> will</c><00:07:28.039><c> crash</c><00:07:28.400><c> with</c><00:07:28.560><c> a</c>

00:07:28.710 --> 00:07:28.720 align:start position:0%
the Heap and webkit will crash with a
 

00:07:28.720 --> 00:07:30.390 align:start position:0%
the Heap and webkit will crash with a
segmentation<00:07:29.199><c> Force</c><00:07:29.960><c> having</c><00:07:30.199><c> this</c>

00:07:30.390 --> 00:07:30.400 align:start position:0%
segmentation Force having this
 

00:07:30.400 --> 00:07:32.390 align:start position:0%
segmentation Force having this
JavaScript<00:07:30.840><c> code</c><00:07:31.039><c> in</c><00:07:31.160><c> a</c><00:07:31.319><c> simple</c><00:07:31.599><c> HTML</c><00:07:32.160><c> file</c>

00:07:32.390 --> 00:07:32.400 align:start position:0%
JavaScript code in a simple HTML file
 

00:07:32.400 --> 00:07:34.469 align:start position:0%
JavaScript code in a simple HTML file
and<00:07:32.479><c> then</c><00:07:32.639><c> opening</c><00:07:33.000><c> the</c><00:07:33.199><c> page</c><00:07:33.440><c> in</c><00:07:33.639><c> Safari</c><00:07:34.400><c> we</c>

00:07:34.469 --> 00:07:34.479 align:start position:0%
and then opening the page in Safari we
 

00:07:34.479 --> 00:07:36.189 align:start position:0%
and then opening the page in Safari we
can<00:07:34.599><c> see</c><00:07:34.759><c> that</c><00:07:34.879><c> Safari</c><00:07:35.319><c> fails</c><00:07:35.680><c> to</c><00:07:35.800><c> load</c><00:07:36.039><c> the</c>

00:07:36.189 --> 00:07:36.199 align:start position:0%
can see that Safari fails to load the
 

00:07:36.199 --> 00:07:38.070 align:start position:0%
can see that Safari fails to load the
page<00:07:36.800><c> and</c><00:07:36.919><c> then</c><00:07:37.039><c> if</c><00:07:37.160><c> we</c><00:07:37.280><c> look</c><00:07:37.479><c> in</c><00:07:37.599><c> the</c><00:07:37.759><c> crash</c>

00:07:38.070 --> 00:07:38.080 align:start position:0%
page and then if we look in the crash
 

00:07:38.080 --> 00:07:41.510 align:start position:0%
page and then if we look in the crash
logs<00:07:38.440><c> of</c><00:07:38.680><c> Mac</c><00:07:38.879><c> OS</c><00:07:39.240><c> we</c><00:07:39.319><c> can</c><00:07:39.479><c> see</c><00:07:40.160><c> that</c><00:07:40.440><c> coma.</c><00:07:41.319><c> web</c>

00:07:41.510 --> 00:07:41.520 align:start position:0%
logs of Mac OS we can see that coma. web
 

00:07:41.520 --> 00:07:44.869 align:start position:0%
logs of Mac OS we can see that coma. web
kit.<00:07:42.080><c> webcontent</c><00:07:43.360><c> crashed</c><00:07:44.360><c> the</c><00:07:44.520><c> patch</c><00:07:44.720><c> for</c>

00:07:44.869 --> 00:07:44.879 align:start position:0%
kit. webcontent crashed the patch for
 

00:07:44.879 --> 00:07:46.749 align:start position:0%
kit. webcontent crashed the patch for
this<00:07:45.000><c> bug</c><00:07:45.280><c> simply</c><00:07:45.680><c> implements</c><00:07:46.080><c> a</c><00:07:46.199><c> check</c><00:07:46.560><c> to</c>

00:07:46.749 --> 00:07:46.759 align:start position:0%
this bug simply implements a check to
 

00:07:46.759 --> 00:07:48.830 align:start position:0%
this bug simply implements a check to
see<00:07:47.120><c> if</c><00:07:47.240><c> the</c><00:07:47.400><c> two</c><00:07:47.599><c> or</c><00:07:47.800><c> from</c><00:07:48.080><c> value</c><00:07:48.360><c> is</c><00:07:48.520><c> greater</c>

00:07:48.830 --> 00:07:48.840 align:start position:0%
see if the two or from value is greater
 

00:07:48.840 --> 00:07:50.469 align:start position:0%
see if the two or from value is greater
than<00:07:48.960><c> the</c><00:07:49.039><c> new</c><00:07:49.280><c> length</c><00:07:49.879><c> and</c><00:07:50.000><c> then</c><00:07:50.120><c> it</c><00:07:50.199><c> will</c>

00:07:50.469 --> 00:07:50.479 align:start position:0%
than the new length and then it will
 

00:07:50.479 --> 00:07:52.350 align:start position:0%
than the new length and then it will
abort<00:07:50.840><c> the</c><00:07:50.960><c> copy</c><00:07:51.240><c> operation</c><00:07:51.680><c> essentially</c><00:07:52.199><c> so</c>

00:07:52.350 --> 00:07:52.360 align:start position:0%
abort the copy operation essentially so
 

00:07:52.360 --> 00:07:54.070 align:start position:0%
abort the copy operation essentially so
that<00:07:52.479><c> we</c><00:07:52.560><c> don't</c><00:07:52.720><c> have</c><00:07:52.840><c> a</c><00:07:52.960><c> subtraction</c><00:07:53.759><c> leading</c>

00:07:54.070 --> 00:07:54.080 align:start position:0%
that we don't have a subtraction leading
 

00:07:54.080 --> 00:07:56.790 align:start position:0%
that we don't have a subtraction leading
to<00:07:54.240><c> an</c><00:07:54.360><c> Ina</c><00:07:54.759><c> underflow</c><00:07:55.759><c> a</c><00:07:55.879><c> bug</c><00:07:56.159><c> like</c><00:07:56.400><c> this</c><00:07:56.560><c> is</c>

00:07:56.790 --> 00:07:56.800 align:start position:0%
to an Ina underflow a bug like this is
 

00:07:56.800 --> 00:07:58.270 align:start position:0%
to an Ina underflow a bug like this is
just<00:07:56.960><c> the</c><00:07:57.120><c> first</c><00:07:57.360><c> building</c><00:07:57.720><c> block</c><00:07:57.960><c> in</c><00:07:58.120><c> what</c>

00:07:58.270 --> 00:07:58.280 align:start position:0%
just the first building block in what
 

00:07:58.280 --> 00:08:00.309 align:start position:0%
just the first building block in what
could<00:07:58.440><c> be</c><00:07:58.639><c> a</c><00:07:58.720><c> full</c><00:07:59.080><c> web</c><00:07:59.599><c> code</c><00:07:59.840><c> execution</c>

00:08:00.309 --> 00:08:00.319 align:start position:0%
could be a full web code execution
 

00:08:00.319 --> 00:08:02.070 align:start position:0%
could be a full web code execution
exploit<00:08:01.080><c> but</c><00:08:01.199><c> this</c><00:08:01.280><c> will</c><00:08:01.400><c> need</c><00:08:01.560><c> to</c><00:08:01.639><c> be</c><00:08:01.800><c> paired</c>

00:08:02.070 --> 00:08:02.080 align:start position:0%
exploit but this will need to be paired
 

00:08:02.080 --> 00:08:04.110 align:start position:0%
exploit but this will need to be paired
with<00:08:02.199><c> a</c><00:08:02.319><c> whole</c><00:08:02.520><c> bunch</c><00:08:02.800><c> of</c><00:08:03.039><c> JavaScript</c><00:08:03.599><c> magic</c>

00:08:04.110 --> 00:08:04.120 align:start position:0%
with a whole bunch of JavaScript magic
 

00:08:04.120 --> 00:08:05.510 align:start position:0%
with a whole bunch of JavaScript magic
to<00:08:04.319><c> create</c><00:08:04.639><c> different</c><00:08:04.919><c> read</c><00:08:05.080><c> and</c><00:08:05.319><c> write</c>

00:08:05.510 --> 00:08:05.520 align:start position:0%
to create different read and write
 

00:08:05.520 --> 00:08:07.309 align:start position:0%
to create different read and write
Primitives<00:08:06.039><c> and</c><00:08:06.159><c> eventually</c><00:08:06.599><c> run</c><00:08:06.800><c> Shell</c><00:08:07.120><c> Code</c>

00:08:07.309 --> 00:08:07.319 align:start position:0%
Primitives and eventually run Shell Code
 

00:08:07.319 --> 00:08:09.149 align:start position:0%
Primitives and eventually run Shell Code
in<00:08:07.479><c> the</c><00:08:07.639><c> context</c><00:08:08.080><c> of</c><00:08:08.240><c> the</c><00:08:08.400><c> web</c><00:08:08.720><c> content</c>

00:08:09.149 --> 00:08:09.159 align:start position:0%
in the context of the web content
 

00:08:09.159 --> 00:08:10.790 align:start position:0%
in the context of the web content
process<00:08:09.800><c> at</c><00:08:09.960><c> that</c><00:08:10.080><c> point</c><00:08:10.280><c> it</c><00:08:10.360><c> could</c><00:08:10.520><c> then</c><00:08:10.639><c> even</c>

00:08:10.790 --> 00:08:10.800 align:start position:0%
process at that point it could then even
 

00:08:10.800 --> 00:08:12.629 align:start position:0%
process at that point it could then even
be<00:08:10.960><c> used</c><00:08:11.199><c> to</c><00:08:11.400><c> execute</c><00:08:11.759><c> a</c><00:08:11.919><c> second</c><00:08:12.280><c> stage</c>

00:08:12.629 --> 00:08:12.639 align:start position:0%
be used to execute a second stage
 

00:08:12.639 --> 00:08:14.790 align:start position:0%
be used to execute a second stage
exploit<00:08:13.159><c> such</c><00:08:13.319><c> as</c><00:08:13.440><c> a</c><00:08:13.560><c> Sandbox</c><00:08:14.000><c> Escape</c><00:08:14.520><c> or</c><00:08:14.680><c> a</c>

00:08:14.790 --> 00:08:14.800 align:start position:0%
exploit such as a Sandbox Escape or a
 

00:08:14.800 --> 00:08:16.950 align:start position:0%
exploit such as a Sandbox Escape or a
kernel<00:08:15.120><c> exploit</c><00:08:15.720><c> leading</c><00:08:16.039><c> to</c><00:08:16.240><c> a</c><00:08:16.360><c> full</c><00:08:16.680><c> system</c>

00:08:16.950 --> 00:08:16.960 align:start position:0%
kernel exploit leading to a full system
 

00:08:16.960 --> 00:08:18.550 align:start position:0%
kernel exploit leading to a full system
compromise<00:08:17.599><c> but</c><00:08:17.720><c> this</c><00:08:17.840><c> is</c><00:08:17.919><c> out</c><00:08:18.080><c> of</c><00:08:18.159><c> the</c><00:08:18.280><c> scope</c>

00:08:18.550 --> 00:08:18.560 align:start position:0%
compromise but this is out of the scope
 

00:08:18.560 --> 00:08:20.430 align:start position:0%
compromise but this is out of the scope
for<00:08:18.680><c> today's</c><00:08:19.039><c> video</c><00:08:19.680><c> all</c><00:08:19.879><c> relevant</c><00:08:20.199><c> links</c>

00:08:20.430 --> 00:08:20.440 align:start position:0%
for today's video all relevant links
 

00:08:20.440 --> 00:08:21.869 align:start position:0%
for today's video all relevant links
will<00:08:20.560><c> be</c><00:08:20.720><c> in</c><00:08:20.800><c> the</c><00:08:20.960><c> description</c><00:08:21.400><c> below</c><00:08:21.680><c> if</c><00:08:21.759><c> you</c>

00:08:21.869 --> 00:08:21.879 align:start position:0%
will be in the description below if you
 

00:08:21.879 --> 00:08:23.469 align:start position:0%
will be in the description below if you
want<00:08:22.000><c> to</c><00:08:22.120><c> check</c><00:08:22.280><c> out</c><00:08:22.440><c> this</c><00:08:22.560><c> bug</c><00:08:22.840><c> yourself</c><00:08:23.199><c> and</c>

00:08:23.469 --> 00:08:23.479 align:start position:0%
want to check out this bug yourself and
 

00:08:23.479 --> 00:08:25.270 align:start position:0%
want to check out this bug yourself and
experiment<00:08:23.840><c> with</c><00:08:23.960><c> it</c><00:08:24.080><c> on</c><00:08:24.199><c> your</c><00:08:24.319><c> own</c><00:08:24.599><c> devices</c>

00:08:25.270 --> 00:08:25.280 align:start position:0%
experiment with it on your own devices
 

00:08:25.280 --> 00:08:26.869 align:start position:0%
experiment with it on your own devices
hope<00:08:25.400><c> you</c><00:08:25.520><c> guys</c><00:08:25.680><c> enjoyed</c><00:08:26.039><c> this</c><00:08:26.199><c> video</c><00:08:26.720><c> thanks</c>

00:08:26.869 --> 00:08:26.879 align:start position:0%
hope you guys enjoyed this video thanks
 

00:08:26.879 --> 00:08:28.350 align:start position:0%
hope you guys enjoyed this video thanks
for<00:08:27.039><c> watching</c><00:08:27.440><c> and</c><00:08:27.560><c> I</c><00:08:27.639><c> will</c><00:08:27.800><c> see</c><00:08:27.960><c> you</c><00:08:28.120><c> in</c><00:08:28.240><c> the</c>

00:08:28.350 --> 00:08:28.360 align:start position:0%
for watching and I will see you in the
 

00:08:28.360 --> 00:08:31.440 align:start position:0%
for watching and I will see you in the
next<00:08:28.520><c> one</c>

