Changeset 8b9bcbc


Ignore:
Timestamp:
Dec 11, 2015 5:14:45 PM (4 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
c8aca62d
Parents:
00d6a49
Message:

SSU: Fix outbound IPv6 errors on Windows without a real v6 address
when explict host is set. Validate addresses before confirming that
we have an IPv6 address. Possibly related to ticket #1538.
javadocs

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • core/java/src/net/i2p/util/Addresses.java

    r00d6a49 r8b9bcbc  
    6363
    6464    /**
     65     *  Warning: When includeLocal is false,
     66     *  all returned addresses should be routable, but they are not necessarily
     67     *  appropriate for external use. For example, Teredo and 6to4 addresses
     68     *  are included with IPv6 results. Additional validation is recommended.
     69     *  See e.g. TransportUtil.isPubliclyRoutable().
     70     *
    6571     *  @return a sorted set of all addresses including wildcard
    6672     *  @param includeLocal whether to include local
    6773     *  @param includeIPv6 whether to include IPV6
    68      *  @return an array of all addresses
     74     *  @return a Set of all addresses
    6975     *  @since 0.8.3
    7076     */
     
    7480
    7581    /**
     82     *  Warning: When includeSiteLocal and includeLoopbackAndWildcard are false,
     83     *  all returned addresses should be routable, but they are not necessarily
     84     *  appropriate for external use. For example, Teredo and 6to4 addresses
     85     *  are included with IPv6 results. Additional validation is recommended.
     86     *  See e.g. TransportUtil.isPubliclyRoutable().
     87     *
    7688     *  @return a sorted set of all addresses
    7789     *  @param includeSiteLocal whether to include private like 192.168.x.x
    7890     *  @param includeLoopbackAndWildcard whether to include 127.x.x.x and 0.0.0.0
    7991     *  @param includeIPv6 whether to include IPV6
    80      *  @return an array of all addresses
     92     *  @return a Set of all addresses
    8193     *  @since 0.9.4
    8294     */
  • history.txt

    r00d6a49 r8b9bcbc  
     12015-12-11 zzz
     2 * Logs: Windows line ending fixes
     3 * Router:
     4   - Fix family verification, partially hook into netdb store()
     5   - Limit wait for NTP to 45 seconds (ticket #1725)
     6   - Increase lookup cache max sizes,
     7     reduce max lookup depth, and increase non-floodfill profile bonus
     8     to attempt to reduce load on floodfills
     9   - Don't let context clock shifts affect calculated uptime
     10 * Transport: More deadlock prevention (ticket #1722)
     11 * SSU: Fix outbound IPv6 errors on Windows without a real v6 address
     12   when explict host is set. Validate addresses before confirming that
     13   we have an IPv6 address. Possibly related to ticket #1538.
     14 * Wrapper: Listen for Windows Service shutdown events to stop router
     15
    1162015-12-10 zzz
    217 * Router:
  • router/java/src/net/i2p/router/RouterVersion.java

    r00d6a49 r8b9bcbc  
    1919    public final static String ID = "Monotone";
    2020    public final static String VERSION = CoreVersion.VERSION;
    21     public final static long BUILD = 11;
     21    public final static long BUILD = 12;
    2222
    2323    /** for example "-test" */
  • router/java/src/net/i2p/router/transport/udp/UDPTransport.java

    r00d6a49 r8b9bcbc  
    332332            if (fixedHost != null && fixedHost.length() > 0) {
    333333                try {
     334                    // TODO getAllByName(), bind to each
    334335                    String testAddr = InetAddress.getByName(fixedHost).getHostAddress();
    335336                    if (Addresses.getAddresses().contains(testAddr))
     
    734735        if (ip == null)
    735736            return;
     737        // this is essentially isValid(ip), but we can't use that because
     738        // _haveIPv6Address is not set yet
     739        if (!(isPubliclyRoutable(ip) || allowLocal())) {
     740            if (_log.shouldLog(Log.WARN))
     741                _log.warn("Invalid address: " + Addresses.toString(ip, port) + " from: " + source);
     742            return;
     743        }
    736744        if (source == SOURCE_INTERFACE && ip.length == 16) {
    737             // must be set before isValid() call
     745            // NOW we can set it, it's a valid v6 address
     746            // (we don't want to set this for Teredo, 6to4, ...)
    738747            _haveIPv6Address = true;
    739748        }
     
    743752        if (!sources.contains(source.toConfigString()))
    744753            return;
    745         if (!isValid(ip)) {
    746             if (_log.shouldLog(Log.WARN))
    747                 _log.warn("Invalid address: " + Addresses.toString(ip, port) + " from: " + source);
    748             return;
    749         }
    750754        if (!isAlive()) {
    751755            if (source == SOURCE_INTERFACE || source == SOURCE_UPNP) {
Note: See TracChangeset for help on using the changeset viewer.