Rebrand application as 'Seedvault'

This commit is contained in:
Steve Soltys 2019-10-28 21:57:47 -04:00
parent 8ea68ea6ca
commit 32f558faf1
101 changed files with 339 additions and 339 deletions

View file

@ -37,6 +37,6 @@ deploy:
script: ./deploy-prebuilt.sh
skip_cleanup: true
on:
repo: stevesoltys/backup
repo: stevesoltys/seedvault
all_branches: true
condition: $TRAVIS_BRANCH =~ ^(master|develop)$

View file

@ -1,7 +1,7 @@
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := permissions_com.stevesoltys.backup.xml
LOCAL_MODULE := permissions_com.stevesoltys.seedvault.xml
LOCAL_MODULE_CLASS := ETC
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/permissions
@ -9,7 +9,7 @@ LOCAL_SRC_FILES := $(LOCAL_MODULE)
include $(BUILD_PREBUILT)
include $(CLEAR_VARS)
LOCAL_MODULE := whitelist_com.stevesoltys.backup.xml
LOCAL_MODULE := whitelist_com.stevesoltys.seedvault.xml
LOCAL_MODULE_CLASS := ETC
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/sysconfig
@ -23,5 +23,5 @@ LOCAL_CERTIFICATE := platform
LOCAL_MODULE_CLASS := APPS
LOCAL_PRIVILEGED_MODULE := true
LOCAL_DEX_PREOPT := false
LOCAL_REQUIRED_MODULES := permissions_com.stevesoltys.backup.xml whitelist_com.stevesoltys.backup.xml
LOCAL_REQUIRED_MODULES := permissions_com.stevesoltys.seedvault.xml whitelist_com.stevesoltys.seedvault.xml
include $(BUILD_PREBUILT)

View file

@ -11,7 +11,7 @@
## [0.1.2] - 2019-02-11
### Fixed
- Downgrade SDK target version to 26 due to [#15](https://github.com/stevesoltys/backup/issues/15).
- Downgrade SDK target version to 26 due to [#15](https://github.com/stevesoltys/seedvault/issues/15).
## [0.1.1] - 2019-02-11
### Added
@ -20,4 +20,4 @@
- Upgrade target SDK version to 28.
### Fixed
- Ignore `com.android.providers.downloads.ui` to resolve [#14](https://github.com/stevesoltys/backup/issues/14).
- Ignore `com.android.providers.downloads.ui` to resolve [#14](https://github.com/stevesoltys/seedvault/issues/14).

View file

@ -1,5 +1,5 @@
# Backup
[![Build Status](https://travis-ci.com/stevesoltys/backup.svg?branch=master)](https://travis-ci.com/stevesoltys/backup)
# Seedvault
[![Build Status](https://travis-ci.com/stevesoltys/seedvault.svg?branch=master)](https://travis-ci.com/stevesoltys/seedvault)
A backup application for the [Android Open Source Project](https://source.android.com/).
@ -9,7 +9,7 @@ A backup application for the [Android Open Source Project](https://source.androi
- Password-based encryption.
## Getting Started
- Check out [the wiki](https://github.com/stevesoltys/backup/wiki) for information on building the application with
- Check out [the wiki](https://github.com/stevesoltys/seedvault/wiki) for information on building the application with
AOSP.
## What makes this different?
@ -17,7 +17,7 @@ This application is compiled with the operating system and does not require a ro
internal APIs as `adb backup` and only requires the permission `android.permission.BACKUP` for this.
## Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/stevesoltys/backup.
Bug reports and pull requests are welcome on GitHub at https://github.com/stevesoltys/seedvault.
## Permissions

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import android.util.Log
import androidx.test.filters.LargeTest
import androidx.test.runner.AndroidJUnit4
import com.stevesoltys.backup.crypto.CipherFactoryImpl
import com.stevesoltys.backup.crypto.KeyManagerTestImpl
import com.stevesoltys.seedvault.crypto.CipherFactoryImpl
import com.stevesoltys.seedvault.crypto.KeyManagerTestImpl
import org.junit.Assert.assertTrue
import org.junit.Test
import org.junit.runner.RunWith

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import androidx.documentfile.provider.DocumentFile
import androidx.test.platform.app.InstrumentationRegistry
import androidx.test.runner.AndroidJUnit4
import com.stevesoltys.backup.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.backup.transport.backup.plugins.createOrGetFile
import com.stevesoltys.seedvault.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.seedvault.transport.backup.plugins.createOrGetFile
import org.junit.After
import org.junit.Assert.assertArrayEquals
import org.junit.Assert.assertNotNull

View file

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.stevesoltys.backup"
package="com.stevesoltys.seedvault"
android:versionCode="6"
android:versionName="1.0.0-alpha1">
@ -58,7 +58,7 @@
android:label="@string/restore_title"
android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="com.stevesoltys.backup.restore.RESTORE_BACKUP" />
<action android:name="com.stevesoltys.seedvault.restore.RESTORE_BACKUP" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import android.app.Application
import android.app.backup.BackupManager.PACKAGE_MANAGER_SENTINEL
@ -6,9 +6,9 @@ import android.app.backup.IBackupManager
import android.content.Context.BACKUP_SERVICE
import android.os.Build
import android.os.ServiceManager.getService
import com.stevesoltys.backup.crypto.KeyManager
import com.stevesoltys.backup.crypto.KeyManagerImpl
import com.stevesoltys.backup.settings.SettingsManager
import com.stevesoltys.seedvault.crypto.KeyManager
import com.stevesoltys.seedvault.crypto.KeyManagerImpl
import com.stevesoltys.seedvault.settings.SettingsManager
/**
* @author Steve Soltys

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import android.app.backup.BackupManagerMonitor.*
import android.app.backup.IBackupManagerMonitor

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import android.app.NotificationChannel
import android.app.NotificationManager
@ -9,7 +9,7 @@ import android.app.backup.BackupTransport.TRANSPORT_PACKAGE_REJECTED
import android.content.Context
import android.content.Intent
import androidx.core.app.NotificationCompat.*
import com.stevesoltys.backup.settings.SettingsActivity
import com.stevesoltys.seedvault.settings.SettingsActivity
private const val CHANNEL_ID_OBSERVER = "NotificationBackupObserver"
private const val CHANNEL_ID_ERROR = "NotificationError"

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import java.nio.charset.Charset
import java.util.*

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import android.app.backup.BackupProgress
import android.app.backup.IBackupObserver

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import android.content.BroadcastReceiver
import android.content.Context
@ -11,9 +11,9 @@ import android.net.Uri
import android.os.Handler
import android.provider.DocumentsContract
import android.util.Log
import com.stevesoltys.backup.settings.FlashDrive
import com.stevesoltys.backup.transport.requestBackup
import com.stevesoltys.backup.ui.storage.AUTHORITY_STORAGE
import com.stevesoltys.seedvault.settings.FlashDrive
import com.stevesoltys.seedvault.transport.requestBackup
import com.stevesoltys.seedvault.ui.storage.AUTHORITY_STORAGE
import java.util.*
import java.util.concurrent.TimeUnit.HOURS

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import javax.crypto.Cipher
import javax.crypto.Cipher.DECRYPT_MODE

View file

@ -1,6 +1,6 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import com.stevesoltys.backup.header.*
import com.stevesoltys.seedvault.header.*
import java.io.EOFException
import java.io.IOException
import java.io.InputStream

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import android.os.Build.VERSION.SDK_INT
import android.security.keystore.KeyProperties.*
@ -10,7 +10,7 @@ import javax.crypto.spec.SecretKeySpec
internal const val KEY_SIZE = 256
private const val KEY_SIZE_BYTES = KEY_SIZE / 8
private const val KEY_ALIAS = "com.stevesoltys.backup"
private const val KEY_ALIAS = "com.stevesoltys.seedvault"
private const val ANDROID_KEY_STORE = "AndroidKeyStore"
interface KeyManager {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.header
package com.stevesoltys.seedvault.header
internal const val VERSION: Byte = 0
internal const val MAX_PACKAGE_LENGTH_SIZE = 255

View file

@ -1,6 +1,6 @@
package com.stevesoltys.backup.header
package com.stevesoltys.seedvault.header
import com.stevesoltys.backup.Utf8
import com.stevesoltys.seedvault.Utf8
import java.io.EOFException
import java.io.IOException
import java.io.InputStream

View file

@ -1,6 +1,6 @@
package com.stevesoltys.backup.header
package com.stevesoltys.seedvault.header
import com.stevesoltys.backup.Utf8
import com.stevesoltys.seedvault.Utf8
import java.io.IOException
import java.io.OutputStream
import java.nio.ByteBuffer

View file

@ -1,8 +1,8 @@
package com.stevesoltys.backup.metadata
package com.stevesoltys.seedvault.metadata
import android.os.Build
import android.os.Build.VERSION.SDK_INT
import com.stevesoltys.backup.header.VERSION
import com.stevesoltys.seedvault.header.VERSION
import java.io.InputStream
data class BackupMetadata(

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup.metadata
package com.stevesoltys.seedvault.metadata
import androidx.annotation.VisibleForTesting
import com.stevesoltys.backup.Utf8
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.header.UnsupportedVersionException
import com.stevesoltys.backup.header.VERSION
import com.stevesoltys.seedvault.Utf8
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.header.UnsupportedVersionException
import com.stevesoltys.seedvault.header.VERSION
import org.json.JSONException
import org.json.JSONObject
import java.io.IOException

View file

@ -1,8 +1,8 @@
package com.stevesoltys.backup.metadata
package com.stevesoltys.seedvault.metadata
import androidx.annotation.VisibleForTesting
import com.stevesoltys.backup.Utf8
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.seedvault.Utf8
import com.stevesoltys.seedvault.crypto.Crypto
import org.json.JSONObject
import java.io.IOException
import java.io.OutputStream

View file

@ -1,12 +1,12 @@
package com.stevesoltys.backup.restore
package com.stevesoltys.seedvault.restore
import android.os.Bundle
import androidx.annotation.CallSuper
import androidx.lifecycle.Observer
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.R
import com.stevesoltys.backup.ui.RequireProvisioningActivity
import com.stevesoltys.backup.ui.RequireProvisioningViewModel
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.ui.RequireProvisioningActivity
import com.stevesoltys.seedvault.ui.RequireProvisioningViewModel
class RestoreActivity : RequireProvisioningActivity() {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.restore
package com.stevesoltys.seedvault.restore
import android.app.Activity.RESULT_OK
import android.os.Bundle
@ -11,10 +11,10 @@ import android.view.WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON
import androidx.fragment.app.Fragment
import androidx.lifecycle.Observer
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.R
import com.stevesoltys.backup.getAppName
import com.stevesoltys.backup.isDebugBuild
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.getAppName
import com.stevesoltys.seedvault.isDebugBuild
import kotlinx.android.synthetic.main.fragment_restore_progress.*
class RestoreProgressFragment : Fragment() {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.restore
package com.stevesoltys.seedvault.restore
import android.app.backup.RestoreSet
import android.view.LayoutInflater
@ -7,8 +7,8 @@ import android.view.ViewGroup
import android.widget.TextView
import androidx.recyclerview.widget.RecyclerView.Adapter
import androidx.recyclerview.widget.RecyclerView.ViewHolder
import com.stevesoltys.backup.R
import com.stevesoltys.backup.restore.RestoreSetAdapter.RestoreSetViewHolder
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.restore.RestoreSetAdapter.RestoreSetViewHolder
internal class RestoreSetAdapter(
private val listener: RestoreSetClickListener,

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.restore
package com.stevesoltys.seedvault.restore
import android.app.backup.RestoreSet
import android.os.Bundle
@ -10,7 +10,7 @@ import android.view.ViewGroup
import androidx.fragment.app.Fragment
import androidx.lifecycle.Observer
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.R
import com.stevesoltys.seedvault.R
import kotlinx.android.synthetic.main.fragment_restore_set.*
class RestoreSetFragment : Fragment() {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.restore
package com.stevesoltys.seedvault.restore
import android.app.Application
import android.app.backup.IRestoreObserver
@ -9,11 +9,11 @@ import android.util.Log
import androidx.annotation.WorkerThread
import androidx.lifecycle.LiveData
import androidx.lifecycle.MutableLiveData
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.R
import com.stevesoltys.backup.BackupMonitor
import com.stevesoltys.backup.transport.TRANSPORT_ID
import com.stevesoltys.backup.ui.RequireProvisioningViewModel
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.BackupMonitor
import com.stevesoltys.seedvault.transport.TRANSPORT_ID
import com.stevesoltys.seedvault.ui.RequireProvisioningViewModel
private val TAG = RestoreViewModel::class.java.simpleName

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.settings
package com.stevesoltys.seedvault.settings
import android.content.ContentResolver
import android.provider.Settings

View file

@ -1,12 +1,12 @@
package com.stevesoltys.backup.settings
package com.stevesoltys.seedvault.settings
import android.os.Bundle
import androidx.annotation.CallSuper
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.R
import com.stevesoltys.backup.ui.RequireProvisioningActivity
import com.stevesoltys.backup.ui.RequireProvisioningViewModel
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.ui.RequireProvisioningActivity
import com.stevesoltys.seedvault.ui.RequireProvisioningViewModel
class SettingsActivity : RequireProvisioningActivity() {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.settings
package com.stevesoltys.seedvault.settings
import android.content.Context
import android.content.Context.BACKUP_SERVICE
@ -22,11 +22,11 @@ import androidx.preference.Preference
import androidx.preference.Preference.OnPreferenceChangeListener
import androidx.preference.PreferenceFragmentCompat
import androidx.preference.TwoStatePreference
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.R
import com.stevesoltys.backup.UsbMonitor
import com.stevesoltys.backup.isMassStorage
import com.stevesoltys.backup.restore.RestoreActivity
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.UsbMonitor
import com.stevesoltys.seedvault.isMassStorage
import com.stevesoltys.seedvault.restore.RestoreActivity
import java.util.*
private val TAG = SettingsFragment::class.java.name

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.settings
package com.stevesoltys.seedvault.settings
import android.content.Context
import android.hardware.usb.UsbDevice

View file

@ -1,8 +1,8 @@
package com.stevesoltys.backup.settings
package com.stevesoltys.seedvault.settings
import android.app.Application
import com.stevesoltys.backup.transport.requestBackup
import com.stevesoltys.backup.ui.RequireProvisioningViewModel
import com.stevesoltys.seedvault.transport.requestBackup
import com.stevesoltys.seedvault.ui.RequireProvisioningViewModel
class SettingsViewModel(app: Application) : RequireProvisioningViewModel(app) {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport
package com.stevesoltys.seedvault.transport
import android.app.backup.BackupAgent.FLAG_CLIENT_SIDE_ENCRYPTION_ENABLED
import android.app.backup.BackupTransport
@ -9,11 +9,11 @@ import android.content.Intent
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import android.util.Log
import com.stevesoltys.backup.settings.SettingsActivity
import com.stevesoltys.seedvault.settings.SettingsActivity
val TRANSPORT_ID: String = ConfigurableBackupTransport::class.java.name
private const val TRANSPORT_DIRECTORY_NAME = "com.stevesoltys.backup.transport.ConfigurableBackupTransport"
private const val TRANSPORT_DIRECTORY_NAME = "com.stevesoltys.seedvault.transport.ConfigurableBackupTransport"
private val TAG = ConfigurableBackupTransport::class.java.simpleName
/**

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport
package com.stevesoltys.seedvault.transport
import android.app.Service
import android.app.backup.BackupManager
@ -11,10 +11,10 @@ import android.os.IBinder
import android.os.RemoteException
import android.util.Log
import androidx.annotation.WorkerThread
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.NotificationBackupObserver
import com.stevesoltys.backup.R
import com.stevesoltys.backup.BackupMonitor
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.NotificationBackupObserver
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.BackupMonitor
private val TAG = ConfigurableBackupTransportService::class.java.simpleName

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport
package com.stevesoltys.seedvault.transport
import android.content.pm.IPackageManager
import android.content.pm.PackageInfo
@ -7,8 +7,8 @@ import android.os.ServiceManager.getService
import android.os.UserHandle
import android.util.Log
import com.google.android.collect.Sets.newArraySet
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.MAGIC_PACKAGE_MANAGER
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.MAGIC_PACKAGE_MANAGER
import java.util.*
private val TAG = PackageService::class.java.simpleName
@ -20,7 +20,7 @@ private val IGNORED_PACKAGES = newArraySet(
"com.android.providers.media",
"com.android.providers.calendar",
"com.android.providers.contacts",
"com.stevesoltys.backup"
"com.stevesoltys.seedvault"
)
/**

View file

@ -1,24 +1,24 @@
package com.stevesoltys.backup.transport
package com.stevesoltys.seedvault.transport
import android.content.Context
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.crypto.CipherFactoryImpl
import com.stevesoltys.backup.crypto.CryptoImpl
import com.stevesoltys.backup.header.HeaderReaderImpl
import com.stevesoltys.backup.header.HeaderWriterImpl
import com.stevesoltys.backup.metadata.MetadataReaderImpl
import com.stevesoltys.backup.metadata.MetadataWriterImpl
import com.stevesoltys.backup.transport.backup.BackupCoordinator
import com.stevesoltys.backup.transport.backup.FullBackup
import com.stevesoltys.backup.transport.backup.InputFactory
import com.stevesoltys.backup.transport.backup.KVBackup
import com.stevesoltys.backup.transport.backup.plugins.DocumentsProviderBackupPlugin
import com.stevesoltys.backup.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.backup.transport.restore.FullRestore
import com.stevesoltys.backup.transport.restore.KVRestore
import com.stevesoltys.backup.transport.restore.OutputFactory
import com.stevesoltys.backup.transport.restore.RestoreCoordinator
import com.stevesoltys.backup.transport.restore.plugins.DocumentsProviderRestorePlugin
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.crypto.CipherFactoryImpl
import com.stevesoltys.seedvault.crypto.CryptoImpl
import com.stevesoltys.seedvault.header.HeaderReaderImpl
import com.stevesoltys.seedvault.header.HeaderWriterImpl
import com.stevesoltys.seedvault.metadata.MetadataReaderImpl
import com.stevesoltys.seedvault.metadata.MetadataWriterImpl
import com.stevesoltys.seedvault.transport.backup.BackupCoordinator
import com.stevesoltys.seedvault.transport.backup.FullBackup
import com.stevesoltys.seedvault.transport.backup.InputFactory
import com.stevesoltys.seedvault.transport.backup.KVBackup
import com.stevesoltys.seedvault.transport.backup.plugins.DocumentsProviderBackupPlugin
import com.stevesoltys.seedvault.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.seedvault.transport.restore.FullRestore
import com.stevesoltys.seedvault.transport.restore.KVRestore
import com.stevesoltys.seedvault.transport.restore.OutputFactory
import com.stevesoltys.seedvault.transport.restore.RestoreCoordinator
import com.stevesoltys.seedvault.transport.restore.plugins.DocumentsProviderRestorePlugin
class PluginManager(context: Context) {

View file

@ -1,14 +1,14 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.app.backup.BackupTransport.*
import android.content.Context
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import android.util.Log
import com.stevesoltys.backup.BackupNotificationManager
import com.stevesoltys.backup.MAGIC_PACKAGE_MANAGER
import com.stevesoltys.backup.metadata.MetadataWriter
import com.stevesoltys.backup.settings.SettingsManager
import com.stevesoltys.seedvault.BackupNotificationManager
import com.stevesoltys.seedvault.MAGIC_PACKAGE_MANAGER
import com.stevesoltys.seedvault.metadata.MetadataWriter
import com.stevesoltys.seedvault.settings.SettingsManager
import java.io.IOException
import java.util.concurrent.TimeUnit.DAYS

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import java.io.IOException
import java.io.OutputStream

View file

@ -1,12 +1,12 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.app.backup.BackupTransport.*
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import android.util.Log
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.header.HeaderWriter
import com.stevesoltys.backup.header.VersionHeader
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.header.HeaderWriter
import com.stevesoltys.seedvault.header.VersionHeader
import libcore.io.IoUtils.closeQuietly
import org.apache.commons.io.IOUtils
import java.io.IOException

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.content.pm.PackageInfo
import java.io.IOException

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.app.backup.BackupDataInput
import android.os.ParcelFileDescriptor

View file

@ -1,13 +1,13 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.app.backup.BackupTransport.*
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import android.util.Log
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.encodeBase64
import com.stevesoltys.backup.header.HeaderWriter
import com.stevesoltys.backup.header.VersionHeader
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.encodeBase64
import com.stevesoltys.seedvault.header.HeaderWriter
import com.stevesoltys.seedvault.header.VersionHeader
import libcore.io.IoUtils.closeQuietly
import java.io.IOException

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.content.pm.PackageInfo
import java.io.IOException

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.transport.backup.plugins
package com.stevesoltys.seedvault.transport.backup.plugins
import android.content.pm.PackageManager
import com.stevesoltys.backup.transport.backup.BackupPlugin
import com.stevesoltys.backup.transport.backup.FullBackupPlugin
import com.stevesoltys.backup.transport.backup.KVBackupPlugin
import com.stevesoltys.seedvault.transport.backup.BackupPlugin
import com.stevesoltys.seedvault.transport.backup.FullBackupPlugin
import com.stevesoltys.seedvault.transport.backup.KVBackupPlugin
import java.io.IOException
import java.io.OutputStream

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.transport.backup.plugins
package com.stevesoltys.seedvault.transport.backup.plugins
import android.content.pm.PackageInfo
import android.util.Log
import com.stevesoltys.backup.transport.backup.DEFAULT_QUOTA_FULL_BACKUP
import com.stevesoltys.backup.transport.backup.FullBackupPlugin
import com.stevesoltys.seedvault.transport.backup.DEFAULT_QUOTA_FULL_BACKUP
import com.stevesoltys.seedvault.transport.backup.FullBackupPlugin
import java.io.IOException
import java.io.OutputStream

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.transport.backup.plugins
package com.stevesoltys.seedvault.transport.backup.plugins
import android.content.pm.PackageInfo
import androidx.documentfile.provider.DocumentFile
import com.stevesoltys.backup.transport.backup.DEFAULT_QUOTA_KEY_VALUE_BACKUP
import com.stevesoltys.backup.transport.backup.KVBackupPlugin
import com.stevesoltys.seedvault.transport.backup.DEFAULT_QUOTA_KEY_VALUE_BACKUP
import com.stevesoltys.seedvault.transport.backup.KVBackupPlugin
import java.io.IOException
import java.io.OutputStream

View file

@ -1,11 +1,11 @@
package com.stevesoltys.backup.transport.backup.plugins
package com.stevesoltys.seedvault.transport.backup.plugins
import android.content.Context
import android.content.pm.PackageInfo
import android.util.Log
import androidx.documentfile.provider.DocumentFile
import com.stevesoltys.backup.settings.SettingsManager
import com.stevesoltys.backup.settings.Storage
import com.stevesoltys.seedvault.settings.SettingsManager
import com.stevesoltys.seedvault.settings.Storage
import java.io.IOException
import java.io.InputStream
import java.io.OutputStream

View file

@ -1,12 +1,12 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.app.backup.BackupTransport.*
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import android.util.Log
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.header.HeaderReader
import com.stevesoltys.backup.header.UnsupportedVersionException
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.header.HeaderReader
import com.stevesoltys.seedvault.header.UnsupportedVersionException
import libcore.io.IoUtils.closeQuietly
import java.io.EOFException
import java.io.IOException

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.content.pm.PackageInfo
import java.io.IOException

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.app.backup.BackupDataOutput
import android.app.backup.BackupTransport.TRANSPORT_ERROR
@ -6,10 +6,10 @@ import android.app.backup.BackupTransport.TRANSPORT_OK
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import android.util.Log
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.decodeBase64
import com.stevesoltys.backup.header.HeaderReader
import com.stevesoltys.backup.header.UnsupportedVersionException
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.decodeBase64
import com.stevesoltys.seedvault.header.HeaderReader
import com.stevesoltys.seedvault.header.UnsupportedVersionException
import libcore.io.IoUtils.closeQuietly
import java.io.IOException
import java.util.*

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.content.pm.PackageInfo
import java.io.IOException

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.app.backup.BackupDataOutput
import android.os.ParcelFileDescriptor

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.app.backup.BackupTransport.TRANSPORT_ERROR
import android.app.backup.BackupTransport.TRANSPORT_OK
@ -8,10 +8,10 @@ import android.app.backup.RestoreSet
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import android.util.Log
import com.stevesoltys.backup.header.UnsupportedVersionException
import com.stevesoltys.backup.metadata.DecryptionFailedException
import com.stevesoltys.backup.metadata.MetadataReader
import com.stevesoltys.backup.settings.SettingsManager
import com.stevesoltys.seedvault.header.UnsupportedVersionException
import com.stevesoltys.seedvault.metadata.DecryptionFailedException
import com.stevesoltys.seedvault.metadata.MetadataReader
import com.stevesoltys.seedvault.settings.SettingsManager
import libcore.io.IoUtils.closeQuietly
import java.io.IOException

View file

@ -1,6 +1,6 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import com.stevesoltys.backup.metadata.EncryptedBackupMetadata
import com.stevesoltys.seedvault.metadata.EncryptedBackupMetadata
interface RestorePlugin {

View file

@ -1,8 +1,8 @@
package com.stevesoltys.backup.transport.restore.plugins
package com.stevesoltys.seedvault.transport.restore.plugins
import android.content.pm.PackageInfo
import com.stevesoltys.backup.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.backup.transport.restore.FullRestorePlugin
import com.stevesoltys.seedvault.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.seedvault.transport.restore.FullRestorePlugin
import java.io.IOException
import java.io.InputStream

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup.transport.restore.plugins
package com.stevesoltys.seedvault.transport.restore.plugins
import android.content.pm.PackageInfo
import androidx.documentfile.provider.DocumentFile
import com.stevesoltys.backup.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.backup.transport.backup.plugins.assertRightFile
import com.stevesoltys.backup.transport.restore.KVRestorePlugin
import com.stevesoltys.seedvault.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.seedvault.transport.backup.plugins.assertRightFile
import com.stevesoltys.seedvault.transport.restore.KVRestorePlugin
import java.io.IOException
import java.io.InputStream

View file

@ -1,14 +1,14 @@
package com.stevesoltys.backup.transport.restore.plugins
package com.stevesoltys.seedvault.transport.restore.plugins
import android.util.Log
import androidx.documentfile.provider.DocumentFile
import com.stevesoltys.backup.metadata.EncryptedBackupMetadata
import com.stevesoltys.backup.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.backup.transport.backup.plugins.FILE_BACKUP_METADATA
import com.stevesoltys.backup.transport.backup.plugins.FILE_NO_MEDIA
import com.stevesoltys.backup.transport.restore.FullRestorePlugin
import com.stevesoltys.backup.transport.restore.KVRestorePlugin
import com.stevesoltys.backup.transport.restore.RestorePlugin
import com.stevesoltys.seedvault.metadata.EncryptedBackupMetadata
import com.stevesoltys.seedvault.transport.backup.plugins.DocumentsStorage
import com.stevesoltys.seedvault.transport.backup.plugins.FILE_BACKUP_METADATA
import com.stevesoltys.seedvault.transport.backup.plugins.FILE_NO_MEDIA
import com.stevesoltys.seedvault.transport.restore.FullRestorePlugin
import com.stevesoltys.seedvault.transport.restore.KVRestorePlugin
import com.stevesoltys.seedvault.transport.restore.RestorePlugin
import java.io.IOException
private val TAG = DocumentsProviderRestorePlugin::class.java.simpleName

View file

@ -1,11 +1,11 @@
package com.stevesoltys.backup.ui
package com.stevesoltys.seedvault.ui
import android.view.MenuItem
import android.view.View
import androidx.annotation.CallSuper
import androidx.appcompat.app.AppCompatActivity
import androidx.fragment.app.Fragment
import com.stevesoltys.backup.R
import com.stevesoltys.seedvault.R
abstract class BackupActivity : AppCompatActivity() {

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.ui
package com.stevesoltys.seedvault.ui
import androidx.lifecycle.LifecycleOwner
import androidx.lifecycle.LiveData
import androidx.lifecycle.Observer
import com.stevesoltys.backup.ui.LiveEvent.ConsumableEvent
import com.stevesoltys.seedvault.ui.LiveEvent.ConsumableEvent
open class LiveEvent<T> : LiveData<ConsumableEvent<T>>() {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui;
package com.stevesoltys.seedvault.ui;
public interface LiveEventHandler<T> {
void onEvent(T t);

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui
package com.stevesoltys.seedvault.ui
class MutableLiveEvent<T> : LiveEvent<T>() {

View file

@ -1,11 +1,11 @@
package com.stevesoltys.backup.ui
package com.stevesoltys.seedvault.ui
import android.content.Intent
import android.os.Bundle
import android.util.Log
import androidx.annotation.CallSuper
import com.stevesoltys.backup.ui.recoverycode.RecoveryCodeActivity
import com.stevesoltys.backup.ui.storage.StorageActivity
import com.stevesoltys.seedvault.ui.recoverycode.RecoveryCodeActivity
import com.stevesoltys.seedvault.ui.storage.StorageActivity
const val REQUEST_CODE_OPEN_DOCUMENT_TREE = 1
const val REQUEST_CODE_BACKUP_LOCATION = 2
@ -14,7 +14,7 @@ const val REQUEST_CODE_RECOVERY_CODE = 3
const val INTENT_EXTRA_IS_RESTORE = "isRestore"
const val INTENT_EXTRA_IS_SETUP_WIZARD = "isSetupWizard"
private const val ACTION_SETUP_WIZARD = "com.stevesoltys.backup.restore.RESTORE_BACKUP"
private const val ACTION_SETUP_WIZARD = "com.stevesoltys.seedvault.restore.RESTORE_BACKUP"
private val TAG = RequireProvisioningActivity::class.java.name

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.ui
package com.stevesoltys.seedvault.ui
import android.app.Application
import androidx.lifecycle.AndroidViewModel
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.ui.storage.StorageViewModel
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.ui.storage.StorageViewModel
abstract class RequireProvisioningViewModel(protected val app: Application) : AndroidViewModel(app) {

View file

@ -1,13 +1,13 @@
package com.stevesoltys.backup.ui.recoverycode
package com.stevesoltys.seedvault.ui.recoverycode
import android.os.Bundle
import android.view.MenuItem
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.R
import com.stevesoltys.backup.ui.BackupActivity
import com.stevesoltys.backup.ui.INTENT_EXTRA_IS_RESTORE
import com.stevesoltys.backup.ui.INTENT_EXTRA_IS_SETUP_WIZARD
import com.stevesoltys.backup.ui.LiveEventHandler
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.ui.BackupActivity
import com.stevesoltys.seedvault.ui.INTENT_EXTRA_IS_RESTORE
import com.stevesoltys.seedvault.ui.INTENT_EXTRA_IS_SETUP_WIZARD
import com.stevesoltys.seedvault.ui.LiveEventHandler
class RecoveryCodeActivity : BackupActivity() {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.recoverycode
package com.stevesoltys.seedvault.ui.recoverycode
import android.view.LayoutInflater
import android.view.View
@ -6,7 +6,7 @@ import android.view.ViewGroup
import android.widget.TextView
import androidx.recyclerview.widget.RecyclerView
import androidx.recyclerview.widget.RecyclerView.Adapter
import com.stevesoltys.backup.R
import com.stevesoltys.seedvault.R
class RecoveryCodeAdapter(private val items: List<CharSequence>) : Adapter<RecoveryCodeViewHolder>() {

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.recoverycode
package com.stevesoltys.seedvault.ui.recoverycode
import android.os.Bundle
import android.view.LayoutInflater
@ -11,8 +11,8 @@ import android.widget.Toast
import android.widget.Toast.LENGTH_LONG
import androidx.fragment.app.Fragment
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.R
import com.stevesoltys.backup.isDebugBuild
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.isDebugBuild
import io.github.novacrypto.bip39.Validation.InvalidChecksumException
import io.github.novacrypto.bip39.Validation.WordNotFoundException
import io.github.novacrypto.bip39.wordlists.English

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.recoverycode
package com.stevesoltys.seedvault.ui.recoverycode
import android.content.res.Configuration.ORIENTATION_LANDSCAPE
import android.os.Bundle
@ -9,7 +9,7 @@ import androidx.fragment.app.Fragment
import androidx.lifecycle.ViewModelProviders
import androidx.recyclerview.widget.GridLayoutManager
import androidx.recyclerview.widget.RecyclerView
import com.stevesoltys.backup.R
import com.stevesoltys.seedvault.R
import kotlinx.android.synthetic.main.fragment_recovery_code_output.*
class RecoveryCodeOutputFragment : Fragment() {

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup.ui.recoverycode
package com.stevesoltys.seedvault.ui.recoverycode
import android.app.Application
import androidx.lifecycle.AndroidViewModel
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.ui.LiveEvent
import com.stevesoltys.backup.ui.MutableLiveEvent
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.ui.LiveEvent
import com.stevesoltys.seedvault.ui.MutableLiveEvent
import io.github.novacrypto.bip39.*
import io.github.novacrypto.bip39.Validation.InvalidChecksumException
import io.github.novacrypto.bip39.Validation.InvalidWordCountException

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.app.Application
import android.app.backup.BackupProgress
@ -7,10 +7,10 @@ import android.net.Uri
import android.os.UserHandle
import android.util.Log
import androidx.annotation.WorkerThread
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.R
import com.stevesoltys.backup.transport.TRANSPORT_ID
import com.stevesoltys.backup.transport.requestBackup
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.transport.TRANSPORT_ID
import com.stevesoltys.seedvault.transport.requestBackup
private val TAG = BackupStorageViewModel::class.java.simpleName

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.content.Intent.FLAG_GRANT_PREFIX_URI_PERMISSION
import android.os.Bundle

View file

@ -1,12 +1,12 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.app.Application
import android.net.Uri
import android.util.Log
import androidx.documentfile.provider.DocumentFile
import com.stevesoltys.backup.R
import com.stevesoltys.backup.transport.backup.plugins.DIRECTORY_ROOT
import com.stevesoltys.backup.transport.restore.plugins.DocumentsProviderRestorePlugin
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.transport.backup.plugins.DIRECTORY_ROOT
import com.stevesoltys.seedvault.transport.restore.plugins.DocumentsProviderRestorePlugin
private val TAG = RestoreStorageViewModel::class.java.simpleName

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.content.Intent
import android.os.Bundle
@ -6,11 +6,11 @@ import android.util.Log
import androidx.annotation.CallSuper
import androidx.appcompat.app.AlertDialog
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.R
import com.stevesoltys.backup.ui.BackupActivity
import com.stevesoltys.backup.ui.INTENT_EXTRA_IS_RESTORE
import com.stevesoltys.backup.ui.INTENT_EXTRA_IS_SETUP_WIZARD
import com.stevesoltys.backup.ui.LiveEventHandler
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.ui.BackupActivity
import com.stevesoltys.seedvault.ui.INTENT_EXTRA_IS_RESTORE
import com.stevesoltys.seedvault.ui.INTENT_EXTRA_IS_SETUP_WIZARD
import com.stevesoltys.seedvault.ui.LiveEventHandler
private val TAG = StorageActivity::class.java.name

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.os.Bundle
import android.view.LayoutInflater
@ -7,7 +7,7 @@ import android.view.View.INVISIBLE
import android.view.View.VISIBLE
import android.view.ViewGroup
import androidx.fragment.app.Fragment
import com.stevesoltys.backup.R
import com.stevesoltys.seedvault.R
import kotlinx.android.synthetic.main.fragment_storage_check.*
private const val TITLE = "title"

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.content.Context
@ -13,8 +13,8 @@ import android.widget.TextView
import androidx.appcompat.app.AlertDialog
import androidx.recyclerview.widget.RecyclerView.Adapter
import androidx.recyclerview.widget.RecyclerView.ViewHolder
import com.stevesoltys.backup.R
import com.stevesoltys.backup.ui.storage.StorageRootAdapter.StorageRootViewHolder
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.ui.storage.StorageRootAdapter.StorageRootViewHolder
internal class StorageRootAdapter(
private val isRestore: Boolean,

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.Manifest.permission.MANAGE_DOCUMENTS
import android.content.Context
@ -14,7 +14,7 @@ import android.provider.DocumentsContract
import android.provider.DocumentsContract.PROVIDER_INTERFACE
import android.provider.DocumentsContract.Root.*
import android.util.Log
import com.stevesoltys.backup.R
import com.stevesoltys.seedvault.R
import java.lang.Long.parseLong
private val TAG = StorageRootFetcher::class.java.simpleName

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.content.Intent
import android.content.Intent.*
@ -12,9 +12,9 @@ import androidx.appcompat.app.AppCompatActivity.RESULT_OK
import androidx.fragment.app.Fragment
import androidx.lifecycle.Observer
import androidx.lifecycle.ViewModelProviders
import com.stevesoltys.backup.R
import com.stevesoltys.backup.ui.INTENT_EXTRA_IS_RESTORE
import com.stevesoltys.backup.ui.REQUEST_CODE_OPEN_DOCUMENT_TREE
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.ui.INTENT_EXTRA_IS_RESTORE
import com.stevesoltys.seedvault.ui.REQUEST_CODE_OPEN_DOCUMENT_TREE
import kotlinx.android.synthetic.main.fragment_storage_root.*
private val TAG = StorageRootsFragment::class.java.simpleName

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.ui.storage
package com.stevesoltys.seedvault.ui.storage
import android.app.Application
import android.content.Context
@ -12,15 +12,15 @@ import android.util.Log
import androidx.lifecycle.AndroidViewModel
import androidx.lifecycle.LiveData
import androidx.lifecycle.MutableLiveData
import com.stevesoltys.backup.Backup
import com.stevesoltys.backup.R
import com.stevesoltys.backup.isMassStorage
import com.stevesoltys.backup.settings.BackupManagerSettings
import com.stevesoltys.backup.settings.FlashDrive
import com.stevesoltys.backup.settings.Storage
import com.stevesoltys.backup.transport.ConfigurableBackupTransportService
import com.stevesoltys.backup.ui.LiveEvent
import com.stevesoltys.backup.ui.MutableLiveEvent
import com.stevesoltys.seedvault.Backup
import com.stevesoltys.seedvault.R
import com.stevesoltys.seedvault.isMassStorage
import com.stevesoltys.seedvault.settings.BackupManagerSettings
import com.stevesoltys.seedvault.settings.FlashDrive
import com.stevesoltys.seedvault.settings.Storage
import com.stevesoltys.seedvault.transport.ConfigurableBackupTransportService
import com.stevesoltys.seedvault.ui.LiveEvent
import com.stevesoltys.seedvault.ui.MutableLiveEvent
private val TAG = StorageViewModel::class.java.simpleName

View file

@ -1,6 +1,6 @@
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<string name="app_name">Backup</string>
<string name="app_name">Seedvault</string>
<string name="restore_backup_button">Restore backup</string>

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup
package com.stevesoltys.seedvault
import kotlin.random.Random

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import javax.crypto.KeyGenerator
import javax.crypto.SecretKey

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import com.stevesoltys.backup.header.HeaderReaderImpl
import com.stevesoltys.backup.header.HeaderWriterImpl
import com.stevesoltys.backup.header.IV_SIZE
import com.stevesoltys.backup.header.MAX_SEGMENT_LENGTH
import com.stevesoltys.seedvault.header.HeaderReaderImpl
import com.stevesoltys.seedvault.header.HeaderWriterImpl
import com.stevesoltys.seedvault.header.IV_SIZE
import com.stevesoltys.seedvault.header.MAX_SEGMENT_LENGTH
import io.mockk.every
import io.mockk.mockk
import org.junit.jupiter.api.Assertions.assertArrayEquals

View file

@ -1,7 +1,7 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import com.stevesoltys.backup.header.HeaderReaderImpl
import com.stevesoltys.backup.header.HeaderWriterImpl
import com.stevesoltys.seedvault.header.HeaderReaderImpl
import com.stevesoltys.seedvault.header.HeaderWriterImpl
import org.junit.jupiter.api.Assertions.assertArrayEquals
import org.junit.jupiter.api.Test
import org.junit.jupiter.api.TestInstance

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import com.stevesoltys.backup.assertContains
import com.stevesoltys.backup.getRandomByteArray
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.backup.header.*
import com.stevesoltys.seedvault.assertContains
import com.stevesoltys.seedvault.getRandomByteArray
import com.stevesoltys.seedvault.getRandomString
import com.stevesoltys.seedvault.header.*
import io.mockk.*
import org.junit.jupiter.api.Assertions.*
import org.junit.jupiter.api.Test

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.crypto
package com.stevesoltys.seedvault.crypto
import io.github.novacrypto.bip39.wordlists.English
import org.junit.jupiter.api.Assertions.assertEquals

View file

@ -1,8 +1,8 @@
package com.stevesoltys.backup.header
package com.stevesoltys.seedvault.header
import com.stevesoltys.backup.Utf8
import com.stevesoltys.backup.assertContains
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.seedvault.Utf8
import com.stevesoltys.seedvault.assertContains
import com.stevesoltys.seedvault.getRandomString
import org.junit.jupiter.api.Assertions.*
import org.junit.jupiter.api.Test
import org.junit.jupiter.api.TestInstance

View file

@ -1,7 +1,7 @@
package com.stevesoltys.backup.header
package com.stevesoltys.seedvault.header
import com.stevesoltys.backup.getRandomByteArray
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.seedvault.getRandomByteArray
import com.stevesoltys.seedvault.getRandomString
import org.junit.jupiter.api.Assertions.*
import org.junit.jupiter.api.Test
import org.junit.jupiter.api.TestInstance

View file

@ -1,8 +1,8 @@
package com.stevesoltys.backup.metadata
package com.stevesoltys.seedvault.metadata
import com.stevesoltys.backup.Utf8
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.seedvault.Utf8
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.getRandomString
import io.mockk.mockk
import org.json.JSONObject
import org.junit.jupiter.api.Assertions.assertThrows

View file

@ -1,7 +1,7 @@
package com.stevesoltys.backup.metadata
package com.stevesoltys.seedvault.metadata
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.getRandomString
import io.mockk.mockk
import org.junit.jupiter.api.Assertions.assertEquals
import org.junit.jupiter.api.Test

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport
package com.stevesoltys.seedvault.transport
import android.app.backup.BackupDataInput
import android.app.backup.BackupDataOutput
@ -7,17 +7,17 @@ import android.app.backup.BackupTransport.TRANSPORT_OK
import android.app.backup.RestoreDescription
import android.app.backup.RestoreDescription.TYPE_FULL_STREAM
import android.os.ParcelFileDescriptor
import com.stevesoltys.backup.BackupNotificationManager
import com.stevesoltys.backup.crypto.CipherFactoryImpl
import com.stevesoltys.backup.crypto.CryptoImpl
import com.stevesoltys.backup.crypto.KeyManagerTestImpl
import com.stevesoltys.backup.encodeBase64
import com.stevesoltys.backup.header.HeaderReaderImpl
import com.stevesoltys.backup.header.HeaderWriterImpl
import com.stevesoltys.backup.metadata.MetadataReaderImpl
import com.stevesoltys.backup.metadata.MetadataWriterImpl
import com.stevesoltys.backup.transport.backup.*
import com.stevesoltys.backup.transport.restore.*
import com.stevesoltys.seedvault.BackupNotificationManager
import com.stevesoltys.seedvault.crypto.CipherFactoryImpl
import com.stevesoltys.seedvault.crypto.CryptoImpl
import com.stevesoltys.seedvault.crypto.KeyManagerTestImpl
import com.stevesoltys.seedvault.encodeBase64
import com.stevesoltys.seedvault.header.HeaderReaderImpl
import com.stevesoltys.seedvault.header.HeaderWriterImpl
import com.stevesoltys.seedvault.metadata.MetadataReaderImpl
import com.stevesoltys.seedvault.metadata.MetadataWriterImpl
import com.stevesoltys.seedvault.transport.backup.*
import com.stevesoltys.seedvault.transport.restore.*
import io.mockk.*
import org.junit.jupiter.api.Assertions.*
import org.junit.jupiter.api.Test

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup.transport
package com.stevesoltys.seedvault.transport
import android.content.Context
import android.content.pm.PackageInfo
import android.util.Log
import com.stevesoltys.backup.crypto.Crypto
import com.stevesoltys.backup.settings.SettingsManager
import com.stevesoltys.seedvault.crypto.Crypto
import com.stevesoltys.seedvault.settings.SettingsManager
import io.mockk.every
import io.mockk.mockk
import io.mockk.mockkStatic

View file

@ -1,13 +1,13 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.app.backup.BackupTransport.TRANSPORT_ERROR
import android.app.backup.BackupTransport.TRANSPORT_OK
import android.net.Uri
import androidx.documentfile.provider.DocumentFile
import com.stevesoltys.backup.BackupNotificationManager
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.backup.metadata.MetadataWriter
import com.stevesoltys.backup.settings.Storage
import com.stevesoltys.seedvault.BackupNotificationManager
import com.stevesoltys.seedvault.getRandomString
import com.stevesoltys.seedvault.metadata.MetadataWriter
import com.stevesoltys.seedvault.settings.Storage
import io.mockk.Runs
import io.mockk.every
import io.mockk.just

View file

@ -1,9 +1,9 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.os.ParcelFileDescriptor
import com.stevesoltys.backup.header.HeaderWriter
import com.stevesoltys.backup.header.VersionHeader
import com.stevesoltys.backup.transport.TransportTest
import com.stevesoltys.seedvault.header.HeaderWriter
import com.stevesoltys.seedvault.header.VersionHeader
import com.stevesoltys.seedvault.transport.TransportTest
import io.mockk.mockk
import java.io.OutputStream
import kotlin.random.Random

View file

@ -1,4 +1,4 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.app.backup.BackupTransport.*
import io.mockk.Runs

View file

@ -1,11 +1,11 @@
package com.stevesoltys.backup.transport.backup
package com.stevesoltys.seedvault.transport.backup
import android.app.backup.BackupDataInput
import android.app.backup.BackupTransport.*
import com.stevesoltys.backup.Utf8
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.backup.header.MAX_KEY_LENGTH_SIZE
import com.stevesoltys.backup.header.VersionHeader
import com.stevesoltys.seedvault.Utf8
import com.stevesoltys.seedvault.getRandomString
import com.stevesoltys.seedvault.header.MAX_KEY_LENGTH_SIZE
import com.stevesoltys.seedvault.header.VersionHeader
import io.mockk.Runs
import io.mockk.every
import io.mockk.just

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.app.backup.BackupTransport.*
import com.stevesoltys.backup.getRandomByteArray
import com.stevesoltys.backup.header.UnsupportedVersionException
import com.stevesoltys.backup.header.VERSION
import com.stevesoltys.backup.header.VersionHeader
import com.stevesoltys.seedvault.getRandomByteArray
import com.stevesoltys.seedvault.header.UnsupportedVersionException
import com.stevesoltys.seedvault.header.VERSION
import com.stevesoltys.seedvault.header.VersionHeader
import io.mockk.Runs
import io.mockk.every
import io.mockk.just

View file

@ -1,13 +1,13 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.app.backup.BackupDataOutput
import android.app.backup.BackupTransport.TRANSPORT_ERROR
import android.app.backup.BackupTransport.TRANSPORT_OK
import com.stevesoltys.backup.encodeBase64
import com.stevesoltys.backup.getRandomByteArray
import com.stevesoltys.backup.header.UnsupportedVersionException
import com.stevesoltys.backup.header.VERSION
import com.stevesoltys.backup.header.VersionHeader
import com.stevesoltys.seedvault.encodeBase64
import com.stevesoltys.seedvault.getRandomByteArray
import com.stevesoltys.seedvault.header.UnsupportedVersionException
import com.stevesoltys.seedvault.header.VERSION
import com.stevesoltys.seedvault.header.VersionHeader
import io.mockk.*
import org.junit.jupiter.api.Assertions.assertEquals
import org.junit.jupiter.api.Assertions.assertThrows

View file

@ -1,15 +1,15 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.app.backup.BackupTransport.TRANSPORT_OK
import android.app.backup.RestoreDescription
import android.app.backup.RestoreDescription.*
import android.content.pm.PackageInfo
import android.os.ParcelFileDescriptor
import com.stevesoltys.backup.getRandomString
import com.stevesoltys.backup.metadata.BackupMetadata
import com.stevesoltys.backup.metadata.EncryptedBackupMetadata
import com.stevesoltys.backup.metadata.MetadataReader
import com.stevesoltys.backup.transport.TransportTest
import com.stevesoltys.seedvault.getRandomString
import com.stevesoltys.seedvault.metadata.BackupMetadata
import com.stevesoltys.seedvault.metadata.EncryptedBackupMetadata
import com.stevesoltys.seedvault.metadata.MetadataReader
import com.stevesoltys.seedvault.transport.TransportTest
import io.mockk.Runs
import io.mockk.every
import io.mockk.just

View file

@ -1,10 +1,10 @@
package com.stevesoltys.backup.transport.restore
package com.stevesoltys.seedvault.transport.restore
import android.os.ParcelFileDescriptor
import com.stevesoltys.backup.getRandomByteArray
import com.stevesoltys.backup.transport.TransportTest
import com.stevesoltys.backup.header.HeaderReader
import com.stevesoltys.backup.header.VERSION
import com.stevesoltys.seedvault.getRandomByteArray
import com.stevesoltys.seedvault.transport.TransportTest
import com.stevesoltys.seedvault.header.HeaderReader
import com.stevesoltys.seedvault.header.VERSION
import io.mockk.mockk
import java.io.InputStream
import kotlin.random.Random

View file

@ -2,7 +2,7 @@
#
# Script to deploy to a prebuilt repo.
REPO_URL="https://stevesoltys:$GITHUB_API_KEY@github.com/stevesoltys/backup-prebuilt"
REPO_URL="https://stevesoltys:$GITHUB_API_KEY@github.com/stevesoltys/seedvault-prebuilt"
TAG=$(git tag -l --points-at HEAD)
git config --global user.email "github@stevesoltys.com"
@ -14,11 +14,11 @@ git checkout $TRAVIS_BRANCH || git checkout -b $TRAVIS_BRANCH
rm -Rf ./*
cp $TRAVIS_BUILD_DIR/Android.mk .
cp $TRAVIS_BUILD_DIR/app/build/outputs/apk/release/app-release-unsigned.apk ./Backup.apk
cp $TRAVIS_BUILD_DIR/permissions_com.stevesoltys.backup.xml .
cp $TRAVIS_BUILD_DIR/whitelist_com.stevesoltys.backup.xml .
cp $TRAVIS_BUILD_DIR/permissions_com.stevesoltys.seedvault.xml .
cp $TRAVIS_BUILD_DIR/whitelist_com.stevesoltys.seedvault.xml .
git add .
git commit -m "Travis build $TRAVIS_BUILD_NUMBER" -m "https://github.com/stevesoltys/backup/commit/$TRAVIS_COMMIT"
git commit -m "Travis build $TRAVIS_BUILD_NUMBER" -m "https://github.com/stevesoltys/seedvault/commit/$TRAVIS_COMMIT"
git push origin $TRAVIS_BRANCH
if [ ! -z ${TAG} ]; then

View file

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<permissions>
<privapp-permissions package="com.stevesoltys.backup">
<privapp-permissions package="com.stevesoltys.seedvault">
<permission name="android.permission.BACKUP"/>
<permission name="android.permission.MANAGE_USB"/>
<permission name="android.permission.WRITE_SECURE_SETTINGS"/>

Some files were not shown because too many files have changed in this diff Show more