scripts/update/hook_durian_update_locationd.js
/*
    Script preparation, needs to be called in standalone usage.
    Separated from constructor for external script usage.
    */
Script preparation, needs to be called in standalone usage.
Separated from constructor for external script usage.
Script preparation needs to be called in standalone usage . Separated from constructor for external script usage .
prepare() {
        var self = this;
        self._locationd_base = Module.getBaseAddress('locationd');
        self._CoreBluetooth_base = Module.getBaseAddress('CoreBluetooth');
        self._objc_msgSend_addr = Module.getExportByName('libobjc.A.dylib', 'objc_msgSend');
        self._objc_msgSend = new NativeFunction(self._objc_msgSend_addr, 'pointer', ['pointer', 'pointer']);
        self.setSymbols(self.ios_version);
        self.showBytes();  
        self.debugStuff();
        self.hookServiceClientDevice();
        self.overwriteSPBeacons();
        self.interceptFirmwareUpdate();
        self.setPacketSize();
    }
prepare ( ) { var self = this ; self . _locationd_base = Module . getBaseAddress ( 'locationd' ) ; self . _CoreBluetooth_base = Module . getBaseAddress ( 'CoreBluetooth' ) ; self . _objc_msgSend_addr = Module . getExportByName ( 'libobjc.A.dylib' , 'objc_msgSend' ) ; self . _objc_msgSend = new NativeFunction ( self . _objc_msgSend_addr , 'pointer' , [ 'pointer' , 'pointer' ] ) ; self . setSymbols ( self . ios_version ) ; self . showBytes ( ) ; self . debugStuff ( ) ; self . hookServiceClientDevice ( ) ; self . overwriteSPBeacons ( ) ; self . interceptFirmwareUpdate ( ) ; self . setPacketSize ( ) ; }
Script preparation, needs to be called in standalone usage.
Script preparation needs to be called in standalone usage .
// some basic addresses // Set the correct symbols // hook sent/received bytes and show them // this one changes the version bytes in L2CAP // hook into exiting global vars // also overwrite the version in a few more places // modify the maximul packet size // print opcode list //self.printOpcodes();