Below are the ADB commands for removing Samsung Knox Guard (KG) and Mobile Device Management (MDM) locks. These commands are essential for bypassing restrictions and restoring full access to your Samsung device. Stay tuned for more tips and guides on mobile software repair and troubleshooting!
adb shell pm uninstall user 0 com.android.systemui
adb shell pm uninstall user 0 com.samsung.klmsagent
adb shell pm uninstall user 0 com.android.ons
adb shell pm uninstall user 0 com.android.dynsystem
adb shell pm uninstall user 0 com.samsung.android.app.updatecenter
adb shell pm uninstall user 0 com.google.android.configupdater
adb shell pm uninstall user 0 com.wssyncmldm
adb shell pm uninstall user 0 com.sec.enterprise.knox.cloudmdm.smdms
adb shell am set-inactive com.samsung.android.kgclient true
adb shell am kill com.samsung.android.kgclient
adb shell am crash com.samsung.android.kgclient
adb shell am stop-app com.samsung.android.kgclient
adb shell pm uninstall-system-updates com.samsung.android.kgclient
adb shell pm disable-user user 0 com.samsung.android.kgclient
adb shell pm enable user 0 com.samsung.android.kgclient
adb shell pm uninstall-system-updates com.samsung.android.kgclient
adb shell pm suspend com.samsung.android.kgclient
adb shell pm uninstall user 0 com.samsung.android.kgclient
adb shell pm install-existing restrict-permissions user 0 com.samsung.android.kgclient
adb shell cmd appops set com.samsung.android.kgclient RUN_IN_BACKGROUND ignore
adb shell cmd appops set com.samsung.android.kgclient RUN_IN_BACKGROUND ignore
adb shell pm suspend com.samsung.android.kgclient
adb shell cmd appops set com.samsung.android.kgclient RUN_IN_BACKGROUND ignore
adb shell am set-inactive com.samsung.android.kgclient true
adb shell am kill com.samsung.android.kgclient
adb shell am crash com.samsung.android.kgclient
adb shell am stop-app com.samsung.android.kgclient
adb shell cmd appops set com.samsung.android.kgclient RUN_IN_BACKGROUND deny
adb shell cmd appops set com.samsung.android.kgclient RUN_ANY_IN_BACKGROUND deny
adb shell cmd appops set com.samsung.android.kgclient WAKE_LOCK deny
adb shell cmd appops set com.samsung.android.kgclient POST_NOTIFICATION deny
adb shell cmd appops set com.samsung.android.kgclient ACCESS_RESTRICTED_SETTINGS deny
adb shell cmd appops set com.samsung.android.kgclient SCHEDULE_EXACT_ALARM deny
adb shell cmd appops set com.samsung.android.kgclient BLUETOOTH_CONNECT deny
adb shell cmd appops set com.samsung.android.kgclient SYSTEM_EXEMPT_FROM_DISMISSIBLE_NOTIFICATIONS deny
adb shell pm install-existing restrict-permissions user 0 com.android.systemui
adb shell pm uninstall user 0 com.google.android.setupwizard
adb install hitech.apk
adb shell dpm set-device-owner com.afwsamples.testdpc/.DeviceAdminReceiver
adb reboot
enjoy