A re-packaged version of the [BouncyCastle](https://www.bouncycastle.org/ 'BouncyCastle WebSite') [JCE](https://docs.oracle.com/en/java/javase/17/security/java-cryptography-architecture-jca-reference-guide.html 'Java Cryptography Architecture Reference Guide') provider with different package name for more deployment freedom.
Originally, this was an attempt at improving the situation on Android, where the shipped embedded version of BouncyCastle was somewhat cut-down and thus not suitable for various purposes.
Apart from being crippled in certain regards, it was also difficult (if not impossible) to use an updated version of BouncyCastle due to class loader conflicts, because they would use identical class and package names.
BorderCastle is the same as the stock BouncyCastle with a couple of small changes and additions to allow for broader uses.
First of all, SpongyCastle doesn't appear to be maintained any longer and thus it is not reflecting recent BouncyCastle versions.
More importantly, as a manufacturer of software libraries and components, it turned out to be important to allow flexible combination of our libraries with other components, while not enforcing dependency version restrictions on the users of our libraries.
Hence, an application making use of our library could still make use of any version of SpongyCastle or BouncyCastle without running into class loader problems, while still guaranteeing the tested and well-defined environment of our BorderCastle version.
- to avoid class loader conflicts, all packages have been renamed from `org.bouncycastle.*` to `org.bordercastle.*`
- the Java Security API provider name is "**BoCa**" rather than "**BC**" (resp. "**BoCaPQC**" instead of "**BCPQC**" for the post quantum provider)
- no class name changes, so the `BouncyCastleProvider` class remains **Bouncy**, not **Border**, but moves to the `org.bordercastle.jce.provider` package
- added a simple class to allow for version checking without having to instantiate a provider (which is an expensive operation): `org.bordercastle.Version`
- changed the names of the resulting built library files to have a consistent naming pattern
- added new constructors for the provider classes to allow instantiating multiple ones with different names, so they can be used in parallel when needed
The BorderCastle JCE provider is signed with a special JCE code signing certificate for JCE provider signing (issued by the "JCE Code Signing CA, Oracle Corporation"). Check the [wiki](https://www.boarderzone.net/code/bz/bordercastle/wiki/BorderCastle-JCE-Signing 'BorderCastle Wiki - JCE Signing') for more information.
This allows the provider to be used for both, on Android and with "normal" Java on desktop/server systems where the Oracle JRE requires JCE providers to be signed.
BorderCastle is licensed under the same [adaptation of the MIT X11 License](https://www.bouncycastle.org/licence.html 'BouncyCastle License') as the original BouncyCastle library.
The [Wiki](https://www.boarderzone.net/code/bz/bordercastle/wiki 'BorderCastle Wiki') describes the necessary steps for [building](https://www.boarderzone.net/code/bz/bordercastle/wiki/Building-BorderCastle 'BorderCastle Wiki - Build Instructions') and the [resulting files](https://www.boarderzone.net/code/bz/bordercastle/wiki/BorderCastle-Libraries 'BorderCastle Wiki - Libraries').
- a great thanks to the original team from [BouncyCastle](https://www.bouncycastle.org/engage/contributors/ 'BouncyCastle Contributors') for providing and maintaining this powerful piece of software!
- [Roberto Tyley](https://github.com/rtyley 'Roberto Tyley Github Page') who came up with the initial idea of creating the Android port called [SpongyCastle](http://rtyley.github.io/spongycastle/ 'SpongyCastle WebSite')