From d7495e3dd46f8c25634fe78c8ae987716e5ec109 Mon Sep 17 00:00:00 2001 From: Armin Schrenk Date: Fri, 10 Jan 2025 15:53:00 +0100 Subject: [PATCH 1/5] specify gpg fingerprint when releasing artifacts [ci skip] --- .github/workflows/publish-central.yml | 3 ++- .github/workflows/publish-github.yml | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish-central.yml b/.github/workflows/publish-central.yml index c8026ed..cb4dadb 100644 --- a/.github/workflows/publish-central.yml +++ b/.github/workflows/publish-central.yml @@ -39,4 +39,5 @@ jobs: MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }} MAVEN_PASSWORD: ${{ secrets.OSSRH_PASSWORD }} MAVEN_GPG_PASSPHRASE: ${{ secrets.RELEASES_GPG_PASSPHRASE }} - MAVEN_GPG_KEY: ${{ secrets.RELEASES_GPG_PRIVATE_KEY }} \ No newline at end of file + MAVEN_GPG_KEY: ${{ secrets.RELEASES_GPG_PRIVATE_KEY }} + MAVEN_GPG_KEY_FINGERPRINT: ${{ vars.RELEASES_GPG_KEY_FINGERPRINT }} diff --git a/.github/workflows/publish-github.yml b/.github/workflows/publish-github.yml index 9b46bd6..c5c1197 100644 --- a/.github/workflows/publish-github.yml +++ b/.github/workflows/publish-github.yml @@ -26,6 +26,7 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} MAVEN_GPG_PASSPHRASE: ${{ secrets.RELEASES_GPG_PASSPHRASE }} MAVEN_GPG_KEY: ${{ secrets.RELEASES_GPG_PRIVATE_KEY }} + MAVEN_GPG_KEY_FINGERPRINT: ${{ vars.RELEASES_GPG_KEY_FINGERPRINT }} notify: runs-on: ubuntu-latest needs: [publish] From c9b348d1f101867d814ae329722d59c34becc892 Mon Sep 17 00:00:00 2001 From: Armin Schrenk Date: Wed, 15 Jan 2025 11:10:34 +0100 Subject: [PATCH 2/5] correct spelling mistake --- integrations-win.vcxproj | 2 +- ...g_cryptomator_windows_uiappearance_WinAppearance_Native.cpp} | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename src/main/native/{org_cryptomator_windows_uiappearnce_WinAppearance_Native.cpp => org_cryptomator_windows_uiappearance_WinAppearance_Native.cpp} (100%) diff --git a/integrations-win.vcxproj b/integrations-win.vcxproj index 4ae64ff..dfd972b 100644 --- a/integrations-win.vcxproj +++ b/integrations-win.vcxproj @@ -124,7 +124,7 @@ - + diff --git a/src/main/native/org_cryptomator_windows_uiappearnce_WinAppearance_Native.cpp b/src/main/native/org_cryptomator_windows_uiappearance_WinAppearance_Native.cpp similarity index 100% rename from src/main/native/org_cryptomator_windows_uiappearnce_WinAppearance_Native.cpp rename to src/main/native/org_cryptomator_windows_uiappearance_WinAppearance_Native.cpp From 6e58f916a776cb1500d864e09405c426588ddefb Mon Sep 17 00:00:00 2001 From: Armin Schrenk Date: Wed, 15 Jan 2025 13:36:54 +0100 Subject: [PATCH 3/5] prevent conversion issue --- .../org_cryptomator_windows_keychain_WindowsHello_Native.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp b/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp index 6f15a64..323643f 100644 --- a/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp +++ b/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp @@ -96,7 +96,7 @@ IBuffer DeriveKeyUsingHKDF(const IBuffer& inputData, const IBuffer& salt, uint32 if (expandKey.KeySize() < macProvider.MacLength()) { throw std::runtime_error("Key provided by HMAC_SHA256 implementation is shorter than the HMAC length."); } - int maxKeySize = 255 * macProvider.MacLength(); + auto maxKeySize = 255 * macProvider.MacLength(); if (keySizeInBytes > maxKeySize) { throw std::runtime_error("HKDF requires keySizeInBytes to be at most " + std::to_string(maxKeySize) + " bytes."); } From 6524db61b459f9f7700489d0aab52d98e536fe8f Mon Sep 17 00:00:00 2001 From: Armin Schrenk Date: Wed, 15 Jan 2025 13:51:05 +0100 Subject: [PATCH 4/5] fixes #95 --- .../org_cryptomator_windows_keychain_WindowsHello_Native.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp b/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp index 323643f..b6b8e07 100644 --- a/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp +++ b/src/main/native/org_cryptomator_windows_keychain_WindowsHello_Native.cpp @@ -21,7 +21,7 @@ using namespace Windows::Security::Cryptography::Core; using namespace Windows::Storage::Streams; static std::atomic g_promptFocusCount{ 0 }; -static IBuffer info = CryptographicBuffer::ConvertStringToBinary(L"EncryptionKey", BinaryStringEncoding::Utf8); +static auto HKDF_INFO = L"org.cryptomator.windows.keychain.windowsHello"; // Helper methods for conversion std::vector jbyteArrayToVector(JNIEnv* env, jbyteArray array) { @@ -153,6 +153,7 @@ bool deriveEncryptionKey(const std::wstring keyId, const std::vector& c // Derive the encryption/decryption key using HKDF const auto response = signature.Result(); + IBuffer info = CryptographicBuffer::ConvertStringToBinary(HKDF_INFO, BinaryStringEncoding::Utf8); key = DeriveKeyUsingHKDF(response, challengeBuffer, 32, info); // needs to be 32 bytes for SHA256 return true; From 3e179c05f3660e0de1263f0f8257d764ab4fee95 Mon Sep 17 00:00:00 2001 From: Armin Schrenk Date: Wed, 15 Jan 2025 16:09:10 +0100 Subject: [PATCH 5/5] prepare 1.4.1 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 07bea39..6843451 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ 4.0.0 org.cryptomator integrations-win - 1.5.0-SNAPSHOT + 1.4.1 Cryptomator Integrations for Windows Provides optional Windows services used by Cryptomator