ADB

Discussion in 'Off-topic Discussion' started by sinner76, Mar 20, 2021.

  1. sinner76

    sinner76 Fapstronaut

    649
    892
    93
    On your phone:
    1-Enable Developer mode and enable USB debugging: https://www.howtogeek.com/129728/how-to-access-the-developer-options-menu-and-enable-usb-debugging-on-android-4.2/
    2-Enable: "Disable permission monitoring". This is usually the last option in Developer mode. It's not present in some phones especially the the very old ones:https://pasteboard.co/JF6u4Pn.png

    On Xiaomi phones, also activate USB Debugging (Security Mode) and installations via usb. (not sure if those options are present on other phones)

    3-Change the USB option to Media Device/MTP. You could that after connecting your phone to your PC by a USB cable as you usually get a notification to choose the USB option. You could also swipe down the status bar of your phone to set the USB options after you plug in the phone. If you still can't find it, typing "usb" in the search bar in your settings app could help.

    On your PC:
    1- Download the latest version of ADB ZIP file for windows (13 MB): https://dl.google.com/android/repository/platform-tools-latest-windows.zip
    2-Extract that zip file directly into your C: drive, so that you get a folder named platform-tools in your C: drive.
    3-From windows start menu open cmd
    4-Use the following code in cmd to change the directory to the platform-tools folder(the one in your C: drive):
    Code:
    cd C:\platform-tools
    5-Use this code to check that adb recognizes your device connected by the USB cable:
    Code:
    adb devices
    [​IMG]

    ADB is now connected and ready for action.

    (The first comment contains steps to speed-up your phone's animations and transitions to prevent bypassing blockers and app locks, in addition to, commands to disable and enable system apps including Webview (in-app browsers))

    -To set Test DPC as Device Owner:

    You have to make sure that you have removed all accounts from your phone settings even facebook, reddit and your Google account.
    After you have removed the accounts, run those commands
    Code:
    adb shell
    Code:
    dpm set-device-owner com.afwsamples.testdpc/.DeviceAdminReceiver
    If you get this error, this means you haven't removed all accounts on your device.

    If you made sure that you have removed all accounts but still get the above error, this means that some apps are creating new accounts once you remove them from your phone settings. So wait for those accounts to appear again and execute the adb commands immediately after you remove them. If you still fail in setting Test DPC as device owner, you could try anther provisioning method, but this will wipe your phone:
    https://github.com/googlesamples/android-testdpc#nfc-provisioning-device-owner
     
    Last edited: Sep 16, 2021
  2. sinner76

    sinner76 Fapstronaut

    649
    892
    93
    Other cool uses of ADB:

    A)Using ADB to speed up animations and transitions. (All credits to @Infidel.48 )

    This will make it impossible to bypass blockers and app locks even if you have very fast fingers.
    Code:
    adb shell
    settings put global window_animation_scale 0.25
    settings put global transition_animation_scale 0.25
    settings put global animator_duration_scale 0.25

    B)Using ADB to disable system apps.

    First, you need an app inspector to get the package name of the app you want to disable:
    https://play.google.com/store/apps/details?id=com.ubqsoft.sec01

    To get the package name:https://ibb.co/mtwFKwK

    Using the package name in the screenshot:
    pm disable-user --user 0 com.huawei.compass

    Now, the app should be gone from your phone.

    To re-enable the app:
    adb shell pm enable com.huawei.compass

    Other ideas:

    Getting rid of in-app browsers:

    If you disable android webview app, in-app browsers won't work but some apps won't function properly. You could:
    pm disable-user --user 0 com.google.android.webview

    Some apps use Chrome's custom tabs to open links, so disabling Chrome (com.android.chrome) is also needed to get rid of all in-app browsers.
     
    Last edited: Sep 19, 2021
  3. Abzu

    Abzu Fapstronaut

    65
    1,070
    113
    i am confused, what does this even do?
     
    xXsinnerXx likes this.
  4. sinner76

    sinner76 Fapstronaut

    649
    892
    93
  5. Abzu

    Abzu Fapstronaut

    65
    1,070
    113
    well afaik it can be done without adb or pc, my brother sent me a trick couple of weeks back how to do it, i didn't open the link but he has applied that on his phone
     
    xXsinnerXx likes this.
  6. sinner76

    sinner76 Fapstronaut

    649
    892
    93
    It would be great, if you could share it! This would be extremely helpful!
     
  7. Abzu

    Abzu Fapstronaut

    65
    1,070
    113
    i am sorry man, i was hugely mistaken, it requires adb and all the computer stuff you mentioned.
     
    xXsinnerXx likes this.
  8. sinner76

    sinner76 Fapstronaut

    649
    892
    93
    No problem!
     
  9. ThisIsHard97

    ThisIsHard97 Fapstronaut

    98
    203
    33
    Hi, I have a Redmi Note 9 Pro and I can't find an option called "Disable permission monitoring". The closest thing I've read is Logging Level, which is off (other options are debug or verbose), but I guess it's another thing. Can you help me on this? Thanks in advance.
     
  10. sinner76

    sinner76 Fapstronaut

    649
    892
    93
    Try skipping this step. This option is not present on al phones.
     
    ThisIsHard97 likes this.
  11. The arabian man

    The arabian man Fapstronaut

    5
    3
    3
  12. sinner76

    sinner76 Fapstronaut

    649
    892
    93
    form test DPC app itself
     

Share This Page