-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
18 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -83,28 +83,24 @@ jobs: | |
# releaseName: "${{ env.ANDROID_VERSION_CODE }} (${{ env.ANDROID_VERSION_NAME }})" | ||
# status: completed | ||
|
||
- name: mobile security framework | ||
run: | | ||
docker pull opensecurity/mobile-security-framework-mobsf | ||
docker run -itd -p 8000:8000 opensecurity/mobile-security-framework-mobsf:latest | ||
cd output | ||
ls -al | ||
wget http://localhost:8000/api_docs | ||
MOBSF_API_KEY=$(grep 'Api Key' api_docs) | ||
echo MOBSF_API_KEY | ||
MOBSF_API_KEY=${MOBSF_API_KEY:37:64} | ||
echo MOBSF_API_KEY | ||
rm api_docs | ||
HASH=$(md5sum remote.apk) | ||
echo 6 | ||
HASH=${HASH:0:32} | ||
echo 7 | ||
curl -F "[email protected]" http://localhost:8000/api/v1/upload -H "Authorization:$MOBSF_API_KEY" | ||
echo 8 | ||
curl -X POST --url http://localhost:8000/api/v1/scan --data "scan_type=apk&file_name=remote.apk&hash=$HASH" -H "Authorization:$MOBSF_API_KEY" | ||
echo 9 | ||
curl -X POST --url http://localhost:8000/api/v1/download_pdf --data "hash=$HASH" -H "Authorization:$MOBSF_API_KEY" --output remote-${{ steps.version.outputs.id }}.pdf | ||
ls -al | ||
# - name: mobile security framework | ||
# run: | | ||
# docker pull opensecurity/mobile-security-framework-mobsf | ||
# docker run -itd -p 8000:8000 opensecurity/mobile-security-framework-mobsf:latest | ||
# cd output | ||
# ls -al | ||
3 wget http://localhost:8000/api_docs | ||
# MOBSF_API_KEY=$(grep 'Api Key' api_docs) | ||
# echo MOBSF_API_KEY | ||
# MOBSF_API_KEY=${MOBSF_API_KEY:42:64} | ||
# echo MOBSF_API_KEY | ||
# rm api_docs | ||
# HASH=$(md5sum remote.apk) | ||
# HASH=${HASH:0:32} | ||
# curl -F "[email protected]" http://localhost:8000/api/v1/upload -H "Authorization:$MOBSF_API_KEY" | ||
# curl -X POST --url http://localhost:8000/api/v1/scan --data "scan_type=apk&file_name=remote.apk&hash=$HASH" -H "Authorization:$MOBSF_API_KEY" | ||
# curl -X POST --url http://localhost:8000/api/v1/download_pdf --data "hash=$HASH" -H "Authorization:$MOBSF_API_KEY" --output remote-${{ steps.version.outputs.id }}.pdf | ||
# ls -al | ||
|
||
- name: rename APK and AAB with version and branch for artifact | ||
if: github.ref != 'refs/heads/master' | ||
|