mirror of https://github.com/M66B/FairEmail.git
Strip IPV6: prefix from bracket addresses
This commit is contained in:
parent
03e8fb8555
commit
ef8eea1d4e
|
@ -2215,6 +2215,8 @@ public class MessageHelper {
|
|||
int e = value.indexOf(']', s + 1);
|
||||
if (s >= 0 && e > 0) {
|
||||
String ip = value.substring(s + 1, e);
|
||||
if (ip.toLowerCase(Locale.ROOT).startsWith("ipv6:"))
|
||||
ip = ip.substring(5);
|
||||
if (ConnectionHelper.isNumericAddress(ip) &&
|
||||
ConnectionHelper.isLocalAddress(ip))
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue