qt: Request Android permissions on APi >= 23 #20814

pull BlockMechanic wants to merge 4 commits into bitcoin:master from BlockMechanic:Fix-Android-Permissions changing 1 files +36 −0
  1. BlockMechanic commented at 9:41 AM on December 31, 2020: contributor

    Starting from Android 6.0 (API 23), users are not asked for permissions at the time of installation rather apps need to request for the permissions at run time. Note : Only the permissions that are defined in the manifest file can be requested at run time.

    see :- Permissions

  2. Request Android permissions on APi >= 23
    Starting from Android 6.0 (API 23), users are not asked for permissions at the time of installation rather apps need to request for the permissions at run time. Note : Only the permissions that are defined in the manifest file can be requested at run time.
    1240fa31af
  3. MarcoFalke renamed this:
    Request Android permissions on APi >= 23
    qt: Request Android permissions on APi >= 23
    on Dec 31, 2020
  4. Fix include aafd9e59a5
  5. DrahtBot added the label GUI on Dec 31, 2020
  6. DrahtBot commented at 3:45 PM on December 31, 2020: member

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--174a7506f384e20aa4161008e828411d-->

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #19471 (util: Make default arg values more specific by hebasto)

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  7. in src/qt/bitcoin.cpp:544 in aafd9e59a5 outdated
     539 | +            if(result != QtAndroid::PermissionResult::Granted) // or maybe == QtAndroid::PermissionResult::Denied
     540 | +            {
     541 | +                auto resultHash = QtAndroid::requestPermissionsSync(QStringList({permission}));
     542 | +                if(resultHash[permission] == QtAndroid::PermissionResult::Denied){
     543 | +					//if(QtAndroid::shouldShowRequestPermissionRationale(permissions)){
     544 | +					    QMessageBox::information(this, "Info", "This permission is requested and required for Xequium to work.");
    


    practicalswift commented at 4:00 PM on December 31, 2020:

    What is Xequium?

  8. Update bitcoin.cpp dbc1c3234e
  9. Update bitcoin.cpp b806c62ca0
  10. in src/qt/bitcoin.cpp:70 in aafd9e59a5 outdated
      65 |  #endif
      66 |  #endif
      67 |  
      68 | +#if defined (Q_OS_ANDROID)
      69 | +#include <QtAndroidExtras/QtAndroid>
      70 | +const QVector<QString> permissions({"android.permission.ACCESS_COARSE_LOCATION",
    


    practicalswift commented at 4:07 PM on December 31, 2020:

    Why should Bitcoin Core ever request the user's location?

    The permission list looks like a security/privacy nightmare TBH :)


    BlockMechanic commented at 9:11 PM on December 31, 2020:

    The permissions list may require review to ensure it is safe. This whole process raises concerns, and questions as to whether permissions are a one time thing or whether they should be requested everytime, as well as management if the process in the background. Due to costs of mobile data, some users may want to opt for wi-fi only or only allowing network access when they are actually using the app. Permissions will be headache IMO but no way around it for newer android versions.

  11. BlockMechanic commented at 1:11 AM on January 2, 2021: contributor

    This seems to be very finnicky across different devices. Closing for now while i figure out a more resilient method.

  12. BlockMechanic closed this on Jan 2, 2021

  13. DrahtBot locked this on Aug 16, 2022

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-21 18:14 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me