Skip to content

Instantly share code, notes, and snippets.

@anestisb
anestisb / art_10.0_cdex_converter.patch
Created January 11, 2020 07:32
Cdex to Dex converter utility using AOSP ART libdexlayout
diff --git a/dexlayout/Android.bp b/dexlayout/Android.bp
index 838510be37..34186d85d7 100644
--- a/dexlayout/Android.bp
+++ b/dexlayout/Android.bp
@@ -132,6 +132,30 @@ cc_defaults {
],
}
+cc_defaults {
+ name: "compact_dex_converter_defaults",
@anestisb
anestisb / art_9.0_compact_dex_converter.patch
Last active October 24, 2024 07:27
Cdex to Dex converter utility using AOSP ART libdexlayout
diff --git a/dexlayout/Android.bp b/dexlayout/Android.bp
index 33ba58f..f3b2a7e 100644
--- a/dexlayout/Android.bp
+++ b/dexlayout/Android.bp
@@ -74,6 +74,13 @@ cc_defaults {
],
}
+cc_defaults {
+ name: "compact_dex_converter_defaults",
@anestisb
anestisb / art_9.0_oatdump_cdex.patch
Last active September 28, 2019 06:10
Patch for Android Pie ART oatdump to convert CompactDex to StandardDex before exporting
diff --git a/oatdump/Android.bp b/oatdump/Android.bp
index 71e276d..3d50229 100644
--- a/oatdump/Android.bp
+++ b/oatdump/Android.bp
@@ -35,6 +35,7 @@ art_cc_binary {
shared_libs: [
"libart",
"libart-compiler",
+ "libart-dexlayout",
"libart-disassembler",
@anestisb
anestisb / oatdump_unquicken.patch
Last active April 14, 2024 17:36
oatdump vdex unquicken
project art/
diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc
index a8ab7c6..2bb04a2 100644
--- a/compiler/driver/compiler_driver.cc
+++ b/compiler/driver/compiler_driver.cc
@@ -442,7 +442,7 @@ void CompilerDriver::CompileAll(jobject class_loader,
// We do not decompile a RETURN_VOID_NO_BARRIER into a RETURN_VOID, as the quickening
// optimization does not depend on the boot image (the optimization relies on not
// having final fields in a class, which does not change for an app).
diff -ru vendor/build.prop /fast-datavault/aosp_prod/out_release_Linux_8.0.0_r3/aosp_prod/target/product/sailfish/vendor/build.prop
--- vendor/build.prop 2009-01-01 10:00:00.000000000 +0200
+++ /fast-datavault/aosp_prod/out_release_Linux_8.0.0_r3/aosp_prod/target/product/sailfish/vendor/build.prop 2017-09-13 10:44:54.183680870 +0300
@@ -1,7 +1,7 @@
-ro.vendor.build.date=Thu Aug 17 20:24:24 UTC 2017
-ro.vendor.build.date.utc=1503001464
-ro.vendor.build.fingerprint=google/sailfish/sailfish:8.0.0/OPR6.170623.012/4283428:user/release-keys
+ro.vendor.build.date=Wed Sep 13 10:44:19 EEST 2017
+ro.vendor.build.date.utc=1505288659
--{ ./system/system/app/BasicDreams/BasicDreams.apk
Signer #1 certificate DN: CN=Android, OU=Android, O=Google Inc., L=Mountain View, ST=California, C=US
Signer #1 certificate SHA-256 digest: c566bebb895d29ebac0667d01dbe2bae5a4aa48947a8a1de8cdf208071a78387
Signer #1 certificate SHA-1 digest: 0d5987e059aa81028dcfa77c66030b669d8ed341
Signer #1 certificate MD5 digest: 2fbc68366c72b5d09065d44a1b44f40b
--{ ./system/system/app/Bluetooth/Bluetooth.apk
Signer #1 certificate DN: CN=Android, OU=Android, O=Google Inc., L=Mountain View, ST=California, C=US
Signer #1 certificate SHA-256 digest: 3ec1c473761c98da4933abd33d6d79f9cd88a954e300a389c93503cc47b4f75e
Signer #1 certificate SHA-1 digest: b841566dc2b469f31114bb271714b5dca644fd80

Keybase proof

I hereby claim:

  • I am anestisb on github.
  • I am anestisb (https://keybase.io/anestisb) on keybase.
  • I have a public key whose fingerprint is B144 C357 6031 F568 21C6 614C AAFF 72FE 2F4B B5DB

To claim this, I am signing this object:

@anestisb
anestisb / Simp.py
Created August 24, 2016 11:05 — forked from xerub/Simp.py
AArch64 mov simplifier IDA plugin
# AArch64 mov simplifier IDA plugin
#
# Copyright (c) 2015 xerub
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,

This is an overview of the usefulness of PaX/grsecurity features for CopperheadOS especially when taking into account the overlap of the access control features with SELinux and that the Nexus line will be entirely 64-bit ARM. Note that it's missing most of the unnamed features without configuration options tied to them. A grsecurity kernel also comes with lots of security bug fixes backported from master, adapted from lkml submissions that were ignored, etc.

Previously, CopperheadOS used ports of PaX to the 3.4 Android kernels used by the Nexus 5 and Galaxy S4. The plan was to start from there, backporting from the PaX stable patches as needed along with reimplementing the relevant pieces of grsecurity without actually applying an old patch and backporting to it.

This is no longer the case for the published releases now that devices have moved to 64-bit ARM (which is not supported by PaX / grsecurity yet) and both the PaX and grsecurity stable patches have become private. There are still PaX ports for test

@anestisb
anestisb / DexGuardDecoder.java
Created February 9, 2016 09:23 — forked from AKosterin/DexGuardDecoder.java
New Dexguard String decoder for JEB 1.5. Tested on GFE 3.1.3. This release auto parse decoder function.
import jeb.api.IScript;
import jeb.api.JebInstance;
import jeb.api.ast.*;
import jeb.api.ast.Class;
import jeb.api.dex.*;
import jeb.api.ui.JavaView;
import jeb.api.ui.View;
import java.util.Arrays;
import java.util.HashMap;