Commit Graph

1423 Commits

Author SHA1 Message Date
5b6e7ba91d Added some skeleton Spec tests for various I2P data types in net.i2p.data 2012-07-30 14:50:51 +00:00
zzz
77a19a0b17 0.9.1 2012-07-30 13:28:56 +00:00
zzz
7ecb90640c fixes after review 2012-07-30 13:15:58 +00:00
691ce6fec7 The first ScalaTest specification: a Hash must be 32 bytes long 2012-07-30 12:36:00 +00:00
618f214a4f Added ScalaTest support to core build.xml
The old JUnit tests are still present, but "ant test" and "ant fulltest" default
to the (pending) ScalaTest ones. To run the ScalaTest tests with Cobertura, execute
the following:

ant -Dscalatest.libs=./lib -Dwith.cobertura=/usr/share/java/cobertura.jar fulltest

The scalatest.libs property must point to a directory containing scala-compiler.jar,
scala-library.jar and scalatest.jar.
2012-07-30 12:26:35 +00:00
48df91f796 Moved existing JUnit tests to junittest/ in preparation for ScalaTest 2012-07-30 04:04:07 +00:00
d27d0bd2e4 A couple more specific excludes for JUnit tests 2012-07-30 04:03:02 +00:00
zzz
54a80d6bdc javadoc 2012-07-27 15:31:20 +00:00
zzz
e2aa2affd7 * LookaheadInputStream: Fix bug causing gunzip fails, esp. on Android
* SSLEepGet: Fix on Android (ticket #668)
2012-07-23 23:10:26 +00:00
zzz
e2588a5379 move DecayingBloomFilter, DecayingHashSet, and xlattice filters from core to router 2012-07-02 19:22:33 +00:00
zzz
ab18550711 * Update: Increase eepget timeouts to reduce retries 2012-06-29 16:25:22 +00:00
zzz
ebb6609a2b fix SimpleTimer logging 2012-06-29 14:05:39 +00:00
zzz
6c8c87b2dd javadocs 2012-06-25 19:29:51 +00:00
zzz
50fba8fc8d propagate from branch 'i2p.i2p' (head db152f1a9e08e80c7bd3b87735b51800e8f4c46f)
to branch 'i2p.i2p.zzz.dhtsnark' (head 9b08b2f47961167d0fee52b6481895c494d410d6)
2012-06-24 19:53:20 +00:00
zzz
5eab417134 propagate from branch 'i2p.i2p' (head db152f1a9e08e80c7bd3b87735b51800e8f4c46f)
to branch 'i2p.i2p.zzz.test' (head 5fd7a423338073ff81f5118cde74317b567846a6)
2012-06-24 19:53:08 +00:00
zzz
1671e3b126 Fix bad size estimate when tags are included in the AES block,
resulting in trailing zeros after the random padding in the unencrypted AES data block.
The number of zeros equaled the number of tags included (typ. 6 or 40).
As the data size is rounded up to the next multiple of 16,
this increased the size of the data by 0, 16, 32, or 48 bytes when tags were included.
Bug introduced 2004-10-30.
2012-06-24 19:23:05 +00:00
zzz
fe53501990 * GarlicMessage:
- Put data clove last to speed acks and leaseset store on far end
  - Change release target
  - Javadocs and cleanups
2012-06-24 14:41:50 +00:00
zzz
e497859587 * ElGamal/AES/SessionTag:
- Increase TX expire from 10 to 12 min, while keeping RX expire at 15 min.
    3 minutes should be plenty of clock skew + delay.
  - Move tags-to-send and low-threshold values to be per-SKM
  - New session config options crypto.tagsToSend and crypto.lowTagThreshold
  - Prep for per-packet override of tags and thresholds
  - Cleanups and Javadocs
* I2PTunnel: Add some defaults for the new session config options
* OCMOSJ:
  - Don't bundle LeaseSet just because we're requesting an ACK
  - Changed session config option shouldBundleReplyInfo to default to true
    and be used to disable bundling altogether when set to false.
    Was previously an undocumented option to force bundling with a certain probability.
  - Don't send tags unless we've already generated a reply token (race)
  - Cleanups and Javadocs
2012-06-24 13:17:52 +00:00
zzz
97b05b1dbf * I2PTunnel: Fix NPE on shared client creation, thx kytv
* Transport: Add Ethiopia to hidden mode list
 * Log and javadoc tweaks
2012-06-24 11:38:37 +00:00
zzz
5883b7344e propagate from branch 'i2p.i2p' (head 80aed456e1c6e4b17906153c9ee6dc9bc45e0eec)
to branch 'i2p.i2p.zzz.dhtsnark' (head dbf88ff4c1429f26656ad34fe0b9ba94305d726a)
2012-06-22 15:13:04 +00:00
zzz
baa89c5bbf * OCMOSJ, ElG, Streaming: log tweaks 2012-06-21 19:10:14 +00:00
zzz
39d9a25e19 log tweak 2012-06-20 12:22:43 +00:00
zzz
b5dad73f6f * I2PSession:
- Greatly simplify the VerifyUsage timers
   - Constructor cleanup
2012-06-20 12:18:57 +00:00
zzz
c6d1c552f8 propagate from branch 'i2p.i2p' (head 9ca94e960929c6af5dea1085105278d2f33217f2)
to branch 'i2p.i2p.zzz.dhtsnark' (head 1f23a71b0fa5169c220f3f21dd705e1fcfbb1b5d)
2012-06-19 23:31:53 +00:00
zzz
129b16d93d * Streaming:
- Listen only on local port if set
   - Listen only for streaming protocol if configured (new option)
   - Javadocs re: ports
2012-06-19 20:26:46 +00:00
zzz
e62b76d2cc Big refactor of the router console update subsystem, in preparation for
implementing out-of-console updaters like i2psnark.

- Add new update interfaces in net.i2p.update
- All update implementations moved to routerconsole update/
- Implement an UpdateManager that registers with the RouterContext
- UpdateManager handles multiple types of things to update
  (router, plugins, news, ...) and methods of updating (HTTP, ...)
- UpdateManager maintains list of installed, downloaded, and available versions of everything
- Define Updaters that can check for a new version and/or download an item
- Individual Updaters register with the UpdateManager obtained from
  I2PAppContext, identifying the type of update item and
  update method they can handle.
- Updaters need only core libs, no router.jar or routerconsole access required.
- All checks and updates are initiated via the UpdateManager.
- All status on checks and updates in-progress or completed are
  obtained from the UpdateManager. No more use of System properties
  to broadcast update state.
- All update and checker tasks are intantiated on demand and threaded;
  no more static references left over.
- Split out the Runners and Checkers from the Handlers and make the inheritance more sane.
- No more permanent NewsFetcher thread; run on the SimpleScheduler queue
  and thread a checker task only to fetch the news.
- No more static NewsFetcher instance in routerconsole.
  All helper methods that are still required are moved to NewsHelper.

The UpdateManager implements the policy for when to check and download.
All requests go through the UpdateManager.

For each update type, there's several parts:
    - The xxxUpdateHandler implements the Updater
    - The xxxUpdateChecker implements the UpdateTask for checking
    - The xxxUpdateRunner implements the UpdateTask for downloading

New and moved classes:

web/				update/
----				-------
new				ConsoleUpdateManager.java

new				PluginUpdateChecker.java from PluginUpdateChecker
PluginUpdateChecker 		-> PluginUpdateHandler.java
PluginUpdateHandler.java	-> PluginUpdateRunner

new				UnsignedUpdateHandler.java
UnsignedUpdateHandler		->  UnsignedUpdateRunner.java
new				UnsignedUpdateChecker from NewsFetcher

UpdateHandler.java remains
new				UpdateHandler.java
new				UpdateRunner.java from UpdateHandler

move				NewsHandler from NewsFetcher
new				NewsFetcher
new				NewsTimerTask

new				DummyHandler


Initial checkin. Unfinished, untested, unpolished.
2012-06-18 22:09:45 +00:00
zzz
fe2b97c941 propagate from branch 'i2p.i2p' (head 27fc588723d201c76ea9c18a6c715b11efcb5b0e)
to branch 'i2p.i2p.zzz.dhtsnark' (head cae6d265415ba9ed4242b3fc888ffcf2a1c1b2f2)
2012-06-11 20:29:19 +00:00
zzz
7469e9c63d * NativeBigInteger: Workaround for Raspberry Pi to load the correct lib 2012-06-11 11:48:34 +00:00
zzz
7b07eb89a3 - Uncomment DHT
- Change DHT from option bit to extension message
- Add DHT start/stop code
- Add UI for DHT enabling
- Add raw datagram protocol type and use for response port
2012-06-02 18:52:46 +00:00
zzz
f14ff31a20 * Timestamper:
- Move from core to router, leave stub in core
     so it doesn't break compatibility. This removes a
     thread in app context and prevents any app context from
     running NTP; external clients must use the time
     received from the router.
   - Increase query interval
2012-05-30 20:03:30 +00:00
zzz
829af21c49 javadoc fix 2012-05-28 18:04:11 +00:00
zzz
c2e39687e6 * RoutingKeyModifier: Several changes to ensure the routing key
is correctly changed just after midnight.
2012-05-20 18:20:48 +00:00
zzz
7a690b245f rename windows installer; 0.9 2012-05-01 21:06:17 +00:00
c89e127d8a Added missing test classes to net.i2p.data.i2cp 2012-04-27 03:00:45 +00:00
104bfa8784 Exclude TestSuite classes from testing 2012-04-27 02:45:00 +00:00
e99749097a Moved tests for net.i2p.data.i2cp into the correct subdirectory 2012-04-26 12:08:14 +00:00
ce8cd91d72 propagate from branch 'i2p.i2p' (head 3002b47d5d20180f84fb6a4f161823bc751989be)
to branch 'i2p.i2p.unittests' (head 97dc8de19916c3d0c7ec42790800c1e23f9ce9e8)
2012-03-30 05:10:53 +00:00
0cefaba925 More excess whitespace removed 2012-03-30 04:40:56 +00:00
zzz
565807126c * RouterInfo: Fix fatal NPE in last checkin 2012-03-28 19:17:39 +00:00
zzz
fbd230f21e * RouterInfo: Add method to validate sig during read-in for speed 2012-03-27 20:25:26 +00:00
zzz
764a7f2e13 remove unused private items (eclipse) 2012-03-26 00:52:06 +00:00
zzz
1db58dee89 remove unused local variables (eclipse) 2012-03-25 22:16:03 +00:00
zzz
f13956d380 remove unused imports (eclipse) 2012-03-25 21:45:18 +00:00
zzz
522ae4eb41 fix fallthrough 2012-03-25 20:52:57 +00:00
zzz
3e889d2747 remove unnecessary casts (eclipse) 2012-03-25 20:42:41 +00:00
ba3bc9e2ed Uncommented two Datagram tests that currently throw NullPointerExceptions 2012-03-24 11:18:37 +00:00
f164951848 Actually test something in DatagramTest.testBadagram, remove excess whitespace 2012-03-24 08:04:49 +00:00
bfaf72a547 Added a couple of tests for net.i2p.client.naming 2012-03-24 05:09:31 +00:00
zzz
0d565818d4 final 2012-03-23 17:01:34 +00:00
zzz
c1a7f90860 test cleanup 2012-03-23 17:01:24 +00:00