-Refactor the logger implementation to make creation more intuitive
-Remove SSH debug logging preference persistence (didn't work properly
anyway, and probably not worth trying to fix)
-Re-organize SFTP Credentials dialog to be more space-efficient
-Add KEX and SHK algorithm spec fields (these get used to build the SFTP
URI when connecting)
-Add CSV test fields/buttons for standalone testing of spec/config
resolution
-App Settings->Log-File for Debugging->SFTP debug logging
-Logs to android log (logcat) if log file is not enabled
-Logs to Kp2a log file if it is enabled
-Logs are tagged as "KP2AJFS[JSch]"
-When enabled, logs ALL levels (DEBUG+).
NOTE: Sensitive SSH connection information may be logged!!
URL encode/decode host parameter in SFTP URI
This version is slightly different than the original PR, given
this branch's changes to SftpStorage.buildFullPath().
Since IPv6 addresses contain colons, they break the host:port URI
parsing logic, since "host" will have colons in it.
This fix adds URL encoding/decoding of the "host" parameter, thus
removing any possible colons in that parameter that could conflict
with the host:port separator.
-Generalize SFTP query param option map building
-Add "key" and "phrase" as SFTP query params
key: custom private key name
phrase: passphrase used to unlock key
-Add CRUD support for custom private keys
Key files are stored in "user_keys" subdirectory
File names are constructed by (sanitized) key name
Basic support for private key content validation
-Existing and new key-related functionality moved into
SftpPublicPrivateKeyUtils class
UI:
-Add custom private key support to SFTP Credentials dialog
Add a new auth mode item (authModeSpinner)
Add Spinner showing saved private key names, with an option
to create a new one (top).
Add Delete Private Key button; deletes the selected key
in Spinner
Testing:
-Add custom private key CRUD support to JavaFileStorageTest app
via file chooser SFTP Credentials panel
Add FLAG_MUTABLE flag to PendingIntent call for API >= 31 to fix an
issue where trying to open an SFTP database (transition to choose a
remote database file) crashes and returns to the Open/New database
screen.
Add FLAG_MUTABLE flag to PendingIntent call for API >= 31 to fix an
issue where trying to open an SFTP database (transition to choose a
remote database file) crashes and returns to the Open/New database
screen.
Set max heap to 1.5G across all java projects. Inspection
via VisualVM found 1G to be a little too aggressive, while
2G seemed overkill. In any case a full build now can reuse
a single GradleDaemon instance instead of three.
Fix the issues that were reported because of that change:
WARNING:The specified Android SDK Build Tools version (28.0.3) is ignored, as it is below the minimum supported version (30.0.3) for Android Gradle Plugin 7.4.0.
Android SDK Build Tools 30.0.3 will be used.
To suppress this warning, remove "buildToolsVersion '28.0.3'" from your build.gradle file, as each version of the Android Gradle Plugin now has a default version of the build tools.
android:exported needs to be explicitly specified for element <activity#com.crocoapps.javafilestoragetest2.MainActivity>. Apps targeting Android 12 and higher are required to specify an explicit value for `android:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details.
Setting the namespace via a source AndroidManifest.xml's package attribute is deprecated.
Please instead set the namespace (or testNamespace) in the module's build.gradle file, as described here: https://developer.android.com/studio/build/configure-app-module#set-namespace
This migration can be done automatically using the AGP Upgrade Assistant, please refer to https://developer.android.com/studio/build/agp-upgrade-assistant for more information.
.../keepass2android/src/java/KP2ASoftkeyboard_AS/app/src/main/AndroidManifest.xml:5:5-46 Warning:
uses-sdk:targetSdkVersion value (14) specified in the manifest file is ignored. It is overridden by the value declared in the DSL or the variant API, or 1 if not declared/present. Current value is (18).
* make changes to comply with new target sdk version requirements (mostly Exported-attribute and mutability flags)
* drop samsung fingerprint support (as suggested by Samsung), would require more hacks to keep it with the new target sdk version
* add build-properties.props to allow specifying a flavor in VS builds.
com.jcraft:jsch is not actively maintained anymore and lacks support
for modern public key algorithms such as rsa-sha2-256. It only
supports ssh-rsa which is disabled in up-to-date environments.
com.github.mwiede:jsch was created as a drop-in replacement which
works in modern environments [1].
Sources are taken from maven central [2]. The following files were
omitted, because they depend on additional 3rd-party libraries which
we do not have / do not need:
com/jcraft/jsch/JUnixSocketFactory.java
com/jcraft/jsch/Log4j2Logger.java
com/jcraft/jsch/PageantConnector.java
com/jcraft/jsch/Slf4jLogger.java
com/jcraft/jsch/SSHAgentConnector.java
com/jcraft/jsch/bc/*
com/jcraft/jsch/jgss/GSSContextKrb5.java
Fixes#1812.
[1] https://github.com/mwiede/jsch
[2] https://repo1.maven.org/maven2/com/github/mwiede/jsch/0.2.5/jsch-0.2.5-sources.jar
Somes files that are in .gitignore are still in the repository
This will remove them.
Commands used to do this:
git rm --cached -r . &&
git add . &&
git restore --staged .gitmodul
The jars in src/java/JavaFileStorage/libs are no more used since commit
a63663c30e
If this removes too many files, it means that .gitignore has to be fixed.
To find which rule removes which file run:
git check-ignore -v <file>
Especially, removing .idea/ completely might not be correct depending on ones
objective.