Author: toad
Date: 2008-09-05 23:24:01 +0000 (Fri, 05 Sep 2008)
New Revision: 22484
Modified:
trunk/freenet/src/freenet/node/Version.java
Log:
1161: (Mandatory midnight GMT 13 September)
L10n:
- Revert a broken (wrong charset) update for the Italian translation.
Minor optimisations:
- More StringBuffer -> StringBuilder.
- Undo some unwise (extra object allocations) use of autoboxing.
- Don't need to set() after already add()ed in BCB.
Client layer, updater priorities, ULPRs:
- Reduce the priority of fetching (when offered) keys that other nodes are
known to want to BULK_SPLITFILE_PRIORITY_CLASS (4/low). They were at 2, and
were interfering with node updating, ARK fetches etc.
- Increase node updater download priority to 2. It was getting swamped with
ARKs etc at 3.
- Increase the priority of the updater polling to between 2 and 1, for similar
reasons.
bytesToInts() was broken:
- was returning the same int over and over.
- caused loss of entropy when creating a MersenneTwister in various places.
- this means that CHK padding will change so CHKs may change (backwards
compatible).
- intsToBytes() was returning 2x as many bytes as it needed. It is used in
splitfile params Metadata, so metadata keys may also change; but they'd change
anyway because of the above.
L10n:
- Increase the size of the box to type in the translation on the translation
toadlet.
- Chinese update from yongzhen.
- Finnish update from Smar and Samu.
- Swedish update from Cooo.
- German update from tommy.
Opennet:
- Announce immediately instead of waiting, if all announcements complete and no
peers have been added.
- Clarify useralert warning slightly.
- Show when freenet is not announcing because it doesn't know its IP yet. Show
the alert in this case.
- Trust seednodes when they give us our IP address (as much as we trust any
other node to report it accurately). Greatly speeds up bootstrapping if we
don't know our IP and can't easily find it (e.g. via UPnP/JSTUN). This is the
case in the automated network testing code, see below.
- Turn off "Be a seednode" by default. Seednodes should turn it on manually.
This change only applies to new nodes as the config is always written to disk.
- Don't dump a node just because it temporarily has 21 peers locations; this
can happen innocently. Dump it if it has 40, and if it has less just take the
first 20.
Security Levels:
- Instead of asking the user whether (s)he wants opennet in the first-time
wizard, we ask them 3 questions to set the security levels in 3 categories:
network, friends and physical. We explain why a user would want each level, and
what the drawbacks are, with a confirmation dialog if they do something that
will probably cause problems.
- The security levels determine the defaults for various config settings. More
will be added later, the main thing at the moment is that HIGH or MAXIMUM
network security sets pure darknet mode, and LOW physical security sets temp
file encryption off.
- The security levels are displayed in a useralert, instead of the opennet
warning. They can be changed at any time from a new sub-page on the config
toadlet, but if the user tries to switch to HIGH or MAXIMUM and has no/few
peers, we warn them with a confirmation dialog explaining the ramifications of
doing this.
- Other config consequences at present:
-- Network level LOW disables one connection per IP on opennet.
-- HIGH or MAXIMUM network level *and* HIGH friends level disables FOAF routing
(but not sending the locations).
-- MAXIMUM network security enables ignoreLocalVsRemoteBandwidthLiability.
-- HIGH friends threat level disables alwaysAllowLocalAddresses on darknet.
- SecurityLevels class, SecurityLevelListener<level type> listener interface.
Datastore:
- MERGE THE SALTED HASH STORE BRANCH.
- New datastore type: salt-hash.
- sdiz has been working on this for months, much testing has happened on FMS.
- The basic principle is a non-chained (i.e. lossy, but with limited quadratic
probing) on-disk hash table. The key is salted and some bits of the hashed
value are used to determine where to store it. So we don't need to maintain an
index.
- The code is much simpler and hopefully more reliable than the BDBJE based
store. It should also be slightly faster and lower resource usage, both locally
and at the network level (according to simulations; it models random
replacement, which should be slightly better than LRU). It won't spontaneously
corrupt and need to be rebuilt, unlike the bdbje store, although resizing and
bloom filters are occasionally necessary (and blocking i.e. on startup).
- It supports a Bloom filter for each store, which greatly reduces the disk
seeking cost of a cache miss. Since most lookups fail, this is a great
optimisation.
- It does support auto-migration from bdbje, but this process takes up a lot of
disk space.
- Key-dependant encryption (to slow down offline analysis when the attacker may
not know what he's looking for at the time of seizure, but finds out about keys
on an ongoing basis) is an option but is off by default.
- The default store type is still bdbje, for the time being. When it has been
fully tested and we are satisfied that it is better, we'll change the default.
Plugins:
- FredPluginToadlet: meta interface for plugins that are closely integrated
into the node look and feel.
- FredPluginUoF: interface for plugins that can be updated over Freenet.
Misc config:
- Set alwaysAllowLocalAddreses on by default on darknet, off by default on
opennet.
- Make includeLocalAddressesInNoderefs per-port i.e. one for opennet, one for
darknet. On by default on darknet, off by default on opennet.
Misc UI:
- Actually tell the user to click on an alert for more details or to change
something. Unfortunately most people don't! Prodding may be required even if
the user is web literate.
- Don't block the activelinks for Chrome, unlike other webkit-based browsers,
it doesn't stall on them (we hope!).
- Update bookmarks
IP detection:
- Try to find our external address from our peers if we have no locally
detected valid address, *even if* we have valid local addresses and have
includeLocalAddressesInNoderef enabled.
Port forward detection:
- Various bugfixes for the FNPSentPackets port forward detection code.
Including the above fix for bytesToInts.
- Unfortunately I'm now of the view that this can't possibly work on frequently
saturated upstream links, and doesn't produce enough data to implement a voting
scheme, so I've disabled it.
- We now rely entirely on the AddressTracker code to determine connectivity.
- Improve warnings for port forwarding slightly, mention possible 24 hour lag
in the long version.
- After opennet has been enabled for an hour, assume we are MAYBE_NATED, and
show the alert.
- Don't show the alert if both ports are DONT_KNOW.
- Fix a bug in AddressTrackerItem that may have been causing inaccurate (too
generous) detections.
Dev stuff:
- More 1.5isms: generics, @Override, for(:).
- Use Class<?> not Class, catch ClassNotFoundException where appropriate in
some reflection based code for SSL.
- Delete duplicate class ImmutableByteArrayWrapper.
- Remove unnecessary casts, imports, etc.
- Trivial refactorings (e.g. use addAll).
- Use ArrayList not Vector for temporary lists.
- Use @SuppressWarnings a bit.
- Squash lots of warnings with the above!
- Logging.
Automated network testing code:
- Record the result of each seednode test in a file for each seednode. Indicate
which nodes have not been connectible for a week.
- Bootstrap times were *severely* biased (way too large) because we didn't know
our IP address until we got a real (non-seed) connection. Now we pick up our
address from the first seednode, and immediately do a viable (with our proper
IP) announcement.
- Option to pass our real IP addres in to the network testing code.
Installer:
- update.sh was broken, the file comparison function wasn't working so it would
always download an update and ignore it.
Contrib:
- Add a build script for db4o.
Tests:
- Add Fields unit tests for bytesToInt, bytesToInts, intToBytes, intsToBytes,
and add lengths checks for both these and their long equivalents.
Website:
- Minor FAQ fix.
sdiz
nextgens
toad
yongzhen
Smar
Samu
Cooo
tommy
Other stuff going on in SVN recently:
batosai's Web of Trust plugin:
- Major refactoring.
- Query on a string version of the identity, but keep the URIs around too.
- Query the database via SODA.
- Remove the test page.
- Added unit tests.
- Refactor trust score calculation: do it in Identity.
Bombe's jSite:
- Version 0.6
- "Reset edition" action.
- Don't forget to record last insertion time.
toad's db4o branch:
- Minor stuff mostly, dead code removal, use 1.5.
- Remove a broken workaround for too many decompressors in SingleFileFetcher.
- Selective deactivation fix.
Modified: trunk/freenet/src/freenet/node/Version.java
===================================================================
--- trunk/freenet/src/freenet/node/Version.java 2008-09-05 23:23:24 UTC (rev
22483)
+++ trunk/freenet/src/freenet/node/Version.java 2008-09-05 23:24:01 UTC (rev
22484)
@@ -24,17 +24,17 @@
public static final String protocolVersion = "1.0";
/** The build number of the current revision */
- private static final int buildNumber = 1160;
+ private static final int buildNumber = 1161;
/** Oldest build of Fred we will talk to */
- private static final int oldLastGoodBuild = 1158;
- private static final int newLastGoodBuild = 1160;
+ private static final int oldLastGoodBuild = 1160;
+ private static final int newLastGoodBuild = 1161;
static final long transitionTime;
static {
final Calendar _cal =
Calendar.getInstance(TimeZone.getTimeZone("GMT"));
// year, month - 1 (or constant), day, hour, minute, second
- _cal.set( 2008, Calendar.SEPTEMBER, 5, 0, 0, 0 );
+ _cal.set( 2008, Calendar.SEPTEMBER, 13, 0, 0, 0 );
transitionTime = _cal.getTimeInMillis();
}