MCPcopy Create free account
hub / github.com/ChendoChap/PS5-Webkit-Execution / malloc

Function malloc

exploit.js:498–511  ·  view source on GitHub ↗
(sz, type = 4)

Source from the content-addressed store, hash-verified

496 }
497
498 function malloc(sz, type = 4) {
499 let backing;
500 if (type == 1) {
501 backing = new Uint8Array(0x10000 + sz);
502 } else if (type == 2) {
503 backing = new Uint16Array(0x10000 + sz);
504 } else if (type == 4) {
505 backing = new Uint32Array(0x10000 + sz);
506 }
507 nogc.push(backing);
508 let ptr = p.read8(p.leakval(backing).add32(0x10));
509 ptr.backing = backing;
510 return ptr;
511 }
512
513 function array_from_address(addr, size) {
514 let og_array = new Uint32Array(0x1000);

Callers

nothing calls this directly

Calls 1

pushMethod · 0.80

Tested by

no test coverage detected