mirror of
https://github.com/MobSF/Mobile-Security-Framework-MobSF.git
synced 2026-10-12 02:06:59 +00:00
* Improve setup scripts. * Python support to 3.8 - 3.10 * Delete MobSF data directory on running setup. * Bump applicable dependencies.
35 lines
1.2 KiB
Batchfile
35 lines
1.2 KiB
Batchfile
@echo off
|
|
echo =======================MobSF Clean Script for Windows=======================
|
|
echo Running this script will delete the Scan database, all files uploaded and generated.
|
|
SET mobsf_home="%userprofile%\.MobSF"
|
|
SET mypath=%~dp0
|
|
echo %mypath:~0,-1%
|
|
IF "%~1"=="y" (
|
|
echo Deleting all uploads
|
|
rmdir "mobsf\uploads" /q /s >nul 2>&1
|
|
echo Deleting all downloads
|
|
rmdir "mobsf\downloads" /q /s >nul 2>&1
|
|
echo Deleting Static Analyzer migrations
|
|
rmdir "mobsf\StaticAnalyzer\migrations" /q /s >nul 2>&1
|
|
echo Deleting Dynamic Analyzer migrations
|
|
rmdir "mobsf\DynamicAnalyzer\migrations" /q /s >nul 2>&1
|
|
echo Deleting MobSF migrations
|
|
rmdir "mobsf\MobSF\migrations" /q /s >nul 2>&1
|
|
echo Deleting temp and log files
|
|
del /f "mobsf\debug.log" >nul 2>&1
|
|
del /f "classes*" >nul 2>&1
|
|
echo Deleting Scan database
|
|
del /f "mobsf\db.sqlite3" >nul 2>&1
|
|
echo Deleting Secret file
|
|
del /f "mobsf\secret" >nul 2>&1
|
|
echo Deleting Previous setup files
|
|
rmdir "%UserProfile%\MobSF" /q /s >nul 2>&1
|
|
del /f "mobsf\setup_done.txt" >nul 2>&1
|
|
echo Deleting MobSF data directory: %mobsf_home%
|
|
del /f "%mobsf_home%" /q /s >nul 2>&1
|
|
echo Done
|
|
) ELSE (
|
|
echo Please run script from mobsf.MobSF directory
|
|
echo 'scripts/clean.bat y
|
|
)
|