Changeset 8d9d3fc


Ignore:
Timestamp:
Nov 19, 2015 2:15:28 PM (5 years ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
b59a8027
Parents:
46f4243
Message:

SSU: Add option to disable extended options
Fix max payload type

Location:
router/java/src/net/i2p/router/transport/udp
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • router/java/src/net/i2p/router/transport/udp/EstablishmentManager.java

    r46f4243 r8d9d3fc  
    137137     */
    138138    private static final String VERSION_ALLOW_EXTENDED_OPTIONS = "0.9.22";
     139    private static final String PROP_DISABLE_EXT_OPTS = "i2np.udp.disableExtendedOptions";
    139140
    140141
     
    370371                    }
    371372                    boolean allowExtendedOptions = VersionComparator.comp(toRouterInfo.getVersion(),
    372                                                                           VERSION_ALLOW_EXTENDED_OPTIONS) >= 0;
     373                                                                          VERSION_ALLOW_EXTENDED_OPTIONS) >= 0
     374                                                   && !_context.getBooleanProperty(PROP_DISABLE_EXT_OPTS);
    373375                    // w/o ext options, it's always 'requested', no need to set
    374376                    boolean requestIntroduction = allowExtendedOptions && _transport.introducersRequired();
  • router/java/src/net/i2p/router/transport/udp/UDPPacket.java

    r46f4243 r8d9d3fc  
    8686    public static final int PAYLOAD_TYPE_DATA = 6;
    8787    public static final int PAYLOAD_TYPE_TEST = 7;
    88     public static final int MAX_PAYLOAD_TYPE = PAYLOAD_TYPE_TEST;
    8988    /** @since 0.8.1 */
    9089    public static final int PAYLOAD_TYPE_SESSION_DESTROY = 8;
     90    public static final int MAX_PAYLOAD_TYPE = PAYLOAD_TYPE_SESSION_DESTROY;
    9191   
    9292    // various flag fields for use in the header
Note: See TracChangeset for help on using the changeset viewer.