Skip to content

Instantly share code, notes, and snippets.

View jeanbmar's full-sized avatar

Jean-Baptiste Martin jeanbmar

View GitHub Profile
// tested with frida server 12.10.4 on a rooted device
rpc.exports = {
init: function(stage, options) {
Java.perform(function() {
var agent = Process.findModuleByName('libff.so');
var counter = 0;
Interceptor.attach(Module.findExportByName(null, 'open'), function(args) {
if (args[0].readUtf8String().indexOf('frida-agent') >= 0) { // prevent our frida detection based on frida imports
args[0].writeUtf8String('libc.so');
// tested with frida server 12.10.4 on a rooted device
// click top left getflag button to display flag in frida console
function onLoad(name, callback) {
var Runtime = Java.use('java.lang.Runtime');
var System = Java.use('java.lang.System');
var VMStack = Java.use('dalvik.system.VMStack');
var VERSION = Java.use('android.os.Build$VERSION');
System.loadLibrary.overload('java.lang.String').implementation = function(libName) {
if (VERSION.SDK_INT.value >= 29) {
@jeanbmar
jeanbmar / ucssc.cs
Created April 15, 2018 18:23
UCS SC unpacking first version
```
// very old and messy stuff
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.IO;
using System.Drawing;
using System.Drawing.Imaging;
@jeanbmar
jeanbmar / rooting-huawei-honor-6c-pro.md
Last active February 23, 2024 12:48
Rooting Huawei Honor 6C Pro

After searching the whole Internet for 2 days, getting piece of info here and there, this is how I was able to root my Huawei Honor 6C Pro (JMM-L22) successfully:

  1. Enable Android developer options
  2. Enable USB debugging and OEM unlock from Android developer options
  3. From a computer, download Honor 6C Pro stock firmware at http://download-c.huawei.com/download/downloadCenter?downloadId=97622&version=410780&siteCode=ru
  4. From a computer, download Huawei Update Extractor at https://forum.xda-developers.com/showthread.php?t=2433454
  5. Start Huawei Update Extractor and open dload/UPDATE.APP from stock firmware
  6. Right-click BOOT.img and extract it to disk
  7. Transfer BOOT.img to phone storage
  8. From phone, download and install MagiskManager APK at https://forum.xda-developers.com/apps/magisk/official-magisk-v7-universal-systemless-t3473445
  9. Launch MagiskManager, click install, click Patch Boot Image File and select transfered BOOT.img