diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md
index 4dee5be3..61187f42 100644
--- a/.github/pull_request_template.md
+++ b/.github/pull_request_template.md
@@ -12,7 +12,7 @@ NOTE:
### Description
-
+
@@ -29,7 +29,7 @@ NOTE:
* [ ] Bug fix (non-breaking change which fixes an issue)
* [ ] New feature (non-breaking change which adds functionality)
* [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
-* [ ] Other (e.g., refactoring, documentation, etc.)
+* [ ] Other (e.g., refactoring, documentation etc.)
diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml
index 4fdee20a..0862a797 100644
--- a/.github/workflows/ubuntu.yml
+++ b/.github/workflows/ubuntu.yml
@@ -59,3 +59,36 @@ jobs:
uses: codecov/codecov-action@v1
with:
fail_ci_if_error: false
+
+ publish:
+ # Run only if the previous job succeeds (only master branch or new tags, no pull requests).
+ if: (endsWith(github.ref, '/master') || startsWith(github.ref, 'refs/tags/v')) && contains(github.event_name, 'pull_request') == false
+ needs: test
+ name: Push updated version to Docker Hub
+ runs-on: ubuntu-latest
+
+ steps:
+ - name: Checkout repository
+ uses: actions/checkout@v2
+
+ - name: Login to DockerHub
+ uses: docker/login-action@v1
+ with:
+ username: claudiugeorgiu
+ password: ${{ secrets.DOCKERHUB_TOKEN }}
+
+ - name: Docker meta
+ id: meta
+ uses: docker/metadata-action@v3
+ with:
+ images: claudiugeorgiu/obfuscapk
+ tags: |
+ type=raw,value=latest
+ type=semver,pattern={{version}}
+
+ - name: Build and push
+ uses: docker/build-push-action@v2
+ with:
+ context: ./src/
+ push: true
+ tags: ${{ steps.meta.outputs.tags }}
diff --git a/.idea/Obfuscapk.iml b/.idea/Obfuscapk.iml
index 5b6fd151..7dd5f0ce 100644
--- a/.idea/Obfuscapk.iml
+++ b/.idea/Obfuscapk.iml
@@ -27,8 +27,9 @@
+
-
+
diff --git a/.idea/misc.xml b/.idea/misc.xml
index 90cb3050..6fccdbfb 100644
--- a/.idea/misc.xml
+++ b/.idea/misc.xml
@@ -3,5 +3,5 @@
-
+
\ No newline at end of file
diff --git a/README.md b/README.md
index 2199d887..fc3de809 100755
--- a/README.md
+++ b/README.md
@@ -6,7 +6,6 @@
[![Ubuntu Build Status](https://github.com/ClaudiuGeorgiu/Obfuscapk/workflows/Ubuntu/badge.svg)](https://github.com/ClaudiuGeorgiu/Obfuscapk/actions?query=workflow%3AUbuntu)
[![Windows Build Status](https://github.com/ClaudiuGeorgiu/Obfuscapk/workflows/Windows/badge.svg)](https://github.com/ClaudiuGeorgiu/Obfuscapk/actions?query=workflow%3AWindows)
[![MacOS Build Status](https://github.com/ClaudiuGeorgiu/Obfuscapk/workflows/MacOS/badge.svg)](https://github.com/ClaudiuGeorgiu/Obfuscapk/actions?query=workflow%3AMacOS)
-[![Docker Hub](https://img.shields.io/docker/cloud/build/claudiugeorgiu/obfuscapk)](https://hub.docker.com/r/claudiugeorgiu/obfuscapk)
[![Python Version](https://img.shields.io/badge/Python-3.7%2B-green.svg?logo=python&logoColor=white)](https://www.python.org/downloads/)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/ClaudiuGeorgiu/Obfuscapk/blob/master/LICENSE)
@@ -119,13 +118,13 @@ have a recent version of Docker installed:
```Shell
$ docker --version
-Docker version 19.03.0, build aeac949
+Docker version 20.10.7, build f0df350
```
#### Official Docker Hub image
The [official Obfuscapk Docker image](https://hub.docker.com/r/claudiugeorgiu/obfuscapk)
-is available on Docker Hub:
+is available on Docker Hub (automatically built from this repository):
```Shell
$ # Download the Docker image.
@@ -500,8 +499,8 @@ functionality.
> This technique analyzes the existing code looking for method invocations of the app,
> ignoring the calls to the Android framework (see `AdvancedReflection`). If it finds
> an instruction with a suitable method invocation (i.e., no constructor methods,
-> public visibility, enough free registers, etc.) such invocation is redirected to
-> a custom method that will invoke the original method using the Reflection APIs.
+> public visibility, enough free registers etc.) such invocation is redirected to a
+> custom method that will invoke the original method using the Reflection APIs.
### [Reorder](https://github.com/ClaudiuGeorgiu/Obfuscapk/tree/master/src/obfuscapk/obfuscators/reorder) \[Code]
diff --git a/src/Dockerfile b/src/Dockerfile
index 3343ba92..f37d64c4 100644
--- a/src/Dockerfile
+++ b/src/Dockerfile
@@ -1,17 +1,17 @@
-FROM python:3.9.0-slim-buster
+FROM python:3.10.1-slim-bullseye
-ENV APKTOOL_VERSION="2.5.0"
+ENV APKTOOL_VERSION="2.6.0"
ENV ANDROID_HOME="/android-sdk-linux"
-ENV BUILD_TOOLS_VERSION="30.0.3"
-ENV PATH="${PATH}:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/build-tools/${BUILD_TOOLS_VERSION}"
+ENV BUILD_TOOLS_VERSION="32.0.0"
+ENV PATH="${PATH}:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/cmdline-tools/bin:${ANDROID_HOME}/build-tools/${BUILD_TOOLS_VERSION}"
# Install the needed tools.
-RUN bash -c 'for i in {1..8}; do mkdir -p "/usr/share/man/man$i"; done' && \
+RUN apt update && \
# Java JDK (needed for apktool).
- apt update && apt install --no-install-recommends -y openjdk-11-jdk-headless wget unzip && \
+ apt install --no-install-recommends -y openjdk-11-jdk-headless wget unzip && \
# Android SDK (needed for zipalign and apksigner).
mkdir -p "${ANDROID_HOME}" && \
- wget -q "https://dl.google.com/android/repository/commandlinetools-linux-6200805_latest.zip" -O android-sdk.zip && \
+ wget -q "https://dl.google.com/android/repository/commandlinetools-linux-7583922_latest.zip" -O android-sdk.zip && \
unzip -q android-sdk.zip -d "${ANDROID_HOME}" && rm android-sdk.zip && \
yes | sdkmanager --sdk_root="${ANDROID_HOME}" "build-tools;${BUILD_TOOLS_VERSION}" && \
# Apktool.
@@ -19,6 +19,9 @@ RUN bash -c 'for i in {1..8}; do mkdir -p "/usr/share/man/man$i"; done' && \
-O /usr/local/bin/apktool && chmod a+x /usr/local/bin/apktool && \
wget -q "https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_${APKTOOL_VERSION}.jar" \
-O /usr/local/bin/apktool.jar && chmod a+x /usr/local/bin/apktool.jar && \
+ # BundleDecompiler.
+ wget -q "https://raw.githubusercontent.com/TamilanPeriyasamy/BundleDecompiler/master/build/libs/BundleDecompiler-0.0.2.jar" \
+ -O /usr/local/bin/BundleDecompiler.jar && chmod a+x /usr/local/bin/BundleDecompiler.jar && \
# Clean.
apt remove --purge -y wget unzip && \
apt autoremove --purge -y && apt clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*