ADFA-2564: Remove Bouncy castle provider from KeyPairGenerator#883
ADFA-2564: Remove Bouncy castle provider from KeyPairGenerator#883Daniel-ADFA merged 2 commits intostagefrom
Conversation
|
closes #830 |
📝 WalkthroughRelease Notes: Remove Bouncy Castle Provider from KeyPairGeneratorChanges
|
| Cohort / File(s) | Summary |
|---|---|
Keystore Cryptography Simplification common/src/main/java/com/itsaky/androidide/managers/ToolsManager.java |
Removed BouncyCastle provider registration and explicit provider specification in KeyPairGenerator. Consolidated password management by replacing keyPassword with storePassword for keystore entry creation. Updated property storage to use KEYPWD for storePassword consistency. |
Estimated code review effort
🎯 2 (Simple) | ⏱️ ~10 minutes
Poem
🐰 Bouncy Castle walls we tear down today,
One provider gone, the default's here to stay,
Password unified, no more the split way,
Simpler keystore magic, hopping through the fray! ✨
🚥 Pre-merge checks | ✅ 1 | ❌ 2
❌ Failed checks (1 warning, 1 inconclusive)
| Check name | Status | Explanation | Resolution |
|---|---|---|---|
| Docstring Coverage | Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. | Write docstrings for the functions missing them to satisfy the coverage threshold. | |
| Description check | ❓ Inconclusive | No pull request description was provided by the author, making it impossible to assess whether it relates to the changeset. | Add a description explaining why the BouncyCastle provider was removed and any relevant context or benefits of this change. |
✅ Passed checks (1 passed)
| Check name | Status | Explanation |
|---|---|---|
| Title check | ✅ Passed | The title accurately describes the main change: removing BouncyCastle provider from KeyPairGenerator, which matches the file modifications in the changeset. |
✏️ Tip: You can configure your own custom pre-merge checks in the settings.
✨ Finishing touches
- 📝 Generate docstrings
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Comment @coderabbitai help to get the list of available commands and usage tips.
There was a problem hiding this comment.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
common/src/main/java/com/itsaky/androidide/managers/ToolsManager.java (1)
218-219: Add explicit BC provider to JcaContentSignerBuilder or use standard algorithm name.The code uses "SHA256WithRSAEncryption", a BouncyCastle-specific algorithm name, without registering the BC provider or explicitly specifying it via
setProvider(). This will causeNoSuchAlgorithmExceptionat runtime on devices where BC is not the default provider. Either:
- Register BC globally before building the signer:
Security.addProvider(new BouncyCastleProvider());- Set the provider explicitly:
.setProvider("BC")or.setProvider(new BouncyCastleProvider())- Use the standard JCA name instead:
"SHA256withRSA"
🧹 Nitpick comments (2)
common/src/main/java/com/itsaky/androidide/managers/ToolsManager.java (2)
61-61: Remove unused import.
BouncyCastleProvideris imported but no longer used since the explicit provider registration was removed.🧹 Suggested cleanup
-import org.bouncycastle.jce.provider.BouncyCastleProvider;
50-50: Remove unused importjava.security.Security.The
Securityclass is not used in this file and can be removed.
No description provided.