New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
URL encoding clashes with base64 encoding values for dbCryptConfig [JDBC610] #641
Comments
Modified by: @mrotteveeldescription: The URL encoding added in JDBC604 conflicts with the base64 encoding support for dbCryptConfig, as URL decoding will transform the + allowed in base64 to a space, which results in an incorrect decoding or a decoding error. We need to find a way to allow both to coexist. Options: Option 1 is probably the least worst option => The URL encoding added in JDBC604 conflicts with the base64 encoding support for dbCryptConfig, as URL decoding will transform the + allowed in base64 to a space, which results in an incorrect decoding or a decoding error. We need to find a way to allow both to coexist. Options: Option 4 is the simplest and most standard, option 1 is probably the most flexible. |
Commented by: @mrotteveel Chose option 4: documented issue in release notes |
Commented by: @mrotteveel Documentation for 3.0.9 needs to be updated as well. |
Modified by: @mrotteveelFix Version: Jaybird 3.0.9 [ 10917 ] |
Commented by: @mrotteveel Updated 3.0.9 release notes |
Modified by: @mrotteveelstatus: Resolved [ 5 ] => Closed [ 6 ] |
Submitted by: @mrotteveel
The URL encoding added in JDBC604 conflicts with the base64 encoding support for dbCryptConfig, as URL decoding will transform the + allowed in base64 to a space, which results in an incorrect decoding or a decoding error.
We need to find a way to allow both to coexist.
Options:
1. Do not URL decode values starting with prefix base64: (under the assumption that if the `:` is not encoded as `%3a`, the remainder of the value is also not URL encoded)
2. Reinstate the + after decoding by replacing any ` ` (0x20) with `+`, possibly error prone
3. Switch to Base64.getUrlDecoder() (which would be an incompatible change, and would be problematic with Java 7 compatibility)
4. Explicitly document this, and recommend people to escape the `+` using `%2b`
Option 4 is the simplest and most standard, option 1 is probably the most flexible.
Commits: dd6e601 0b8d483
The text was updated successfully, but these errors were encountered: