Commit graph

1154 commits

Author SHA1 Message Date
Alexander Bakker ac75c346ec Update translations from Crowdin 2022-11-20 13:23:40 +01:00
Alexander Bakker 5dfdbabf30 Patch scrypt implementation to directly use Java's Integer.rotateLeft
This should improve performance in some rare cases where the wrapper
function that BouncyCastle has for Integer.rotateLeft is not inlined.

See: #1024
2022-11-20 12:54:55 +01:00
Alexander Bakker e7cc3e6ca3 Fix a crash by only creating toasts using Toast.makeText() 2022-11-16 10:48:21 +01:00
Alexander Bakker f081cfa77b Add support for importing 2FAS schema v3 backups
Fixes #1026
2022-11-15 22:44:13 +01:00
Alexander Bakker 55dc4b22d5 Set RESULT_CANCELED before calling finishAffinity()
This fixes a crash in AuthActivity:

Exception java.lang.IllegalStateException: Can not be called to deliver a result
2022-11-12 11:50:01 +01:00
Alexander Bakker 9f55d4f659 Do not print a trace when calling the private finish() overload fails 2022-11-09 20:42:59 +01:00
Alexander Bakker 715c5112ab Fix a crash caused by ViewHolder.getAdapterPosition returning -1 2022-11-09 20:18:18 +01:00
Alexander Bakker e77df1eee4 Set fallbackLineSpacing to false for the OTP TextView
This prevents any dynamic changes in height that may occur while using
tap to reveal on Android 13 and up.
2022-11-09 18:50:38 +01:00
Alexander Bakker f6f549aaeb Be even more clear about why we can't import from certain apps anymore 2022-11-09 18:50:38 +01:00
Alexander Bakker 12dad56fe3 Update test dependencies to stable releases 2022-11-09 15:49:33 +01:00
Alexander Bakker 286d74b69a Switch comments of tile_open_vault and tile_open_scanner 2022-11-07 21:01:11 +01:00
Alexander Bakker 10ecd513fc Add context to tile_open_vault and tile_open_scanner strings 2022-11-07 21:00:08 +01:00
elena c45564d852 Allow exporting specific groups 2022-11-06 18:38:34 +00:00
Alexander Bakker 98e802a534
Merge pull request #1019 from beemdevelopment/feature/quick-settings
Add quick setting tiles
2022-11-06 15:34:10 +01:00
Michael Schättgen 6a1e6db486 Add quick setting tiles 2022-11-06 15:21:33 +01:00
elena 237e6744a5 Add option to hide icons 2022-11-06 13:26:47 +00:00
Alexander Bakker 599be44369
Merge pull request #1017 from orange-elephant/reveal-on-hotp-increment
Reveal hidden code on HOTP increment click
2022-11-06 12:18:40 +01:00
Alexander Bakker b2a98d9799 Release v2.1-beta2 2022-11-03 22:50:55 +01:00
Alexander Bakker bee490d091 Check for nulls when opening ContentResolver streams 2022-11-03 22:41:30 +01:00
Michael Schättgen dd88f5bb0c Fix crash when using non latin language 2022-11-03 13:37:15 +01:00
elena af9be15ae0 Reveal hidden code on HOTP increment click 2022-11-02 21:07:37 +00:00
Alexander Bakker 8562fafda7 Release v2.1-beta1 2022-11-02 17:11:39 +01:00
Alexander Bakker 708a5f4a19 Update translations from Crowdin 2022-11-02 15:45:27 +01:00
Alexander Bakker fcc7b7baa2 Use MaterialDividerItemDecoration for compact view mode
This allows us to disable the divider for the "Showing x entries" footer
2022-11-02 15:18:07 +01:00
Alexander Bakker 7c0b22920d Fix minor entry margin issues
Accidentally introduced with the entry pinning feature

This also moves the favorite field to the vault instead of shared
preference in order to avoid some complexity
2022-11-02 15:14:59 +01:00
Alexander Bakker c27d080a11 Fix call to notifyItemMoved when entry change causes sort change
This fixes an issue introduced in ffcbaffcfc
2022-11-02 15:09:42 +01:00
Alexander Bakker 289b8775d3 Update ZXing to 3.5.1 2022-11-02 12:40:20 +01:00
Alexander Bakker c12397a509 Update dependencies 2022-11-01 20:19:00 +01:00
Alexander Bakker 0aef57e610 Add context to favorite strings to indicate that they're verbs 2022-10-27 22:12:49 +02:00
Alexander Bakker 7993142cc5 Show a warning when a separate export/backup password is configured 2022-10-27 22:12:44 +02:00
Michael Schättgen 5ec1e33a31 Add ability to favorite/pin entries 2022-10-26 14:07:49 +02:00
Alexander Bakker c58b773878 Rename some things related to plaintext backup warning 2022-10-25 18:38:07 +02:00
Alexander Bakker 681326839c Fix back navigation in preferences when pressing the home action button 2022-10-16 13:27:20 +02:00
Alexander Bakker 3d124d225e Use VaultLockReceiver in a Context-registered manner
Turns out we can't listen from ACTION_SCREEN_OFF from a
manifest-registered broadcast receiver
2022-10-15 20:48:36 +02:00
Alexander Bakker 8292173297 Remove unused code for storage read permission request results 2022-10-12 17:39:40 +02:00
Alexander Bakker 84e179f9d3 Add helper to simplify animation end listeners 2022-10-12 17:36:46 +02:00
Alexander Bakker ad77bd687f Add support for predictive back gesture 2022-10-12 17:25:40 +02:00
Alexander Bakker c6888b11df Add an icon to the backup status in preferences 2022-10-10 22:33:42 +02:00
elena c206d4bee8 Additional code grouping options 2022-10-09 21:24:01 +01:00
Alexander Bakker 7de7fba2c8 Disable R8 obfuscation 2022-10-09 18:28:56 +02:00
Alexander Bakker 8ea28327db Optimize APK size by fixing R8 rules and excluding some BC resources 2022-10-09 17:18:13 +02:00
Alexander Bakker 80c37556c7 Prevent double launches of the intro and auth activities
Since API level 33: When opening Aegis right after installing it,
Android will send a configuration change event (CONFIG_ASSETS_PATHS),
causing MainActivity to restart almost immediately. This would also
cause two IntroActivity's to be started on top of eachother.
2022-10-09 16:33:28 +02:00
Alexander Bakker 7517cfc975 Update dependencies 2022-10-09 12:53:46 +02:00
Alexander Bakker 4198ca3bb7 Update Gradle 2022-10-09 12:51:06 +02:00
Alexander Bakker 3927ddec3e Make vault lock intent used in notifications more explicit
Aegis can display a notification to the user as a reminder that the vault is
unlocked. If the user taps the notification, the vault is locked. CodeQL
reported that Aegis may be vulnerable to CWE-927, because of the use of an
implicit intent wrapped by a PendingIntent in that notification.

This does not appear to be exploitable in our case, because we use
``PendingIntent.getBroadcast`` and explicitly set the action of the wrapped
intent. Aegis also does not read or act on any information from the received
intent. This means that a malicious app cannot launch activities or send a
broadcast with a different action, as is common with these type of weakness. The
worst an app with notification access can do, is lock the vault.

Either way, it's good to make the intent explicit, so this patch addresses that.
Additionally, for API level 23 and up, we've made the wrapped intent immutable a
while back.

We'd like to thank John Rune, who ran a CodeQL scan on the Aegis codebase and
privately disclosed this finding to us.
2022-10-09 11:56:09 +02:00
Alexander Bakker adc9179364 Always copy VaultFileCredentials when accessing it
This makes sure that mutations to the credentails can only ever be persisted
intentionally.
2022-10-05 19:42:18 +02:00
Alexander Bakker 8ae8130b71 Store and display backup error messages more clearly 2022-10-05 18:21:50 +02:00
Alexander Bakker 4427498d5e Rename the instrumented tests to be more consistent 2022-10-05 13:44:12 +02:00
Alexander Bakker aad6d78750 Move the panic trigger setting to the Security fragment 2022-10-05 13:27:28 +02:00
Alexander Bakker ef2e803e04 Make the entry count text a bit smaller 2022-10-05 13:25:17 +02:00
Alexander Bakker c718ea79c5 Update dependencies 2022-10-03 19:29:06 +02:00
Alexander Bakker acc6b9a3de
Merge pull request #973 from orange-elephant/entries-shown-count
Add entries showing count
2022-09-28 13:48:35 +02:00
elena 4bf807c46a Add entries showing count 2022-09-23 18:49:23 +01:00
Alexander Bakker e4798703f0 Make the FAB scroll listener a less sensitive
This should help minimize the glitchiness that can occur when scrolling
through the entry list.

Close #963.
2022-09-17 18:27:56 +02:00
Alexander Bakker 80624f844c Perform a version check when importing from the Steam app
Fixes #986.
2022-09-17 18:08:21 +02:00
Maarten Trompper 78feb25543 Minimize or Close app after copying OTP
Close #805
2022-09-17 17:51:03 +02:00
Alexander Bakker 3bc10bd4b8 Disallow importing empty secrets
Fixes #975

And display "ERROR" for any existing bad entries. This is kind of ugly,
but it's better than crashing, and there are probably very few (or zero)
users who have bad entries anyway.
2022-09-17 17:31:59 +02:00
Alexander Bakker 66b7fd38d6
Merge pull request #964 from orange-elephant/google-auth-style-export
Google Authenticator compatible export
2022-09-17 15:46:56 +02:00
elena bc665b6980 Google Authenticator compatible export 2022-09-16 17:57:42 +01:00
Alexander Bakker 06405d10ad Only request the POST_NOTIFICATIONS permission in tests on API 33 2022-09-14 21:36:31 +02:00
Alexander Bakker 1e3ceefeec Request permission to show notifications
This is needed since API 33, because we show a "Vault unlocked"
notification if the user has enabled encryption and has unlocked the
vault.
2022-09-14 20:54:08 +02:00
Alexander Bakker 642864fca1 Mark clipboard data as "sensitive" when copying tokens 2022-09-14 18:33:28 +02:00
Alexander Bakker 3ec6e35011 Update dependencies
This also updates the test dependencies to an alpha version. We have to
use a pre-stable version, because these include some fixes for running
on API 33.
2022-09-14 18:08:47 +02:00
Alexander Bakker e19ceb0761
Merge pull request #981 from jas14/monochromatic-icon
Add monochrome launcher icon
2022-09-14 17:33:53 +02:00
Joe Stein 012b66fe9b Pin Robolectric target SDKs to 32 2022-09-05 17:09:48 -04:00
Joe Stein 4cd0d2de04 Bump targetSdkVersion to 33 2022-09-05 17:09:43 -04:00
Joe Stein bb3f4d733f Add monochrome adaptive icon for Android 13 2022-09-03 23:08:40 -04:00
Maarten Trompper 05a8c7c51f Fixes #794 2022-08-26 20:31:29 +02:00
Alexander Bakker 029ca81bbf Don't catch the IllegalArgumentException when calling getMissingIndices
We always call isSingleBatch beforehand, so if the exception occurs,
it's a bug.
2022-08-22 19:14:51 +02:00
Alexander Bakker 70ceca6a7b
Merge pull request #958 from orange-elephant/fix-scan-google-auth-export-from-image
Import Google Authenticator exports by image
2022-08-22 19:06:59 +02:00
elena 2767727ad4 Import google auth export from image 2022-08-21 18:47:54 +01:00
Alexander Bakker 79022be3b6 Add an import button to the intro 2022-08-17 19:11:35 +02:00
Alexander Bakker dcda668671 Disable postprocessing for debug builds to speed them up 2022-08-17 12:00:17 +02:00
elena 5bb32a982b Enable sharing text to Aegis 2022-08-11 21:32:33 +01:00
Alexander Bakker 85e230c46a
Merge pull request #957 from orange-elephant/add-plaintext-export-warning
Add warning banner after plaintext export
2022-08-11 21:03:20 +02:00
elena 045b8280bf Add warning banner after plaintext export 2022-08-10 17:17:51 +01:00
Alexander Bakker 6fd8a3b6b4 Allow sharing multiple QR code images to Aegis through a single intent
This also refactors the logic for handling incoming intents a bit
2022-08-10 17:48:36 +02:00
Alexander Bakker e46857a26e Add support for importing multiple QR code images in one go
This is also part of the preparation needed for scanning Google
Authenticator Export QR codes from images.
2022-08-10 17:22:09 +02:00
Alexander Bakker b875baacef
Merge pull request #948 from orange-elephant/Add-mOTP-support
Add MOTP support
2022-08-07 18:31:51 +02:00
elena 3441deee64 Add MOTP support 2022-08-07 16:40:08 +01:00
Alexander Bakker bd3697659f Try harder to find QR codes in image files
And refactor a bit by moving some of the QR scanning related logic to a
separate helper class.
2022-08-07 17:13:58 +02:00
Alexander Bakker 5f12eae678 Add tests for scanning QR codes 2022-08-04 21:47:51 +02:00
Alexander Bakker 3b715d58cf
Merge pull request #952 from Hovn/master
Set the searchview to occupy all Toolbar widths when it expands
2022-08-04 18:49:59 +02:00
Alexander Bakker 76245677b0 Downgrade ResourceType linter error to a warning 2022-08-03 22:42:56 +02:00
Alexander Bakker f73a64acd6 Update gradle and dependencies 2022-08-03 20:38:10 +02:00
HovnCompany b4f12af23a Set the searchview to occupy all Toolbar widths when it expands 2022-08-01 16:00:40 +08:00
Alexander Bakker 043b17909c Wait for ViewPager to be idle in instrumented tests
This fixes the flakiness issues with the intro tests
2022-06-06 19:07:02 +02:00
Alexander Bakker 1dcf56a0fa Capture screenshots of failing instrumented tests 2022-06-06 14:52:17 +02:00
Alexander Bakker f32ac0e8ab Make ProgressDialog adhere to the "Secure screen" setting 2022-06-06 14:05:16 +02:00
Alexander Bakker 8d3b2e2c9d Rename slot type DERIVED to PASSWORD 2022-06-06 13:55:19 +02:00
Alexander Bakker 5db365a999 Add instrumented tests for backup and export 2022-06-06 13:19:46 +02:00
Alexander Bakker a492bcbde3 Add an option to set a separate password for backups and exports 2022-06-05 23:03:11 +02:00
Alexander Bakker d40ebf0f67 Use a higher resolution app icon in the intro 2022-06-05 12:33:53 +02:00
Alexander Bakker 1373a67ea0 Only re-sort entry list when not using custom sorting
This fixes a crash introduced in #910.
2022-06-04 19:01:37 +02:00
Alexander Bakker 11d7493245
Merge pull request #924 from CristianAUnisa/double-click-copy-crash
Avoid crash when double clicking on "Copy" button
2022-06-04 14:49:22 +02:00
CristianAUnisa d2f0f71be5 Check if there's a selected item after pressing on an Action menu item 2022-06-04 14:48:14 +02:00
Alexander Bakker 49b334ff70 Show dialog when trying to import from a recent Google Auth version 2022-06-04 14:35:36 +02:00
CristianAUnisa 4cf0465a32 Check if Google Authenticator entry is encrypted 2022-06-04 12:47:44 +02:00
Alexander Bakker 98de86b53e
Merge pull request #910 from CristianAUnisa/sort-on-replace
Sort list after editing entry
2022-05-22 13:36:42 +02:00
CristianAUnisa ffcbaffcfc Sort list after editing entry 2022-05-22 13:19:55 +02:00
Alexander Bakker ce9a15b7bc Allow filtering by "No group"
This is a continuation of #830

Close #826, #830
2022-05-22 13:11:34 +02:00
Alexander Bakker 3b1035b5e1 Reset the action bar subtitle when the back button is pressed 2022-05-22 12:02:23 +02:00
Alexander Bakker 239d8740be
Merge pull request #912 from CristianAUnisa/screen-rotation-bugfix-686
Restore search query on screen rotation
2022-05-22 11:55:01 +02:00
CristianAUnisa 49130cee73 Restore search query on screen rotation 2022-05-07 16:15:30 +02:00
Alexander Bakker 0909341caa Improve QR reader efficiency and support inverted QR codes 2022-05-01 19:22:20 +02:00
Alexander Bakker 81d5915969
Merge pull request #908 from CristianAUnisa/bitwarden-remote
Add Bitwarden importer
2022-04-30 13:13:42 +02:00
CristianAUnisa 8d4a687817 Add Bitwarden importer
Added license notice for Simple Flat Mapper

Added Steam secret support to Bitwarden importer

https://bitwarden.com/help/authenticator-keys/#steam-guard-totps

Added tests
2022-04-24 16:55:38 +02:00
Alexander Bakker b0e8d041d0
Merge pull request #904 from CristianAUnisa/dont-hide-fab-on-keydown
Don't hide "Add entry" button when a DPad key is pressed
2022-04-21 19:00:52 +02:00
CristianAUnisa ca49cd4df5 Don't hide "Add entry" button when DPAD key is pressed 2022-04-21 18:49:41 +02:00
Alexander Bakker beadf4db8b Use requireContext, requireActivity and requirePreference where possible 2022-04-10 18:44:25 +02:00
Alexander Bakker f7b4cceb81 Remove unused SlotAdapter and SlotHolder 2022-04-10 18:14:00 +02:00
Alexander Bakker 86b86fef10 Pass current values to Dialog functions instead of reading from prefs 2022-04-10 17:48:26 +02:00
Alexander Bakker 927ea50c33 Ignore JSON exceptions in getUsageCounts instead of printing them 2022-04-10 17:12:19 +02:00
Alexander Bakker 339a31b0f3 Show a backup reminder if auto backups are not enabled
If the user doesn't have auto backups enabled, the reminder will pop up
up every time a significant change is made to the vault.

Users can get rid of the reminder by:
- Creating an export
- Enabling automatic backups (either ours or Android backups will do)
2022-04-10 17:12:12 +02:00
Alexander Bakker cf9fbf081c Don't print the exception of readVaultFile if the file was not found 2022-04-10 14:46:41 +02:00
Alexander Bakker d4557065ea Disable the MissingQuantity lint check to fix the build 2022-04-10 14:41:55 +02:00
Alexander Bakker d0c8c5fae4 Update Gradle and dependencies 2022-04-09 18:28:15 +02:00
Alexander Bakker b8fa67304a Release v2.0.3
(cherry picked from commit 32ee0915a7)
2022-03-27 21:58:31 +02:00
Alexander Bakker 903948d57c Stop using dependency injection in AegisBackupAgent
Because the app launches in a restricted mode when restoring a backup,
dependency injection with Dagger Hilt doesn't work inside BackupAgent. This
would cause backup restore operations to fail. This issue got introduced by the
recent switch to Dagger Hilt, which has not been included in a release of Aegis
yet.
2022-03-16 14:43:13 +01:00
Alexander Bakker 71eb6b133c Remove SlotManagerActivity from AndroidManifest 2022-03-06 14:54:36 +01:00
Alexander Bakker 6f66706685 Don't pass MIME type along when selecting icon pack file to import
Fixes #757
2022-03-06 13:55:12 +01:00
Alexander Bakker 6d8a8c066c Remove unused string resources 2022-03-06 13:49:40 +01:00
Alexander Bakker baa3cac5a4 Remove slot manager activity
We don't really use this anymore, and it was only available for debug builds anyway
2022-03-06 13:33:57 +01:00
Alexander Bakker 71f2b54deb Use Dagger Hilt for dependency injection
This gets rid of our own janky dependency injection through the AegisApplication class
2022-03-06 13:06:34 +01:00
Alexander Bakker 927f5f2bd5
Merge pull request #845 from Hacker437/Dialog
Updated Delete Dialog
2022-02-27 18:18:56 +01:00
Praveen Kumar c0020684de Change the layout of the entry delete dialog and include more info 2022-02-27 17:46:47 +01:00
Alexander Bakker b8066c1925 Use Aegis icon as lock status notification icon 2022-02-18 12:54:30 +01:00
Alexander Bakker 0f3e5c537c Allow customization of password reminder frequency
Close #769
2022-02-17 18:14:08 +01:00
Alexander Bakker 5ce21a94ea Only skip panic trigger signature check if running under a test 2022-02-17 15:47:27 +01:00
Alexander Bakker d1d5df8051 Add tests for the Ripple panic trigger action 2022-02-17 14:25:32 +01:00
Alexander Bakker b9a81bdd75 Always allow D2D transfers in backup agent 2022-02-17 13:16:05 +01:00
Alexander Bakker 0938d3688a Set dataExtractionRules in AndroidManifest for Android 12+ 2022-02-17 13:16:05 +01:00
Alexander Bakker fcb7bf032b Add support for importing 2FAS schema v2 backups 2022-02-10 20:58:06 +01:00
Alexander Bakker acfb70c267 Move Yandex secret validation tests to a different folder 2022-02-06 12:55:02 +01:00
Alexander Bakker 119c3838e1 Silence lint error related to calling private method through reflection 2022-02-04 21:23:35 +01:00
Alexander Bakker 473cb7bfeb Set FLAG_IMMUTABLE on the intent of the lock status notification
This fixes a crash on API 31
2022-02-02 21:06:21 +01:00
Alexander Bakker 3d13117752 Refactor Yandex support a bit and fix some style issues 2022-02-02 17:55:09 +01:00
Alexander Bakker 76c89f0fcc
Merge pull request #869 from RandomRoot/feature-yandexotp
Feature: Add Yandex OTP support
2022-02-02 13:40:48 +01:00
Alexander Bakker 185e22a82e Downgrade camera-view back to 1.0.0-alpha32
Can't mix and match 1.0.0 and 1.1.0.
2022-01-31 22:07:40 +01:00
Alexander Bakker e88c3ea6db Update dependencies 2022-01-31 21:59:02 +01:00
Mikhail Prokofev af2bf6f683 Add Yandex OTP support 2022-01-26 18:43:55 +03:00
moesheyab f14bd99f63 Fix Aegis import dialog message title 2022-01-16 12:21:18 -08:00
Alexander Bakker f9b4e8fa3e Use the first grapheme for the TextDrawable icon
Fixes #862
2022-01-03 20:23:04 +01:00
Alexander Bakker 153f5e09d8 Update dependencies 2021-12-04 11:54:02 +01:00
Alexander Bakker aec639cc53 Add a test for the Duo importer 2021-12-04 11:42:28 +01:00
Alexander Bakker 5c196f1ca5
Merge pull request #835 from anibyl/feature-duo
Add DUO importer
2021-12-04 11:09:20 +01:00
Sieva Kimajeŭ 56ddefa246 Add DUO importer. #68 2021-12-02 15:47:43 -08:00
Alexander Bakker 4c977a6371 Disable the PIN keyboard when enabling encryption
Fixes #854
2021-11-28 19:27:40 +01:00
Praveen Kumar 0652eaa5cd Added Focus Search on App Start
Renamed key

Removed unnecessary code
2021-11-08 17:34:49 +00:00
Alexander Bakker adfc472a39 Bump target SDK version to 31 and update dependencies 2021-11-03 12:23:06 +01:00