all: re-do package structure yet again
This commit is contained in:
parent
010c6e227c
commit
549ee790d3
204 changed files with 823 additions and 829 deletions
|
@ -27,7 +27,7 @@ android {
|
||||||
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace = "dev.msfjarvis.aps"
|
namespace = "app.passwordstore"
|
||||||
|
|
||||||
lint {
|
lint {
|
||||||
abortOnError = true
|
abortOnError = true
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.autofill.oreo.ui
|
package app.passwordstore.autofill.oreo.ui
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.IntentSender
|
import android.content.IntentSender
|
|
@ -22,7 +22,7 @@
|
||||||
android:required="false" />
|
android:required="false" />
|
||||||
|
|
||||||
<application
|
<application
|
||||||
android:name="dev.msfjarvis.aps.Application"
|
android:name=".Application"
|
||||||
android:allowBackup="false"
|
android:allowBackup="false"
|
||||||
android:dataExtractionRules="@xml/data_extraction_rules"
|
android:dataExtractionRules="@xml/data_extraction_rules"
|
||||||
android:fullBackupContent="@xml/backup_content"
|
android:fullBackupContent="@xml/backup_content"
|
||||||
|
@ -34,26 +34,26 @@
|
||||||
tools:targetApi="s">
|
tools:targetApi="s">
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.passwords.PasswordStore"
|
android:name=".ui.passwords.PasswordStore"
|
||||||
android:configChanges="orientation|screenSize"
|
android:configChanges="orientation|screenSize"
|
||||||
android:exported="false" />
|
android:exported="false" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.onboarding.activity.OnboardingActivity"
|
android:name=".ui.onboarding.activity.OnboardingActivity"
|
||||||
android:configChanges="orientation|screenSize"
|
android:configChanges="orientation|screenSize"
|
||||||
android:exported="false" />
|
android:exported="false" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.proxy.ProxySelectorActivity"
|
android:name=".ui.proxy.ProxySelectorActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.crypto.DecryptActivityV2"
|
android:name=".ui.crypto.DecryptActivityV2"
|
||||||
android:exported="true" />
|
android:exported="true" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.main.LaunchActivity"
|
android:name=".ui.main.LaunchActivity"
|
||||||
android:configChanges="orientation|screenSize"
|
android:configChanges="orientation|screenSize"
|
||||||
android:exported="true"
|
android:exported="true"
|
||||||
android:theme="@style/NoBackgroundThemeM3">
|
android:theme="@style/NoBackgroundThemeM3">
|
||||||
|
@ -73,60 +73,60 @@
|
||||||
tools:node="replace" />
|
tools:node="replace" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.git.config.GitServerConfigActivity"
|
android:name=".ui.git.config.GitServerConfigActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:label="@string/title_activity_git_clone"
|
android:label="@string/title_activity_git_clone"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.git.config.GitConfigActivity"
|
android:name=".ui.git.config.GitConfigActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:label="@string/title_activity_git_config"
|
android:label="@string/title_activity_git_config"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.git.log.GitLogActivity"
|
android:name=".ui.git.log.GitLogActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:label="@string/title_activity_git_log" />
|
android:label="@string/title_activity_git_log" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.settings.SettingsActivity"
|
android:name=".ui.settings.SettingsActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:label="@string/action_settings"
|
android:label="@string/action_settings"
|
||||||
android:parentActivityName=".ui.passwords.PasswordStore" />
|
android:parentActivityName=".ui.passwords.PasswordStore" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.crypto.PasswordCreationActivity"
|
android:name=".ui.crypto.PasswordCreationActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:label="@string/new_password_title"
|
android:label="@string/new_password_title"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.crypto.PasswordCreationActivityV2"
|
android:name=".ui.crypto.PasswordCreationActivityV2"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:label="@string/new_password_title"
|
android:label="@string/new_password_title"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.crypto.DecryptActivity"
|
android:name=".ui.crypto.DecryptActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.crypto.GetKeyIdsActivity"
|
android:name=".ui.crypto.GetKeyIdsActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/NoBackgroundThemeM3" />
|
android:theme="@style/NoBackgroundThemeM3" />
|
||||||
|
|
||||||
<service
|
<service
|
||||||
android:name="dev.msfjarvis.aps.util.services.ClipboardService"
|
android:name=".util.services.ClipboardService"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:process=":clipboard_service_process" />
|
android:process=":clipboard_service_process" />
|
||||||
<service
|
<service
|
||||||
android:name="dev.msfjarvis.aps.util.services.PasswordExportService"
|
android:name=".util.services.PasswordExportService"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:process=":password_export_service_process" />
|
android:process=":password_export_service_process" />
|
||||||
<service
|
<service
|
||||||
android:name="dev.msfjarvis.aps.util.services.OreoAutofillService"
|
android:name=".util.services.OreoAutofillService"
|
||||||
android:exported="true"
|
android:exported="true"
|
||||||
android:permission="android.permission.BIND_AUTOFILL_SERVICE">
|
android:permission="android.permission.BIND_AUTOFILL_SERVICE">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
|
@ -138,50 +138,50 @@
|
||||||
</service>
|
</service>
|
||||||
|
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.folderselect.SelectFolderActivity"
|
android:name=".ui.folderselect.SelectFolderActivity"
|
||||||
android:exported="false" />
|
android:exported="false" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.sshkeygen.SshKeyImportActivity"
|
android:name=".ui.sshkeygen.SshKeyImportActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/NoBackgroundThemeM3"
|
android:theme="@style/NoBackgroundThemeM3"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.sshkeygen.SshKeyGenActivity"
|
android:name=".ui.sshkeygen.SshKeyGenActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:label="@string/pref_ssh_keygen_title"
|
android:label="@string/pref_ssh_keygen_title"
|
||||||
android:windowSoftInputMode="adjustResize" />
|
android:windowSoftInputMode="adjustResize" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.autofill.AutofillDecryptActivity"
|
android:name=".ui.autofill.AutofillDecryptActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/NoBackgroundThemeM3" />
|
android:theme="@style/NoBackgroundThemeM3" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.autofill.AutofillDecryptActivityV2"
|
android:name=".ui.autofill.AutofillDecryptActivityV2"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/NoBackgroundThemeM3" />
|
android:theme="@style/NoBackgroundThemeM3" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.autofill.AutofillFilterView"
|
android:name=".ui.autofill.AutofillFilterView"
|
||||||
android:configChanges="orientation|keyboardHidden"
|
android:configChanges="orientation|keyboardHidden"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/DialogLikeThemeM3"
|
android:theme="@style/DialogLikeThemeM3"
|
||||||
android:windowSoftInputMode="adjustNothing" />
|
android:windowSoftInputMode="adjustNothing" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.autofill.AutofillSaveActivity"
|
android:name=".ui.autofill.AutofillSaveActivity"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/NoBackgroundThemeM3" />
|
android:theme="@style/NoBackgroundThemeM3" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.autofill.oreo.ui.AutofillSmsActivity"
|
android:name=".autofill.oreo.ui.AutofillSmsActivity"
|
||||||
android:configChanges="orientation"
|
android:configChanges="orientation"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/DialogLikeThemeM3"
|
android:theme="@style/DialogLikeThemeM3"
|
||||||
android:windowSoftInputMode="adjustNothing" />
|
android:windowSoftInputMode="adjustNothing" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.autofill.AutofillPublisherChangedActivity"
|
android:name=".ui.autofill.AutofillPublisherChangedActivity"
|
||||||
android:configChanges="orientation|keyboardHidden"
|
android:configChanges="orientation|keyboardHidden"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
android:theme="@style/DialogLikeThemeM3"
|
android:theme="@style/DialogLikeThemeM3"
|
||||||
android:windowSoftInputMode="adjustNothing" />
|
android:windowSoftInputMode="adjustNothing" />
|
||||||
<activity
|
<activity
|
||||||
android:name="dev.msfjarvis.aps.ui.pgp.PGPKeyImportActivity"
|
android:name=".ui.pgp.PGPKeyImportActivity"
|
||||||
android:theme="@style/NoBackgroundThemeM3" />
|
android:theme="@style/NoBackgroundThemeM3" />
|
||||||
</application>
|
</application>
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps
|
package app.passwordstore
|
||||||
|
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import androidx.appcompat.app.AppCompatDelegate
|
import androidx.appcompat.app.AppCompatDelegate
|
||||||
|
@ -10,18 +10,18 @@ import androidx.appcompat.app.AppCompatDelegate.MODE_NIGHT_AUTO_BATTERY
|
||||||
import androidx.appcompat.app.AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM
|
import androidx.appcompat.app.AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM
|
||||||
import androidx.appcompat.app.AppCompatDelegate.MODE_NIGHT_NO
|
import androidx.appcompat.app.AppCompatDelegate.MODE_NIGHT_NO
|
||||||
import androidx.appcompat.app.AppCompatDelegate.MODE_NIGHT_YES
|
import androidx.appcompat.app.AppCompatDelegate.MODE_NIGHT_YES
|
||||||
|
import app.passwordstore.injection.context.FilesDirPath
|
||||||
|
import app.passwordstore.injection.prefs.SettingsPreferences
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
|
import app.passwordstore.util.git.sshj.setUpBouncyCastleForSshj
|
||||||
|
import app.passwordstore.util.proxy.ProxyUtils
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
|
import app.passwordstore.util.settings.runMigrations
|
||||||
import com.google.android.material.color.DynamicColors
|
import com.google.android.material.color.DynamicColors
|
||||||
import dagger.hilt.android.HiltAndroidApp
|
import dagger.hilt.android.HiltAndroidApp
|
||||||
import dev.msfjarvis.aps.injection.context.FilesDirPath
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.SettingsPreferences
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.setUpBouncyCastleForSshj
|
|
||||||
import dev.msfjarvis.aps.util.proxy.ProxyUtils
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import dev.msfjarvis.aps.util.settings.runMigrations
|
|
||||||
import io.sentry.Sentry
|
import io.sentry.Sentry
|
||||||
import io.sentry.protocol.User
|
import io.sentry.protocol.User
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
|
@ -3,12 +3,12 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.data.crypto
|
package app.passwordstore.data.crypto
|
||||||
|
|
||||||
|
import app.passwordstore.crypto.PGPKeyManager
|
||||||
|
import app.passwordstore.crypto.PGPainlessCryptoHandler
|
||||||
|
import app.passwordstore.util.extensions.isOk
|
||||||
import com.github.michaelbull.result.unwrap
|
import com.github.michaelbull.result.unwrap
|
||||||
import dev.msfjarvis.aps.crypto.PGPKeyManager
|
|
||||||
import dev.msfjarvis.aps.crypto.PGPainlessCryptoHandler
|
|
||||||
import dev.msfjarvis.aps.util.extensions.isOk
|
|
||||||
import java.io.ByteArrayInputStream
|
import java.io.ByteArrayInputStream
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
|
@ -3,9 +3,9 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.data.password
|
package app.passwordstore.data.password
|
||||||
|
|
||||||
import dev.msfjarvis.aps.data.passfile.Totp
|
import app.passwordstore.data.passfile.Totp
|
||||||
import kotlin.time.ExperimentalTime
|
import kotlin.time.ExperimentalTime
|
||||||
|
|
||||||
@OptIn(ExperimentalTime::class)
|
@OptIn(ExperimentalTime::class)
|
|
@ -2,13 +2,13 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.data.password
|
package app.passwordstore.data.password
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
import dev.msfjarvis.aps.ui.crypto.BasePgpActivity
|
import app.passwordstore.ui.crypto.BasePgpActivity
|
||||||
import dev.msfjarvis.aps.ui.main.LaunchActivity
|
import app.passwordstore.ui.main.LaunchActivity
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
||||||
data class PasswordItem(
|
data class PasswordItem(
|
|
@ -2,18 +2,18 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.data.repo
|
package app.passwordstore.data.repo
|
||||||
|
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
|
import app.passwordstore.Application
|
||||||
|
import app.passwordstore.data.password.PasswordItem
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.settings.PasswordSortOrder
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dev.msfjarvis.aps.Application
|
|
||||||
import dev.msfjarvis.aps.data.password.PasswordItem
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.settings.PasswordSortOrder
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import org.eclipse.jgit.api.Git
|
import org.eclipse.jgit.api.Git
|
||||||
import org.eclipse.jgit.lib.Repository
|
import org.eclipse.jgit.lib.Repository
|
|
@ -1,4 +1,4 @@
|
||||||
package dev.msfjarvis.aps.injection.context
|
package app.passwordstore.injection.context
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
|
@ -13,7 +13,7 @@ class ContextModule {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* We inject [Context.getFilesDir] to break the dependency on [Context], allowing tests to run on
|
* We inject [Context.getFilesDir] to break the dependency on [Context], allowing tests to run on
|
||||||
* the JVM. The principle here is identical to why [dev.msfjarvis.aps.util.totp.TotpFinder]
|
* the JVM. The principle here is identical to why [app.passwordstore.util.totp.TotpFinder]
|
||||||
* exists.
|
* exists.
|
||||||
*
|
*
|
||||||
* @param context [ApplicationContext]
|
* @param context [ApplicationContext]
|
|
@ -1,4 +1,4 @@
|
||||||
package dev.msfjarvis.aps.injection.context
|
package app.passwordstore.injection.context
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import javax.inject.Qualifier
|
import javax.inject.Qualifier
|
|
@ -3,14 +3,14 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.injection.coroutines
|
package app.passwordstore.injection.coroutines
|
||||||
|
|
||||||
|
import app.passwordstore.util.coroutines.DefaultDispatcherProvider
|
||||||
|
import app.passwordstore.util.coroutines.DispatcherProvider
|
||||||
import dagger.Binds
|
import dagger.Binds
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import dev.msfjarvis.aps.util.coroutines.DefaultDispatcherProvider
|
|
||||||
import dev.msfjarvis.aps.util.coroutines.DispatcherProvider
|
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
@InstallIn(SingletonComponent::class)
|
@InstallIn(SingletonComponent::class)
|
|
@ -3,13 +3,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.injection.crypto
|
package app.passwordstore.injection.crypto
|
||||||
|
|
||||||
|
import app.passwordstore.crypto.PGPainlessCryptoHandler
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.Provides
|
import dagger.Provides
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import dev.msfjarvis.aps.crypto.PGPainlessCryptoHandler
|
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
@InstallIn(SingletonComponent::class)
|
@InstallIn(SingletonComponent::class)
|
|
@ -3,16 +3,16 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.injection.crypto
|
package app.passwordstore.injection.crypto
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
import app.passwordstore.crypto.PGPKeyManager
|
||||||
|
import app.passwordstore.util.coroutines.DispatcherProvider
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.Provides
|
import dagger.Provides
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.android.qualifiers.ApplicationContext
|
import dagger.hilt.android.qualifiers.ApplicationContext
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import dev.msfjarvis.aps.crypto.PGPKeyManager
|
|
||||||
import dev.msfjarvis.aps.util.coroutines.DispatcherProvider
|
|
||||||
import javax.inject.Qualifier
|
import javax.inject.Qualifier
|
||||||
|
|
||||||
@Module
|
@Module
|
|
@ -1,4 +1,4 @@
|
||||||
package dev.msfjarvis.aps.injection.prefs
|
package app.passwordstore.injection.prefs
|
||||||
|
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import javax.inject.Qualifier
|
import javax.inject.Qualifier
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.injection.prefs
|
package app.passwordstore.injection.prefs
|
||||||
|
|
||||||
import javax.inject.Qualifier
|
import javax.inject.Qualifier
|
||||||
|
|
|
@ -1,17 +1,17 @@
|
||||||
package dev.msfjarvis.aps.injection.prefs
|
package app.passwordstore.injection.prefs
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Context.MODE_PRIVATE
|
import android.content.Context.MODE_PRIVATE
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import androidx.security.crypto.EncryptedSharedPreferences
|
import androidx.security.crypto.EncryptedSharedPreferences
|
||||||
import androidx.security.crypto.MasterKey
|
import androidx.security.crypto.MasterKey
|
||||||
|
import app.passwordstore.BuildConfig
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.Provides
|
import dagger.Provides
|
||||||
import dagger.Reusable
|
import dagger.Reusable
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.android.qualifiers.ApplicationContext
|
import dagger.hilt.android.qualifiers.ApplicationContext
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import dev.msfjarvis.aps.BuildConfig
|
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
@InstallIn(SingletonComponent::class)
|
@InstallIn(SingletonComponent::class)
|
|
@ -1,4 +1,4 @@
|
||||||
package dev.msfjarvis.aps.injection.prefs
|
package app.passwordstore.injection.prefs
|
||||||
|
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import javax.inject.Qualifier
|
import javax.inject.Qualifier
|
|
@ -1,4 +1,4 @@
|
||||||
package dev.msfjarvis.aps.injection.prefs
|
package app.passwordstore.injection.prefs
|
||||||
|
|
||||||
import javax.inject.Qualifier
|
import javax.inject.Qualifier
|
||||||
|
|
|
@ -3,17 +3,17 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.injection.pwgen
|
package app.passwordstore.injection.pwgen
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
import app.passwordstore.passgen.diceware.DicewarePassphraseGenerator
|
||||||
|
import app.passwordstore.passgen.diceware.Die
|
||||||
|
import app.passwordstore.passgen.diceware.RandomIntGenerator
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.Provides
|
import dagger.Provides
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.android.components.FragmentComponent
|
import dagger.hilt.android.components.FragmentComponent
|
||||||
import dagger.hilt.android.qualifiers.ApplicationContext
|
import dagger.hilt.android.qualifiers.ApplicationContext
|
||||||
import dev.msfjarvis.aps.passgen.diceware.DicewarePassphraseGenerator
|
|
||||||
import dev.msfjarvis.aps.passgen.diceware.Die
|
|
||||||
import dev.msfjarvis.aps.passgen.diceware.RandomIntGenerator
|
|
||||||
import java.io.InputStream
|
import java.io.InputStream
|
||||||
import java.security.SecureRandom
|
import java.security.SecureRandom
|
||||||
import javax.inject.Qualifier
|
import javax.inject.Qualifier
|
||||||
|
@ -47,7 +47,7 @@ object DicewareModule {
|
||||||
@[Provides WordlistQualifier]
|
@[Provides WordlistQualifier]
|
||||||
fun provideDefaultWordList(@ApplicationContext context: Context): InputStream {
|
fun provideDefaultWordList(@ApplicationContext context: Context): InputStream {
|
||||||
return context.resources.openRawResource(
|
return context.resources.openRawResource(
|
||||||
dev.msfjarvis.aps.passgen.diceware.R.raw.diceware_wordlist
|
app.passwordstore.passgen.diceware.R.raw.diceware_wordlist
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -3,14 +3,14 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.injection.totp
|
package app.passwordstore.injection.totp
|
||||||
|
|
||||||
|
import app.passwordstore.util.totp.TotpFinder
|
||||||
|
import app.passwordstore.util.totp.UriTotpFinder
|
||||||
import dagger.Binds
|
import dagger.Binds
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.android.components.ActivityComponent
|
import dagger.hilt.android.components.ActivityComponent
|
||||||
import dev.msfjarvis.aps.util.totp.TotpFinder
|
|
||||||
import dev.msfjarvis.aps.util.totp.UriTotpFinder
|
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
@InstallIn(ActivityComponent::class)
|
@InstallIn(ActivityComponent::class)
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.adapters
|
package app.passwordstore.ui.adapters
|
||||||
|
|
||||||
import android.text.method.PasswordTransformationMethod
|
import android.text.method.PasswordTransformationMethod
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
|
@ -11,11 +11,11 @@ import android.view.View
|
||||||
import android.view.ViewGroup
|
import android.view.ViewGroup
|
||||||
import androidx.core.content.ContextCompat
|
import androidx.core.content.ContextCompat
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.passfile.Totp
|
||||||
|
import app.passwordstore.data.password.FieldItem
|
||||||
|
import app.passwordstore.databinding.ItemFieldBinding
|
||||||
import com.google.android.material.textfield.TextInputLayout
|
import com.google.android.material.textfield.TextInputLayout
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.passfile.Totp
|
|
||||||
import dev.msfjarvis.aps.data.password.FieldItem
|
|
||||||
import dev.msfjarvis.aps.databinding.ItemFieldBinding
|
|
||||||
|
|
||||||
class FieldItemAdapter(
|
class FieldItemAdapter(
|
||||||
private var fieldItemList: List<FieldItem>,
|
private var fieldItemList: List<FieldItem>,
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.adapters
|
package app.passwordstore.ui.adapters
|
||||||
|
|
||||||
import android.text.SpannableString
|
import android.text.SpannableString
|
||||||
import android.text.style.RelativeSizeSpan
|
import android.text.style.RelativeSizeSpan
|
||||||
|
@ -13,10 +13,10 @@ import androidx.appcompat.widget.AppCompatTextView
|
||||||
import androidx.recyclerview.selection.ItemDetailsLookup
|
import androidx.recyclerview.selection.ItemDetailsLookup
|
||||||
import androidx.recyclerview.selection.Selection
|
import androidx.recyclerview.selection.Selection
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
import dev.msfjarvis.aps.data.password.PasswordItem
|
import app.passwordstore.data.password.PasswordItem
|
||||||
import dev.msfjarvis.aps.util.viewmodel.SearchableRepositoryAdapter
|
import app.passwordstore.util.viewmodel.SearchableRepositoryAdapter
|
||||||
import dev.msfjarvis.aps.util.viewmodel.stableId
|
import app.passwordstore.util.viewmodel.stableId
|
||||||
import kotlinx.coroutines.CoroutineScope
|
import kotlinx.coroutines.CoroutineScope
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.autofill
|
package app.passwordstore.ui.autofill
|
||||||
|
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
@ -17,6 +17,12 @@ import androidx.activity.result.contract.ActivityResultContracts.StartIntentSend
|
||||||
import androidx.annotation.RequiresApi
|
import androidx.annotation.RequiresApi
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.data.passfile.PasswordEntry
|
||||||
|
import app.passwordstore.util.autofill.AutofillPreferences
|
||||||
|
import app.passwordstore.util.autofill.AutofillResponseBuilder
|
||||||
|
import app.passwordstore.util.autofill.DirectoryStructure
|
||||||
|
import app.passwordstore.util.extensions.OPENPGP_PROVIDER
|
||||||
|
import app.passwordstore.util.extensions.asLog
|
||||||
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
||||||
import com.github.androidpasswordstore.autofillparser.Credentials
|
import com.github.androidpasswordstore.autofillparser.Credentials
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
|
@ -24,12 +30,6 @@ import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.onSuccess
|
import com.github.michaelbull.result.onSuccess
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.data.passfile.PasswordEntry
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillPreferences
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillResponseBuilder
|
|
||||||
import dev.msfjarvis.aps.util.autofill.DirectoryStructure
|
|
||||||
import dev.msfjarvis.aps.util.extensions.OPENPGP_PROVIDER
|
|
||||||
import dev.msfjarvis.aps.util.extensions.asLog
|
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.io.InputStream
|
import java.io.InputStream
|
||||||
|
@ -55,8 +55,8 @@ class AutofillDecryptActivity : AppCompatActivity() {
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|
||||||
private const val EXTRA_FILE_PATH = "dev.msfjarvis.aps.autofill.oreo.EXTRA_FILE_PATH"
|
private const val EXTRA_FILE_PATH = "app.passwordstore.autofill.oreo.EXTRA_FILE_PATH"
|
||||||
private const val EXTRA_SEARCH_ACTION = "dev.msfjarvis.aps.autofill.oreo.EXTRA_SEARCH_ACTION"
|
private const val EXTRA_SEARCH_ACTION = "app.passwordstore.autofill.oreo.EXTRA_SEARCH_ACTION"
|
||||||
|
|
||||||
private var decryptFileRequestCode = 1
|
private var decryptFileRequestCode = 1
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.autofill
|
package app.passwordstore.ui.autofill
|
||||||
|
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
@ -14,6 +14,13 @@ import android.view.autofill.AutofillManager
|
||||||
import androidx.annotation.RequiresApi
|
import androidx.annotation.RequiresApi
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.data.crypto.CryptoRepository
|
||||||
|
import app.passwordstore.data.passfile.PasswordEntry
|
||||||
|
import app.passwordstore.ui.crypto.PasswordDialog
|
||||||
|
import app.passwordstore.util.autofill.AutofillPreferences
|
||||||
|
import app.passwordstore.util.autofill.AutofillResponseBuilder
|
||||||
|
import app.passwordstore.util.autofill.DirectoryStructure
|
||||||
|
import app.passwordstore.util.extensions.asLog
|
||||||
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
||||||
import com.github.androidpasswordstore.autofillparser.Credentials
|
import com.github.androidpasswordstore.autofillparser.Credentials
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
|
@ -21,13 +28,6 @@ import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.onSuccess
|
import com.github.michaelbull.result.onSuccess
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.data.crypto.CryptoRepository
|
|
||||||
import dev.msfjarvis.aps.data.passfile.PasswordEntry
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordDialog
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillPreferences
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillResponseBuilder
|
|
||||||
import dev.msfjarvis.aps.util.autofill.DirectoryStructure
|
|
||||||
import dev.msfjarvis.aps.util.extensions.asLog
|
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
@ -44,8 +44,8 @@ class AutofillDecryptActivityV2 : AppCompatActivity() {
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|
||||||
private const val EXTRA_FILE_PATH = "dev.msfjarvis.aps.autofill.oreo.EXTRA_FILE_PATH"
|
private const val EXTRA_FILE_PATH = "app.passwordstore.autofill.oreo.EXTRA_FILE_PATH"
|
||||||
private const val EXTRA_SEARCH_ACTION = "dev.msfjarvis.aps.autofill.oreo.EXTRA_SEARCH_ACTION"
|
private const val EXTRA_SEARCH_ACTION = "app.passwordstore.autofill.oreo.EXTRA_SEARCH_ACTION"
|
||||||
|
|
||||||
private var decryptFileRequestCode = 1
|
private var decryptFileRequestCode = 1
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.autofill
|
package app.passwordstore.ui.autofill
|
||||||
|
|
||||||
import android.annotation.TargetApi
|
import android.annotation.TargetApi
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
|
@ -24,22 +24,22 @@ import androidx.core.widget.addTextChangedListener
|
||||||
import androidx.lifecycle.ViewModelProvider
|
import androidx.lifecycle.ViewModelProvider
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.password.PasswordItem
|
||||||
|
import app.passwordstore.databinding.ActivityOreoAutofillFilterBinding
|
||||||
|
import app.passwordstore.util.autofill.AutofillMatcher
|
||||||
|
import app.passwordstore.util.autofill.AutofillPreferences
|
||||||
|
import app.passwordstore.util.autofill.DirectoryStructure
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
|
import app.passwordstore.util.viewmodel.FilterMode
|
||||||
|
import app.passwordstore.util.viewmodel.ListMode
|
||||||
|
import app.passwordstore.util.viewmodel.SearchMode
|
||||||
|
import app.passwordstore.util.viewmodel.SearchableRepositoryAdapter
|
||||||
|
import app.passwordstore.util.viewmodel.SearchableRepositoryViewModel
|
||||||
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.password.PasswordItem
|
|
||||||
import dev.msfjarvis.aps.databinding.ActivityOreoAutofillFilterBinding
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillMatcher
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillPreferences
|
|
||||||
import dev.msfjarvis.aps.util.autofill.DirectoryStructure
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.FilterMode
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.ListMode
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.SearchMode
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.SearchableRepositoryAdapter
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.SearchableRepositoryViewModel
|
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.logcat
|
import logcat.logcat
|
||||||
|
@ -54,9 +54,9 @@ class AutofillFilterView : AppCompatActivity() {
|
||||||
private const val WIDTH_PERCENTAGE = 0.75
|
private const val WIDTH_PERCENTAGE = 0.75
|
||||||
|
|
||||||
private const val EXTRA_FORM_ORIGIN_WEB =
|
private const val EXTRA_FORM_ORIGIN_WEB =
|
||||||
"dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_FORM_ORIGIN_WEB"
|
"app.passwordstore.autofill.oreo.ui.EXTRA_FORM_ORIGIN_WEB"
|
||||||
private const val EXTRA_FORM_ORIGIN_APP =
|
private const val EXTRA_FORM_ORIGIN_APP =
|
||||||
"dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_FORM_ORIGIN_APP"
|
"app.passwordstore.autofill.oreo.ui.EXTRA_FORM_ORIGIN_APP"
|
||||||
private var matchAndDecryptFileRequestCode = 1
|
private var matchAndDecryptFileRequestCode = 1
|
||||||
|
|
||||||
fun makeMatchAndDecryptFileIntentSender(
|
fun makeMatchAndDecryptFileIntentSender(
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.autofill
|
package app.passwordstore.ui.autofill
|
||||||
|
|
||||||
import android.annotation.TargetApi
|
import android.annotation.TargetApi
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
|
@ -17,16 +17,16 @@ import android.text.format.DateUtils
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import android.view.autofill.AutofillManager
|
import android.view.autofill.AutofillManager
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.ActivityOreoAutofillPublisherChangedBinding
|
||||||
|
import app.passwordstore.util.autofill.AutofillMatcher
|
||||||
|
import app.passwordstore.util.autofill.AutofillPublisherChangedException
|
||||||
|
import app.passwordstore.util.extensions.asLog
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
||||||
import com.github.androidpasswordstore.autofillparser.computeCertificatesHash
|
import com.github.androidpasswordstore.autofillparser.computeCertificatesHash
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.ActivityOreoAutofillPublisherChangedBinding
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillMatcher
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillPublisherChangedException
|
|
||||||
import dev.msfjarvis.aps.util.extensions.asLog
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.logcat
|
import logcat.logcat
|
||||||
|
|
||||||
|
@ -35,9 +35,9 @@ class AutofillPublisherChangedActivity : AppCompatActivity() {
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|
||||||
private const val EXTRA_APP_PACKAGE = "dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_APP_PACKAGE"
|
private const val EXTRA_APP_PACKAGE = "app.passwordstore.autofill.oreo.ui.EXTRA_APP_PACKAGE"
|
||||||
private const val EXTRA_FILL_RESPONSE_AFTER_RESET =
|
private const val EXTRA_FILL_RESPONSE_AFTER_RESET =
|
||||||
"dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_FILL_RESPONSE_AFTER_RESET"
|
"app.passwordstore.autofill.oreo.ui.EXTRA_FILL_RESPONSE_AFTER_RESET"
|
||||||
private var publisherChangedRequestCode = 1
|
private var publisherChangedRequestCode = 1
|
||||||
|
|
||||||
fun makePublisherChangedIntentSender(
|
fun makePublisherChangedIntentSender(
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.autofill
|
package app.passwordstore.ui.autofill
|
||||||
|
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
@ -14,19 +14,19 @@ import androidx.activity.result.contract.ActivityResultContracts.StartActivityFo
|
||||||
import androidx.annotation.RequiresApi
|
import androidx.annotation.RequiresApi
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.os.bundleOf
|
import androidx.core.os.bundleOf
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.ui.crypto.PasswordCreationActivity
|
||||||
|
import app.passwordstore.ui.crypto.PasswordCreationActivityV2
|
||||||
|
import app.passwordstore.util.autofill.AutofillMatcher
|
||||||
|
import app.passwordstore.util.autofill.AutofillPreferences
|
||||||
|
import app.passwordstore.util.autofill.AutofillResponseBuilder
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
||||||
import com.github.androidpasswordstore.autofillparser.Credentials
|
import com.github.androidpasswordstore.autofillparser.Credentials
|
||||||
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordCreationActivity
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordCreationActivityV2
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillMatcher
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillPreferences
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillResponseBuilder
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
|
@ -38,15 +38,15 @@ class AutofillSaveActivity : AppCompatActivity() {
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|
||||||
private const val EXTRA_FOLDER_NAME = "dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_FOLDER_NAME"
|
private const val EXTRA_FOLDER_NAME = "app.passwordstore.autofill.oreo.ui.EXTRA_FOLDER_NAME"
|
||||||
private const val EXTRA_PASSWORD = "dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_PASSWORD"
|
private const val EXTRA_PASSWORD = "app.passwordstore.autofill.oreo.ui.EXTRA_PASSWORD"
|
||||||
private const val EXTRA_NAME = "dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_NAME"
|
private const val EXTRA_NAME = "app.passwordstore.autofill.oreo.ui.EXTRA_NAME"
|
||||||
private const val EXTRA_SHOULD_MATCH_APP =
|
private const val EXTRA_SHOULD_MATCH_APP =
|
||||||
"dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_SHOULD_MATCH_APP"
|
"app.passwordstore.autofill.oreo.ui.EXTRA_SHOULD_MATCH_APP"
|
||||||
private const val EXTRA_SHOULD_MATCH_WEB =
|
private const val EXTRA_SHOULD_MATCH_WEB =
|
||||||
"dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_SHOULD_MATCH_WEB"
|
"app.passwordstore.autofill.oreo.ui.EXTRA_SHOULD_MATCH_WEB"
|
||||||
private const val EXTRA_GENERATE_PASSWORD =
|
private const val EXTRA_GENERATE_PASSWORD =
|
||||||
"dev.msfjarvis.aps.autofill.oreo.ui.EXTRA_GENERATE_PASSWORD"
|
"app.passwordstore.autofill.oreo.ui.EXTRA_GENERATE_PASSWORD"
|
||||||
|
|
||||||
private var saveRequestCode = 1
|
private var saveRequestCode = 1
|
||||||
|
|
|
@ -2,12 +2,12 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.autofill
|
package app.passwordstore.ui.autofill
|
||||||
|
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import android.widget.TextView
|
import android.widget.TextView
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
|
|
||||||
class PasswordViewHolder(view: View) : RecyclerView.ViewHolder(view) {
|
class PasswordViewHolder(view: View) : RecyclerView.ViewHolder(view) {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.crypto
|
package app.passwordstore.ui.crypto
|
||||||
|
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
import android.content.ClipData
|
import android.content.ClipData
|
||||||
|
@ -17,23 +17,23 @@ import android.view.WindowManager
|
||||||
import androidx.annotation.CallSuper
|
import androidx.annotation.CallSuper
|
||||||
import androidx.annotation.StringRes
|
import androidx.annotation.StringRes
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.injection.prefs.SettingsPreferences
|
||||||
|
import app.passwordstore.util.extensions.OPENPGP_PROVIDER
|
||||||
|
import app.passwordstore.util.extensions.asLog
|
||||||
|
import app.passwordstore.util.extensions.clipboard
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.snackbar
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
|
import app.passwordstore.util.services.ClipboardService
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.getOr
|
import com.github.michaelbull.result.getOr
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.SettingsPreferences
|
|
||||||
import dev.msfjarvis.aps.util.extensions.OPENPGP_PROVIDER
|
|
||||||
import dev.msfjarvis.aps.util.extensions.asLog
|
|
||||||
import dev.msfjarvis.aps.util.extensions.clipboard
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.snackbar
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import dev.msfjarvis.aps.util.services.ClipboardService
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.crypto
|
package app.passwordstore.ui.crypto
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -12,17 +12,17 @@ import android.view.MenuItem
|
||||||
import androidx.activity.result.IntentSenderRequest
|
import androidx.activity.result.IntentSenderRequest
|
||||||
import androidx.activity.result.contract.ActivityResultContracts.StartIntentSenderForResult
|
import androidx.activity.result.contract.ActivityResultContracts.StartIntentSenderForResult
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.passfile.PasswordEntry
|
||||||
|
import app.passwordstore.data.password.FieldItem
|
||||||
|
import app.passwordstore.databinding.DecryptLayoutBinding
|
||||||
|
import app.passwordstore.ui.adapters.FieldItemAdapter
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.passfile.PasswordEntry
|
|
||||||
import dev.msfjarvis.aps.data.password.FieldItem
|
|
||||||
import dev.msfjarvis.aps.databinding.DecryptLayoutBinding
|
|
||||||
import dev.msfjarvis.aps.ui.adapters.FieldItemAdapter
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
|
@ -3,25 +3,25 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.crypto
|
package app.passwordstore.ui.crypto
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.Menu
|
import android.view.Menu
|
||||||
import android.view.MenuItem
|
import android.view.MenuItem
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.crypto.CryptoRepository
|
||||||
|
import app.passwordstore.data.passfile.PasswordEntry
|
||||||
|
import app.passwordstore.data.password.FieldItem
|
||||||
|
import app.passwordstore.databinding.DecryptLayoutBinding
|
||||||
|
import app.passwordstore.ui.adapters.FieldItemAdapter
|
||||||
|
import app.passwordstore.util.extensions.isErr
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.crypto.CryptoRepository
|
|
||||||
import dev.msfjarvis.aps.data.passfile.PasswordEntry
|
|
||||||
import dev.msfjarvis.aps.data.password.FieldItem
|
|
||||||
import dev.msfjarvis.aps.databinding.DecryptLayoutBinding
|
|
||||||
import dev.msfjarvis.aps.ui.adapters.FieldItemAdapter
|
|
||||||
import dev.msfjarvis.aps.util.extensions.isErr
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.crypto
|
package app.passwordstore.ui.crypto
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.crypto
|
package app.passwordstore.ui.crypto
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
@ -25,6 +25,25 @@ import androidx.core.content.edit
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
import androidx.core.widget.doAfterTextChanged
|
import androidx.core.widget.doAfterTextChanged
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.passfile.PasswordEntry
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.databinding.PasswordCreationActivityBinding
|
||||||
|
import app.passwordstore.ui.dialogs.DicewarePasswordGeneratorDialogFragment
|
||||||
|
import app.passwordstore.ui.dialogs.OtpImportDialogFragment
|
||||||
|
import app.passwordstore.ui.dialogs.PasswordGeneratorDialogFragment
|
||||||
|
import app.passwordstore.util.autofill.AutofillPreferences
|
||||||
|
import app.passwordstore.util.autofill.DirectoryStructure
|
||||||
|
import app.passwordstore.util.crypto.GpgIdentifier
|
||||||
|
import app.passwordstore.util.extensions.asLog
|
||||||
|
import app.passwordstore.util.extensions.base64
|
||||||
|
import app.passwordstore.util.extensions.commitChange
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.isInsideRepository
|
||||||
|
import app.passwordstore.util.extensions.snackbar
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.onSuccess
|
import com.github.michaelbull.result.onSuccess
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
|
@ -38,25 +57,6 @@ import com.google.zxing.integration.android.IntentIntegrator
|
||||||
import com.google.zxing.integration.android.IntentIntegrator.QR_CODE
|
import com.google.zxing.integration.android.IntentIntegrator.QR_CODE
|
||||||
import com.google.zxing.qrcode.QRCodeReader
|
import com.google.zxing.qrcode.QRCodeReader
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.passfile.PasswordEntry
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.databinding.PasswordCreationActivityBinding
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.DicewarePasswordGeneratorDialogFragment
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.OtpImportDialogFragment
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.PasswordGeneratorDialogFragment
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillPreferences
|
|
||||||
import dev.msfjarvis.aps.util.autofill.DirectoryStructure
|
|
||||||
import dev.msfjarvis.aps.util.crypto.GpgIdentifier
|
|
||||||
import dev.msfjarvis.aps.util.extensions.asLog
|
|
||||||
import dev.msfjarvis.aps.util.extensions.base64
|
|
||||||
import dev.msfjarvis.aps.util.extensions.commitChange
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.isInsideRepository
|
|
||||||
import dev.msfjarvis.aps.util.extensions.snackbar
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.ByteArrayInputStream
|
import java.io.ByteArrayInputStream
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.File
|
import java.io.File
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.crypto
|
package app.passwordstore.ui.crypto
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
@ -23,6 +23,24 @@ import androidx.core.content.edit
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
import androidx.core.widget.doAfterTextChanged
|
import androidx.core.widget.doAfterTextChanged
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.crypto.CryptoRepository
|
||||||
|
import app.passwordstore.data.passfile.PasswordEntry
|
||||||
|
import app.passwordstore.databinding.PasswordCreationActivityBinding
|
||||||
|
import app.passwordstore.ui.dialogs.DicewarePasswordGeneratorDialogFragment
|
||||||
|
import app.passwordstore.ui.dialogs.OtpImportDialogFragment
|
||||||
|
import app.passwordstore.ui.dialogs.PasswordGeneratorDialogFragment
|
||||||
|
import app.passwordstore.util.autofill.AutofillPreferences
|
||||||
|
import app.passwordstore.util.autofill.DirectoryStructure
|
||||||
|
import app.passwordstore.util.extensions.asLog
|
||||||
|
import app.passwordstore.util.extensions.base64
|
||||||
|
import app.passwordstore.util.extensions.commitChange
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.isInsideRepository
|
||||||
|
import app.passwordstore.util.extensions.snackbar
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.onSuccess
|
import com.github.michaelbull.result.onSuccess
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
|
@ -35,24 +53,6 @@ import com.google.zxing.integration.android.IntentIntegrator
|
||||||
import com.google.zxing.integration.android.IntentIntegrator.QR_CODE
|
import com.google.zxing.integration.android.IntentIntegrator.QR_CODE
|
||||||
import com.google.zxing.qrcode.QRCodeReader
|
import com.google.zxing.qrcode.QRCodeReader
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.crypto.CryptoRepository
|
|
||||||
import dev.msfjarvis.aps.data.passfile.PasswordEntry
|
|
||||||
import dev.msfjarvis.aps.databinding.PasswordCreationActivityBinding
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.DicewarePasswordGeneratorDialogFragment
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.OtpImportDialogFragment
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.PasswordGeneratorDialogFragment
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillPreferences
|
|
||||||
import dev.msfjarvis.aps.util.autofill.DirectoryStructure
|
|
||||||
import dev.msfjarvis.aps.util.extensions.asLog
|
|
||||||
import dev.msfjarvis.aps.util.extensions.base64
|
|
||||||
import dev.msfjarvis.aps.util.extensions.commitChange
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.isInsideRepository
|
|
||||||
import dev.msfjarvis.aps.util.extensions.snackbar
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.io.IOException
|
import java.io.IOException
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.crypto
|
package app.passwordstore.ui.crypto
|
||||||
|
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
import android.content.DialogInterface
|
import android.content.DialogInterface
|
||||||
|
@ -12,11 +12,11 @@ import android.view.KeyEvent
|
||||||
import android.view.WindowManager
|
import android.view.WindowManager
|
||||||
import androidx.core.widget.doOnTextChanged
|
import androidx.core.widget.doOnTextChanged
|
||||||
import androidx.fragment.app.DialogFragment
|
import androidx.fragment.app.DialogFragment
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.DialogPasswordEntryBinding
|
||||||
|
import app.passwordstore.util.extensions.finish
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.DialogPasswordEntryBinding
|
|
||||||
import dev.msfjarvis.aps.util.extensions.finish
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import kotlinx.coroutines.flow.MutableStateFlow
|
import kotlinx.coroutines.flow.MutableStateFlow
|
||||||
import kotlinx.coroutines.flow.asStateFlow
|
import kotlinx.coroutines.flow.asStateFlow
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.dialogs
|
package app.passwordstore.ui.dialogs
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -14,12 +14,12 @@ import android.view.ViewTreeObserver
|
||||||
import android.widget.FrameLayout
|
import android.widget.FrameLayout
|
||||||
import androidx.annotation.StringRes
|
import androidx.annotation.StringRes
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.BasicBottomSheetBinding
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
import com.google.android.material.bottomsheet.BottomSheetBehavior
|
import com.google.android.material.bottomsheet.BottomSheetBehavior
|
||||||
import com.google.android.material.bottomsheet.BottomSheetDialog
|
import com.google.android.material.bottomsheet.BottomSheetDialog
|
||||||
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
|
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.BasicBottomSheetBinding
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* [BottomSheetDialogFragment] that exposes a simple [androidx.appcompat.app.AlertDialog] like API
|
* [BottomSheetDialogFragment] that exposes a simple [androidx.appcompat.app.AlertDialog] like API
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.dialogs
|
package app.passwordstore.ui.dialogs
|
||||||
|
|
||||||
import android.app.AlertDialog
|
import android.app.AlertDialog
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
|
@ -15,16 +15,16 @@ import androidx.core.os.bundleOf
|
||||||
import androidx.fragment.app.DialogFragment
|
import androidx.fragment.app.DialogFragment
|
||||||
import androidx.fragment.app.setFragmentResult
|
import androidx.fragment.app.setFragmentResult
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.FragmentPwgenDicewareBinding
|
||||||
|
import app.passwordstore.injection.prefs.PasswordGeneratorPreferences
|
||||||
|
import app.passwordstore.passgen.diceware.DicewarePassphraseGenerator
|
||||||
|
import app.passwordstore.ui.crypto.PasswordCreationActivity
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys.DICEWARE_LENGTH
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys.DICEWARE_SEPARATOR
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.FragmentPwgenDicewareBinding
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.PasswordGeneratorPreferences
|
|
||||||
import dev.msfjarvis.aps.passgen.diceware.DicewarePassphraseGenerator
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordCreationActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys.DICEWARE_LENGTH
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys.DICEWARE_SEPARATOR
|
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import kotlinx.coroutines.flow.launchIn
|
import kotlinx.coroutines.flow.launchIn
|
||||||
import kotlinx.coroutines.flow.merge
|
import kotlinx.coroutines.flow.merge
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.dialogs
|
package app.passwordstore.ui.dialogs
|
||||||
|
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
@ -14,16 +14,16 @@ import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.os.bundleOf
|
import androidx.core.os.bundleOf
|
||||||
import androidx.fragment.app.DialogFragment
|
import androidx.fragment.app.DialogFragment
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.ui.crypto.BasePgpActivity
|
||||||
|
import app.passwordstore.ui.crypto.GetKeyIdsActivity
|
||||||
|
import app.passwordstore.ui.passwords.PasswordStore
|
||||||
|
import app.passwordstore.util.extensions.commitChange
|
||||||
import com.google.android.material.checkbox.MaterialCheckBox
|
import com.google.android.material.checkbox.MaterialCheckBox
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import com.google.android.material.textfield.TextInputEditText
|
import com.google.android.material.textfield.TextInputEditText
|
||||||
import com.google.android.material.textfield.TextInputLayout
|
import com.google.android.material.textfield.TextInputLayout
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.BasePgpActivity
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.GetKeyIdsActivity
|
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordStore
|
|
||||||
import dev.msfjarvis.aps.util.extensions.commitChange
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import me.msfjarvis.openpgpktx.util.OpenPgpApi
|
import me.msfjarvis.openpgpktx.util.OpenPgpApi
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.dialogs
|
package app.passwordstore.ui.dialogs
|
||||||
|
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
|
@ -12,14 +12,14 @@ import android.view.ViewTreeObserver
|
||||||
import android.widget.FrameLayout
|
import android.widget.FrameLayout
|
||||||
import androidx.core.os.bundleOf
|
import androidx.core.os.bundleOf
|
||||||
import androidx.fragment.app.setFragmentResult
|
import androidx.fragment.app.setFragmentResult
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.ui.passwords.PasswordFragment.Companion.ACTION_FOLDER
|
||||||
|
import app.passwordstore.ui.passwords.PasswordFragment.Companion.ACTION_KEY
|
||||||
|
import app.passwordstore.ui.passwords.PasswordFragment.Companion.ACTION_PASSWORD
|
||||||
|
import app.passwordstore.ui.passwords.PasswordFragment.Companion.ITEM_CREATION_REQUEST_KEY
|
||||||
import com.google.android.material.bottomsheet.BottomSheetBehavior
|
import com.google.android.material.bottomsheet.BottomSheetBehavior
|
||||||
import com.google.android.material.bottomsheet.BottomSheetDialog
|
import com.google.android.material.bottomsheet.BottomSheetDialog
|
||||||
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
|
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordFragment.Companion.ACTION_FOLDER
|
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordFragment.Companion.ACTION_KEY
|
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordFragment.Companion.ACTION_PASSWORD
|
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordFragment.Companion.ITEM_CREATION_REQUEST_KEY
|
|
||||||
|
|
||||||
class ItemCreationBottomSheet : BottomSheetDialogFragment() {
|
class ItemCreationBottomSheet : BottomSheetDialogFragment() {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.dialogs
|
package app.passwordstore.ui.dialogs
|
||||||
|
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
|
@ -12,9 +12,9 @@ import android.view.WindowManager
|
||||||
import androidx.core.os.bundleOf
|
import androidx.core.os.bundleOf
|
||||||
import androidx.fragment.app.DialogFragment
|
import androidx.fragment.app.DialogFragment
|
||||||
import androidx.fragment.app.setFragmentResult
|
import androidx.fragment.app.setFragmentResult
|
||||||
|
import app.passwordstore.databinding.FragmentManualOtpEntryBinding
|
||||||
|
import app.passwordstore.ui.crypto.PasswordCreationActivity
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dev.msfjarvis.aps.databinding.FragmentManualOtpEntryBinding
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordCreationActivity
|
|
||||||
|
|
||||||
class OtpImportDialogFragment : DialogFragment() {
|
class OtpImportDialogFragment : DialogFragment() {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.dialogs
|
package app.passwordstore.ui.dialogs
|
||||||
|
|
||||||
import android.app.AlertDialog
|
import android.app.AlertDialog
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
|
@ -19,18 +19,18 @@ import androidx.core.os.bundleOf
|
||||||
import androidx.fragment.app.DialogFragment
|
import androidx.fragment.app.DialogFragment
|
||||||
import androidx.fragment.app.setFragmentResult
|
import androidx.fragment.app.setFragmentResult
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.FragmentPwgenBinding
|
||||||
|
import app.passwordstore.passgen.random.MaxIterationsExceededException
|
||||||
|
import app.passwordstore.passgen.random.NoCharactersIncludedException
|
||||||
|
import app.passwordstore.passgen.random.PasswordGenerator
|
||||||
|
import app.passwordstore.passgen.random.PasswordLengthTooShortException
|
||||||
|
import app.passwordstore.passgen.random.PasswordOption
|
||||||
|
import app.passwordstore.ui.crypto.PasswordCreationActivity
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.FragmentPwgenBinding
|
|
||||||
import dev.msfjarvis.aps.passgen.random.MaxIterationsExceededException
|
|
||||||
import dev.msfjarvis.aps.passgen.random.NoCharactersIncludedException
|
|
||||||
import dev.msfjarvis.aps.passgen.random.PasswordGenerator
|
|
||||||
import dev.msfjarvis.aps.passgen.random.PasswordLengthTooShortException
|
|
||||||
import dev.msfjarvis.aps.passgen.random.PasswordOption
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordCreationActivity
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import kotlinx.coroutines.flow.launchIn
|
import kotlinx.coroutines.flow.launchIn
|
||||||
import kotlinx.coroutines.flow.merge
|
import kotlinx.coroutines.flow.merge
|
||||||
import kotlinx.coroutines.flow.onEach
|
import kotlinx.coroutines.flow.onEach
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.folderselect
|
package app.passwordstore.ui.folderselect
|
||||||
|
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.Menu
|
import android.view.Menu
|
||||||
|
@ -10,10 +10,10 @@ import android.view.MenuItem
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.fragment.app.FragmentManager
|
import androidx.fragment.app.FragmentManager
|
||||||
import androidx.fragment.app.commit
|
import androidx.fragment.app.commit
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
import dev.msfjarvis.aps.ui.passwords.PASSWORD_FRAGMENT_TAG
|
import app.passwordstore.ui.passwords.PASSWORD_FRAGMENT_TAG
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordStore
|
import app.passwordstore.ui.passwords.PasswordStore
|
||||||
|
|
||||||
class SelectFolderActivity : AppCompatActivity(R.layout.select_folder_layout) {
|
class SelectFolderActivity : AppCompatActivity(R.layout.select_folder_layout) {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.folderselect
|
package app.passwordstore.ui.folderselect
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -12,16 +12,16 @@ import androidx.fragment.app.Fragment
|
||||||
import androidx.fragment.app.activityViewModels
|
import androidx.fragment.app.activityViewModels
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.password.PasswordItem
|
||||||
|
import app.passwordstore.databinding.PasswordRecyclerViewBinding
|
||||||
|
import app.passwordstore.ui.adapters.PasswordItemRecyclerAdapter
|
||||||
|
import app.passwordstore.ui.passwords.PasswordStore
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.viewmodel.ListMode
|
||||||
|
import app.passwordstore.util.viewmodel.SearchableRepositoryViewModel
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.password.PasswordItem
|
|
||||||
import dev.msfjarvis.aps.databinding.PasswordRecyclerViewBinding
|
|
||||||
import dev.msfjarvis.aps.ui.adapters.PasswordItemRecyclerAdapter
|
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordStore
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.ListMode
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.SearchableRepositoryViewModel
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import me.zhanghai.android.fastscroll.FastScrollerBuilder
|
import me.zhanghai.android.fastscroll.FastScrollerBuilder
|
||||||
|
|
|
@ -2,31 +2,31 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.git.base
|
package app.passwordstore.ui.git.base
|
||||||
|
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.injection.prefs.GitPreferences
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.git.ErrorMessages
|
||||||
|
import app.passwordstore.util.git.operation.BreakOutOfDetached
|
||||||
|
import app.passwordstore.util.git.operation.CloneOperation
|
||||||
|
import app.passwordstore.util.git.operation.GcOperation
|
||||||
|
import app.passwordstore.util.git.operation.PullOperation
|
||||||
|
import app.passwordstore.util.git.operation.PushOperation
|
||||||
|
import app.passwordstore.util.git.operation.ResetToRemoteOperation
|
||||||
|
import app.passwordstore.util.git.operation.SyncOperation
|
||||||
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.Err
|
import com.github.michaelbull.result.Err
|
||||||
import com.github.michaelbull.result.Result
|
import com.github.michaelbull.result.Result
|
||||||
import com.github.michaelbull.result.andThen
|
import com.github.michaelbull.result.andThen
|
||||||
import com.github.michaelbull.result.mapError
|
import com.github.michaelbull.result.mapError
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.GitPreferences
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.git.ErrorMessages
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.BreakOutOfDetached
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.CloneOperation
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.GcOperation
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.PullOperation
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.PushOperation
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.ResetToRemoteOperation
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.SyncOperation
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.git.config
|
package app.passwordstore.ui.git.config
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -12,18 +12,18 @@ import android.util.Patterns
|
||||||
import android.view.MenuItem
|
import android.view.MenuItem
|
||||||
import androidx.core.os.postDelayed
|
import androidx.core.os.postDelayed
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.databinding.ActivityGitConfigBinding
|
||||||
|
import app.passwordstore.ui.git.base.BaseGitActivity
|
||||||
|
import app.passwordstore.ui.git.log.GitLogActivity
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
import com.github.michaelbull.result.fold
|
import com.github.michaelbull.result.fold
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.databinding.ActivityGitConfigBinding
|
|
||||||
import dev.msfjarvis.aps.ui.git.base.BaseGitActivity
|
|
||||||
import dev.msfjarvis.aps.ui.git.log.GitLogActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.logcat
|
import logcat.logcat
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.git.config
|
package app.passwordstore.ui.git.config
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
@ -15,21 +15,21 @@ import androidx.core.os.postDelayed
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
import androidx.core.widget.doOnTextChanged
|
import androidx.core.widget.doOnTextChanged
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.databinding.ActivityGitCloneBinding
|
||||||
|
import app.passwordstore.ui.dialogs.BasicBottomSheet
|
||||||
|
import app.passwordstore.ui.git.base.BaseGitActivity
|
||||||
|
import app.passwordstore.util.extensions.snackbar
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.AuthMode
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
|
import app.passwordstore.util.settings.Protocol
|
||||||
import com.github.michaelbull.result.fold
|
import com.github.michaelbull.result.fold
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.databinding.ActivityGitCloneBinding
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.BasicBottomSheet
|
|
||||||
import dev.msfjarvis.aps.ui.git.base.BaseGitActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.snackbar
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.AuthMode
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import dev.msfjarvis.aps.util.settings.Protocol
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
|
@ -3,15 +3,15 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.git.log
|
package app.passwordstore.ui.git.log
|
||||||
|
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.MenuItem
|
import android.view.MenuItem
|
||||||
import androidx.recyclerview.widget.DividerItemDecoration
|
import androidx.recyclerview.widget.DividerItemDecoration
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
import dev.msfjarvis.aps.databinding.ActivityGitLogBinding
|
import app.passwordstore.databinding.ActivityGitLogBinding
|
||||||
import dev.msfjarvis.aps.ui.git.base.BaseGitActivity
|
import app.passwordstore.ui.git.base.BaseGitActivity
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Displays the repository's git commits in git-log fashion.
|
* Displays the repository's git commits in git-log fashion.
|
|
@ -3,14 +3,14 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.git.log
|
package app.passwordstore.ui.git.log
|
||||||
|
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.view.ViewGroup
|
import android.view.ViewGroup
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
import dev.msfjarvis.aps.databinding.GitLogRowLayoutBinding
|
import app.passwordstore.databinding.GitLogRowLayoutBinding
|
||||||
import dev.msfjarvis.aps.util.git.GitCommit
|
import app.passwordstore.util.git.GitCommit
|
||||||
import dev.msfjarvis.aps.util.git.GitLogModel
|
import app.passwordstore.util.git.GitLogModel
|
||||||
import java.text.DateFormat
|
import java.text.DateFormat
|
||||||
import java.util.Date
|
import java.util.Date
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.main
|
package app.passwordstore.ui.main
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -10,17 +10,17 @@ import android.os.Handler
|
||||||
import android.os.Looper
|
import android.os.Looper
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
|
import app.passwordstore.ui.crypto.BasePgpActivity
|
||||||
|
import app.passwordstore.ui.crypto.DecryptActivity
|
||||||
|
import app.passwordstore.ui.crypto.DecryptActivityV2
|
||||||
|
import app.passwordstore.ui.passwords.PasswordStore
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator.Result
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.ui.crypto.BasePgpActivity
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.DecryptActivity
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.DecryptActivityV2
|
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordStore
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator.Result
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
@AndroidEntryPoint
|
@AndroidEntryPoint
|
|
@ -3,11 +3,11 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.onboarding.activity
|
package app.passwordstore.ui.onboarding.activity
|
||||||
|
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
|
|
||||||
class OnboardingActivity : AppCompatActivity(R.layout.activity_onboarding) {
|
class OnboardingActivity : AppCompatActivity(R.layout.activity_onboarding) {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.onboarding.fragments
|
package app.passwordstore.ui.onboarding.fragments
|
||||||
|
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.View
|
import android.view.View
|
||||||
|
@ -11,18 +11,18 @@ import androidx.activity.result.contract.ActivityResultContracts
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.fragment.app.Fragment
|
import androidx.fragment.app.Fragment
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.databinding.FragmentCloneBinding
|
||||||
|
import app.passwordstore.ui.git.config.GitServerConfigActivity
|
||||||
|
import app.passwordstore.util.extensions.finish
|
||||||
|
import app.passwordstore.util.extensions.performTransactionWithBackStack
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.databinding.FragmentCloneBinding
|
|
||||||
import dev.msfjarvis.aps.ui.git.config.GitServerConfigActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.finish
|
|
||||||
import dev.msfjarvis.aps.util.extensions.performTransactionWithBackStack
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.asLog
|
import logcat.asLog
|
||||||
import logcat.logcat
|
import logcat.logcat
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.onboarding.fragments
|
package app.passwordstore.ui.onboarding.fragments
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -13,18 +13,18 @@ import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.fragment.app.Fragment
|
import androidx.fragment.app.Fragment
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.databinding.FragmentKeySelectionBinding
|
||||||
|
import app.passwordstore.ui.crypto.GetKeyIdsActivity
|
||||||
|
import app.passwordstore.util.extensions.commitChange
|
||||||
|
import app.passwordstore.util.extensions.finish
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.extensions.snackbar
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.databinding.FragmentKeySelectionBinding
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.GetKeyIdsActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.commitChange
|
|
||||||
import dev.msfjarvis.aps.util.extensions.finish
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.extensions.snackbar
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
|
@ -3,18 +3,18 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.onboarding.fragments
|
package app.passwordstore.ui.onboarding.fragments
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import androidx.annotation.Keep
|
import androidx.annotation.Keep
|
||||||
import androidx.fragment.app.Fragment
|
import androidx.fragment.app.Fragment
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
import dev.msfjarvis.aps.databinding.FragmentWelcomeBinding
|
import app.passwordstore.databinding.FragmentWelcomeBinding
|
||||||
import dev.msfjarvis.aps.ui.settings.SettingsActivity
|
import app.passwordstore.ui.settings.SettingsActivity
|
||||||
import dev.msfjarvis.aps.util.extensions.performTransactionWithBackStack
|
import app.passwordstore.util.extensions.performTransactionWithBackStack
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
|
||||||
@Keep
|
@Keep
|
||||||
class WelcomeFragment : Fragment(R.layout.fragment_welcome) {
|
class WelcomeFragment : Fragment(R.layout.fragment_welcome) {
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.passwords
|
package app.passwordstore.ui.passwords
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
|
@ -21,31 +21,31 @@ import androidx.fragment.app.activityViewModels
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
import androidx.recyclerview.widget.DividerItemDecoration
|
import androidx.recyclerview.widget.DividerItemDecoration
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager
|
import androidx.recyclerview.widget.LinearLayoutManager
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.password.PasswordItem
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.databinding.PasswordRecyclerViewBinding
|
||||||
|
import app.passwordstore.injection.prefs.SettingsPreferences
|
||||||
|
import app.passwordstore.ui.adapters.PasswordItemRecyclerAdapter
|
||||||
|
import app.passwordstore.ui.dialogs.BasicBottomSheet
|
||||||
|
import app.passwordstore.ui.dialogs.ItemCreationBottomSheet
|
||||||
|
import app.passwordstore.ui.git.base.BaseGitActivity
|
||||||
|
import app.passwordstore.ui.git.config.GitServerConfigActivity
|
||||||
|
import app.passwordstore.ui.util.OnOffItemAnimator
|
||||||
|
import app.passwordstore.util.extensions.base64
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.settings.AuthMode
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
|
import app.passwordstore.util.settings.PasswordSortOrder
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
|
import app.passwordstore.util.shortcuts.ShortcutHandler
|
||||||
|
import app.passwordstore.util.viewmodel.SearchableRepositoryViewModel
|
||||||
import com.github.michaelbull.result.fold
|
import com.github.michaelbull.result.fold
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.password.PasswordItem
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.databinding.PasswordRecyclerViewBinding
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.SettingsPreferences
|
|
||||||
import dev.msfjarvis.aps.ui.adapters.PasswordItemRecyclerAdapter
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.BasicBottomSheet
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.ItemCreationBottomSheet
|
|
||||||
import dev.msfjarvis.aps.ui.git.base.BaseGitActivity
|
|
||||||
import dev.msfjarvis.aps.ui.git.config.GitServerConfigActivity
|
|
||||||
import dev.msfjarvis.aps.ui.util.OnOffItemAnimator
|
|
||||||
import dev.msfjarvis.aps.util.extensions.base64
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.settings.AuthMode
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import dev.msfjarvis.aps.util.settings.PasswordSortOrder
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import dev.msfjarvis.aps.util.shortcuts.ShortcutHandler
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.SearchableRepositoryViewModel
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.passwords
|
package app.passwordstore.ui.passwords
|
||||||
|
|
||||||
import android.annotation.SuppressLint
|
import android.annotation.SuppressLint
|
||||||
import android.content.ComponentName
|
import android.content.ComponentName
|
||||||
|
@ -24,40 +24,40 @@ import androidx.fragment.app.FragmentManager
|
||||||
import androidx.fragment.app.commit
|
import androidx.fragment.app.commit
|
||||||
import androidx.lifecycle.ViewModelProvider
|
import androidx.lifecycle.ViewModelProvider
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.password.PasswordItem
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.ui.crypto.BasePgpActivity
|
||||||
|
import app.passwordstore.ui.crypto.BasePgpActivity.Companion.getLongName
|
||||||
|
import app.passwordstore.ui.crypto.DecryptActivity
|
||||||
|
import app.passwordstore.ui.crypto.DecryptActivityV2
|
||||||
|
import app.passwordstore.ui.crypto.PasswordCreationActivity
|
||||||
|
import app.passwordstore.ui.crypto.PasswordCreationActivityV2
|
||||||
|
import app.passwordstore.ui.dialogs.FolderCreationDialogFragment
|
||||||
|
import app.passwordstore.ui.folderselect.SelectFolderActivity
|
||||||
|
import app.passwordstore.ui.git.base.BaseGitActivity
|
||||||
|
import app.passwordstore.ui.onboarding.activity.OnboardingActivity
|
||||||
|
import app.passwordstore.ui.settings.SettingsActivity
|
||||||
|
import app.passwordstore.util.autofill.AutofillMatcher
|
||||||
|
import app.passwordstore.util.extensions.base64
|
||||||
|
import app.passwordstore.util.extensions.commitChange
|
||||||
|
import app.passwordstore.util.extensions.contains
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.isInsideRepository
|
||||||
|
import app.passwordstore.util.extensions.listFilesRecursively
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
|
import app.passwordstore.util.settings.AuthMode
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
|
import app.passwordstore.util.shortcuts.ShortcutHandler
|
||||||
|
import app.passwordstore.util.viewmodel.SearchableRepositoryViewModel
|
||||||
import com.github.michaelbull.result.fold
|
import com.github.michaelbull.result.fold
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import com.google.android.material.textfield.TextInputEditText
|
import com.google.android.material.textfield.TextInputEditText
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.password.PasswordItem
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.BasePgpActivity
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.BasePgpActivity.Companion.getLongName
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.DecryptActivity
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.DecryptActivityV2
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordCreationActivity
|
|
||||||
import dev.msfjarvis.aps.ui.crypto.PasswordCreationActivityV2
|
|
||||||
import dev.msfjarvis.aps.ui.dialogs.FolderCreationDialogFragment
|
|
||||||
import dev.msfjarvis.aps.ui.folderselect.SelectFolderActivity
|
|
||||||
import dev.msfjarvis.aps.ui.git.base.BaseGitActivity
|
|
||||||
import dev.msfjarvis.aps.ui.onboarding.activity.OnboardingActivity
|
|
||||||
import dev.msfjarvis.aps.ui.settings.SettingsActivity
|
|
||||||
import dev.msfjarvis.aps.util.autofill.AutofillMatcher
|
|
||||||
import dev.msfjarvis.aps.util.extensions.base64
|
|
||||||
import dev.msfjarvis.aps.util.extensions.commitChange
|
|
||||||
import dev.msfjarvis.aps.util.extensions.contains
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.isInsideRepository
|
|
||||||
import dev.msfjarvis.aps.util.extensions.listFilesRecursively
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import dev.msfjarvis.aps.util.settings.AuthMode
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import dev.msfjarvis.aps.util.shortcuts.ShortcutHandler
|
|
||||||
import dev.msfjarvis.aps.util.viewmodel.SearchableRepositoryViewModel
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.lang.Character.UnicodeBlock
|
import java.lang.Character.UnicodeBlock
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
|
@ -4,19 +4,19 @@
|
||||||
*/
|
*/
|
||||||
@file:Suppress("BlockingMethodInNonBlockingContext")
|
@file:Suppress("BlockingMethodInNonBlockingContext")
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.pgp
|
package app.passwordstore.ui.pgp
|
||||||
|
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import androidx.activity.result.contract.ActivityResultContracts.OpenDocument
|
import androidx.activity.result.contract.ActivityResultContracts.OpenDocument
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.crypto.KeyUtils.tryGetId
|
||||||
|
import app.passwordstore.crypto.PGPKey
|
||||||
|
import app.passwordstore.crypto.PGPKeyManager
|
||||||
import com.github.michaelbull.result.mapBoth
|
import com.github.michaelbull.result.mapBoth
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.crypto.KeyUtils.tryGetId
|
|
||||||
import dev.msfjarvis.aps.crypto.PGPKey
|
|
||||||
import dev.msfjarvis.aps.crypto.PGPKeyManager
|
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import kotlinx.coroutines.runBlocking
|
import kotlinx.coroutines.runBlocking
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.proxy
|
package app.passwordstore.ui.proxy
|
||||||
|
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import android.net.InetAddresses
|
import android.net.InetAddresses
|
||||||
|
@ -16,15 +16,15 @@ import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.core.os.postDelayed
|
import androidx.core.os.postDelayed
|
||||||
import androidx.core.widget.doOnTextChanged
|
import androidx.core.widget.doOnTextChanged
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.ActivityProxySelectorBinding
|
||||||
|
import app.passwordstore.injection.prefs.ProxyPreferences
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.proxy.ProxyUtils
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.ActivityProxySelectorBinding
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.ProxyPreferences
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.proxy.ProxyUtils
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private val WEB_ADDRESS_REGEX = Patterns.WEB_URL.toRegex()
|
private val WEB_ADDRESS_REGEX = Patterns.WEB_URL.toRegex()
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import android.annotation.SuppressLint
|
import android.annotation.SuppressLint
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
@ -15,6 +15,11 @@ import androidx.appcompat.widget.AppCompatTextView
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
import androidx.lifecycle.Lifecycle
|
import androidx.lifecycle.Lifecycle
|
||||||
import androidx.lifecycle.LifecycleEventObserver
|
import androidx.lifecycle.LifecycleEventObserver
|
||||||
|
import app.passwordstore.BuildConfig
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.autofill.DirectoryStructure
|
||||||
|
import app.passwordstore.util.extensions.autofillManager
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.androidpasswordstore.autofillparser.BrowserAutofillSupportLevel
|
import com.github.androidpasswordstore.autofillparser.BrowserAutofillSupportLevel
|
||||||
import com.github.androidpasswordstore.autofillparser.getInstalledBrowsersWithAutofillSupportLevel
|
import com.github.androidpasswordstore.autofillparser.getInstalledBrowsersWithAutofillSupportLevel
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
|
@ -25,11 +30,6 @@ import de.Maxr1998.modernpreferences.helpers.singleChoice
|
||||||
import de.Maxr1998.modernpreferences.helpers.switch
|
import de.Maxr1998.modernpreferences.helpers.switch
|
||||||
import de.Maxr1998.modernpreferences.preferences.SwitchPreference
|
import de.Maxr1998.modernpreferences.preferences.SwitchPreference
|
||||||
import de.Maxr1998.modernpreferences.preferences.choice.SelectionItem
|
import de.Maxr1998.modernpreferences.preferences.choice.SelectionItem
|
||||||
import dev.msfjarvis.aps.BuildConfig
|
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.autofill.DirectoryStructure
|
|
||||||
import dev.msfjarvis.aps.util.extensions.autofillManager
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
|
|
||||||
class AutofillSettings(private val activity: FragmentActivity) : SettingsProvider {
|
class AutofillSettings(private val activity: FragmentActivity) : SettingsProvider {
|
||||||
|
|
|
@ -3,23 +3,23 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import android.content.pm.ShortcutManager
|
import android.content.pm.ShortcutManager
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.core.content.getSystemService
|
import androidx.core.content.getSystemService
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator.Result
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import de.Maxr1998.modernpreferences.PreferenceScreen
|
import de.Maxr1998.modernpreferences.PreferenceScreen
|
||||||
import de.Maxr1998.modernpreferences.helpers.checkBox
|
import de.Maxr1998.modernpreferences.helpers.checkBox
|
||||||
import de.Maxr1998.modernpreferences.helpers.onClick
|
import de.Maxr1998.modernpreferences.helpers.onClick
|
||||||
import de.Maxr1998.modernpreferences.helpers.singleChoice
|
import de.Maxr1998.modernpreferences.helpers.singleChoice
|
||||||
import de.Maxr1998.modernpreferences.preferences.choice.SelectionItem
|
import de.Maxr1998.modernpreferences.preferences.choice.SelectionItem
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator.Result
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
|
|
||||||
class GeneralSettings(private val activity: FragmentActivity) : SettingsProvider {
|
class GeneralSettings(private val activity: FragmentActivity) : SettingsProvider {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
@ -12,14 +12,14 @@ import android.os.Build
|
||||||
import androidx.activity.result.contract.ActivityResultContracts
|
import androidx.activity.result.contract.ActivityResultContracts
|
||||||
import androidx.documentfile.provider.DocumentFile
|
import androidx.documentfile.provider.DocumentFile
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.BuildConfig
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.services.PasswordExportService
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import de.Maxr1998.modernpreferences.PreferenceScreen
|
import de.Maxr1998.modernpreferences.PreferenceScreen
|
||||||
import de.Maxr1998.modernpreferences.helpers.checkBox
|
import de.Maxr1998.modernpreferences.helpers.checkBox
|
||||||
import de.Maxr1998.modernpreferences.helpers.onClick
|
import de.Maxr1998.modernpreferences.helpers.onClick
|
||||||
import de.Maxr1998.modernpreferences.helpers.pref
|
import de.Maxr1998.modernpreferences.helpers.pref
|
||||||
import dev.msfjarvis.aps.BuildConfig
|
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.services.PasswordExportService
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
|
|
||||||
class MiscSettings(activity: FragmentActivity) : SettingsProvider {
|
class MiscSettings(activity: FragmentActivity) : SettingsProvider {
|
||||||
|
|
|
@ -3,16 +3,16 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.ui.pgp.PGPKeyImportActivity
|
||||||
|
import app.passwordstore.util.extensions.launchActivity
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
import de.Maxr1998.modernpreferences.PreferenceScreen
|
import de.Maxr1998.modernpreferences.PreferenceScreen
|
||||||
import de.Maxr1998.modernpreferences.helpers.checkBox
|
import de.Maxr1998.modernpreferences.helpers.checkBox
|
||||||
import de.Maxr1998.modernpreferences.helpers.onClick
|
import de.Maxr1998.modernpreferences.helpers.onClick
|
||||||
import de.Maxr1998.modernpreferences.helpers.pref
|
import de.Maxr1998.modernpreferences.helpers.pref
|
||||||
import dev.msfjarvis.aps.ui.pgp.PGPKeyImportActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.launchActivity
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
|
|
||||||
class PGPSettings(private val activity: FragmentActivity) : SettingsProvider {
|
class PGPSettings(private val activity: FragmentActivity) : SettingsProvider {
|
||||||
|
|
|
@ -3,18 +3,18 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import android.text.InputType
|
import android.text.InputType
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import de.Maxr1998.modernpreferences.PreferenceScreen
|
import de.Maxr1998.modernpreferences.PreferenceScreen
|
||||||
import de.Maxr1998.modernpreferences.helpers.checkBox
|
import de.Maxr1998.modernpreferences.helpers.checkBox
|
||||||
import de.Maxr1998.modernpreferences.helpers.editText
|
import de.Maxr1998.modernpreferences.helpers.editText
|
||||||
import de.Maxr1998.modernpreferences.helpers.onSelectionChange
|
import de.Maxr1998.modernpreferences.helpers.onSelectionChange
|
||||||
import de.Maxr1998.modernpreferences.helpers.singleChoice
|
import de.Maxr1998.modernpreferences.helpers.singleChoice
|
||||||
import de.Maxr1998.modernpreferences.preferences.choice.SelectionItem
|
import de.Maxr1998.modernpreferences.preferences.choice.SelectionItem
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
|
|
||||||
class PasswordSettings(private val activity: FragmentActivity) : SettingsProvider {
|
class PasswordSettings(private val activity: FragmentActivity) : SettingsProvider {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
|
@ -13,6 +13,23 @@ import androidx.activity.result.contract.ActivityResultContracts
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.core.content.getSystemService
|
import androidx.core.content.getSystemService
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.injection.prefs.GitPreferences
|
||||||
|
import app.passwordstore.ui.git.config.GitConfigActivity
|
||||||
|
import app.passwordstore.ui.git.config.GitServerConfigActivity
|
||||||
|
import app.passwordstore.ui.proxy.ProxySelectorActivity
|
||||||
|
import app.passwordstore.ui.sshkeygen.ShowSshKeyFragment
|
||||||
|
import app.passwordstore.ui.sshkeygen.SshKeyGenActivity
|
||||||
|
import app.passwordstore.ui.sshkeygen.SshKeyImportActivity
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.launchActivity
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.extensions.snackbar
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.git.sshj.SshKey
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
|
@ -25,23 +42,6 @@ import de.Maxr1998.modernpreferences.PreferenceScreen
|
||||||
import de.Maxr1998.modernpreferences.helpers.checkBox
|
import de.Maxr1998.modernpreferences.helpers.checkBox
|
||||||
import de.Maxr1998.modernpreferences.helpers.onClick
|
import de.Maxr1998.modernpreferences.helpers.onClick
|
||||||
import de.Maxr1998.modernpreferences.helpers.pref
|
import de.Maxr1998.modernpreferences.helpers.pref
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.GitPreferences
|
|
||||||
import dev.msfjarvis.aps.ui.git.config.GitConfigActivity
|
|
||||||
import dev.msfjarvis.aps.ui.git.config.GitServerConfigActivity
|
|
||||||
import dev.msfjarvis.aps.ui.proxy.ProxySelectorActivity
|
|
||||||
import dev.msfjarvis.aps.ui.sshkeygen.ShowSshKeyFragment
|
|
||||||
import dev.msfjarvis.aps.ui.sshkeygen.SshKeyGenActivity
|
|
||||||
import dev.msfjarvis.aps.ui.sshkeygen.SshKeyImportActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.launchActivity
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.extensions.snackbar
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.SshKey
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
|
|
||||||
class RepositorySettings(private val activity: FragmentActivity) : SettingsProvider {
|
class RepositorySettings(private val activity: FragmentActivity) : SettingsProvider {
|
||||||
|
|
|
@ -3,19 +3,19 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.view.MenuItem
|
import android.view.MenuItem
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.ActivityPreferenceRecyclerviewBinding
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import de.Maxr1998.modernpreferences.Preference
|
import de.Maxr1998.modernpreferences.Preference
|
||||||
import de.Maxr1998.modernpreferences.PreferencesAdapter
|
import de.Maxr1998.modernpreferences.PreferencesAdapter
|
||||||
import de.Maxr1998.modernpreferences.helpers.screen
|
import de.Maxr1998.modernpreferences.helpers.screen
|
||||||
import de.Maxr1998.modernpreferences.helpers.subScreen
|
import de.Maxr1998.modernpreferences.helpers.subScreen
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.ActivityPreferenceRecyclerviewBinding
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
|
|
||||||
class SettingsActivity : AppCompatActivity() {
|
class SettingsActivity : AppCompatActivity() {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.settings
|
package app.passwordstore.ui.settings
|
||||||
|
|
||||||
import de.Maxr1998.modernpreferences.PreferenceScreen
|
import de.Maxr1998.modernpreferences.PreferenceScreen
|
||||||
|
|
|
@ -2,15 +2,15 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.sshkeygen
|
package app.passwordstore.ui.sshkeygen
|
||||||
|
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import androidx.fragment.app.DialogFragment
|
import androidx.fragment.app.DialogFragment
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.git.sshj.SshKey
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.SshKey
|
|
||||||
|
|
||||||
class ShowSshKeyFragment : DialogFragment() {
|
class ShowSshKeyFragment : DialogFragment() {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.sshkeygen
|
package app.passwordstore.ui.sshkeygen
|
||||||
|
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -14,18 +14,18 @@ import androidx.appcompat.app.AppCompatActivity
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.core.content.getSystemService
|
import androidx.core.content.getSystemService
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.databinding.ActivitySshKeygenBinding
|
||||||
|
import app.passwordstore.injection.prefs.GitPreferences
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator.Result
|
||||||
|
import app.passwordstore.util.extensions.keyguardManager
|
||||||
|
import app.passwordstore.util.extensions.viewBinding
|
||||||
|
import app.passwordstore.util.git.sshj.SshKey
|
||||||
import com.github.michaelbull.result.fold
|
import com.github.michaelbull.result.fold
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.databinding.ActivitySshKeygenBinding
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.GitPreferences
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator.Result
|
|
||||||
import dev.msfjarvis.aps.util.extensions.keyguardManager
|
|
||||||
import dev.msfjarvis.aps.util.extensions.viewBinding
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.SshKey
|
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import kotlin.coroutines.resume
|
import kotlin.coroutines.resume
|
||||||
import kotlin.coroutines.suspendCoroutine
|
import kotlin.coroutines.suspendCoroutine
|
|
@ -3,18 +3,18 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.ui.sshkeygen
|
package app.passwordstore.ui.sshkeygen
|
||||||
|
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.widget.Toast
|
import android.widget.Toast
|
||||||
import androidx.activity.result.contract.ActivityResultContracts
|
import androidx.activity.result.contract.ActivityResultContracts
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.git.sshj.SshKey
|
||||||
import com.github.michaelbull.result.onFailure
|
import com.github.michaelbull.result.onFailure
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.SshKey
|
|
||||||
|
|
||||||
class SshKeyImportActivity : AppCompatActivity() {
|
class SshKeyImportActivity : AppCompatActivity() {
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.ui.util
|
package app.passwordstore.ui.util
|
||||||
|
|
||||||
import androidx.recyclerview.widget.DefaultItemAnimator
|
import androidx.recyclerview.widget.DefaultItemAnimator
|
||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.auth
|
package app.passwordstore.util.auth
|
||||||
|
|
||||||
import android.app.KeyguardManager
|
import android.app.KeyguardManager
|
||||||
import androidx.annotation.StringRes
|
import androidx.annotation.StringRes
|
||||||
|
@ -12,7 +12,7 @@ import androidx.biometric.BiometricPrompt
|
||||||
import androidx.core.content.ContextCompat
|
import androidx.core.content.ContextCompat
|
||||||
import androidx.core.content.getSystemService
|
import androidx.core.content.getSystemService
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
import logcat.logcat
|
import logcat.logcat
|
||||||
|
|
||||||
object BiometricAuthenticator {
|
object BiometricAuthenticator {
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.autofill
|
package app.passwordstore.util.autofill
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.IntentSender
|
import android.content.IntentSender
|
||||||
|
@ -14,6 +14,14 @@ import android.service.autofill.SaveInfo
|
||||||
import android.view.inputmethod.InlineSuggestionsRequest
|
import android.view.inputmethod.InlineSuggestionsRequest
|
||||||
import android.widget.inline.InlinePresentationSpec
|
import android.widget.inline.InlinePresentationSpec
|
||||||
import androidx.annotation.RequiresApi
|
import androidx.annotation.RequiresApi
|
||||||
|
import app.passwordstore.autofill.oreo.ui.AutofillSmsActivity
|
||||||
|
import app.passwordstore.ui.autofill.AutofillDecryptActivity
|
||||||
|
import app.passwordstore.ui.autofill.AutofillDecryptActivityV2
|
||||||
|
import app.passwordstore.ui.autofill.AutofillFilterView
|
||||||
|
import app.passwordstore.ui.autofill.AutofillPublisherChangedActivity
|
||||||
|
import app.passwordstore.ui.autofill.AutofillSaveActivity
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
||||||
import com.github.androidpasswordstore.autofillparser.FillableForm
|
import com.github.androidpasswordstore.autofillparser.FillableForm
|
||||||
import com.github.androidpasswordstore.autofillparser.fillWith
|
import com.github.androidpasswordstore.autofillparser.fillWith
|
||||||
|
@ -21,14 +29,6 @@ import com.github.michaelbull.result.fold
|
||||||
import dagger.assisted.Assisted
|
import dagger.assisted.Assisted
|
||||||
import dagger.assisted.AssistedFactory
|
import dagger.assisted.AssistedFactory
|
||||||
import dagger.assisted.AssistedInject
|
import dagger.assisted.AssistedInject
|
||||||
import dev.msfjarvis.aps.autofill.oreo.ui.AutofillSmsActivity
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillDecryptActivity
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillDecryptActivityV2
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillFilterView
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillPublisherChangedActivity
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillSaveActivity
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.asLog
|
import logcat.asLog
|
|
@ -2,18 +2,18 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.autofill
|
package app.passwordstore.util.autofill
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import android.widget.Toast
|
import android.widget.Toast
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
|
import app.passwordstore.R
|
||||||
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
import com.github.androidpasswordstore.autofillparser.FormOrigin
|
||||||
import com.github.androidpasswordstore.autofillparser.computeCertificatesHash
|
import com.github.androidpasswordstore.autofillparser.computeCertificatesHash
|
||||||
import com.github.michaelbull.result.Err
|
import com.github.michaelbull.result.Err
|
||||||
import com.github.michaelbull.result.Ok
|
import com.github.michaelbull.result.Ok
|
||||||
import com.github.michaelbull.result.Result
|
import com.github.michaelbull.result.Result
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.LogPriority.WARN
|
import logcat.LogPriority.WARN
|
|
@ -2,16 +2,16 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.autofill
|
package app.passwordstore.util.autofill
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import androidx.annotation.RequiresApi
|
import androidx.annotation.RequiresApi
|
||||||
|
import app.passwordstore.data.passfile.PasswordEntry
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.services.getDefaultUsername
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.androidpasswordstore.autofillparser.Credentials
|
import com.github.androidpasswordstore.autofillparser.Credentials
|
||||||
import dev.msfjarvis.aps.data.passfile.PasswordEntry
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.services.getDefaultUsername
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.nio.file.Paths
|
import java.nio.file.Paths
|
||||||
import kotlinx.coroutines.flow.first
|
import kotlinx.coroutines.flow.first
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.autofill
|
package app.passwordstore.util.autofill
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.IntentSender
|
import android.content.IntentSender
|
||||||
|
@ -13,6 +13,14 @@ import android.service.autofill.FillCallback
|
||||||
import android.service.autofill.FillResponse
|
import android.service.autofill.FillResponse
|
||||||
import android.service.autofill.SaveInfo
|
import android.service.autofill.SaveInfo
|
||||||
import androidx.annotation.RequiresApi
|
import androidx.annotation.RequiresApi
|
||||||
|
import app.passwordstore.autofill.oreo.ui.AutofillSmsActivity
|
||||||
|
import app.passwordstore.ui.autofill.AutofillDecryptActivity
|
||||||
|
import app.passwordstore.ui.autofill.AutofillDecryptActivityV2
|
||||||
|
import app.passwordstore.ui.autofill.AutofillFilterView
|
||||||
|
import app.passwordstore.ui.autofill.AutofillPublisherChangedActivity
|
||||||
|
import app.passwordstore.ui.autofill.AutofillSaveActivity
|
||||||
|
import app.passwordstore.util.features.Feature
|
||||||
|
import app.passwordstore.util.features.Features
|
||||||
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
import com.github.androidpasswordstore.autofillparser.AutofillAction
|
||||||
import com.github.androidpasswordstore.autofillparser.AutofillScenario
|
import com.github.androidpasswordstore.autofillparser.AutofillScenario
|
||||||
import com.github.androidpasswordstore.autofillparser.Credentials
|
import com.github.androidpasswordstore.autofillparser.Credentials
|
||||||
|
@ -22,14 +30,6 @@ import com.github.michaelbull.result.fold
|
||||||
import dagger.assisted.Assisted
|
import dagger.assisted.Assisted
|
||||||
import dagger.assisted.AssistedFactory
|
import dagger.assisted.AssistedFactory
|
||||||
import dagger.assisted.AssistedInject
|
import dagger.assisted.AssistedInject
|
||||||
import dev.msfjarvis.aps.autofill.oreo.ui.AutofillSmsActivity
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillDecryptActivity
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillDecryptActivityV2
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillFilterView
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillPublisherChangedActivity
|
|
||||||
import dev.msfjarvis.aps.ui.autofill.AutofillSaveActivity
|
|
||||||
import dev.msfjarvis.aps.util.features.Feature
|
|
||||||
import dev.msfjarvis.aps.util.features.Features
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.asLog
|
import logcat.asLog
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.autofill
|
package app.passwordstore.util.autofill
|
||||||
|
|
||||||
import android.annotation.SuppressLint
|
import android.annotation.SuppressLint
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
|
@ -18,9 +18,9 @@ import android.widget.inline.InlinePresentationSpec
|
||||||
import androidx.annotation.DrawableRes
|
import androidx.annotation.DrawableRes
|
||||||
import androidx.autofill.inline.UiVersions
|
import androidx.autofill.inline.UiVersions
|
||||||
import androidx.autofill.inline.v1.InlineSuggestionUi
|
import androidx.autofill.inline.v1.InlineSuggestionUi
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
import dev.msfjarvis.aps.ui.passwords.PasswordStore
|
import app.passwordstore.ui.passwords.PasswordStore
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
||||||
data class DatasetMetadata(val title: String, val subtitle: String?, @DrawableRes val iconRes: Int)
|
data class DatasetMetadata(val title: String, val subtitle: String?, @DrawableRes val iconRes: Int)
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.crypto
|
package app.passwordstore.util.crypto
|
||||||
|
|
||||||
import me.msfjarvis.openpgpktx.util.OpenPgpUtils
|
import me.msfjarvis.openpgpktx.util.OpenPgpUtils
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.extensions
|
package app.passwordstore.util.extensions
|
||||||
|
|
||||||
import android.app.KeyguardManager
|
import android.app.KeyguardManager
|
||||||
import android.content.ClipboardManager
|
import android.content.ClipboardManager
|
||||||
|
@ -21,13 +21,13 @@ import androidx.core.content.getSystemService
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
import androidx.security.crypto.EncryptedSharedPreferences
|
import androidx.security.crypto.EncryptedSharedPreferences
|
||||||
import androidx.security.crypto.MasterKey
|
import androidx.security.crypto.MasterKey
|
||||||
|
import app.passwordstore.BuildConfig
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.util.git.operation.GitOperation
|
||||||
import com.github.michaelbull.result.Ok
|
import com.github.michaelbull.result.Ok
|
||||||
import com.github.michaelbull.result.Result
|
import com.github.michaelbull.result.Result
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
import dev.msfjarvis.aps.BuildConfig
|
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.GitOperation
|
|
||||||
import logcat.logcat
|
import logcat.logcat
|
||||||
|
|
||||||
/** Get an instance of [AutofillManager]. Only available on Android Oreo and above */
|
/** Get an instance of [AutofillManager]. Only available on Android Oreo and above */
|
|
@ -2,14 +2,14 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.extensions
|
package app.passwordstore.util.extensions
|
||||||
|
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
import com.github.michaelbull.result.Err
|
import com.github.michaelbull.result.Err
|
||||||
import com.github.michaelbull.result.Ok
|
import com.github.michaelbull.result.Ok
|
||||||
import com.github.michaelbull.result.Result
|
import com.github.michaelbull.result.Result
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.util.Date
|
import java.util.Date
|
||||||
import logcat.asLog
|
import logcat.asLog
|
|
@ -3,13 +3,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.extensions
|
package app.passwordstore.util.extensions
|
||||||
|
|
||||||
import androidx.annotation.IdRes
|
import androidx.annotation.IdRes
|
||||||
import androidx.fragment.app.Fragment
|
import androidx.fragment.app.Fragment
|
||||||
import androidx.fragment.app.FragmentManager
|
import androidx.fragment.app.FragmentManager
|
||||||
import androidx.fragment.app.commit
|
import androidx.fragment.app.commit
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
|
|
||||||
/** Check if [permission] is granted to the app. Aliases to [isPermissionGranted] internally. */
|
/** Check if [permission] is granted to the app. Aliases to [isPermissionGranted] internally. */
|
||||||
fun Fragment.isPermissionGranted(permission: String): Boolean {
|
fun Fragment.isPermissionGranted(permission: String): Boolean {
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.extensions
|
package app.passwordstore.util.extensions
|
||||||
|
|
||||||
import android.view.LayoutInflater
|
import android.view.LayoutInflater
|
||||||
import android.view.View
|
import android.view.View
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.features
|
package app.passwordstore.util.features
|
||||||
|
|
||||||
/** List of all feature flags for the app. */
|
/** List of all feature flags for the app. */
|
||||||
enum class Feature(
|
enum class Feature(
|
|
@ -3,10 +3,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.features
|
package app.passwordstore.util.features
|
||||||
|
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
import dev.msfjarvis.aps.injection.prefs.SettingsPreferences
|
import app.passwordstore.injection.prefs.SettingsPreferences
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class Features
|
class Features
|
|
@ -3,12 +3,12 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.git
|
package app.passwordstore.util.git
|
||||||
|
|
||||||
import android.os.RemoteException
|
import android.os.RemoteException
|
||||||
import androidx.annotation.StringRes
|
import androidx.annotation.StringRes
|
||||||
import dev.msfjarvis.aps.Application
|
import app.passwordstore.Application
|
||||||
import dev.msfjarvis.aps.R
|
import app.passwordstore.R
|
||||||
import java.net.UnknownHostException
|
import java.net.UnknownHostException
|
||||||
|
|
||||||
/**
|
/**
|
|
@ -3,10 +3,17 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.git
|
package app.passwordstore.util.git
|
||||||
|
|
||||||
import android.widget.Toast
|
import android.widget.Toast
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.extensions.snackbar
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.git.GitException.PullException
|
||||||
|
import app.passwordstore.util.git.GitException.PushException
|
||||||
|
import app.passwordstore.util.git.operation.GitOperation
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
import com.github.michaelbull.result.Result
|
import com.github.michaelbull.result.Result
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
|
@ -14,13 +21,6 @@ import dagger.hilt.EntryPoint
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.android.EntryPointAccessors
|
import dagger.hilt.android.EntryPointAccessors
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.extensions.snackbar
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.git.GitException.PullException
|
|
||||||
import dev.msfjarvis.aps.util.git.GitException.PushException
|
|
||||||
import dev.msfjarvis.aps.util.git.operation.GitOperation
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import org.eclipse.jgit.api.CommitCommand
|
import org.eclipse.jgit.api.CommitCommand
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.git
|
package app.passwordstore.util.git
|
||||||
|
|
||||||
import java.util.Date
|
import java.util.Date
|
||||||
|
|
|
@ -3,15 +3,15 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.git
|
package app.passwordstore.util.git
|
||||||
|
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.util.extensions.asLog
|
||||||
|
import app.passwordstore.util.extensions.hash
|
||||||
|
import app.passwordstore.util.extensions.time
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.util.extensions.asLog
|
|
||||||
import dev.msfjarvis.aps.util.extensions.hash
|
|
||||||
import dev.msfjarvis.aps.util.extensions.time
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import logcat.LogPriority.ERROR
|
import logcat.LogPriority.ERROR
|
||||||
import logcat.logcat
|
import logcat.logcat
|
||||||
import org.eclipse.jgit.api.Git
|
import org.eclipse.jgit.api.Git
|
|
@ -2,12 +2,12 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
|
||||||
import org.eclipse.jgit.api.RebaseCommand
|
import org.eclipse.jgit.api.RebaseCommand
|
||||||
import org.eclipse.jgit.api.ResetCommand
|
import org.eclipse.jgit.api.ResetCommand
|
||||||
import org.eclipse.jgit.lib.RepositoryState
|
import org.eclipse.jgit.lib.RepositoryState
|
|
@ -2,9 +2,9 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
import org.eclipse.jgit.api.Git
|
import org.eclipse.jgit.api.Git
|
||||||
import org.eclipse.jgit.api.GitCommand
|
import org.eclipse.jgit.api.GitCommand
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import android.annotation.SuppressLint
|
import android.annotation.SuppressLint
|
||||||
import android.content.SharedPreferences
|
import android.content.SharedPreferences
|
||||||
|
@ -13,6 +13,11 @@ import androidx.annotation.StringRes
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.core.widget.doOnTextChanged
|
import androidx.core.widget.doOnTextChanged
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.injection.prefs.GitPreferences
|
||||||
|
import app.passwordstore.util.git.sshj.InteractivePasswordFinder
|
||||||
|
import app.passwordstore.util.settings.AuthMode
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.google.android.material.checkbox.MaterialCheckBox
|
import com.google.android.material.checkbox.MaterialCheckBox
|
||||||
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
import com.google.android.material.dialog.MaterialAlertDialogBuilder
|
||||||
import com.google.android.material.textfield.TextInputEditText
|
import com.google.android.material.textfield.TextInputEditText
|
||||||
|
@ -21,11 +26,6 @@ import dagger.hilt.EntryPoint
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.android.EntryPointAccessors
|
import dagger.hilt.android.EntryPointAccessors
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.injection.prefs.GitPreferences
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.InteractivePasswordFinder
|
|
||||||
import dev.msfjarvis.aps.util.settings.AuthMode
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import kotlin.coroutines.Continuation
|
import kotlin.coroutines.Continuation
|
||||||
import kotlin.coroutines.resume
|
import kotlin.coroutines.resume
|
||||||
|
|
|
@ -3,9 +3,9 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
import org.eclipse.jgit.api.GitCommand
|
import org.eclipse.jgit.api.GitCommand
|
||||||
|
|
||||||
/**
|
/**
|
|
@ -2,11 +2,24 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.widget.Toast
|
import android.widget.Toast
|
||||||
import androidx.fragment.app.FragmentActivity
|
import androidx.fragment.app.FragmentActivity
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.data.repo.PasswordRepository
|
||||||
|
import app.passwordstore.ui.sshkeygen.SshKeyGenActivity
|
||||||
|
import app.passwordstore.ui.sshkeygen.SshKeyImportActivity
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator
|
||||||
|
import app.passwordstore.util.auth.BiometricAuthenticator.Result.*
|
||||||
|
import app.passwordstore.util.git.GitCommandExecutor
|
||||||
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
|
import app.passwordstore.util.git.sshj.SshAuthMethod
|
||||||
|
import app.passwordstore.util.git.sshj.SshKey
|
||||||
|
import app.passwordstore.util.git.sshj.SshjSessionFactory
|
||||||
|
import app.passwordstore.util.settings.AuthMode
|
||||||
|
import app.passwordstore.util.settings.GitSettings
|
||||||
import com.github.michaelbull.result.Err
|
import com.github.michaelbull.result.Err
|
||||||
import com.github.michaelbull.result.Ok
|
import com.github.michaelbull.result.Ok
|
||||||
import com.github.michaelbull.result.Result
|
import com.github.michaelbull.result.Result
|
||||||
|
@ -17,19 +30,6 @@ import dagger.hilt.EntryPoint
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.android.EntryPointAccessors
|
import dagger.hilt.android.EntryPointAccessors
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.data.repo.PasswordRepository
|
|
||||||
import dev.msfjarvis.aps.ui.sshkeygen.SshKeyGenActivity
|
|
||||||
import dev.msfjarvis.aps.ui.sshkeygen.SshKeyImportActivity
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator
|
|
||||||
import dev.msfjarvis.aps.util.auth.BiometricAuthenticator.Result.*
|
|
||||||
import dev.msfjarvis.aps.util.git.GitCommandExecutor
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.SshAuthMethod
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.SshKey
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.SshjSessionFactory
|
|
||||||
import dev.msfjarvis.aps.util.settings.AuthMode
|
|
||||||
import dev.msfjarvis.aps.util.settings.GitSettings
|
|
||||||
import kotlin.coroutines.resume
|
import kotlin.coroutines.resume
|
||||||
import kotlin.coroutines.suspendCoroutine
|
import kotlin.coroutines.suspendCoroutine
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
|
@ -2,9 +2,9 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
import org.eclipse.jgit.api.GitCommand
|
import org.eclipse.jgit.api.GitCommand
|
||||||
|
|
||||||
class PullOperation(
|
class PullOperation(
|
|
@ -2,9 +2,9 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
import org.eclipse.jgit.api.GitCommand
|
import org.eclipse.jgit.api.GitCommand
|
||||||
|
|
||||||
class PushOperation(callingActivity: ContinuationContainerActivity) :
|
class PushOperation(callingActivity: ContinuationContainerActivity) :
|
|
@ -2,9 +2,9 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
import org.eclipse.jgit.api.ResetCommand
|
import org.eclipse.jgit.api.ResetCommand
|
||||||
|
|
||||||
class ResetToRemoteOperation(callingActivity: ContinuationContainerActivity) :
|
class ResetToRemoteOperation(callingActivity: ContinuationContainerActivity) :
|
|
@ -2,9 +2,9 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.operation
|
package app.passwordstore.util.git.operation
|
||||||
|
|
||||||
import dev.msfjarvis.aps.util.git.sshj.ContinuationContainerActivity
|
import app.passwordstore.util.git.sshj.ContinuationContainerActivity
|
||||||
|
|
||||||
class SyncOperation(
|
class SyncOperation(
|
||||||
callingActivity: ContinuationContainerActivity,
|
callingActivity: ContinuationContainerActivity,
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.sshj
|
package app.passwordstore.util.git.sshj
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import androidx.activity.result.contract.ActivityResultContracts
|
import androidx.activity.result.contract.ActivityResultContracts
|
|
@ -2,16 +2,16 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.sshj
|
package app.passwordstore.util.git.sshj
|
||||||
|
|
||||||
import android.app.PendingIntent
|
import android.app.PendingIntent
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import androidx.activity.result.IntentSenderRequest
|
import androidx.activity.result.IntentSenderRequest
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
import dev.msfjarvis.aps.util.extensions.OPENPGP_PROVIDER
|
import app.passwordstore.util.extensions.OPENPGP_PROVIDER
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import java.io.Closeable
|
import java.io.Closeable
|
||||||
import java.security.PublicKey
|
import java.security.PublicKey
|
||||||
import java.security.interfaces.ECKey
|
import java.security.interfaces.ECKey
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.sshj
|
package app.passwordstore.util.git.sshj
|
||||||
|
|
||||||
import com.hierynomus.sshj.key.KeyAlgorithm
|
import com.hierynomus.sshj.key.KeyAlgorithm
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.sshj
|
package app.passwordstore.util.git.sshj
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.pm.PackageManager
|
import android.content.pm.PackageManager
|
||||||
|
@ -16,15 +16,15 @@ import android.util.Base64
|
||||||
import androidx.core.content.edit
|
import androidx.core.content.edit
|
||||||
import androidx.security.crypto.EncryptedFile
|
import androidx.security.crypto.EncryptedFile
|
||||||
import androidx.security.crypto.MasterKey
|
import androidx.security.crypto.MasterKey
|
||||||
|
import app.passwordstore.Application
|
||||||
|
import app.passwordstore.R
|
||||||
|
import app.passwordstore.util.extensions.getEncryptedGitPrefs
|
||||||
|
import app.passwordstore.util.extensions.getString
|
||||||
|
import app.passwordstore.util.extensions.sharedPrefs
|
||||||
|
import app.passwordstore.util.extensions.unsafeLazy
|
||||||
|
import app.passwordstore.util.settings.PreferenceKeys
|
||||||
import com.github.michaelbull.result.getOrElse
|
import com.github.michaelbull.result.getOrElse
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import dev.msfjarvis.aps.Application
|
|
||||||
import dev.msfjarvis.aps.R
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getEncryptedGitPrefs
|
|
||||||
import dev.msfjarvis.aps.util.extensions.getString
|
|
||||||
import dev.msfjarvis.aps.util.extensions.sharedPrefs
|
|
||||||
import dev.msfjarvis.aps.util.extensions.unsafeLazy
|
|
||||||
import dev.msfjarvis.aps.util.settings.PreferenceKeys
|
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.io.IOException
|
import java.io.IOException
|
||||||
import java.security.KeyFactory
|
import java.security.KeyFactory
|
|
@ -2,7 +2,7 @@
|
||||||
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
* Copyright © 2014-2021 The Android Password Store Authors. All Rights Reserved.
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.aps.util.git.sshj
|
package app.passwordstore.util.git.sshj
|
||||||
|
|
||||||
import com.github.michaelbull.result.runCatching
|
import com.github.michaelbull.result.runCatching
|
||||||
import com.hierynomus.sshj.key.KeyAlgorithms
|
import com.hierynomus.sshj.key.KeyAlgorithms
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue