briar issueshttps://code.briarproject.org/briar/briar/-/issues2021-04-12T13:18:14Zhttps://code.briarproject.org/briar/briar/-/issues/57Detect DB durability failures2021-04-12T13:18:14ZakwizgranDetect DB durability failuresIf the app or device crashes, the database may fail to store data durably:
http://www.h2database.com/html/advanced.html#durability_problems
This may cause a wide range of problems, including data sync bugs where a peer believes we've s...If the app or device crashes, the database may fail to store data durably:
http://www.h2database.com/html/advanced.html#durability_problems
This may cause a wide range of problems, including data sync bugs where a peer believes we've stored some data because we acked it, but we failed to store the data durably. The peer won't ever resend the acked data.
To detect durability problems, store a flag in the DB indicating whether the DB is dirty. At startup, if the DB is dirty then a crash has occurred. Otherwise mark the DB dirty before handling the first transaction. At shutdown, mark the DB clean after handling the last transaction.
If a crash is detected then we can attempt to recover from any problems it may have caused, for example by asking peers to forget about any acks we've sent.
This approach relies on the assumption that if transaction A is committed before transaction B is started, it's not possible for the database to durably store transaction B but not transaction A. Is that a safe assumption?Adapt to changes in the Android platformSebastianSebastian2021-04-30https://code.briarproject.org/briar/briar/-/issues/1114Show when user feedback has been received2021-07-06T10:03:53ZakwizgranShow when user feedback has been receivedA user asked to be shown when their feedback was received.A user asked to be shown when their feedback was received.Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1720ACRA 4.11 crashes during init with targetSdkVersion set to R (30)2021-01-06T12:31:44ZakwizgranACRA 4.11 crashes during init with targetSdkVersion set to R (30)Looks like we'll need to migrate to ACRA 5 before targetting API 30. The crash doesn't happen on the API 30 emulator with targetSdkVersion set to 29, so this isn't urgent.
```
2020-03-31 11:02:33.685 25167-25167/org.briarproject.briar.a...Looks like we'll need to migrate to ACRA 5 before targetting API 30. The crash doesn't happen on the API 30 emulator with targetSdkVersion set to 29, so this isn't urgent.
```
2020-03-31 11:02:33.685 25167-25167/org.briarproject.briar.android.debug E/AndroidRuntime: FATAL EXCEPTION: main
Process: org.briarproject.briar.android.debug, PID: 25167
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/android/internal/util/Predicate;
at org.acra.util.IOUtils.streamToString(IOUtils.java:84)
at org.acra.ACRA.getCurrentProcessName(ACRA.java:303)
at org.acra.ACRA.isACRASenderServiceProcess(ACRA.java:294)
at org.acra.ACRA.init(ACRA.java:210)
at org.acra.ACRA.init(ACRA.java:173)
at org.acra.ACRA.init(ACRA.java:157)
at org.acra.ACRA.init(ACRA.java:140)
at org.briarproject.briar.android.BriarApplicationImpl.attachBaseContext(BriarApplicationImpl.java:100)
at android.app.Application.attach(Application.java:351)
at android.app.Instrumentation.newApplication(Instrumentation.java:1159)
at android.app.LoadedApk.makeApplication(LoadedApk.java:1203)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6521)
at android.app.ActivityThread.access$1300(ActivityThread.java:229)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1885)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:216)
at android.app.ActivityThread.main(ActivityThread.java:7464)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:549)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:955)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.android.internal.util.Predicate" on path: DexPathList[[zip file "/data/app/~~g6kWDR95CtejUwuMSRctEg==/org.briarproject.briar.android.debug-C8FXbrMV6GsjIoTVns77-A==/base.apk"],nativeLibraryDirectories=[/data/app/~~g6kWDR95CtejUwuMSRctEg==/org.briarproject.briar.android.debug-C8FXbrMV6GsjIoTVns77-A==/lib/x86, /system/lib, /system_ext/lib, /product/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:202)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
at org.acra.util.IOUtils.streamToString(IOUtils.java:84)
at org.acra.ACRA.getCurrentProcessName(ACRA.java:303)
at org.acra.ACRA.isACRASenderServiceProcess(ACRA.java:294)
at org.acra.ACRA.init(ACRA.java:210)
at org.acra.ACRA.init(ACRA.java:173)
at org.acra.ACRA.init(ACRA.java:157)
at org.acra.ACRA.init(ACRA.java:140)
at org.briarproject.briar.android.BriarApplicationImpl.attachBaseContext(BriarApplicationImpl.java:100)
at android.app.Application.attach(Application.java:351)
at android.app.Instrumentation.newApplication(Instrumentation.java:1159)
at android.app.LoadedApk.makeApplication(LoadedApk.java:1203)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6521)
at android.app.ActivityThread.access$1300(ActivityThread.java:229)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1885)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:216)
at android.app.ActivityThread.main(ActivityThread.java:7464)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:549)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:955)
```Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1743Research whether our wake lock tags are still effective2021-09-01T10:10:21ZakwizgranResearch whether our wake lock tags are still effectiveLeave Briar running on devices with recent versions of Huawei PowerGenie and Evenwell PowerMonitor to see whether our wake lock tags still protect us from being killed.Leave Briar running on devices with recent versions of Huawei PowerGenie and Evenwell PowerMonitor to see whether our wake lock tags still protect us from being killed.Adapt to changes in the Android platformakwizgranakwizgran2021-04-30https://code.briarproject.org/briar/briar/-/issues/1753API 30: Access to installed packages is restricted2021-01-12T11:22:23ZakwizgranAPI 30: Access to installed packages is restrictedWhen we target API 30 we'll need to make changes to retain the ability to check whether power management apps are installed:
https://medium.com/androiddevelopers/package-visibility-in-android-11-cc857f221cd9
* [x] `AndroidTorPlugin`: `...When we target API 30 we'll need to make changes to retain the ability to check whether power management apps are installed:
https://medium.com/androiddevelopers/package-visibility-in-android-11-cc857f221cd9
* [x] `AndroidTorPlugin`: `pm.getPackageInfo(app.getPackageName(), 0)`
* [x] `AndroidWakeLockManagerImpl`: `packageName.startsWith()`
* [x] `PanicPreferencesFragment`: `pm.getApplicationInfo(panicTriggerApp)`
* [x] `PanicPreferencesFragment`: `intent.resolveActivity(pm)`
* [x] `PanicPreferencesFragment`: `PanicResponder.resolveTriggerApps(pm)`
* [x] `ScreenFilterMonitorImpl`: `pm.getInstalledPackages(GET_PERMISSIONS)`
* [x] `ScreenFilterMonitorImpl`: `pm.getPackageInfo(PLAY_SERVICES_PACKAGE, GET_SIGNATURES)`
* [x] `SettingsFragment`: `intent.resolveActivity(pm)`
* [x] `HuaweiView`: `pm.queryIntentActivities(i, PackageManager.MATCH_DEFAULT_ONLY)`
* [x] `KeyAgreementActivity`: `Intent(ACTION_REQUEST_DISCOVERABLE).resolveActivity(pm)`
* [x] `LinkDialogFragment`: `pm.queryIntentActivities()`Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1793Feedback screen has wrong title in screen reader2021-07-06T10:03:53ZakwizgranFeedback screen has wrong title in screen readerWhen opening the feedback screen, the TalkBack screen reader reads the title as "Briar crash reporter". I'm guessing this is the default title for the activity and it's changed to "Feedback" after the point where the screen reader reads ...When opening the feedback screen, the TalkBack screen reader reads the title as "Briar crash reporter". I'm guessing this is the default title for the activity and it's changed to "Feedback" after the point where the screen reader reads the title.Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1819Crash if screen is rotated during setup and "Create Account" is tapped twice2021-07-06T10:03:53ZakwizgranCrash if screen is rotated during setup and "Create Account" is tapped twiceI got the following crash on the Nokia 3.1 (Android 10) while trying to reproduce another bug. During setup, I rotated the screen to landscape and back to portrait after tapping "Create Account", which caused the progress wheel to disapp...I got the following crash on the Nokia 3.1 (Android 10) while trying to reproduce another bug. During setup, I rotated the screen to landscape and back to portrait after tapping "Create Account", which caused the progress wheel to disappear and the "Create Account" button to reappear. I tapped the button again and Briar crashed:
```
2020-10-29 10:58:16.219 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Destroying StartupActivity
2020-10-29 10:58:16.224 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Stopping SplashScreenActivity
2020-10-29 10:58:16.229 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Destroying SplashScreenActivity
2020-10-29 10:58:28.199 10998-11087/org.briarproject.briar.android.debug I/SetupControllerImpl: Creating account
2020-10-29 10:58:28.380 10998-11087/org.briarproject.briar.android.debug I/IdentityManagerImpl: Creating identity took 178 ms
2020-10-29 10:58:28.381 10998-11087/org.briarproject.briar.android.debug I/IdentityManagerImpl: Identity registered
2020-10-29 10:58:29.328 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Pausing SetupActivity
2020-10-29 10:58:29.343 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Stopping SetupActivity
2020-10-29 10:58:29.412 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Destroying SetupActivity
2020-10-29 10:58:29.614 10998-11087/org.briarproject.briar.android.debug I/ScryptKdf: KDF cost parameter 8192
2020-10-29 10:58:30.015 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Creating SetupActivity
2020-10-29 10:58:30.087 10998-11087/org.briarproject.briar.android.debug I/ScryptKdf: Deriving key from password took 472 ms
2020-10-29 10:58:30.213 10998-11087/org.briarproject.briar.android.debug I/AndroidKeyStrengthener: Loaded key from keystore
2020-10-29 10:58:30.338 10998-11087/org.briarproject.briar.android.debug I/AccountManagerImpl: Storing database key in file
2020-10-29 10:58:30.341 10998-11087/org.briarproject.briar.android.debug I/AccountManagerImpl: Created database key directory
2020-10-29 10:58:30.344 10998-11087/org.briarproject.briar.android.debug I/AccountManagerImpl: Stored database key in backup file
2020-10-29 10:58:30.345 10998-11087/org.briarproject.briar.android.debug I/AccountManagerImpl: Renamed backup file to primary
2020-10-29 10:58:30.347 10998-11087/org.briarproject.briar.android.debug I/AccountManagerImpl: Stored second copy of database key in backup file
2020-10-29 10:58:30.354 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Starting SetupActivity
2020-10-29 10:58:30.366 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Resuming SetupActivity
2020-10-29 10:58:33.257 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Pausing SetupActivity
2020-10-29 10:58:33.261 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Stopping SetupActivity
2020-10-29 10:58:33.288 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Destroying SetupActivity
2020-10-29 10:58:33.623 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Creating SetupActivity
2020-10-29 10:58:33.968 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Starting SetupActivity
2020-10-29 10:58:33.980 10998-10998/org.briarproject.briar.android.debug I/BaseActivity: Resuming SetupActivity
2020-10-29 10:58:36.130 10998-11087/org.briarproject.briar.android.debug I/SetupControllerImpl: Creating account
2020-10-29 10:58:36.132 10998-11087/org.briarproject.briar.android.debug E/AndroidRuntime: FATAL EXCEPTION: pool-3-thread-1
Process: org.briarproject.briar.android.debug, PID: 10998
java.lang.AssertionError: Already have a database key
at org.briarproject.bramble.account.AccountManagerImpl.createAccount(AccountManagerImpl.java:169)
at org.briarproject.briar.android.account.SetupControllerImpl.lambda$createAccount$0$SetupControllerImpl(SetupControllerImpl.java:111)
at org.briarproject.briar.android.account.-$$Lambda$SetupControllerImpl$bM_lMydguKzowB8BXIvR9b0joQw.run(Unknown Source:8)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:919)
```Adapt to changes in the Android platformIvanaIvana2021-04-30https://code.briarproject.org/briar/briar/-/issues/1821Bluetooth setup screen2021-08-31T13:11:23ZakwizgranBluetooth setup screenReflected transport properties should enable most devices to learn their own Bluetooth addresses, but there's still a bootstrapping problem when a group of two or more contacts are all running Android 8.1+ and none of them added each oth...Reflected transport properties should enable most devices to learn their own Bluetooth addresses, but there's still a bootstrapping problem when a group of two or more contacts are all running Android 8.1+ and none of them added each other via Bluetooth.
We could solve this by adding a "Bluetooth setup" workflow. If the user activates the Bluetooth plugin and we don't know the device's address, we tell the user that Bluetooth needs to be set up and that they need a contact nearby to help with this. When both users are ready, we perform discovery, show a list of devices, and ask the users to pick each other's devices. If the devices succeed in making a connection they'll learn each other's addresses and exchange them via reflected transport properties.Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1824Adapt to power management restrictions2021-04-30T13:42:29ZakwizgranAdapt to power management restrictionsAdapt to changes in the Android platform2021-04-30https://code.briarproject.org/briar/briar/-/issues/1826Finish migrating SettingsFragment to ViewModel2021-04-01T13:22:18ZakwizgranFinish migrating SettingsFragment to ViewModelA ViewModel for Settings has been introduced in #214 ([`214-user-avatars`](https://code.briarproject.org/briar/briar/-/tree/214-user-avatars)). The rest of the non-UI logic should get migrated there and exposed via LiveData.
Subtask of ...A ViewModel for Settings has been introduced in #214 ([`214-user-avatars`](https://code.briarproject.org/briar/briar/-/tree/214-user-avatars)). The rest of the non-UI logic should get migrated there and exposed via LiveData.
Subtask of #1823.Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1827Raise target API level to 302021-05-05T16:08:09ZakwizgranRaise target API level to 30Adapt to changes in the Android platform2021-04-30https://code.briarproject.org/briar/briar/-/issues/1861Remove calls to WifiManager#getConfiguredNetworks()2021-01-06T12:31:58ZakwizgranRemove calls to WifiManager#getConfiguredNetworks()AndroidSecureRandomProvider calls WifiManager#getConfiguredNetworks() at startup. This call requires ACCESS_FINE_LOCATION on API 30. Remove this call, and any other calls to this method.
Subtask of #1827.AndroidSecureRandomProvider calls WifiManager#getConfiguredNetworks() at startup. This call requires ACCESS_FINE_LOCATION on API 30. Remove this call, and any other calls to this method.
Subtask of #1827.Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1865Migrate SetupController to ViewModel2021-04-06T12:40:15ZTorsten GroteMigrate SetupController to ViewModelSubtask of #1800Subtask of #1800Adapt to changes in the Android platformDaniel LublinDaniel Lublin2021-04-30https://code.briarproject.org/briar/briar/-/issues/1866Migrate BlogController and FeedController to ViewModel2021-10-29T12:05:09ZTorsten GroteMigrate BlogController and FeedController to ViewModelBoth controllers share code in BaseController.
Subtask of #1800Both controllers share code in BaseController.
Subtask of #1800Adapt to changes in the Android platformIvanaIvana2021-04-30https://code.briarproject.org/briar/briar/-/issues/1867Introduce ViewModel for ContactListFragment2021-04-06T12:39:54ZTorsten GroteIntroduce ViewModel for ContactListFragmentThe ContactListFragment does lots of work on the UI level, this should be migrated to a ViewModel scoped to the fragment. See !1327
Subtask of #1823.The ContactListFragment does lots of work on the UI level, this should be migrated to a ViewModel scoped to the fragment. See !1327
Subtask of #1823.Adapt to changes in the Android platformSebastianSebastian2021-04-30https://code.briarproject.org/briar/briar/-/issues/1869Introduce ViewModel for ForumListFragment2021-04-06T12:40:53ZTorsten GroteIntroduce ViewModel for ForumListFragmentThe ForumListFragment does lots of work on the UI level, this should be migrated to a ViewModel scoped to the fragment. See !1327
Subtask of #1823.The ForumListFragment does lots of work on the UI level, this should be migrated to a ViewModel scoped to the fragment. See !1327
Subtask of #1823.Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1870Migrate ForumController to ViewModel2021-04-06T12:40:10ZTorsten GroteMigrate ForumController to ViewModelSubtask of #1800Subtask of #1800Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30https://code.briarproject.org/briar/briar/-/issues/1871Introduce ViewModel for IntroductionActivity (and ContactChooserFragment)2021-05-05T16:08:46ZTorsten GroteIntroduce ViewModel for IntroductionActivity (and ContactChooserFragment)The IntroductionActivity and its two fragments do lots of work on the UI level, this should be migrated to a ViewModel scoped to the activity that both fragments also access.
Subtask of #1823.
Test instructions:
1. Check that contact ...The IntroductionActivity and its two fragments do lots of work on the UI level, this should be migrated to a ViewModel scoped to the activity that both fragments also access.
Subtask of #1823.
Test instructions:
1. Check that contact list used displays correctly
* Go into a conversation
* menu → make introduction
* check that list does not contain the contact you're introducing
2. Check that contact list used updates properly
* On some device (A) repeat steps from 1.
* While the contact selection list is open: use a different device (B) and sent a message to (A). Make sure the number of unread messages displayed on (A) updates and also the contact moves up to the top as it now is the contact with the last recent message
3. Check that selecting a contact works
* Repeat steps from 1.
* select a contact and check that the next screen show the expected contacts
4. Make sure going back to contact selection and repeatedly selecting contacts works as expected
* Repeat steps from 3.
* Navigate back to the list of contacts to introduce your contact to
* Select a different contact than before, check that the next screen show the contact selected the second time
* Just to be sure, try again with a third contact
5. Check screen rotation doesn't break anything
* Repeat steps from 4.
* During navigation, rotate device at different times during the processAdapt to changes in the Android platformIvanaIvana2021-04-30https://code.briarproject.org/briar/briar/-/issues/1872Finish migrating KeyAgreementActivity to ViewModel2021-05-05T16:08:47ZTorsten GroteFinish migrating KeyAgreementActivity to ViewModelThe `KeyAgreementActivity` is abstract and only implemented by `ContactExchangeActivity`. See if both can be merged and more logic moved into `ContactExchangeViewModel`.
`KeyAgreementFragment` is doing lots of work and interactions with...The `KeyAgreementActivity` is abstract and only implemented by `ContactExchangeActivity`. See if both can be merged and more logic moved into `ContactExchangeViewModel`.
`KeyAgreementFragment` is doing lots of work and interactions with briar-core. This should also be moved into the ViewModel.
Subtask of #1823.Adapt to changes in the Android platformIvanaIvana2021-04-30https://code.briarproject.org/briar/briar/-/issues/1873Migrate GroupController to ViewModel2021-04-06T12:40:04ZTorsten GroteMigrate GroupController to ViewModelSubtask of #1800Subtask of #1800Adapt to changes in the Android platformTorsten GroteTorsten Grote2021-04-30