[JAVA-4443] Replace org.bson.internal.Base64 with java.util.Base64 Created: 13/Jan/22 Updated: 28/Oct/23 Resolved: 17/Jan/22 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | Internal |
| Affects Version/s: | None |
| Fix Version/s: | 4.5.0 |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Jeffrey Yemin | Assignee: | Jeffrey Yemin |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Backwards Compatibility: | Minor Change |
| Documentation Changes: | Not Needed |
| Description |
|
The driver has a vendored copy of Apache Commons' Base64 implementation. Now that the driver's minimum JDK is Java 8, it can be replaced with the JDKs Base64 API. One reason to do this sooner than later is that it appears that the vendored code is buggy. It improperly decodes Mw6mdTVPQfm4quqSCLVB3g=, while the JDKs version throws an exception, which appears to be correct. When re-encoding, it encodes to Mw6mdTVPQfm4quqSCLVB3g==, which both versions are able to decode. |
| Comments |
| Comment by Githook User [ 17/Jan/22 ] |
|
Author: {'name': 'Jeff Yemin', 'email': 'jeff.yemin@mongodb.com', 'username': 'jyemin'}Message: Replace org.bson.internal.Base64 with java.util.Base64 (#854)
|