-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix InetAddress-wrapping of long AFSocketAddresses
Long socket addresses, such as non-ASCII addresses in the Abstract Namespace close to the maximum length of 108 bytes may not be representable by our custom address wrapping representation used for InetAddress, resulting in an exception upon bind, etc. This is caused by URL-encoding any non-printable characters, resulting in three UTF-8 characters per byte (3*108+x > 255, an internal limit). Introduce a fixed-length hex-encoding, which is recognizable by a wrapped-hostname string starting with "[%%", followed by a sequence of 2-character hex values (2*108+2+x <= 255).
- Loading branch information
1 parent
f8f280c
commit ef283bb
Showing
2 changed files
with
47 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters