Skip to content

Commit

Permalink
Remove security lowering kludge.
Browse files Browse the repository at this point in the history
As stated in the description of this option, if a large portion of the network disables packet padding it makes the network easier to trace. 15 years later now, if network overhead is a real concern for some users they can tweak this themselves.
  • Loading branch information
Juiceman committed Jan 2, 2024
1 parent ba8249c commit 6e69571
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions src/freenet/node/NodeCryptoConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -240,18 +240,7 @@ public void set(Boolean val) throws InvalidConfigValueException, NodeNeedRestart
});

paddDataPackets = config.getBoolean("paddDataPackets");
securityLevels.addNetworkThreatLevelListener(new SecurityLevelListener<NETWORK_THREAT_LEVEL>() {

@Override
public void onChange(NETWORK_THREAT_LEVEL oldLevel, NETWORK_THREAT_LEVEL newLevel) {
// Might be useful for nodes which are running with a tight bandwidth quota to minimize the overhead,
// so turn it off for LOW. Otherwise is sensible.
if(newLevel == NETWORK_THREAT_LEVEL.LOW)
paddDataPackets = false;
if(oldLevel == NETWORK_THREAT_LEVEL.LOW)
paddDataPackets = true;
}
});
}

/** The number of config options i.e. the amount to increment sortOrder by */
Expand Down

0 comments on commit 6e69571

Please sign in to comment.