Large diffs are not rendered by default.

Oops, something went wrong.
@@ -5,6 +5,7 @@
/* global XMLHttpRequest */
var utils = require('./utils');

var SDBCore = require('./sdbcore');
var AsyncCaller = require('./AsyncCaller');
var svcMixin = require('./svc');
var sploitMixin = require('./sploitMixin');
@@ -90,6 +91,15 @@ var SploitCore = function (exploitMe) {

var sc = this;

if (config.sdbcore) {
utils.log('Pwning sdb module...');
this.sdb = new SDBCore(this, this.version);
if(!this.sdb.initialized) {
utils.log('Failed to initialize sdb');
this.sdb = null;
}
}

sc.getServices(["set:sys", "set:fd"], function (setsys, setfd) {
var getSetting = function (session, cls, nam) { // session is set:sys
var out = new Uint32Array(1);
BIN +12 KB nros/ace.nro
Binary file not shown.
@@ -104,6 +104,11 @@ app.get('/minmain.js', function (req, res) {
res.end(fs.readFileSync(path.resolve(__dirname, 'exploit/minmain.js')));
});

app.get('/nros/ace.nro', function (req, res) {
var u8 = new Uint8Array(fs.readFileSync(path.resolve(__dirname, 'nros/ace.nro')));
res.end(JSON.stringify(Array.prototype.slice.call(u8)));
});

app.get('/cache', function (req, res) {
var md5 = crypto.createHash('md5');
md5.update(req.headers['user-agent']);
@@ -5,7 +5,7 @@ sc.write4(0x3052524E, buf);
sc.write8([0x00000350, 0x1], utils.add2(buf, 0x340));
sc.write4(0x1000, utils.add2(buf, 0x338));

var hash = '02bc556cdadb4be3be06b87e8ae7081688bdb57aeb1138d5182f5b2bfe6d48ec';
var hash = '8f6c79e4c65815069ab85964016aa5cea6bd2c83216bb2ea54b6232812b3051f';
sc.memview(utils.add2(buf, 0x350), hash.length / 2, function(ab) {
var u8 = new Uint8Array(ab);
for(var i = 0; i < hash.length; i += 2)
@@ -37,6 +37,7 @@ sc.write8(nrobase, sc.getAddr(temp), 4);
temp.set(u32);
sc.write8(ta, sc.getAddr(temp), 4);

sc.svcNroBase = sc.ipcMsg(0).data(0, nrobase, 0x3000, [0, 0], 0).sendPid().sendTo('ldr:ro').show().data[1];
var t = sc.ipcMsg(0).data(0, nrobase, 0x3000, [0, 0], 0).sendPid().sendTo('ldr:ro').assertOk();
sc.nroBase = [t.data[0], t.data[1]];

utils.log('NRO loaded at ' + utils.paddr(sc.svcNroBase));