Compare commits

...

2551 Commits

Author SHA1 Message Date
zzz
c7de4e46c1 0.9.14.1 2014-08-09 21:24:18 +00:00
zzz
fbdc535287 * i2psnark: Fix more escaped messages 2014-08-08 20:05:42 +00:00
64ec9f6a00 GeoIP db updates
Updates to geoip.txt and geoipv6.dat.gz based on Maxmind GeoLite Country
database from 2014-08-06
2014-08-07 23:28:51 +00:00
2d6f71dc12 debian: changelog update 2014-08-07 23:26:17 +00:00
zzz
d4722e0d2c * i2psnark: Fix excaped message 2014-08-07 13:39:24 +00:00
zzz
7187f6f714 * Console: Display full path to config file
* i2ptunnel: More escaping
2014-08-06 13:40:25 +00:00
e10e05166f refresh patch 2014-08-06 09:03:18 +00:00
b0f8d84a7f updated debian/po/uk.po 2014-08-06 09:03:02 +00:00
zzz
0e9ceba057 * i2ptunnel: Fix filtering of custom options 2014-08-05 21:26:48 +00:00
zzz
fe3059f0ab * Plugins: Enforce signing key matches that in plugin.config 2014-08-05 21:23:48 +00:00
bd566f52cf Adding SWAT's reseed(su3) certificate. 2014-08-05 09:27:24 +00:00
zzz
b7e0dabe61 fix manual wrapper URL 2014-08-04 15:49:46 +00:00
zzz
2d2348f671 payload bounds check 2014-08-03 14:36:20 +00:00
zzz
b28eb708a4 * Console:
- Fix update buttons
   - Don't filter parameter names starting with "nofilter_"
   - Re-allow configadvanced, news URL, and unsigned update URL if routerconsole.advanced=true
   - Re-allow plugin install if routerconsole.advanced=true or routerconsole.enablePluginInstall=true
   - Only allow whitelisted plugin signers, unless routerconsole.allowUntrustedPlugins=true
   - Re-allow clients.config changes if routerconsole.advanced=true or routerconsole.enableClientChange=true
   - More escaping
 * i2psnark: Fix add torrent form
2014-08-03 13:58:51 +00:00
bf9c4b2346 new su3 cert as pwd for old lost, old one not in use till yet 2014-07-31 19:11:48 +00:00
zzz
d33aa097fe bump 2014-07-31 14:56:04 +00:00
zzz
8673c232b6 Whitelist of known plugin public keys
Compiled by kytv from plugins.i2p
todo: implementation
2014-07-31 14:51:02 +00:00
zzz
d3ea5d2122 drop ExecNamingService, moving to i2p.scripts 2014-07-31 14:44:52 +00:00
zzz
370d2555c7 Notes and logging re: compiling with Java 8 2014-07-31 14:42:51 +00:00
zzz
5332cee3e8 update credit as requested 2014-07-27 11:02:59 +00:00
zzz
1246e1c498 0.9.14 2014-07-26 20:32:26 +00:00
zzz
d6b0b1b93c refresh tweaks
another escape html
2014-07-26 20:14:01 +00:00
zzz
1e0c970c95 remove add client button 2014-07-26 19:31:36 +00:00
zzz
db9f49c7d4 updates after review:
Disable clients.config editing in UI
Strip single quotes too
Fix double-escaping in susimail folder page
2014-07-26 18:58:58 +00:00
zzz
1603353ae8 Susimail escaping from psi plus some more 2014-07-26 16:50:58 +00:00
zzz
6753d23309 Add filtering for getParameterMap()
Don't return null entries in getParameterValues() array
Log in getParameterValues() too
static
2014-07-26 15:09:40 +00:00
zzz
ca5755b0fd javadoc move new classes 2014-07-26 13:51:48 +00:00
zzz
2c8223274d filter pattern tweaks 2014-07-26 13:43:52 +00:00
zzz
f0dd09cf9c filter logging 2014-07-26 12:18:35 +00:00
zzz
4746d9eb80 Fix CSP to allow inline style and refresh
Add filter to all webapps
2014-07-26 11:01:16 +00:00
zzz
99401c5639 fix link 2014-07-26 10:51:42 +00:00
zzz
58578d9020 Console:
XSSFilter patch from str4d:
  XSSFilter and XSSRequestWrapper were from http://ricardozuasti.com/2012/stronger-anti-cross-site-scripting-xss-filter-for-java-web-apps/
  No provided license, but it is clearly intended for public consumption.
  But most of it is boilerplate provided by the Servlet Filter system.
  In fact, now that I have stripped out his JS-specific patterns and replaced it with the whitelist,
  it is effectively identical to what I would have written from scratch.
2014-07-26 09:39:31 +00:00
zzz
af575d6c95 * Console:
- Fix several XSS issues (thx Aaron Portnoy of Exodus Intel)
  - Add Content-Security-Policy and X-XSS-Protection headers
  - Disable changing news feed URL from UI
  - Disable plugin install from UI
  - Disable setting unsigned update URL from UI
  - Disable /configadvanced
* DataHelper: Disallow \r in storeProps() (thx joernchen of Phenoelit)
* ExecNamingService: Disable (thx joernchen of Phenoelit)
* Startup: Add susimail.config to migrated files
2014-07-26 09:32:26 +00:00
e9c8748c0b Updated Eclipse settings 2014-07-26 02:48:49 +00:00
08409d016b translation updates from Transifex 2014-07-23 13:55:58 +00:00
42bfbfc60b geoip database updates 2014-07-23 13:54:36 +00:00
c7c087d964 fix poupdate target 2014-07-23 13:49:09 +00:00
bd45d5483f Added new reseed host, thanks to Backup.
Notes: Only HTTPS and SU3 (v2) support.
2014-07-22 17:56:50 +00:00
zzz
ce4874d825 better logging of reseed su3 errors 2014-07-21 20:05:05 +00:00
9b408b67ef Adding Matt's SU3 reseed key. 2014-07-21 18:07:02 +00:00
zzz
c3bf100082 readme_fr.html thx hummingbird 2014-07-21 13:24:13 +00:00
zzz
b282ccd890 increment error count on exception 2014-07-21 13:23:14 +00:00
f38b741813 Adding sindu's reseed key. ( i2p-netdb.innovatio.no ) 2014-07-21 01:47:37 +00:00
3a899d52d1 Don't grab the ClientApp if we don't need to 2014-07-19 23:55:43 +00:00
zzz
a2567b0ee2 * SusiMail: Better error message on decode fail
http://forum.i2p/viewtopic.php?t=11469
2014-07-19 16:31:59 +00:00
zzz
4b0019c732 * SAM: Add support for RAW on the bridge socket in v3 (ticket #1334)
log fixes
2014-07-19 15:43:51 +00:00
zzz
5d21738410 * i2psnark: Don't prefer leeches during end game, to
prevent slowdowns or stalls
2014-07-19 12:48:16 +00:00
zzz
df81006b42 javadoc 2014-07-19 12:40:23 +00:00
zzz
2c7006e9bd Streaming; Disable fail-fast for now. It's failing on leaseset lookup
far too often. Need to fix that first.
2014-07-19 12:39:37 +00:00
b1caa8d5a3 fix URL in initialNews: It's i2p-projekt not i2p-project
(thanks to SeekingFor for the heads-up)
2014-07-15 23:46:08 +00:00
zzz
8b2ffada10 - fix test
- final
- last week's history
2014-07-15 14:30:19 +00:00
0998738e94 Updated history 2014-07-15 12:59:56 +00:00
c04062bbdf Forgot to update @since 2014-07-15 12:58:58 +00:00
0c7a3a3a39 Stubs for I2CP connections over Unix domain sockets 2014-07-15 12:54:22 +00:00
zzz
f364a83f4f mtn.i2p-projekt.i2p 2014-07-14 20:40:36 +00:00
zzz
9dabc75866 * SU3File: Disable the X.509 CN checking of local certs on Android,
as the javax.naming classes are not available.
   Any issues with local certs will be discovered in non-Android testing.
2014-07-13 13:29:55 +00:00
zzz
2c185ea76c * Datagrams:
- Redefine the repliable datagram signature for non-DSA_SHA1 sig types;
    was the sig of the SHA-256 of the payload, now the sig of the payload itself.
    This is an incompatible change but nobody is yet using the new
    sig types for datagram applications.
  - Don't pollute the hash cache with hashes of payloads
  - Check for too-big datagrams
  - Remove assertion check
  - Cleanups
2014-07-11 19:31:44 +00:00
zzz
39e859c368 javadoc 2014-07-11 19:29:44 +00:00
zzz
dfbe3c4eb1 signing key type check 2014-07-09 13:29:52 +00:00
zzz
b8170a544b add reseed cert 2014-07-09 13:27:57 +00:00
4e7f92ec89 Removing certificate + added it to delete list 2014-07-09 00:46:18 +00:00
292683268b Thanks for the past support in reseeding pkol!
Removing reseed host after request.


From: pkol <pkol@mail.i2p>
To: Meeh <meeh@mail.i2p>
Subject: Reseed server shutdown
X-Mailer: smtp.postman.i2p - Official I2P Mailer

Hi meeh,

I wanted to announce the discontinuation of my reseed server
(reseed.pkol.de) at the end of July/beginning of August.

Thanks for your support during the initial setup.

Cheers
pkol
2014-07-09 00:29:59 +00:00
zzz
dc14abd4d3 BFNS: Trim whitespace from hosts.txt when importing
DataStructureImpl: Throw unique exception on bad base 64
2014-07-05 21:58:48 +00:00
zzz
dd782f08f7 hosts.txt: Remove trailing whitespace causing test failure 2014-07-05 21:44:23 +00:00
zzz
d57dc9a8a2 * Reseed: Check su3 version as date code 2014-07-05 19:15:26 +00:00
zzz
4e463d57ce * Reseed: Send If-Modified-Since in fetches
* EepGet: Fixes for adding etag or lastmod headers before fetch
2014-07-05 18:41:09 +00:00
zzz
e0c0cc8b63 Avoid publishing null IP when using forced address config 2014-07-05 17:02:44 +00:00
zzz
cc50d47376 log warning on very low MTU 2014-07-05 17:01:29 +00:00
zzz
4da7548caa * Reseed:
- Fix URLs without trailing /
   - Cleanups of su3 code
2014-07-05 13:39:51 +00:00
zzz
91a676cb36 public constructors for SKM 2014-07-05 13:37:53 +00:00
zzz
48a32fb3b8 spacing 2014-07-05 13:37:35 +00:00
zzz
845b45a57d javadoc 2014-07-05 13:36:29 +00:00
zzz
7b7a620999 * Console: Add event log viewer (ticket #1117) 2014-07-03 13:13:57 +00:00
zzz
82217d5ebc increase default refresh on graphs page 2014-07-03 13:08:24 +00:00
zzz
b95ec70d7d Console: Check wrapper version before calling WrapperManager.getProperties() 2014-07-03 13:07:41 +00:00
zzz
aa3d3670a4 * PrivateKeyFile: Check for key type mismatch 2014-07-03 13:06:21 +00:00
zzz
8198c83982 * Base64:
- Catch numerous decoding errors that were previously misdecoded (ticket #1318)
  - Improve decoding efficiency, reduce copies
  - encode(String) now uses UTF-8 encoding
  - decode() now accepts short strings without trailing '='
  - whitespace in decode will now cause an error, was previously ignored
  - Cleanups
2014-07-03 13:03:56 +00:00
75ff7987b8 re-enable reseed.pkol.de:443 (ticket #1326) as it seems to be working again 2014-07-02 22:02:27 +00:00
9c87685c02 fix date in history.txt 2014-07-02 13:57:24 +00:00
ce2bb85440 Update Java Service Wrapper to v3.5.25
- Windows: x86 and x64 versions self-compiled with VS2010 in
  Windows 7. The icon has been changed from Tanuki's default to Itoopie.
- Linux ARMv6: Compiled on a RaspberryPi using gcc 4.6.3-14+rpi1,
  Oracle Java 1.7.0+update40 and stripped
- All other binaries are from the "community edition" deltapack offered by
  Tanuki.
2014-07-02 13:54:47 +00:00
43fdff2292 postinstall: remove some redundancy, update comments 2014-07-02 13:51:17 +00:00
zzz
06525adf3d Chinese eepsite help from xkimo 2014-06-30 13:23:06 +00:00
zzz
cff4210dfd merge of 'a88d14e53014d9ab4a5d6e156e3abe2e496284c2'
and 'bcf2bb5bf040195d80e26c4bf643ba0df8386f8a'
2014-06-29 11:44:37 +00:00
zzz
d855c5de50 * NetDB: Add more su3 checks
* SU3File: Improve CLI help
2014-06-29 11:43:57 +00:00
f1a738340f checkcerts.sh: remove unnecessary echos 2014-06-29 11:37:24 +00:00
9827c48527 checkremotecerts.sh: support for ports 2014-06-29 11:27:57 +00:00
367d68e552 Adding three reseed hosts, all with reseed-v2 support
* uk.reseed.i2p2.no
* us.reseed.i2p2.no
* jp.reseed.i2p2.no
2014-06-29 02:15:26 +00:00
1498ed361e Added my reseed key 2014-06-29 02:13:02 +00:00
zzz
91bc16ce05 * NetDB: Fix handling reseed URLs with ports (ticket #1278)
by fixing the dup host check
2014-06-29 00:44:31 +00:00
861a1e26d7 merge of '2542a527f53e4df3896ae26f5b0cf7d0a45128ff'
and '4944f31a9bec7dcacd3a97f6e451fd4eaf5f4096'
2014-06-28 21:58:50 +00:00
a5b2f9a5e9 temporarily disable reseed.pkol.de:443 (ticket #1326) 2014-06-28 21:55:24 +00:00
9550484037 checkremotecerts.sh: fix regex so that commented out hosts are not matched
(//" was needed and  // " would pass through)
2014-06-28 21:51:09 +00:00
b33284bb8e added echelon su3 reseed cert 2014-06-28 20:01:03 +00:00
zzz
ce2694e8fb * NetDB: Add support for reseeding with su3 files (ticket #934) 2014-06-28 19:37:59 +00:00
44073732e2 build.xml: copy built binaries to build/ in the build* targets
This will hopefully make it easier for apps to use bits of I2P as build-deps.
2014-06-28 16:51:38 +00:00
zzz
fef591412e SAM: Cherrypick from patch in ticket #1318:
- Add SIGNATURE_TYPE support to GENERATE and CREATE
   - Don't NPE checking dest+privkeys
   - Simplify HELLO checking
   - Don't require two params in HELLO message
   - Make MIN parameter optional too
   - Version checking fixes
   - Bump version to 3.1, only visible if requested
   - Cleanups, javadocs
2014-06-28 14:14:39 +00:00
f191e50b14 Custom target so I2P-Bote can be built against source 2014-06-28 05:57:34 +00:00
zzz
3379432e5f SAM: Cherrypick from patch in ticket #1318:
- Check for extra bytes in private key string
   - checkPrivateDestination() returns boolean instead of throws
2014-06-27 21:05:54 +00:00
zzz
bb9129b61b SAM: Cherrypick from patch in ticket #1318:
- Fix empty properties check
   - Overrides
   - Statics
2014-06-27 20:53:01 +00:00
zzz
0fc3029aaa SAM:
Version handling (ticket #1318)
   - MAX param now optional
   - 1-digit versions now accepted for MIN and MAX
   - Use VersionComparator for version tests
   - Don't require a minor version of 0
   - Fix empty properties check
   - Overrides
   - Prep for version 3.1
  Throw exception on null option key (ticket #1325)
2014-06-27 20:36:34 +00:00
zzz
d8c8586ccf SAM: No synch needed for finals;
Move fields to top
2014-06-27 16:53:05 +00:00
zzz
38a4728283 SAM: Use SAMHandler.writeString() where possible,
Use DataHelper.getASCII() for byte conversion
2014-06-27 16:46:57 +00:00
zzz
7888705b01 final 2014-06-27 16:31:24 +00:00
zzz
31938f49d6 SAM: Fix checkPrivateDestination() for key certs (ticket #1318) 2014-06-27 16:19:07 +00:00
zzz
c95ed2ea96 SAM: Rename exceptions, make serialVersionUID private,
add new SAMException constructor
2014-06-27 16:15:22 +00:00
zzz
b5ed247a53 SAM: more Log conditionals, javadocs 2014-06-27 15:55:12 +00:00
zzz
22aff49747 SAM: Log conditionals, javadocs 2014-06-27 15:53:16 +00:00
zzz
e4430f05e4 2 more pkg private 2014-06-27 15:32:56 +00:00
zzz
1047691c64 SAM: Make all classes package private except the SAMBridge entry point 2014-06-27 15:26:44 +00:00
zzz
f3180b3f6f SAM client logging cleanup 2014-06-27 15:14:21 +00:00
zzz
616866cc9e Build: Move remaining jars to Java 6, as we will require
API 9 in the next Android release.
2014-06-27 13:57:43 +00:00
58512b8230 build.xml: add new macros for use in the release target
Also move away from using external binaries when an ant task can do the job.
2014-06-26 20:01:07 +00:00
zzz
ca4555c496 lint redundant cast all over 2014-06-26 15:26:58 +00:00
zzz
bc99bc7206 javadoc fixes 2014-06-26 12:51:33 +00:00
zzz
1420c773a6 * Streaming; Drop the preliminary channel implementations,
as added by 'dream' in late 2011. Testing couldn't have happened,
   as they don't work and can't ever work as designed.
   Channels must have underlying file descriptors unless you implement
   your own Selector and that would probably require JNI.
   See http://zzz.i2p/topics/1229 for details.
   Also http://stackoverflow.com/questions/911780/how-do-i-define-my-own-selectablechannel
2014-06-24 12:49:18 +00:00
zzz
690b40ed77 * Tunnels: Reject participating tunnels when hidden (ticket #1314) 2014-06-23 20:23:32 +00:00
zzz
986de4c1d6 Streaming: Fix connection error message 2014-06-23 20:12:12 +00:00
zzz
01da32364f Streaming: Bundle I2PSocketException messages for translation 2014-06-23 20:10:11 +00:00
zzz
8b1abc08db Add Destination.toBase32() 2014-06-23 20:06:03 +00:00
69e56f8f6b 'Home': (temporarily?) disable salt.i2p.
At this point it's been offline for a month with no sign of returning.
2014-06-23 08:19:30 +00:00
b611d0238a build.xml: minor tweaks to comments, indentation 2014-06-22 00:45:50 +00:00
zzz
2dcc9b7a1e i2psnark:
- Display webapp name in html title (ticket #1311)
  - Use tracker from magnet link in display (ticket #1313)
  - Clarify auto-start (ticket #1293)
  - Include tracker in magnet link on details page (ticket #964)
  - Recognize .azw4 extension as ebook
  - Cleanups
2014-06-21 02:30:25 +00:00
zzz
3e54b5d544 New Spanish eepsite help page from 'lati2p' 2014-06-19 01:13:17 +00:00
zzz
8845ce6e1c Findbugs all over:
- Serializable
 - hashCode()
 - Make DataStructureImpl Serializable (removed from DataStructure in 2005)
2014-06-15 16:14:13 +00:00
ff189e796c slackbuild: minor changes to the comments 2014-06-14 09:15:55 +00:00
89c07ac969 slackbuild: remove gettext as a run-time requirement as it's not *strictly* req'd 2014-06-14 09:15:14 +00:00
a8e878f894 SlackBuild: version extraction using awk (thanks 'ihavei2p') (ticket #1310) 2014-06-14 00:08:49 +00:00
1f8f3eb4d9 Fix up the included SlackBuild (ticket #1310) 2014-06-13 22:44:42 +00:00
zzz
8fd2a05bf9 duh 2014-06-13 22:12:38 +00:00
zzz
002d057c92 findbugs all over 2014-06-13 21:37:18 +00:00
ab44488e4c i2prouter: don't use uname -p to determine the arch
- This came from the script from Tanuki but it does return useful information
  (as far as its use in the script) in my testing. uname -m is better for our
  needs. (The problem is only seen on certain CPUs when *all* available wrapper
  binaries are present and the script tries to resolve the correct binary to use..
2014-06-13 20:55:36 +00:00
653ffbc82e build.xml: add jbigi-linux-x86-only target 2014-06-13 20:28:02 +00:00
zzz
95fd0291e3 * Tunnels: Don't get stuck only building tunnels for an empty pool (ticket #1300) 2014-06-13 13:40:52 +00:00
zzz
2a269ff1a9 * Transports: Disallow Carrier Grade NAT (RFC 6598) addresses 2014-06-13 13:39:15 +00:00
zzz
83ccfb4596 * i2psnark: Fix NPE when fetching invalid torrent (ticket #1307) 2014-06-13 13:38:30 +00:00
e968828916 i2prouter: add amdfx* as an x64 CPU / move ldd check 2014-06-12 00:41:14 +00:00
ed85a2b82b Executables get 755, not 744
While this may be the primary cause of the problem mentioned in ticket #1310,
plenty of other fixes/changes will be forthcoming.
2014-06-11 19:27:54 +00:00
e692e21dc9 updates to SlackBuild READMEs 2014-06-11 19:24:58 +00:00
zzz
662fe3ebc2 * i2psnark: Fix decoding of negative numbers (ticket #1307) 2014-06-10 19:54:05 +00:00
zzz
1bf8fd92e4 * NewsFetcher: Only treat correct status codes as success
The last-modified date was getting updated even when
   the server returned e.g. 503, preventing routers from
   getting the latest file on a subsequent fetch.
2014-06-10 19:52:55 +00:00
zzz
4dd8a6421a Tomcat: Bundle a stripped tomcat-coyote.jar with the utils
required to precompile jsps with tags (SusiDNS and Bote).
As of 6.0.39, these utils are required but they are not bundled
in the Tomcat deployer package, the main package is required.
This checkin has only the classes required from the jar.
2014-06-10 00:17:19 +00:00
zzz
884b285bf5 * Jetty 8.1.15.v20140411
* Tomcat 6.0.41
2014-06-09 20:39:49 +00:00
zzz
cb340152df * i2psnark:
- Linkify all announce URLs on details page
   - Sanitize announce URLs
2014-06-09 14:14:01 +00:00
zzz
299a44e7eb i2psnark: display peer version when available 2014-06-07 17:07:44 +00:00
zzz
40e5bcbdbb * NetDB: Reduce negative lookup cache time
* OCMOSJ:
   - Increase timeout if we must lookup leaseset
 * Streaming:
   - Shorter expire time in TCBCache
   - Don't fail a connection once it is up
   - Log tweaks
2014-06-07 13:23:38 +00:00
zzz
d328e78727 * SusiMail: Extend times on background checker (still disabled by default) 2014-06-07 13:17:40 +00:00
zzz
1bcb9b24b6 * Console: Fix NPE in summary bar 2014-06-07 13:16:19 +00:00
zzz
3c1c130bf0 * i2psnark: Fix errors when checking read-only files 2014-06-07 13:15:13 +00:00
zzz
df3442563c * Eepsite: Updated French help page (thx hummingbird) 2014-06-07 13:13:33 +00:00
zzz
331b1fa742 fix test breakage 2014-06-01 18:04:04 +00:00
zzz
b97a53177e * i2psnark:
- Store seed/leech status in DHT tracker (ticket #1280)
   - Increase max received DHT nodes (Vuze sends more than K)
   - Recognize not-registered message from diftracker
   - Fix bug in DHT unannounce()
2014-06-01 17:13:00 +00:00
zzz
633b71ba19 history for prop, -2 2014-05-31 16:58:05 +00:00
zzz
f3dd42143d cleanups 2014-05-29 12:44:27 +00:00
zzz
7c79f5d5e5 propagate from branch 'i2p.i2p.zzz.test2' (head 9aee013cf961ba795a6b5333481634c52d43abc5)
to branch 'i2p.i2p' (head e439e67c49695a624fabdf6f3cd1a8f7a3fd7ea5)
2014-05-29 12:31:49 +00:00
zzz
af5c0bd8a7 Console, i2psnark, susimail: Recognize emacs-w3m as a text-mode browser
As reported at http://zzz.i2p/topics/1630
untested
2014-05-28 21:25:35 +00:00
c07bfe34ab s/www\.i2p2\.i2p/i2p-projekt.i2p/g 2014-05-27 12:55:53 +00:00
49681415e2 Change "view source" link from Trac to Github. 2014-05-27 12:54:46 +00:00
190e8c01b7 update irc servers mentioned in the router console
- remove freshcoffee, add dg and echelon
2014-05-27 12:48:01 +00:00
zzz
6ae86f7d81 * i2psnark: Support ports in announce URLs, 2nd try (ticket #1283) 2014-05-27 12:06:59 +00:00
0aeb3ca75e s/i2plugins/plugins/ since i2plugins hasn't existed for years 2014-05-26 14:28:41 +00:00
1d3e12abb7 router console: fix links to i2p project pages
Some pages, such as Arabic linked to the German version.
Most pages mentioned "i2p-projekt and its mirror i2p-projekt.i2p"
2014-05-26 14:27:55 +00:00
5e8428ef6c router console: s;forum\.i2p2\.de;forum.i2p;g 2014-05-26 14:18:59 +00:00
19e3064529 remove #i2p-help from the router console (merged into #i2p) 2014-05-26 14:10:47 +00:00
f9dbd74ad8 update links to syndie to point to its eepsite 2014-05-26 13:59:22 +00:00
zzz
ff837cf66e i2ptunnel: Define standard tunnel properties and types in one place 2014-05-26 13:36:41 +00:00
zzz
e0914c358e susimail: fix NPE (ticket #1296) 2014-05-25 23:17:19 +00:00
zzz
0e9bb23c7b i2psnark:
- Respond to get_peers with an empty peers list instead of
    a nodes list if the requester was the only peer (ticket #1279)
  - Fix sendError() (still unused)
2014-05-25 21:41:43 +00:00
zzz
7ff5d36f07 i2psnark DHT tweaks (ticket #1281)
- Extend DHT tracker expire time from 45m to 3h
  - Extend DHT announce interval from 10m to 40m
  - Increase announces from 1 peer to 4
2014-05-25 20:38:39 +00:00
zzz
5a3eab0c7c i2psnark:
- Change "private" value in infohash from string to number,
    to match what everybody else does
  - Send seed/leech status in DHT announces (ticket #1280)
2014-05-25 19:41:01 +00:00
zzz
c28f707f55 cleanup 2014-05-25 19:23:04 +00:00
zzz
ef96c88719 HTTP Client:
- Add GUI options for user-agent, referer, accept
  - Fix SSL (initial socket data in I2PTunnelRunner)
  - Disable SSL to i2p addresses by default, add GUI option
  - Fix NPE in error handler
2014-05-25 19:17:36 +00:00
faa2435e33 checkremotecerts: fail if CN doesn't match
Since all reseed hosts now have proper certificates with matching CNs, I'm
making this script enforce a stricter policy, requiring matching CNs.
2014-05-24 13:13:35 +00:00
0537a221d3 temporarily disabling uk.reseed.i2p2.no 2014-05-24 10:08:58 +00:00
99c5a1978f merge of 'be06d7987687efb0d6b027f04a2efbf702218677'
and 'f6541fdc88966f2e0e510c2291b33cf716a3a62a'
2014-05-22 18:09:55 +00:00
zzz
d106f483a1 0.9.13 2014-05-22 14:59:02 +00:00
dee84e70ae Eclipse project for entire routerconsole dir 2014-05-22 01:51:05 +00:00
09995b77b4 Eclipse project for entire installer dir 2014-05-21 02:02:36 +00:00
06894f9f0b Export jstl.jar and standard.jar in Eclipse 2014-05-20 21:34:45 +00:00
zzz
73943b1a08 javadocs 2014-05-20 13:23:31 +00:00
zzz
b573dab05f javadocs 2014-05-20 13:22:07 +00:00
zzz
a766eca283 Crypto: Don't start YK thread in constructor (ticket #973) 2014-05-20 13:14:55 +00:00
zzz
a65edbef92 SSU: Fix peer test deadlock (ticket #1286) 2014-05-20 12:35:48 +00:00
zzz
7479aa235e fixes after review 2014-05-20 12:03:19 +00:00
zzz
4167cd955b Console: Cheap workaround for old wrappers (ticket #1285) 2014-05-18 23:24:03 +00:00
zzz
d1bd893a7b * I2PTunnel:
- Display custom error pages for I2PSocketExceptions (ticket #788)
   - Tag I2PSocketException text for translation (no bundles yet)
   - Move methods from superclasses to I2PTunnelHTTPClientBase
   - Fix connect client error pages, but they aren't displayed anyway
   - Don't start I2PTunnelRunner threads in constructor (ticket #973)
   - Synch close() in I2PTunnelServer
   - Cleanups and javadocs
2014-05-18 21:13:22 +00:00
zzz
2467856011 * Streaming: Cleanup, don't fail hard on no tunnels (ticket #788) 2014-05-18 00:44:51 +00:00
zzz
d32b4e9f24 * I2CP: Per-message status codes back through streaming (ticket #788)
- New I2PSessionException
   - Streaming PacketQueue requests status for SYNs on outbound conns
   - PacketQueue throws I2PSessionException in streams
2014-05-18 00:05:13 +00:00
zzz
1acd5caaa8 * HTTP client: Fix 'connection reset' browser messages
after an error in the first line (ticket #1277)
   - A SocketException is an IOE
   - out can't be null
2014-05-17 23:44:16 +00:00
zzz
f69b757305 * i2psnark: Support ports in announce URLs (ticket #1283) 2014-05-17 22:10:10 +00:00
d2db41bc89 remove cert from delete list 2014-05-16 14:04:45 +00:00
f3b4377ee1 re-add netdb.i2p2.no.crt 2014-05-16 13:58:51 +00:00
551a8091a9 GeoIP db updates; Japanese Susimail translation, -21-rc 2014-05-15 23:22:40 +00:00
f994590ad7 Translation updates
sk, ja, de, fr, it zh, nl, uk, nb
2014-05-15 23:14:38 +00:00
zzz
8371b8f806 * I2CP: Client-side prep for asynch status for sent messages (ticket #788)
- Clean up and reuse MessageState for asynch notification
   - New I2PSession sendMessage() method and listener
   - Move VerifyUsage from SimpleScheduler to SimpleTimer2 for efficiency
   - Fix up javadocs
2014-05-15 20:11:21 +00:00
5d04f8db89 checkremotecerts.sh fix test logic
Script would return 0 even connecting to the remote host failed.
2014-05-15 03:38:29 +00:00
06de347373 -20-rc 2014-05-14 14:18:24 +00:00
2bf2eb482e update outbound UA to match TBB's 2014-05-14 14:14:23 +00:00
zzz
a93666cd36 * I2CP: Prep for per-message reliability settings (ticket #788)
Router side:
     Store message nonce in ClientMessage, so we may send
     a MessageStatusMessage with a failure code to the client
     without sending an ACCEPTED MessageStatusMessage first.
     All MessageStatusMessages sent in response to outbound messages will now have a valid nonce.
2014-05-14 13:49:42 +00:00
zzz
dbb7eb3d88 * I2CP: Prep for per-message reliability settings (ticket #788)
Add bounds checks for flags
2014-05-14 12:15:57 +00:00
zzz
39169f0450 reveal key cert settings in i2ptunnel 2014-05-14 12:13:43 +00:00
zzz
df71308664 Susimail: Don't let an exception on one mail break others 2014-05-13 21:36:06 +00:00
zzz
e393f82eb7 * i2psnark: Escaping fixes on details page 2014-05-13 21:35:12 +00:00
zzz
8480a204ea * BOB, SAM, i2psnark: Fix datagram NPE (ticket #1275)
This could only happen on an extremely overloaded router.
2014-05-13 18:45:54 +00:00
zzz
197be5f60f * SusiMail: AIOOBE fix 3nd try (ticket #1269) 2014-05-13 18:39:56 +00:00
zzz
5621e9b390 * SusiMail: AIOOBE fix 2nd try (ticket #1269) 2014-05-12 20:46:30 +00:00
485d785e0b merge of 'dcf98ef995380862d3e668685caaa0acd403f068'
and 'f9fdb1592f632ef5de78e3dc7dac3f75ce4e3c39'
2014-05-10 15:38:20 +00:00
8d71d496be new self signed certificate which fits to the host name reseed.i2p.projekt.de 2014-05-10 15:21:54 +00:00
zzz
738bae46d2 * SusiMail:
- Remove deleted messages from memory too
   - Disable delete button when really-delete button shown
2014-05-10 14:47:46 +00:00
zzz
d519228efb change exception type 2014-05-10 14:44:09 +00:00
zzz
72c404c4d4 * NTCP: Fix NPE (ticket #996)
(hopefully)
2014-05-10 14:42:13 +00:00
zzz
d2e3547a2e * Crypto: JVM AES only faster for larger data size 2014-05-09 19:13:28 +00:00
zzz
8d9790fd77 * CPUID:
- Add hasAES()
   - Fix bugs in unused hasSSE3(), hasSSE41(), hasSSE42()
 * Crypto: Use JVM AES when faster
 * SystemVersion: Add isJava7() and isX86()
2014-05-09 15:28:54 +00:00
zzz
cd91a6b2a4 * SusiMail: Add more locking (ticket #1269) 2014-05-09 12:15:12 +00:00
zzz
e165c1805d unnecessary cast 2014-05-09 12:14:19 +00:00
292b0a81c0 remove debugging cruft 2014-05-09 10:33:01 +00:00
b9e9c07d95 checkremotecerts.sh: clean-ups, compatibility updates
It now works with either gnutls or openssl, and both gnutls v2 and gnutls v3.
2014-05-09 10:21:15 +00:00
837bf9eafe add i2pdocs.str4d.i2p to hosts.txt
It's linked on the website but wasn't in any of the default lists.
2014-05-09 10:11:22 +00:00
zzz
cfdbef05c5 set GPG key ID in release target 2014-05-08 19:23:15 +00:00
47b10e9771 checkremotecerts.sh: explicit check that cert exists 2014-05-08 17:56:37 +00:00
1b5a2ddef3 updated cert for ieb9oopo per email in ticket #1266 2014-05-08 17:55:41 +00:00
c161649ed5 Add script to check reseeder host certificate validity 2014-05-08 13:31:32 +00:00
c9b5c03e1b remove certs that are no longer used 2014-05-08 12:47:46 +00:00
c4c04d7ec5 rename i2pproject cert
The other self-signed certs are named after the host that they're being used
for. Maintaining this naming scheme will make automated testing easier.
2014-05-08 12:46:44 +00:00
b4e03fa969 Removing netdb.i2p2.* certs
These have not been used for some time. netdb.i2p2.no is using an *.i2p2.de
cert from Commodo.
2014-05-08 12:45:31 +00:00
zzz
1cdcf1cb0a i2ptunnel: Display warning for duplicate client ports (ticket #1265) 2014-05-07 16:00:38 +00:00
zzz
56b6992ca8 i2psnark: Add log message if directory does not exist (ticket #1263) 2014-05-07 15:58:24 +00:00
zzz
2beaea4a86 Tunnels: Revert expl. OB default back to 2 + 0-1 for now 2014-05-07 14:50:45 +00:00
zzz
2dc97b160a i2psnark: Allow click on entire table cell for viewing torrent details 2014-05-07 14:48:42 +00:00
zzz
a014918c0d Transports: Use constant time method for HMAC verification 2014-05-07 14:47:15 +00:00
zzz
fb9a4eb87a SSU: Extend establishment phase retx timeout 2014-05-07 14:43:46 +00:00
zzz
cd83c48526 DSAEngine: Minor cleanup 2014-05-07 14:41:28 +00:00
zzz
5b2766ddfb Data: Use Arrays.equals() directly, same as DataHelper.eq() 2014-05-07 14:40:03 +00:00
zzz
f912b01137 Fix console getting disabled when saving client config (ticket #1260)
Router: Add warning at startup if console is disabled
2014-05-07 14:36:41 +00:00
zzz
b0db4e4fff * SusiMail:
- Don't fetch headers from folder sorters
   - Update debug setting when saving config
2014-05-07 14:34:51 +00:00
zzz
649f76fb06 add hiddengate.i2p 2014-05-07 14:33:20 +00:00
zzz
67ea2f3717 SusiMail: Remove dups in war 2014-05-01 17:05:57 +00:00
zzz
e9e535cb94 * SusiMail:
- Move js to resources
   - js for delete boxes in folder view
2014-05-01 14:34:02 +00:00
zzz
7822b5c3ac SusiMail: header padding 2014-05-01 13:13:20 +00:00
zzz
767bd05ce1 SusiMail: new sorter base class 2014-05-01 13:02:44 +00:00
zzz
36ebe19cd7 SusiMail po update for TX 2014-05-01 12:04:10 +00:00
zzz
943ea957a2 * Plugins: Retry deletion at restart if it fails (ticket #1257) 2014-04-30 14:22:25 +00:00
zzz
04a3673366 remove UTF8 in commented-out test 2014-04-30 11:28:13 +00:00
zzz
1dfbe73b73 * SusiMail:
- Add print css
   - Add some divs
   - Hide header and footer in mobile css
   - Fix 'from' address in compose
   - Boolean config parse cleanup
   - Config textarea row count
2014-04-29 19:50:28 +00:00
zzz
87889bb322 * UDP:
- Locking fixes on peer testing
   - More locking fixes on rebuilding address
   - Slow down peer test frequency, esp. when firewalled
* Transports:
   - Deprecate unused recheckReachability()
2014-04-27 18:46:11 +00:00
zzz
aa0616d7c5 * UDP:
- Locking fixes on rebuilding address
   - Don't rapidly churn address when we don't have enough introducers
2014-04-27 15:47:43 +00:00
zzz
611ff6357e * NTCP: Remove published NTCP address if SSU becomes firewalled,
to fix the "Firewalled with NTCP enabled" message
2014-04-27 15:01:01 +00:00
zzz
91d7a0ab98 * SusiMail:
- Add locking for disk cache
   - Remove cancel button from login page
   - New configuration page
   - Move set page form to configuration page
   - Theme and folder js enhancements
   - Wrench icon from Silk, same license as the others
2014-04-27 14:57:28 +00:00
zzz
f5661da595 * Router: Set killVMOnEnd before runRouter() (for azi2phelper)
* RoutingKeyGenerator: Don't assume UTC (for azi2phelper)
2014-04-27 14:53:15 +00:00
zzz
3f56ce206d * SusiMail:
- Subject sort enhancements
   - Tag Re: and Fwd:
2014-04-25 20:05:23 +00:00
zzz
8a2308b411 * SusiMail:
- Send delete to server for mails already downloaded
   - Fix idle closer waiting for deletions
   - Add tooltips for icons
   - Add new options to properties resource
   - Add feedback when reload config button pushed (ticket #1158)
   - Reset page size when config reloaded
   - Remove max page size limit
   - Show page nav buttons on bottom too if page is big
   - Set title to subject on message view
   - Log tweaks
2014-04-25 18:47:47 +00:00
zzz
04cabf40b5 * SusiMail:
- Move delete and confirmation button in folder view to bottom left,
     page size form to bottom right
   - Attachment finals and cleanup
   - Increase max size for full download again
   - Fix repeated re-saves of mail to disk
   - Enable auto-deletion of downloaded mails
   - Consolidate check box processing
   - Button spacing tweaks
2014-04-25 16:11:35 +00:00
zzz
4e0c4f6f98 * SusiMail:
- Tweak sort button display based on current sort
   - Secondary sort based on date
   - Ignore "Re:" in subject sort
2014-04-25 14:09:28 +00:00
zzz
75bd235eb2 * SusiMail:
- Add raw attachment download method
   - Display image attachments inline
   - Don't rezip certain attachment types, just offer link
   - Handle attachment sending directly, don't put ref in session
2014-04-25 13:04:04 +00:00
zzz
05236b093a * SusiMail:
- Fix sorting buttons, broken by POST check
2014-04-25 04:15:50 +00:00
zzz
260ebe512c * SusiMail:
- Add icon for new mail
     (from Silk icons, same license as others)
   - Attachment logic tweak
2014-04-25 04:09:14 +00:00
zzz
c2dab16c8c * SusiMail:
- Add icons for attachments and spam
     (from Silk icons, same license as others)
   - Add checks for POST for XSS prevention
2014-04-25 03:42:18 +00:00
zzz
945d455f33 * SusiMail:
- Different colors for new mail and spam
2014-04-24 21:33:43 +00:00
zzz
c8f8f6ff34 * SusiMail:
- Add background mail checker, not yet enabled
   - Add idle timeout connection closer
   - Rely on idle checker for most delayed deletions
   - Cleanup resources better when shutting down session
   - Don't add deleted mails to folder, caused errors after deletions
   - Set socket soTimeouts so things don't hang forever
   - Display errors after check mail button pushed
   - More IOE debug logging
2014-04-24 20:54:22 +00:00
zzz
0d4f597a59 SusiDNS: Fix subscription edit page, thx bubbles 2014-04-24 14:26:21 +00:00
zzz
775047fbc2 * SusiMail:
- Fix HeaderLine decoder going past the headers,
     which was causing corruption in forwarded mails
   - More efficient output buffer allocation in HeaderLine decoder
2014-04-24 01:25:50 +00:00
zzz
1e4b43314c * SusiMail:
- Fix fetching of new mail
   - More Folder cleanup
   - Prep for not leaving on server
   - Prep for background checker
2014-04-23 22:46:57 +00:00
zzz
b365817c99 * SusiMail:
- Queue deletions for a delayed background thread
   - Synch all folder access
   - NPE fixes
   - Javadoc fixes
2014-04-23 19:40:57 +00:00
zzz
bbb04774d1 compile fix 2014-04-22 20:52:08 +00:00
zzz
1823e5e641 * SusiMail:
- Load all mails from disk at startup
   - Add offline mode
   - MailCache now has the total UIDL view
   - Copy silk folder icon from snark to console for use by susimail
2014-04-22 20:01:24 +00:00
zzz
4d2dc1c8e8 * SusiMail:
- Show sender name in folder view
   - Add support for configured sender name
   - Add HTML escaping of '&'
   - Fix Folder sorting so UP is up and DOWN is down
   - Use replace() instead of replaceAll() where appropriate
   - Fix capture by show page after back button
2014-04-22 18:45:09 +00:00
zzz
6986f90bf8 * SusiMail:
- Fix encoding in sent mails on non-UTF8 platforms (thx cryptosynthesis)
   - Clean up all other getBytes() calls
   - Tweak spacing on up buttons
2014-04-22 11:48:45 +00:00
zzz
b43ebd2486 * SusiMail:
- Add persistent cache
   - Remove ID sorter
   - Mail size getter/setter
   - Set mail size when setting body
   - Only send CAPA once
   - Tagged string tweaks
2014-04-22 11:18:56 +00:00
zzz
7bf3ea5200 * SusiMail:
- Pipeline all deletes and quit
   - Don't reconnect after delete and quit
   - Verify connected before each POP3 operation
   - Null check in comparators
   - Don't clear messages if a reconnection fails
   - Use locale-based sorting for strings
   - Increase limit for full fetch again
   - Increase default page size back again
2014-04-21 23:00:46 +00:00
490727b401 fix i2ptunnel 2014-04-21 20:59:29 +00:00
zzz
49f4f3398d * SusiMail:
- Add MailPart constructor, make fields final
   - Add ReadBuffer constructor, make fields final
   - Move decoding to MailPart method
   - Setters/getters for Mail header, body, part
   - Classes package private
   - Finals, constructors
2014-04-21 20:17:08 +00:00
b84682fdc9 * findbugs: mostly stream closure fixes in router, apps, core 2014-04-21 10:54:52 +00:00
zzz
b9491b269b * SusiMail:
- Pipeline initial fetch of messages, huge speedup
2014-04-20 22:22:22 +00:00
zzz
b70cbb28b2 * SusiMail:
- Send CAPA
   - Pipeline STAT, UIDL, and LIST
2014-04-20 19:31:28 +00:00
zzz
673c14287a * SusiMail:
- Rework in POP3 in prep for more pipelining
2014-04-20 18:38:54 +00:00
zzz
b4a0ffdbbd * SusiMail:
- Don't require an attachment to be "uploaded" to send it
   - Move delete attachment button, hide if no attachments
   - Icon for delete attachment button
   - Fix html error in bccToSelf input
2014-04-20 17:12:21 +00:00
zzz
3b2e5bded2 * SusiMail:
- Don't store encoding class names in config
   - New susimail.debug setting in config
   - Use DataHelper to load config file
   - Close any open POP3 socket when session is unbound
   - Don't keep returning user to compose page (ticket #1252)
   - Add javascript capture of back button from compose page
2014-04-20 15:19:30 +00:00
67eb3cc140 unblocking USERS (ticket #1249) and various safe Inspircd commands 2014-04-20 11:53:39 +00:00
zzz
5a683149ab * SusiMail:
- New reply button icon (from Silk, same license as the others)
   - Save BCC-to-self preference in the session
   - Tweak the BCC-to-self layout
   - Fix date format in reply
2014-04-20 02:45:01 +00:00
zzz
b75ad1ca5a * SusiMail:
- Use pipelining in SMTP
   - Rewrite SMTP response processing
   - Translate SMTP error messages
   - Right-justify msg size in folder view
   - String.compareTo() cleanup
2014-04-20 01:26:11 +00:00
zzz
552ab31559 Console: Remove the classpath workarounds for SusiMail,
since it isn't using the jetty classes any more
2014-04-19 20:46:31 +00:00
zzz
4abfde4047 SusiMail:
- CSS padding in inputs
   - Flush writes in SMTP
   - Don't wait for SMTP response after QUIT
   - Translate the "login failed" message
   - Show "no messages" in folder view if none
   - Message view attachment cleanups
   - Fix the message view layout in CSS
   - Pipeline USER and PASS to save a round-trip at startup
   - Better synchronization in POP3
   - Properly de-byte-stuff in POP3
   - Flush writes in POP3 for speedup
   - Remove unnecessary caching in POP3, this is handled in MailCache
   - More efficient handling of POP3 server responses
   - Remove 60s timeout for fetching a message,
     so retrieval of large messages doesn't fail
   - Don't allow line breaks in date/time or size in folder view
   - Use DataHelper.formatSize2() for message size
   - Identify susimail log messages in wrapper
   - Debug log tweaks
2014-04-19 20:44:50 +00:00
zzz
6ecfedba37 SusiMail:
- Increase max size of mails that are fetched in full,
     previous limit was so small it never happened.
   - Move page nav to top of folder view, hide if only one page
   - Put message nav buttons on second line
   - Refuse to send mail with no "to"
   - Reduce default page size as it slows startup
   - Remove unnecessary casts
   - Right justify some input fields
2014-04-19 16:57:56 +00:00
zzz
43883a90d2 SusiMail: Successfully extend session expiration (ticket #1253)
by renaming the cookie, so we don't have a common session ID
with the base context and get it expired there.
2014-04-18 21:32:45 +00:00
zzz
3930113f00 I2PTunnel IRC Client: Prevent AIOOBE (ticket #1254) 2014-04-18 16:44:39 +00:00
zzz
029198c213 * SusiMail:
- Don't force reconnection on folder view (ticket #1253)
   - Only show logout button on folder view
   - Switch subject and date headers on message view
   - Button theme tweaks
   - Debug logging
   - Fix NPE when RELEASE=false
   - Synch tweaks
   - hellip
   - Footer tweak
2014-04-18 16:43:07 +00:00
zzz
493788f4f8 merge of '9f159df098940fb0feecf6eae0c990c62736bb9c'
and 'ba82e9e4c57bd8d9f567c9252fe7b5815972e370'
2014-04-18 01:50:14 +00:00
zzz
028776de88 * SusiMail:
- Extend session expiration (ticket #1253)
   - Handle non-UTF8 encoding on header lines (ticket #508)
   - Display dates in current locale and time zone
   - Display sender name on message view
   - Remove sort-by-ID buttons
   - Hide "reload config" button unless config file is present
   - Increase default page size
   - Add dependency tracking to build
2014-04-18 01:48:03 +00:00
705de68aa3 allow PROTOCTL and LINKS through the filter.
http://www.unrealircd.com/files/docs/technical/protoctl.txt

We already allow /MAP and /LINKS is pretty much the same.
2014-04-18 01:46:19 +00:00
zzz
eb96a74e32 configclients: Don't allow console disable 2014-04-18 01:14:23 +00:00
zzz
614f34c6b4 Stats: clean up addRateData() calls 2014-04-17 18:58:38 +00:00
zzz
f77a3c7f56 NTCP: Log tweaks to help on ticket #996 2014-04-17 18:54:58 +00:00
zzz
6de81d41d2 SSU: SessionRequest replay prevention (ticket #1212)
NTCP: Just use first 8 bytes of Hx^Hi for replay check
2014-04-17 18:52:40 +00:00
zzz
7ac9dc5542 Tunnels: Increase OBEP throttle limit for now 2014-04-17 18:50:24 +00:00
zzz
2195c2fe98 SusiMail: Button styling for prev,next,list 2014-04-17 18:48:52 +00:00
zzz
3f35e927dd SusiMail:
- Initializer cleanup, finals
   - Escape "--" inside HTML comments
   - Log errors to router log too
   - Notes on ticket #508 header line issues
2014-04-17 18:48:07 +00:00
zzz
5ec659513b SusiDNS:
- Move some methods to BaseBean
   - Locking on config file accesses
   - Remove static log and context
2014-04-17 18:39:52 +00:00
zzz
1039a4b7a0 i2psnark: Randomize announce list order and limit size 2014-04-17 18:36:37 +00:00
zzz
88899c1233 clean up unused router stuff 2014-04-06 18:28:34 +00:00
d429514a3a debian: remove dep on ${misc:Depends}
This causes the 'i2p' package to force the version of i2p-router to match.
2014-04-06 16:04:17 +00:00
zzz
b2c6fcbb73 merge of '0c93d925b9ac38f2475b39aa2b80eaa1454214d6'
and '97ec023f8ba85ebdabe5ee0bd3f9e107710f170f'
2014-04-06 15:19:30 +00:00
zzz
3b1e030b39 NetDB: Iterative search improvements
- Pass DSRM hashes through IMD to ILJ for client tunnels too
- Query unknown DRSM hashes in ILJ without looking up
  when using client tunnels; look up after querying
  when using expl. tunnels to speed things up
- Don't look up banlisted hashes
- Check 'from' hash in DSRM against list of peers sent to
- Don't query an unknown peer through a zero-hop OB tunnel
- Log tweaks
Extend expiration of returned message in IMD
2014-04-06 15:18:16 +00:00
zzz
e097a1caeb NetDB: Skip LS verifies when shutting down
remove unneeded null check
2014-04-06 15:15:23 +00:00
d6b09f8bab don't check launch4j xml 2014-04-06 14:36:36 +00:00
zzz
6d46344171 drop launch4j demos, docs, and source 2014-04-06 14:03:43 +00:00
zzz
24e807b238 Skip key cert LS verifies for floodfills that don't support them
Fix continuation after skipping key cert LS stores for floodfills
that don't support them; ditto big leasesets
2014-04-05 14:05:40 +00:00
zzz
fdf6f5d51f -2 2014-04-05 12:59:11 +00:00
zzz
4b938a02e7 log tweak 2014-04-05 12:33:53 +00:00
zzz
44a5740a04 Add server option for unique local address per-client
as suggested in https://lists.torproject.org/pipermail/tor-dev/2014-March/006576.html
2014-04-05 12:30:58 +00:00
zzz
8d73b2e838 Fix changing outproxy without stopping tunnel (ticket #1164) 2014-04-05 12:24:50 +00:00
zzz
e1fc6893b4 SocketErrorListener callback is unimplemented 2014-04-05 12:18:14 +00:00
7487ab8848 i2ptunnel: remove extraneous '>' from editClient 2014-04-02 01:25:47 +00:00
e675416b8c debian: re-enable javadocs pkgs, bump changelog 2014-04-01 21:27:49 +00:00
24a133fe67 add .pc/ to .*ignore 2014-04-01 21:22:41 +00:00
zzz
0570feda6f * NetDB: Handle RI response from non-floodfill router down a client tunnel 2014-04-01 13:05:51 +00:00
zzz
b206665c72 TunnelPoolSettings constructor tweak 2014-04-01 13:03:40 +00:00
zzz
8a6fb132f5 * Console: Fix summary bar html when displaying an update constraint 2014-04-01 13:01:13 +00:00
zzz
6992ca8b98 build path update 2014-04-01 13:00:28 +00:00
zzz
fd916a7646 test script updates 2014-04-01 12:59:27 +00:00
zzz
90cd68900e 0.9.12 2014-03-31 12:43:15 +00:00
zzz
3f865edb4f Convert pt_BR getopt translation from ISO-8859-15 to escaped UTF-8 2014-03-31 12:36:50 +00:00
2e8681de2c getopt translations 2014-03-28 20:23:53 +00:00
zzz
2d85b98c20 * i2ptunnel.config: Remove irc.freshcoffee.i2p
* NetDbRenderer: Adjust debug floodfill estimate
 * StatManager: Don't start thread for an empty config
 * StatisticsManager: Don't publish client tunnel stats
 * Log tweaks
2014-03-28 14:01:39 +00:00
d28d6efb79 geoip updates 2014-03-28 12:21:52 +00:00
43d84a5f07 fr, nb, and ru translation updates 2014-03-28 12:21:32 +00:00
e4d57f62bb merge of '1202f5d3645add930a96dfa77cd2b2ebfb56ca95'
and '5c131297d763f8953029fea257681d55f2103aaa'
2014-03-24 11:57:46 +00:00
a974268e7b postinstall: fix freebsd x86 wrapper path
Spotted in the FreeBSD Port (http://svnweb.freebsd.org/ports/head/security/i2p/files/patch-installer__resources__postinstall.sh?view=markup)
2014-03-24 11:57:04 +00:00
zzz
1695af7011 belated jisko.i2p 2014-03-23 20:44:47 +00:00
682c4cd0b8 remove extraneous '>' from editServer 2014-03-23 18:33:29 +00:00
0f6d039391 Console: Handle stopping plugin ClientApps 2014-03-23 10:55:00 +00:00
d6233a8798 add *.torrent to .gitignore 2014-03-21 11:35:37 +00:00
4f12e81dbb build: add -pre-release target, add addt'l files to distclean
Moving the pre-release checks to a new target (to be run at the very start of
"release")
2014-03-21 11:35:04 +00:00
ab612d0088 cleanup of *clean targets, remove more generated files in distclean 2014-03-19 22:00:43 +00:00
3fa7bb9dc5 mtn-ignore: ignore .torrent 2014-03-19 21:59:27 +00:00
22b3d4d70b translation updates 2014-03-16 23:56:43 +00:00
zzz
bd6c588c74 * SSU: Fix corruption of introducer keys 2014-03-16 18:27:46 +00:00
zzz
6c202e8f1d fix router identity test broken by previous checkin 2014-03-15 19:40:41 +00:00
zzz
24e6750529 * Certificate: Fix null cert hash code
* Hash: Cleanup of cached hash
* NetDB: Randomize returned DSM timestamp
2014-03-15 18:43:42 +00:00
af7ce8e18e remove extraneous <a> tag
(fixing my mistake)
2014-03-15 13:47:53 +00:00
zzz
c73f0eeeb5 more Jetty classpath cleanup 2014-03-13 13:58:50 +00:00
zzz
c68769cf7f MultiMap: Cleanups, javadocs after review 2014-03-13 13:57:10 +00:00
zzz
3e639a319d SAM:
- Classes static/private
 - Fields private/final
 - Remove unused fields
 - Remove shadowing fields
 - Remove dup method overrides
 - Remove static Logs
 - Remove unnecessary field initialization
 - Atomics
 - Findbugs
2014-03-13 12:22:04 +00:00
zzz
1bbb79f5b1 log tweaks 2014-03-13 12:17:34 +00:00
84e6991374 Add .su3 to .mtn-ignore, create new .gitignore file 2014-03-13 11:27:37 +00:00
5d1796bb6f Debian: Remove service directory when package is purged
This was in the 0.9.11 packages but not checked into mtn.
2014-03-13 02:31:23 +00:00
bfba732f76 Debian: Add systemd support (ticket #1208)
Currently just for Debian unstable and Ubuntu Saucy and newer.
2014-03-13 02:29:41 +00:00
zzz
738c5ed14e Streaming: Workaround for jwebcache and i2phex (ticket #1231) 2014-03-12 16:02:23 +00:00
zzz
beed080390 anoncoin.i2p 2014-03-12 15:21:17 +00:00
zzz
3624d66c12 send message on HTTP Server OOM 2014-03-12 15:18:41 +00:00
zzz
2cca2781fd * Streaming: Track recently closed connections (ticket #1161)
Consolidate and synchronize code for selecting a random stream ID
2014-03-12 12:39:53 +00:00
zzz
31d485299c log tweak 2014-03-12 12:36:00 +00:00
zzz
a39f667c2f set BAOS size 2014-03-12 12:35:29 +00:00
zzz
5283fc923e * Wrapper: Fix failed restarts on ARM (ticket #1230);
extend shutdown timeouts for all archs.
2014-03-12 12:33:36 +00:00
zzz
c57552f4e9 * Console: Handle ISO-639-2 language codes (ticket #1229) 2014-03-12 12:29:38 +00:00
zzz
96b4c6b219 findbugs sam/bob 2014-03-12 12:27:23 +00:00
zzz
51911bd9a8 fix jetty deprecations 2014-03-12 12:25:30 +00:00
zzz
1f5926e4e9 * PeerManager: Restore profileOrganizer.sameCountryBonus advanced config,
inadvertently removed in 0.9.10
2014-03-08 16:03:35 +00:00
zzz
d6a02a13ad * Router:
- Look for DeliveryStatusMessages beyond the message expiration,
     so we don't throw out a tagset that gets acked late
   - Allow re-adding of a "failed" tagset to the SKM
   - Extend max message age in MessageValidator
   - Remove unused and confusing timeout param when registering a selector
   - Log tweaks, javadocs, cleanups
2014-03-07 14:17:11 +00:00
e282491798 merge of '10a291d2283174a7527515a7448d220d5023ffc0'
and '6ace0f7ffbda402db7e1af21a74ca29ad54829c2'
2014-03-07 08:35:12 +00:00
2b0dfed012 Fixed Android API version detection, load cacerts dir for API >= 14 2014-03-07 08:27:14 +00:00
zzz
9d80aff977 * GarlicClove, CloveSet, GarlicMessageParser:
- Cleanup, reduce object churn, comment out unused code
   - Limit max cloves to 32
2014-03-06 19:31:09 +00:00
zzz
a0724dc009 * Router: Encrypt DeliveryStatusMessages sent in garlics (ticket #1217) 2014-03-06 16:21:36 +00:00
zzz
8c820bb237 clean up build classpath (ticket #1165) 2014-03-06 06:03:58 +00:00
zzz
3fdc964eac javadoc fixes 2014-03-05 16:53:04 +00:00
zzz
597662d0dc * Transports: Don't send a duplicate store of our RI at
start of a connection (ticket #1187)
 * NTCP:
   - Lower send priority of the RI at exchange
   - Bob will now send his RI even if he doesn't have Alice's
   - Send RI again sooner on long-lived connections
2014-03-05 16:32:04 +00:00
17c80c29e6 Updated history.txt 2014-03-05 03:35:52 +00:00
5d0bfc63fa Updated readme.html files for new website paths 2014-03-05 03:34:53 +00:00
0c449f8b8e susimail: Removed remaining Jetty dependencies in susimail (ticket #1165)
Thanks for the patch, wockenfuss!
2014-03-05 03:02:08 +00:00
36b6baa33e Updated .mtn-ignore 2014-03-05 02:58:07 +00:00
2c049878c6 Enable addressbook.jar building (for I2P-Android) 2014-03-03 03:49:48 +00:00
zzz
81c58c1796 log tweak 2014-03-01 13:13:52 +00:00
zzz
36a3edf612 - DatabaseStoreMessage: Don't instantiate an ArrayList unless we need it
- Overrides in GarlicConfig/PGC for efficiency and clarity
 - Check for valid ID in DeliveryStatusMessage
 - Misc. log tweaks, javadocs, cleanups
2014-02-27 13:37:11 +00:00
zzz
4b6fd3d387 format tweak 2014-02-24 14:06:24 +00:00
zzz
f777696e14 finals, volatiles, cleanups 2014-02-24 14:02:48 +00:00
zzz
c9c181c14a * NetDB: Slow down router refresh after startup to reduce load
on exploratory tunnels
2014-02-24 14:01:35 +00:00
zzz
a62b7a4374 * Tunnels: Rate-limit connections at the OBEP (ticket #1134) 2014-02-24 14:00:39 +00:00
zzz
9d7a9c9895 * NTCP:
- Add check for replayed session requests (ticket #1212)
   - Disable inbound check connection
   - Reduce object churn in EstablishmentManager
   - Don't pollute Hash cache in EstablishmentManager
   - addRateData() cleanup
2014-02-24 13:54:52 +00:00
zzz
5d6a1c5e35 reduce log level 2014-02-24 13:52:44 +00:00
zzz
c48266fdc4 * Transports: Use SigUtil.rectify() in DH 2014-02-24 13:51:20 +00:00
zzz
895d54d36d minor cleanup 2014-02-24 13:46:07 +00:00
ba0e1a3aa9 * I2PTunnel: add 'irc.dg.i2p' to the default IRC2P tunnel (for more information, see http://echelon.i2p/docs/IRC2p/irc2p_userguide.txt) 2014-02-23 21:38:12 +00:00
6ec665db50 Br. Portugese, French, Japanese, Polish translation updates 2014-02-23 16:54:49 +00:00
7f4c52cf42 remove #i2p-help from initialNews 2014-02-23 16:40:28 +00:00
37728e38c9 (hopefully) langbox fixes 2014-02-22 23:58:25 +00:00
zzz
18b4a2427b * I2CP Client: Generate revocation key of same type as signing key
* i2ptunnel: Only offer Sig options that are available in the JVM
 * LeaseSet: Add check for SigTYpe mismatch
 * SigType: Add isAvailable()
2014-02-21 17:47:30 +00:00
zzz
3102970540 * RouterAddress: Restore storage of expiration and use in signature
calculation, broken in 0.9.3, in anticipation of using it someday
2014-02-21 14:57:28 +00:00
zzz
c679091afd target build property 2014-02-21 13:59:27 +00:00
zzz
91cdf85772 * Router: Allow null args to main() (broke Android) 2014-02-20 14:08:05 +00:00
zzz
aab8b10adf * i2ptunnel: Add inproxy block option to HTTP server 2014-02-20 14:07:02 +00:00
5bcfe1ec72 don't link to docs.i2p2.de in the router console
docs.i2p2.de was last updated in October of 2010!
2014-02-18 19:51:35 +00:00
zzz
4209c291ba * history for prop, -9 (ticket #1090) 2014-02-17 14:18:18 +00:00
zzz
7c5dc7fa55 propagate from branch 'i2p.i2p.zzz.jetty8' (head 0a03ce60906c508b08cc84b3044954844a6ee157)
to branch 'i2p.i2p' (head d99392e09883a92b99a316b4deed0586dcf4ea5b)
2014-02-17 14:01:13 +00:00
zzz
c6dfb8744a Jetty 8.1.14 jars 2014-02-17 13:58:19 +00:00
zzz
6e0ca92041 * getopt fix for PrivateKeyFile -t sigtype, busted in prop
* history for prop, -8
2014-02-17 13:39:32 +00:00
zzz
2f7eb56790 propagate from branch 'i2p.i2p.zzz.ecdsa' (head e83bcdc842f5995d310a4295147f9326a993e010)
to branch 'i2p.i2p' (head 4983f716f8740bc7ddfae5561a562a0d42a815ae)
2014-02-17 13:29:41 +00:00
zzz
8c98ef7328 update version 2014-02-17 13:14:23 +00:00
zzz
45997fd1d5 * SSU:
- Restrict authentication with Bob's intro key to session created packet
2014-02-17 13:05:17 +00:00
zzz
6a3e5ec620 * SSU:
- Use session key for relay request/response if available (ticket #1206)
   - Remove packetAuthTime stats
   - Misc. cleanups and logging
2014-02-17 12:56:08 +00:00
zzz
18cbf3d253 * HMAC:
- Replace BC MD5 with JVM version, refactor I2PHMAC to use
     MessageDigest instead of BC Digest (ticket #1189)
   - Use JVM HmacSHA256 instead of I2PHMAC for Syndie since it is standard
2014-02-17 12:03:22 +00:00
zzz
4df6a6f47b min java version for izpack 2014-02-16 22:31:17 +00:00
5542406f3d Merge pull request from https://github.com/i2p/i2p.i2p/pull/1 2014-02-16 11:28:48 +00:00
zzz
a9fceae181 * I2CP:
- Add session limit, add new status code for refused
   - Ramdomize session ID, prevent dups
   - Make session IDs immutable
2014-02-14 17:05:32 +00:00
zzz
c79ff0dc09 minor cleanups 2014-02-14 17:02:14 +00:00
zzz
e2fc5c6957 * Tunnels: Change expl. OB default to 3+0 2014-02-13 15:46:34 +00:00
zzz
5667a6647f * Router: Convert to getopt (ticket #1173) 2014-02-13 14:43:23 +00:00
zzz
b70d616083 update links 2014-02-12 23:06:30 +00:00
75fa2b1809 typo fix 2014-02-12 21:38:42 +00:00
zzz
66d9017d58 fix PingTest 2014-02-11 19:45:52 +00:00
53efb7119a merge of '12c51adcf9862cc57488b27ec00002b1bb399294'
and 'b870e2fda1291f95ae4e6e35cc5ded300578d92b'
2014-02-11 14:15:35 +00:00
8b946bb56b Remove mention of Pebble in the router console for reasons noted in ticket #865 2014-02-11 14:15:04 +00:00
zzz
8ed34e3edf * HTTP client proxy: Don't flush after headers for a POST,
so the POST data is included in the SYN packet,
   to improve speed and reliability of small POSTs
2014-02-11 13:44:37 +00:00
d8fef53aef i2prouter: - note FBSD10 workaround in ticket #1118
- remove tanuki's script version checks
2014-02-11 01:54:45 +00:00
zzz
6af82f2a9a history for prop, -2 2014-02-10 20:32:20 +00:00
zzz
36b2547ca4 propagate from branch 'i2p.i2p.zzz.test2' (head 7db2f2b73bc7c44b4be1077185314201c5b0bfe6)
to branch 'i2p.i2p' (head ea9844ecc27e816a09cf5d9b36c10ee2c3d1bcc9)
2014-02-10 18:46:38 +00:00
zzz
72e96cdd23 remove concatentation within appends 2014-02-10 18:33:32 +00:00
zzz
a2ba9bbdb1 * Checklist updates
* Console:
   - Don't reset graph settings when clicking restart or shutdown on graphs page
   - Don't recommend guest login on trac, it's disabled
   - Catch and remove corrupt jrb file (ticket #1186)
   - Always set default language on /configui
 * Readme: Update links
 * Transports: Reduce target connection count again to reduce
               tunnel reject rate further
2014-02-10 14:22:43 +00:00
f6d9a6917f Removed a comment line from french translation 2014-02-09 20:27:42 +00:00
zzz
2e91890401 Javadoc fixes to correct release number
Remove unused lock object
 Add irc.dg.i2p
 0.9.11
2014-02-08 18:09:46 +00:00
zzz
1956068698 * Addressbook:
- Rewrite subscriptions.txt to convert to new default URL
   - Static method call cleanups
2014-02-08 16:02:50 +00:00
zzz
855cae0a45 propagate from branch 'i2p.i2p' (head eac6caabd2ea6731ee27111f0dbadf5afcd3695b)
to branch 'i2p.i2p.zzz.test2' (head 911a8782667d878dd7a2976c7fb10d481d80e023)
2014-02-07 16:33:59 +00:00
zzz
ef3a12f01a * UpdateManager:
- Convert to RouterApp and remove update hooks from context
     (ticket #1185)
2014-02-07 15:40:23 +00:00
zzz
37bf750ab9 * I2PTunnel:
- Convert to getopt (ticket #1173)
   - Add more argument sanity checking
   - Add a usage output
2014-02-07 14:24:09 +00:00
zzz
090a790a9d * Services:
- Move backup news to psi.i2p
   - Move default addressbook subscription to i2p-projekt.i2p
   - Remove www.i2p2.i2p from default update lists
   - Add psi.i2p to hosts.txt
   - Update links on help pages to avoid redirects on new website
     and select the correct language
 * SusiDNS: Fix whitespace issues
2014-02-07 12:52:54 +00:00
8ef3bb3d82 version number fix 2014-02-06 18:50:54 +00:00
388019249d -10-rc
Debian changelog update, Korean debconf translation, history.txt update
2014-02-06 18:45:11 +00:00
91d1364832 February 2014 geoip db updates 2014-02-06 18:43:45 +00:00
2ec1d8484f Brazilian Portuguese, Danish, French, Japanese, Polish, Russian, Ukrainian 2014-02-06 18:32:23 +00:00
zzz
9a01fdf57c * PrivateKeyFile:
- Convert to getopt (ticket #1173)
   - New option -e for hashcash effort, instead of -h with optional arg
   - Stub out -t option, to be propped from ecdsa branch
   Will require manual merge with ecdsa branch...
2014-02-06 15:30:03 +00:00
zzz
deec84713f * EepHead, PartialEepGet, SSLEepGet:
- Convert to getopt (ticket #1173)
 * EepHead, PartialEepGet:
   - New option -c for clearnet (no proxy), same as -p:0
   - New option -o, same as EepGet
   - Proxy option -p with host name arg only (no ':') now allowed
   - Add proxy auth support with -u and -x options (ticket #1173)
 * EepGet:
   - Catch error in -h option
   - Cleanups
2014-02-06 14:18:51 +00:00
zzz
0d028122a6 * EepGet:
- Support Digest proxy authentication(ticket #1173)
   - Move authentication parsing method from I2PTunnelHTTPClientBase
2014-02-06 01:29:46 +00:00
zzz
4998f86efe * EepGet:
- Convert to getopt (ticket #1173)
   - New option -c for clearnet (no proxy), same as -p:0
   - Proxy option -p with host name arg only (no ':') now allowed
   - Proxy password option is now -x, not the second arg to -u
   - Prompt for proxy password if not supplied in options
   - Line length option is now -l, not the second arg to -m
   - Error on nonproxied .onion hosts
   - Update man page, sort options (ticket #1173)
2014-02-05 16:10:56 +00:00
zzz
839bd51bc8 javadoc fix 2014-02-05 14:46:23 +00:00
zzz
936f2bb317 combine help strings 2014-02-04 14:32:36 +00:00
zzz
0cd774273c * I2Ping:
- Convert to getopt (ticket #1173)
   - Add support for from/to ports
2014-02-04 14:11:09 +00:00
zzz
fe391ff29f Convert all jars and wars to compile to 1.6 target,
except for the following which are used by android,
to maintain compatibility with very old phones, for now:

	addressbook.war
	BOB.jar
	i2p.jar
	i2ptunnel.jar
	mstreaming.jar
	router.jar
	streaming.jar
2014-02-03 23:59:48 +00:00
zzz
001b127258 * Jetty:
- Update to Jetty 8.x, Servlet 3.0, JSP 2.2
   - Require Java 6
   - Use Servlet and JSP jars from Jetty instead of Tomcat
   - Tomcat remains at 6.0.37 supporting Servlet 2.5 / JSP 2.1
   - Remove Jetty dependency in console error pages
   - Build files for Jetty 8.1.14
   - Doc updates
   - Delete Jetty 7.6.14
   - Jetty 8.1.14 not yet checked in,
     waiting to see if a new version is released soon,
     but build will download it for testing
2014-02-03 23:24:45 +00:00
zzz
7c00a5165f Build: Honor require.gettext=false for i2prouter translations 2014-02-03 20:43:02 +00:00
zzz
e1c3e2c1c7 * Getopt bundle fixes for Java Properties standard:
Fix comment lines
   Encoding conversion to UTF-8 with escapes
   Add unicode escapes for all chars over 0x7f
   Change Transifex type to PROPERTIES
   Also:
    - Remove BOMs
    - Remove \r
    - Remove blank lines
   Encodings were as follows:
     cs: marked ISO-8859-2
     pl: marked ISO-8859-2, possibly corrupt, ?? in two strings
     de, es, fr: marked ISO-8859-1
     hu: detected as ISO-8859-2
     it: apparently ISO-8859-1
     ja: Unicode escaped already
     nb, nl: ASCII
     ro: marked ISO-8859-2 but actually UTF-8
     zh: detected as GB2312 w/ CRLF
     zh_TW: UTF-8 w/ BOM w/ CRLF
2014-02-02 21:05:14 +00:00
zzz
e9b3577eec snark: cache PeerID.toString() 2014-02-02 17:19:06 +00:00
zzz
3622501471 * Streaming:
- Set ports on many packets that were missing them
   - Use connection throttling methods on pings too (ticket #1142)
   - Add methods to set ports on pings
   - Argument checking on ping methods
2014-02-02 16:47:29 +00:00
zzz
b7207fd29f Use getopt lib in SU3File (ticket #1173) 2014-02-02 15:14:00 +00:00
zzz
4dc1241d2f Add lightweight getopt command line parsing lib
(ticket #1173)
This is Java getopt 1.0.14 (released 2012/02/08)
Source was retrieved from https://github.com/arenn/java-getopt
Previous version 1.0.13 (released 2006/08/29)
is available at http://www.urbanophile.com/arenn/hacking/getopt/
Copyright (c) 1998 by Aaron M. Renn (arenn@urbanophile.com),
LGPL v2.
Include the small translation files, add to build.xml and to .tx/config
Fixes:
  Simplified Chinese
    MessagesBundle_chs.properties renamed to MessagesBundle_zh.properties
  Traditional Chinese
    MessagesBundle_cht.properties renamed to MessagesBundle_zh_TW.properties
  Norwegian Bokmaal
    MessagesBundle_no.properties renamed to MessagesBundle_nb.properties
2014-02-02 15:12:44 +00:00
zzz
c59603d31b fix swapped Dutch and Norwegian on /configui 2014-02-02 14:39:41 +00:00
zzz
3ab149a399 streaming javadoc fixes 2014-02-01 12:37:45 +00:00
zzz
99f28519fb * SOCKS: Remove static logs 2014-01-31 18:38:15 +00:00
zzz
05aa88b4e8 * /logs: Fix encoding of wrapper log section (ticket #1193)
- remove a cast in FileUtil
2014-01-31 18:34:27 +00:00
zzz
887f953efb * NetDB: Fix cases where corrupt RouterInfo files were not deleted (ticket #1190) 2014-01-31 18:32:22 +00:00
zzz
5e16c42e4e * InboundMessageDistributor: Set reply flag on LeaseSets 2014-01-30 13:02:16 +00:00
2cea7cdb30 fix 2014-01-29 21:41:52 +00:00
e60da8e8ff Added new https reseed, i2p-netdb.innovatio.no (Sindu) 2014-01-29 19:45:10 +00:00
zzz
be12995753 * Tunnels: Change expl. IB default to 2 + 0-1 2014-01-28 22:50:51 +00:00
zzz
c30419107f * /configclients: Add link to plugins.i2p; don't show delete button for console 2014-01-28 22:48:52 +00:00
zzz
2cacded182 datagram sigtype bugfix 2014-01-28 22:40:36 +00:00
zzz
ec22a1dafc - Only store LS with more than 6 leases to routers that support it 2014-01-28 22:35:33 +00:00
434bf13be9 * I2PSnark: Make 'kitty.png' transparent. 2014-01-28 21:11:39 +00:00
236df32f30 volatiles 2014-01-28 17:42:14 +00:00
zzz
28575dbdae * Key certs:
- Hide setting in i2ptunnel edit pages unless advanced user
  - Only store LS with key certs to routers that support it
2014-01-28 14:21:54 +00:00
zzz
5b9d669d79 * I2CP: Use client tunnels for b32 lookups (ticket #1166)
- convert some calls to use getDestHash()
   - javadocs
2014-01-28 13:27:44 +00:00
zzz
b2f4fde7e5 history for prop, -6 2014-01-27 18:50:44 +00:00
zzz
9eefe1e935 propagate from branch 'i2p.i2p.zzz.i2cp' (head d4ac8162a4ba299ac912640f19076c3c90afdc67)
to branch 'i2p.i2p' (head adc5102c93383e01c74b87f04449dc9c307f6e75)
2014-01-27 16:47:22 +00:00
zzz
b91f041ad7 I2CP:
- Add missing session ID assignments in HostLookup/Reply constructors
2014-01-27 16:38:00 +00:00
zzz
ba96f72899 help tweak 2014-01-27 16:37:39 +00:00
5d322245d8 Ticket #1183 - move message serialization later in the SSU pipeline 2014-01-27 14:47:58 +00:00
zzz
6b16907e40 * i2ptunnel HTTP Proxy: Fix default enable for outproxy plugin 2014-01-27 13:32:24 +00:00
zzz
0c326f989e Remove outproxy hook vestiges in context, history for prop, -3 2014-01-25 18:23:46 +00:00
zzz
e0a499dd0f propagate from branch 'i2p.i2p.zzz.outproxy' (head 02da481346e0bf35b289f00b32f50871da202afb)
to branch 'i2p.i2p' (head eb2820957208e17c76e8c10a2c36e59e0da61895)
2014-01-25 18:16:38 +00:00
zzz
0f862124fe - Tweak display name of HTTP client tunnel
- Show outproxy plugin status on i2ptunnel index page
2014-01-25 17:56:35 +00:00
zzz
d00be4ceee update error pages for HTTPS 2014-01-25 15:52:04 +00:00
zzz
ec8354860e * NetDB: Fix NPE after client shutdown (ticket #1174) 2014-01-25 15:08:56 +00:00
zzz
f9144f2fbf * StatisticsManager: Lower frequency for publishing stats again 2014-01-25 15:07:57 +00:00
zzz
5d2ff5e648 * Installer: Update links
* Update release checklist
2014-01-25 15:06:51 +00:00
zzz
ce475d2cd6 sort imports 2014-01-25 15:05:43 +00:00
zzz
72bd1fe91b * i2psnark: Lower threshold for auto-stop
* Update: All updates via torrent
2014-01-25 14:58:34 +00:00
747d833392 Fix 2014-01-25 00:59:42 +00:00
3427464de6 Move OutNetMessage buffer preparation to the Writer threads
(Ticket #1184)
 Up version to -1
2014-01-25 00:46:30 +00:00
zzz
9ca625a64e - Fix up the header processing for SSL thru HTTP proxy
- Fix the CONNECT line output
- Set use-plugin default to true
- Log tweaks
- rename a variable
2014-01-24 16:52:29 +00:00
9e87fd9b13 Sync fix for NTCPConnection._currentOutbound 2014-01-24 15:35:55 +00:00
zzz
5b6ed48ec0 0.9.10 2014-01-22 01:30:33 +00:00
zzz
96f6865835 bump for review 2014-01-21 00:51:08 +00:00
fa50f9f246 * Adding http(s) uk.reseed.i2p2.no (Meeh)
* Adding http i2p-netdb.innovatio.no (Sindu)
2014-01-21 00:00:27 +00:00
538b4b10d7 Translation updates from Transifex 2014-01-20 17:00:24 +00:00
bdb3e26d07 geoip (v4 and v6) updates 2014-01-20 16:17:32 +00:00
ec87600e80 Chinese language update 2014-01-20 16:13:31 +00:00
zzz
0624f46e67 * Console: Change www.i2p2.i2p links to i2p-projekt.i2p
* Reseed: Remove netdb.i2p2.de
2014-01-20 15:52:14 +00:00
ece1198dd4 Fixed NPE 2014-01-15 02:31:07 +00:00
zzz
8bbab31872 * NetDB: Fix handling of DSM down client tunnels 2014-01-12 19:21:52 +00:00
zzz
8c6922ac5f * NetDB: Fix handling of DSRM down client tunnels
ISJ log tweak
2014-01-12 15:24:13 +00:00
zzz
6b67f399f6 * NetDB:
- Reduce min part tunnels for ffs to 35
   - Use client tunnels for LS lookups from OCMOSJ (ticket #1166)
2014-01-12 01:10:38 +00:00
a9598633b3 Missing file from BOB logging fix 2014-01-11 17:14:09 +00:00
1fb2672b67 BOB: Pass through I2CP host/port (ticket #827) 2014-01-11 04:30:59 +00:00
4308ce6347 Fixed logging for BOB-one.jar 2014-01-11 01:56:47 +00:00
32b095efbd BOB: Implement ClientApp interface (ticket #347) 2014-01-10 21:11:55 +00:00
zzz
eb4bdfcefb add i2pjump 2014-01-10 16:31:39 +00:00
fc6554cabc typo fix (a03adeb0, part 2) 2014-01-10 11:44:37 +00:00
058590f69b Fixed language names in routerconsole 2014-01-10 06:15:17 +00:00
zzz
576984badc I2CP:
- Add SessionID to HostLookup/Reply messages, for future
    use when we have multiple sessions
  - New SessionID constructor w/ value
  - Throw IAE on invalid SessionID values
  - Bump all comments from 0.9.10 to 0.9.11
2014-01-10 02:24:15 +00:00
9825fcf97b update of en source files, bump build 2014-01-09 19:33:54 +00:00
1ed96d72b2 i2prouter translation updates 2014-01-09 19:24:45 +00:00
a29935abb3 New Brazilian Portuguese translation
- New translation from Transifex
- Update langbox widths
2014-01-09 19:24:11 +00:00
e92a5da5a5 tx: update hostname in config, add pt_BR 2014-01-09 19:21:38 +00:00
f08e0299ef Updated translations from Transifex 2014-01-09 19:17:38 +00:00
zzz
9757435b09 NewsFetcher: Delay news fetch on new installs (ticket #1153) 2014-01-09 14:03:49 +00:00
zzz
80fadb4580 Kad: Fix NPE when removing yourself 2014-01-09 12:27:18 +00:00
8658c23974 susimail: Fixed pagination with zero entries (ticket #1168) 2014-01-09 04:31:30 +00:00
0264cc9030 susimail: UTF-8 support from wockenfuss (ticket #508) 2014-01-09 03:34:45 +00:00
bd5b6b32b5 Updated history 2014-01-09 03:33:57 +00:00
dc0a1281bf Migrated overlap fix from Fux (ticket #773) 2014-01-09 03:10:50 +00:00
zzz
c20c697126 RouterAppManager: Allow registration of untracked ClientApps,
required for orchid plugin
2014-01-08 15:17:09 +00:00
zzz
44e7110c9a Fix StandardServerSocket.isClosed() and close()
thx cacapo
ref: http://zzz.i2p/topics/1547
2014-01-08 00:32:51 +00:00
zzz
c860c49c6b Add jisko.i2p to home page
Icon source: http://jisko.i2p/wiki/File:Jisko_console_icon.png
Icon license: Copyleft: This work of art is free; you can redistribute it and/or modify it.
ref: http://zzz.i2p/topics/1539
2014-01-08 00:30:28 +00:00
zzz
b16e66d39a Add GUI outproxy plugin enable setting for all tunnel proxies
(only implemented in HTTP)
More SSL support in I2PTunnelHTTPClient
  - Add separate config for SSL outproxy
2014-01-06 16:56:00 +00:00
3b06f0b83c Change the test url to www.i2p-projekt.i2p 2014-01-06 16:06:20 +00:00
zzz
0bc6c23ac9 Remove outproxy hook in context, use ClientAppManager:
- Add clientAppManager() to I2PAppContext so it can be used there
  - Add routerAppManager() to RouterContext for convenience inside router

Start of SSL support in I2PTunnelHTTPClient
  - Add initialSocketData support back to I2PTunnelOutproxyRunner
  - Works for orchid (and in-net?)
  - TODO Doesn't work for in-net proxy
  - Need separate config for SSL proxy
2014-01-06 13:57:45 +00:00
zzz
17e63b054c add sigtype to i2ptunnel client gui too 2014-01-05 16:38:39 +00:00
zzz
0fae0640d6 missing file 2014-01-05 02:55:46 +00:00
zzz
d054e12952 New interface and context hooks for in-jvm outproxy
Support in HTTP client proxy
All preliminary, maybe better to use ClientAppManager?
2014-01-05 00:52:00 +00:00
dc60c2b478 * Console: Change /configclients 'advanced warning' to include 'toopie, no red 2014-01-04 23:40:41 +00:00
zzz
b59aa1fb69 move I2PSocketOptionsImpl from mini to impl 2014-01-04 22:10:10 +00:00
54a21bfa7b Fix compilation of non-JUnit tests (disabled by default) 2014-01-04 19:57:47 +00:00
50f55877f8 make public method protected 2014-01-04 19:56:55 +00:00
f9ff262318 Fix junit tests for streaming, thank you zab (and thank you zzz) for helping out. 2014-01-04 19:45:52 +00:00
91ba76f2a6 merge of '1fd43bf251a91d33bb1ea9b06f2b35a40be3b9c9'
and '766a92b57cdf82d3b1d1e3a71ef2a3109e883add'
2014-01-04 17:41:15 +00:00
ec97bc2f81 Stab at fixing streaming tests.
Add javadoc package.html
Fix import order
2014-01-04 17:39:32 +00:00
zzz
fba209ca7d restore method used by bote 2014-01-04 17:32:38 +00:00
zzz
b91b242a1a bump 2014-01-04 16:54:12 +00:00
zzz
38186c8f75 TunnelPoolSettings:
Split out the defaults for expl/client IB/OB.
  Client default now 3 hops.
  Expl default still 2 hops, with OB Expl + 0-1,
  en route to 3+0.
2014-01-04 16:48:45 +00:00
zzz
1b3aefbbce PeerManager: Remove small same-country bonus
This was done back when we were desperate for
 build improvement but it's bad for anonymity
 and probably a little slow also
2014-01-04 16:43:54 +00:00
zzz
c03511b971 exception causes 2014-01-04 16:40:06 +00:00
zzz
78e7599a8a better wording 2014-01-04 16:39:10 +00:00
zzz
dc871cf1eb XSS 2014-01-04 16:38:05 +00:00
e98b9d0af5 bump for testing 2014-01-04 14:27:51 +00:00
2a09d5baa6 * Streaming: Move streaming to new package (ticket #1135) 2014-01-04 14:09:33 +00:00
zzz
41e071efe5 * Key cert GUI support:
- Add setting in i2ptunnel server edit page
  - Comment out cert setting on i2ptunnel server edit page
  - Show key type on susidns details page
  - Show key type on LS debug page
2014-01-03 15:31:08 +00:00
zzz
e8e239616f * Crypto: More implementation for key certs
- Support i2cp.destination.sigType option in TunnelController and
    I2PSocketManagerFactory
  - Fixup of Destination.create() and Destination.size()
  - Add generic off/len methods in DSAEngine, needed for streaming
  - Fixup of sign/verify in streaming Packet
  - Javadocs
2014-01-03 00:22:44 +00:00
1feb317f8b typo 2013-12-25 09:39:19 +00:00
09668453d0 * Console: Add 'advanced warning' to /confgiclients
* SOCKS5Server: Remove redundant, commented out line from my previous findbugs
2013-12-25 09:37:46 +00:00
zzz
5842e25205 Initial support for key certificates and arbitrary types and lengths
of signing keys and signatures in RouterIdentities and Destinations.
Untested, not even for regressions, except with command line
using PrivateKeyFile.
Based on preliminary spec at http://zzz.i2p/topics/1442?page=1#p7524
Not done:
 - Transport handshake signing
 - Configuration of default type
 - Specification of type in options to I2PSocketManagerFactory
 - Specification of type in i2ptunnel
 - Fix up caching of SigningPublicKey and P256 key cert
 - Any non-default crypto type in the key cert
 - Documentation
2013-12-24 16:41:05 +00:00
zzz
5219791673 I2CP:
- Add support for b64 conversion in destLookup()
  - Catch invalid message length sooner
I2Ping:
  - Extend I2PTunnelClientBase so non-shared-client,
    I2CP options, and other features will work
  - Fixes for fields and threading
Streaming:
  - Send LS with ping (broken since 0.9.2)
  - Set the NO_ACK flag on pings and pongs
2013-12-21 18:10:59 +00:00
zzz
bf485d8bce history update and date fixes 2013-12-21 18:01:04 +00:00
zzz
cc97a19d3c I2CP:
- Add support for hostname lookups over I2CP with new
    HostLookup and HostReply messages.
  - Move username / password from CreateSession
    to GetDate for early authentication;
    this is an incompatible chage.
    Outside router context with authentication enabled,
    new clients will not work with old routers.
    Early authentication is not yet enforced, enable with
    i2cp.strictAuth=true. Will change default to true in a later release.
  - Block all actions before authentication.
  - Better disconnect messages to clients for diagnostics
  - Improve lookup command, add auth command in i2ptunnel CLI for testing
  - Don't start ClientWriterRunner thread in constructor
  - Don't flush in ClientWriterRunner unless necessary
  - Send GetDate even in SimpleSession outside of RouterContext
  - Improve SetDate wait logic to reduce locks and break out when
    Disconnect received
  - Add Disconnect handler to SimpleSession
  - I2Ping cleanups
  - Javadocs
2013-12-21 00:21:48 +00:00
zzz
38c02b44b9 Streaming: final, volatile, logging 2013-12-19 12:24:51 +00:00
zzz
04a596899a NetDB: Fixes for ExpireRoutersJob
- Don't expire if too few routers
  - Don't expire if net is disconnected
  - Don't run in VMCommSystem
2013-12-19 12:23:29 +00:00
zzz
ee1ed1bb82 Nice message during graceful shutdown
May need to tweak the wording
2013-12-19 12:20:32 +00:00
zzz
2b39d28e99 fix comment 2013-12-19 12:16:39 +00:00
zzz
8cb503d8bb EepGet: Allow override of the User-Agent
i2psnark: Set User-Agent
2013-12-15 15:16:54 +00:00
zzz
efff25a87c NetDB:
- Just before midnight, flood to new location too so lookups
   don't fail after keyspace rotation (ticket #510)
 - Refactor RoutingKeyGenerator and UpdateRoutingKeyModifierJob
   in support of the above
 - Display next key on LS debug page
2013-12-14 14:38:00 +00:00
zzz
6e2583ad92 NetDB:
- Increase new kad size to K=24, B=4
 - Fix router count by counting in the data store, not the kbuckets
 - Randomize the order we load router infos at startup so we
   don't bias the kbuckets
2013-12-13 17:50:39 +00:00
zzz
af84bcf945 i2ptunnel:
- Show destination for persistent client key only if available;
   show b32 for the key as well
2013-12-13 17:45:35 +00:00
zzz
3dc429415b use advanced setting to show LS debug 2013-12-13 17:31:13 +00:00
zzz
ec9dd25631 sort i2ptunnel CLI help for sanity 2013-12-13 17:30:18 +00:00
zzz
2bda87d5a7 comment out main 2013-12-13 17:29:43 +00:00
a7a816e0a7 wrapper: 3.5.23 updates for win64 2013-12-10 23:23:06 +00:00
zzz
3d9d722cee history for props, -1 2013-12-10 11:39:45 +00:00
zzz
289a8e7b40 merge of '3f93d2c09c89b5c68487c33fd700ef7c2feeeb61'
and 'b2c58f8462ab5c08682b711436c387b421bdd0c2'
2013-12-10 11:11:08 +00:00
7d3aa33c25 Fixed type argument problem causing infinite recursion 2013-12-10 05:55:19 +00:00
zzz
0db1314595 propagate from branch 'i2p.i2p.zzz.netdbkad' (head bc7310e940f01e68bd6be0ed0681eb624dada332)
to branch 'i2p.i2p' (head 98569f30891693e6888913f50b88d1f37969fe45)
2013-12-10 02:31:08 +00:00
zzz
68641626aa propagate from branch 'i2p.i2p.zzz.test2' (head ec8e362ce8b93280b518c599a3cc075b89085d2b)
to branch 'i2p.i2p' (head c9b1eef91f61f4482ad11c4f2b2d01be67a17ad2)
2013-12-10 02:26:32 +00:00
zzz
5b9fb403c9 Jetty 7.6.14.v20131031 2013-12-10 02:26:00 +00:00
a4114b96fd Deprecation warning fixes 2013-12-09 20:45:11 +00:00
de184ed139 propagate from branch 'i2p.i2p.str4d.cleanup' (head 736423cc308e964bab55068e625f8a1852932ec5)
to branch 'i2p.i2p' (head 0ac335d5dc4ccaeb113af4fb5c0e993a6f42fdbe)
2013-12-09 19:51:39 +00:00
zzz
04c342ec6a PrivateKeyFile: Fix ISE (ticket #1145)
broken in 0.9.9
2013-12-09 16:38:00 +00:00
zzz
27ce28027d i2ptunnel: Disable streaming pings for clients (ticket #1142)
i2psnark: Disable streaming pings (ticket #1142)
2013-12-09 16:11:53 +00:00
zzz
f8a54bde19 0.9.9 2013-12-07 15:30:29 +00:00
zzz
3acfdbe8f7 i2ptunnel IRC client: Do not filter server PING or client PONG (ticket #1141) 2013-12-06 15:26:12 +00:00
zzz
d9fed57c89 more finals 2013-12-05 16:25:16 +00:00
zzz
46e7e9be82 finals 2013-12-05 16:21:36 +00:00
zzz
d87d4eb232 I2CP: Disconnect client on attempt to publish invalid leaseset 2013-12-05 16:14:51 +00:00
zzz
88ea451f81 propagate from branch 'i2p.i2p' (head 2634e424f06e58231c47f1ec318e9ae21c94a8b3)
to branch 'i2p.i2p.zzz.test2' (head 68ca880caf69a06c0fd01fc70675df795aef1de2)
2013-12-05 16:07:32 +00:00
822ec4aa53 Debian: patch refresh 2013-12-04 18:46:28 +00:00
zzz
7b0b07933f finals 2013-12-04 14:21:03 +00:00
zzz
7fe8573df4 i2psnark ConnectionAcceptor:
- Fix ConnectionAcceptor not restarting after tunnel
    restart, preventing incoming connections
  - locking tweaks
  - cleaner reschedule tweaks
  - don't store server socket locally
  - constructor tweaks / finals
  - Stop acceptor when tunnel disconnects
  - javadocs
2013-12-04 14:17:38 +00:00
c180292358 Style fix: leave brackets around for() one-liners 2013-12-04 03:51:02 +00:00
a3fa48dcbe Removed dead code 2013-12-04 03:50:26 +00:00
zzz
445e4301d5 bump for review 2013-12-01 21:27:43 +00:00
736da22bba update geoip from maxmind's 2013-11-05 db 2013-12-01 20:15:32 +00:00
f29c64cd70 merge of '37bb29ce149260c55fb90ec8e56262262382fd9d'
and 'c4f7358a50c9982c5d63e9e5201f4e3f9562422f'
2013-12-01 20:13:49 +00:00
aa4b4b9d2b French, Italian, Romanian, Spanish, and Swedish translation updates 2013-12-01 20:09:16 +00:00
1112fc8544 Yes it's deprecated, it should still use proper generics 2013-11-30 12:52:50 +00:00
9b361ac445 Fixed history. Last commit was actually blocking "X-Powered-By". Oops. 2013-11-28 21:12:35 +00:00
0ff423fc57 I2PTunnel: Don't send 'X-Forwarded-For' on HTTP server tunnels for anonymity reasons (reported by 'trixie' on IRC). 2013-11-28 21:03:19 +00:00
efe3bd2c05 Use for each when Iterator not needed 2013-11-28 11:56:54 +00:00
f112baac48 propagate from branch 'i2p.i2p' (head cbfe85d22c4d0b05c901db3fa751b57889d9b2d6)
to branch 'i2p.i2p.str4d.cleanup' (head 94fe1764f50b459da18222434034ad46d604c7a1)
2013-11-28 11:12:41 +00:00
707f616498 Changes from -rc diff review 2013-11-28 11:10:57 +00:00
ed2feb3ff7 Core: findbugs 2013-11-27 23:22:49 +00:00
a17b1b99c0 Moved StatLogSplitter to i2p.scripts/java-utils 2013-11-27 22:48:46 +00:00
27bc32f2f3 Core: findbugs exclusions (for use in Eclipse or Jenkins) 2013-11-27 11:17:17 +00:00
b535054e13 generics 2013-11-27 11:14:16 +00:00
97a9a6090a Use copy constructor instead of clone() 2013-11-27 01:55:29 +00:00
8b8e2c88c1 type argument 2013-11-27 01:55:14 +00:00
9d7ee30c15 More cleanups 2013-11-27 01:42:34 +00:00
4ee144533a Another warning suppression to be removed at Java6 2013-11-27 01:25:20 +00:00
0f2a983bb7 i2psnark: type arguments, warning suppression (to be removed at Java6) 2013-11-27 01:11:48 +00:00
8fd2f9090e propagate from branch 'i2p.i2p' (head 7903431c2a396fceb1e0428b2be3dde03ba24635)
to branch 'i2p.i2p.str4d.cleanup' (head cfbae7380c3fa106f578d5de399701cfb72d5747)
2013-11-27 00:57:19 +00:00
8770d7eae0 i2psnark: Comparable type arguments 2013-11-26 21:09:36 +00:00
c59ef24acf i2psnark: more type arguments 2013-11-26 20:16:45 +00:00
85aa2fb083 i2psnark: MetaInfo type arguments (thx zzz) 2013-11-26 19:54:53 +00:00
zzz
434b9fa0d1 GeoIP: Thread the periodic lookup so it doesn't clog the timer queue 2013-11-26 16:28:24 +00:00
zzz
56116ad8c2 PeerManager: Thread the periodic reorg so it doesn't clog the timer queue 2013-11-26 15:51:00 +00:00
zzz
c0ef19a281 i2psnark: Fix mixed public/private tracker detection
(thx str4d)
2013-11-26 03:07:21 +00:00
9804e5b7d9 i2psnark: more type arguments 2013-11-26 01:34:08 +00:00
2f33186e58 i2psnark: type arguments, unused imports, for each 2013-11-26 00:20:03 +00:00
0347c56c96 Deprecation fixes 2013-11-25 23:29:48 +00:00
e77409e57a Close resources 2013-11-25 23:14:09 +00:00
615ba94559 propagate from branch 'i2p.i2p' (head d12a1fd746cd9314de5de5e1000c02cf4c59100d)
to branch 'i2p.i2p.str4d.cleanup' (head e20c143dd50a9c802999068a95e12198b07e4c36)
2013-11-25 22:36:27 +00:00
ce0596d5b1 Reseed: Listen to "Require SSL" config option 2013-11-25 21:11:56 +00:00
35b6926e4f Ticket #1047 : Do not adjust window on receiving dups. 2013-11-25 19:21:27 +00:00
zzz
76925fa3bd console: add debug link if advanced config is set 2013-11-25 15:59:34 +00:00
zzz
dbdf36d85c Update: Increase torrent from 30% to 60% 2013-11-25 15:34:49 +00:00
zzz
60aa8c57a4 I2PTunnel: Fix a shared client configured with i2cp.newDestOnResume
not restarting correctly, caused by previous checkin
2013-11-24 23:42:53 +00:00
zzz
001070f677 fix setting of BC_AVAILABLE thx str4d 2013-11-24 23:42:13 +00:00
c6f2d4948b Class generics 2013-11-24 23:41:06 +00:00
zzz
8699c82614 Kad unit tests:
- Port KBSTest from i2p.zzz.kademlia branch
  - Fix RandomTrimmer so it always returns true, so it may be used
    as the trimmer in the unit tests
2013-11-24 23:39:47 +00:00
zzz
1d7eedd463 Kad unit tests:
- Move KBucketSetTest to new directory
  - Fix testSelf() as new implementation will never include myself
  - Delete KBucketImplTest, not applicable/useful now
  Next todo: port KBSTest from i2p.zzz.kademlia branch
2013-11-24 21:58:42 +00:00
zzz
796a231f54 NetDB:
- Move net.i2p.kademlia package from i2psnark to core, and convert
    netdb to use it.
  - Delete old implementation in netdb
  - Fixups in netdb for generics
  - Add debug output to /debug

  This is the next step in the development plan, in which we previously:
    - Copied the code from netdb to the i2p.zzz.kademlia branch, fixed it,
      and made it generic for hash size (June 2012);
    - Moved it from the i2p.zzz.kademlia branch to the i2p.i2p.zzz.dhtsnark
      branch, and implemented KRPC with it (June 2012);
    - Propped it from i2p.i2p.zzz.dhtsnark to trunk for 0.9.2 (July-Sept. 2012);
    - Proved it out in 0.9.2 - 0.9.9 (Oct. 2012 - Nov. 2013)

  The plan was to maintain the KBucketSet public methods throughout the development
  so we could drop the new version back into netdb, so here we drop it in.

  Setting of K=16, B=3 is just an initial guess, to be reviewed.
  This moves about 18 KB from i2psnark.jar to i2p.jar and removes about 12 KB from router.jar.
  Unit test fixup: todo.
2013-11-24 16:38:51 +00:00
e1fcad686c propagate from branch 'i2p.i2p' (head 72c44737466e553fec443a79fffa7636894fe383)
to branch 'i2p.i2p.str4d.cleanup' (head 5a2425d7523b732840e55039f88cea5699f1aa83)
2013-11-24 01:20:11 +00:00
zzz
ffa03f2b83 IterativeSearchJob:
- Recheck completion status just before sending out a wrapped message
 - log tweaks
2013-11-23 17:56:40 +00:00
zzz
54fb91ba8e I2PTunnel: Call destroySocketManager() when replacing
a client socket manager configured with i2cp.newDestOnResume,
  or a shared client.
  This prevents lots of orphaned StreamingTimer threads.
  There are still cases where these threads may stick around,
  when a tunnel is stopped but not restarted. We don't know in
  some cases when a tunnel could be restarted and when it can't.
  destroySocketManager() should always be called when discarding a
  SocketManager but i2ptunnel doesn't do that now. More to do,
  but this fixes the most common case of leaked threads.
  Related tickets: ##642 #961
2013-11-23 17:54:01 +00:00
zzz
e498e2113f Snark: make a set of the default trackers so the config array
can be private and the lookup for the form is more efficient.
2013-11-23 14:45:38 +00:00
zzz
f42ac71fe0 UDP PeerState findbugs volatile/atomic/synch 2013-11-23 14:37:33 +00:00
zzz
74f2fd06cc Deprecate Signature.FAKE_SIGNATURE 2013-11-23 14:33:58 +00:00
zzz
143a0dfc47 Transport: Reduce target connections from 60% to 45% of limit.
This will improve network capacity.
   Apparent problems with lower limits were actually due to
   unrelated bugs that were fixed by 0.9.8.1-22.
   This can go lower still; I've been testing 33% without issues.
2013-11-23 14:29:23 +00:00
fdb0097934 Temporarily moved old help.jsp translations back 2013-11-23 11:44:07 +00:00
0dde4162e6 susimail: Fix NPE when deleting last message (ticket #414) 2013-11-23 04:24:30 +00:00
zzz
844bae18ba fixup after prop 2013-11-22 22:19:06 +00:00
zzz
9e4d5c0e61 propagate from branch 'i2p.i2p' (head da40262a8b7685de3877c1d7d6d16a155caa9e7c)
to branch 'i2p.i2p.zzz.test2' (head 6263bb149b8301059d0471bcc1d47caeca660f4e)
2013-11-22 17:29:45 +00:00
zzz
9b8d3eb688 Startup:
Wait a while and recheck if a recent ping file is there,
    so that a crashed router doesn't prevent a restart (ticket #633)
2013-11-22 17:27:49 +00:00
8478bfbddc BOB: for each 2013-11-22 11:46:39 +00:00
d6bb5f6a4d i2ptunnel: type arguments 2013-11-22 11:41:12 +00:00
e9fec9354b ministreaming: type arguments 2013-11-22 11:37:44 +00:00
f9f0e6d0a2 SAM: for each 2013-11-22 11:36:26 +00:00
3bc0be1cbe susidns: type arguments, for each 2013-11-22 11:25:22 +00:00
8d826cee93 susimail:
- Generics in Folder
- for each
- type arguments
2013-11-22 11:18:41 +00:00
e853d9a40b Router: more type arguments, for each 2013-11-22 10:16:34 +00:00
15bf94b479 Core: type arguments 2013-11-22 09:34:42 +00:00
6314f33d8f desktopgui: unused imports 2013-11-22 04:25:48 +00:00
5fa0376f58 SAM: type arguments, unused imports 2013-11-22 04:22:14 +00:00
552dd189a5 streaming: type arguments, unused imports 2013-11-22 04:18:26 +00:00
57144f3e6a Added Eclipse projects for SAM and streaming 2013-11-22 03:58:02 +00:00
zzz
0454639db8 bump -30-rc 2013-11-21 23:02:21 +00:00
c32b451733 i2psnark: type arguments, unused imports 2013-11-21 12:43:45 +00:00
2f4765665d routerconsole: type arguments, unused imports 2013-11-21 11:31:50 +00:00
bff79cdae8 susimail: type arguments 2013-11-21 10:49:15 +00:00
4bddf8ae0b susidns: type arguments, unused imports 2013-11-21 10:17:35 +00:00
ae79deff39 net.i2p.jetty.*: type arguments, unused imports 2013-11-21 10:13:34 +00:00
e3aeb267f8 Eclipse classpath consolidation 2013-11-21 09:38:09 +00:00
c5c26c440d Eclipse Ant builders for core, router and jettylib 2013-11-21 09:11:42 +00:00
77971624b4 Created Eclipse project for installer/resources
Reverts a change in 7fe82070
This project can be added to the classpath of a JUnit runner
2013-11-21 08:54:42 +00:00
f5621c5082 Converted lib Eclipse project to standard folder 2013-11-21 08:52:04 +00:00
3fa7fe9733 Updated routerconsole Eclipse classpath 2013-11-21 08:40:05 +00:00
c97d07e10a org.cybergarage.*: more type arguments 2013-11-21 06:08:41 +00:00
567c328331 org.cybergarage.*: type arguments, unused imports 2013-11-21 05:58:54 +00:00
3aa982529e org.xlattice.crypto.*: type arguments 2013-11-21 05:56:14 +00:00
0c07f9ff96 More type arguments in UDPTransport 2013-11-21 05:23:35 +00:00
f0055ccbfe Made type argument for Transport.getClockSkews() consistent 2013-11-21 02:27:53 +00:00
693cc828c2 Type arguments in OutNetMessage 2013-11-21 02:27:03 +00:00
688dd23111 gnu.crypto.prng.*: type arguments 2013-11-21 02:18:59 +00:00
e38db5eb44 i2ptunnel: type arguments, unused imports 2013-11-20 23:36:39 +00:00
817f531619 merge of '743aa294fa15c3243bb6ad56d4de64f5eff15051'
and '85fa37bf6c3090c0d4c10f4b7b2d679549090c37'
2013-11-20 23:15:31 +00:00
53623da2eb addressbook: type arguments, unused imports 2013-11-20 23:14:40 +00:00
4910266d9b merge of '63ea1d70b3fd3886a050d7b196cd7ae261844164'
and '6a57f7039fe5697b9770d642ac1d4653e4b9878c'
2013-11-20 23:10:52 +00:00
24ae66df6d Core JUnit tests: type arguments, unused imports 2013-11-20 23:06:17 +00:00
228bd980db Router JUnit tests: type arguments, unused imports 2013-11-20 22:47:14 +00:00
f161a2dfc9 BOB: NamedDB accesses are synchronized, correct findbugs fix is to remove volatile 2013-11-20 22:12:44 +00:00
abe1dc676e Dead code, type arguments 2013-11-20 22:05:37 +00:00
zzz
9de57a5d5a log tweak; bump -29-rc 2013-11-20 21:16:13 +00:00
2cc742c3ed Fixed stupid pasting bug 2013-11-20 19:54:10 +00:00
5bcfe025d5 fix build 2013-11-20 15:40:21 +00:00
6dc6ca7713 avoid <? extends Object> generics 2013-11-20 15:11:35 +00:00
eabcc96a99 remove useless string 2013-11-20 14:52:44 +00:00
28b6675979 findbugs BOB/SAM. more to do. 2013-11-20 12:02:44 +00:00
413ad6b0e6 BOB findbugs 2013-11-20 09:56:57 +00:00
a7a7e96188 Findbugs in imported core code 2013-11-20 09:15:12 +00:00
796dbc5d2e Fixed bug hidden by Set<RouterInfo> -> Set -> Set<Hash> unchecked conversion 2013-11-20 04:18:15 +00:00
c86845078c Reverted change in net.i2p.router.Router 2013-11-20 04:06:59 +00:00
89dcceefee Core: type arguments, unused imports 2013-11-20 04:02:28 +00:00
bacce17990 Router: type arguments, unused imports 2013-11-20 02:46:24 +00:00
e61e950713 update patch / update debian changelog 2013-11-20 00:50:39 +00:00
244209d3b7 Translation updates, addition of Japanese language
-28
2013-11-19 23:59:46 +00:00
zzz
dbe0a8240e Translations:
- Add support for country variants (ticket #1133)
  - Refactor data in ConfigUIHelper
Config files: Allow empty values
2013-11-18 23:18:46 +00:00
zzz
7e3e08532f more static atomics 2013-11-17 15:03:10 +00:00
zzz
1d4190734d Findbugs all over
- volatile -> atomic
 - unused code and fields
 - closing streams
 - hashCode / equals
 - known non-null
 - Number.valueOf
 - new String
 Still avoiding SAM, BOB, SusiMail
2013-11-16 13:22:05 +00:00
zzz
96cf1d60c2 * Jetty: Fix eepsite and webapp cache control directives.
Eepsite fix for new installs only.
  Fix i2psnark BasicServlet javadoc about param prefix.
  (ticket #1128)
2013-11-15 18:51:14 +00:00
3aa33378c1 i2prouter: s/3\.5\.20/3.5.22/g 2013-11-15 01:02:37 +00:00
747bd0c5a3 Update Java Service Wrapper to v3.5.22
- Windows: Self-compiled with VS2010 in Windows 7. The icon has been
  changed from Tanuki's default to Itoopie.
- Linux ARMv6: Compiled on a RaspberryPi using gcc 4.6.3-14+rpi1,
  Icedtea6 6b27-1.12.5-1+rpi1 and stripped
- All other binaries are from the "community edition" deltapack offered by
  Tanuki.
2013-11-15 01:01:49 +00:00
zzz
ea7b42810f * InboundMessageDistributor:
- Put garlicked DSM messages in the InNetMessagePool instead of handling directly,
     so the IterativeSearchJob will see the response and declare success.
     Only affected LS lookups as we do not request encrypted replies for RI lookups.
     Similar to the fix for verifies 6dc5bed94321ae2b290cfe351511d18465e08f91
     This bug was causing initial lookups to fail but subsequent ones to succeed.
     Broken since 0.9.7 when encrypted replies was introduced.
     Ticket #1125
2013-11-14 17:39:31 +00:00
zzz
19022baa27 log tweaks, final 2013-11-14 17:36:57 +00:00
e8248f5005 volatile 2013-11-14 15:18:46 +00:00
f8178b7165 ticket #1125: revert previous change as it is not relevant
to test failure
2013-11-13 11:43:24 +00:00
79b5d9748d patch refresh 2013-11-13 01:03:19 +00:00
zzz
b53ed94e8f Findbugs:
- Fix several 'increment of volatile is not atomic' all over
    Remaining: UDP PeerState.java, to be checked in separately
  - Comment out all of unused MessageStateMonitor
2013-11-12 19:28:23 +00:00
zzz
df84a2fcd0 save server status text to return to user 2013-11-12 19:19:21 +00:00
25e7dea370 merge of '4f6d64a50c7c5c27682914984831fc581724659d'
and 'e5def490e4eba793ca0d2bcb739771dcdf8c0242'
2013-11-11 23:49:02 +00:00
90919ebf6b Make ObjectCounter Serializable 2013-11-11 23:48:15 +00:00
zzz
76078deb3f handle numeric private value in metainfo 2013-11-11 23:24:14 +00:00
1b95a03d2e merge of '3a7591d75dacb165b1b1d26c6bdd94184076fb03'
and 'ba02b6daf2d660339ff05cfe0479344391e6e34f'
2013-11-10 23:27:39 +00:00
108039de08 partial revert of 6df9f4e154d148867ee158cbe9e9acf3fb73d680 2013-11-10 23:00:57 +00:00
addd2e6d6a merge of '3f85581f65aedde0f96729d197aaab223174f2e4'
and '6df9f4e154d148867ee158cbe9e9acf3fb73d680'
2013-11-10 22:22:10 +00:00
5c38d5a6c9 Findbugs: More findbugs fixes. Including but not limited to: null check fixes and some synchronization 2013-11-10 22:20:13 +00:00
zzz
69489dd19e use DataHelper.skip() in a few more places 2013-11-10 22:20:06 +00:00
zzz
3fce0e8e45 xlattice findbugs 2013-11-10 22:19:45 +00:00
35fb332c2c moar test cases 2013-11-10 21:13:42 +00:00
zzz
1b5309be05 junit test for new DataHelper.skip() 2013-11-10 20:42:24 +00:00
zzz
d2a1025b3f about 20 findbugs fixes all over 2013-11-10 20:07:46 +00:00
0a8f79f0e3 Findbugs: A stab at squashing some issues across the board. Probably more to follow. 2013-11-10 19:04:57 +00:00
zzz
18e4c2ac63 log tweak 2013-11-10 15:34:44 +00:00
zzz
90c2e08489 Streaming:
- Fix uncaught exception when log level = WARN, broken in -23
2013-11-10 15:32:54 +00:00
zzz
598ef67c4e Tunnel fragments:
- more checks, don't allow fragment #0 in follow-on fragment
  - Set message ID in constructor
2013-11-10 15:27:28 +00:00
zzz
1b9d870b91 i2psnark: Don't announce more than torrent size as downloaded amount 2013-11-10 15:20:07 +00:00
zzz
68f67b7c8e UPnP:
(ticket #1123)
 - Add new config i2np.upnp.ignore to specify UDNs of ignored devices
 - Add display of ignored devices on /peers
2013-11-10 15:17:42 +00:00
d2f0c251c0 use four digit umask in wrapper.config
According to http://wrapper.tanukisoftware.com/doc/english/prop-umask.html the
umask is a four digit number.
2013-11-09 16:19:33 +00:00
zzz
2b2f34b3f1 A better killyourtv.i2p icon
New icon from FatCow, licensed as specified in our docs.
   ref: http://zzz.i2p/topics/1492
2013-11-08 18:28:35 +00:00
zzz
4e680479da Home page: replace all default eepsite icons.
New icons from FatCow, licensed as specified in our docs.
   ref: http://zzz.i2p/topics/1492
2013-11-08 15:26:32 +00:00
zzz
d1b93e0705 DeliveryInstructions:
- Comment out unused encryption fields to save space
  - New static immutable LOCAL instruction to reduce object churn
2013-11-08 14:39:43 +00:00
zzz
4382def62f log tweak 2013-11-08 14:35:28 +00:00
zzz
952a56c537 JobQueue: Log a warning if a job is scheduled too far in the future,
to catch bugs like the one in -7 where requeue() is called
          with an absolute time instead of a delay
2013-11-08 14:34:33 +00:00
zzz
67aead214b Tunnel Endpoints:
- Reject type 3 (undefined) delivery instructions at both OBEP and IBEP,
     would be treated as LOCAL
   - Reject type 0 (LOCAL) delivery instructions at OBEP, no current usage,
     would cause NPE if handled
2013-11-08 14:31:14 +00:00
zzz
50f45a50a7 minor optimization 2013-11-08 14:24:06 +00:00
6b326c3705 merge of '15e16e2fd4c5be75a63b28616b413a8d1e13e1d6'
and '2449ac4142097e34b7ad4c4c4cb16c163a786a16'
2013-11-07 20:39:59 +00:00
919ec3af01 work on failing JUnit test 2013-11-07 20:38:52 +00:00
ca5a301a4f i2prouter: create i2p.dir.config with umask from wrapper.config 2013-11-07 19:56:01 +00:00
zzz
ae76a6ee1a findbugs correctness fixes, all over the place 2013-11-07 19:20:25 +00:00
zzz
5cbecb3599 log IP change in event log 2013-11-07 13:13:21 +00:00
zzz
5a34e1de4f * NetDB: Fix RI publish interval, broken in -7 2013-11-07 12:31:46 +00:00
zzz
c810694e07 * i2psnark: Fix file links, broken in -12 (ticket #1114) 2013-11-07 12:29:05 +00:00
zzz
ca866d48e6 * Logging: Track duplicates across flush interval (ticket #1110) 2013-11-07 12:23:37 +00:00
f1e77499e2 allow webapps.config to be 'preseeded' with values 2013-11-04 22:05:22 +00:00
zzz
9007db1485 Expire wasUnreachable entries, so inbound tunnel build failures don't escalate
and the peer doesn't have a severe penalty in the CapacityCalculator forever.
This may fix the tunnel build problems that started in -10. Or not.
2013-11-03 15:26:21 +00:00
zzz
85c998e500 HTTP proxy: Fix addressbook name on redirect page 2013-11-03 15:04:37 +00:00
zzz
8296f8229e + * NetDB: Allow store of leaseset as long as one lease has not expired 2013-11-03 15:01:31 +00:00
zzz
059ae3a80e - Add network status to event log 2013-11-03 15:00:00 +00:00
67e242c441 Debian patch refresh and readme file update 2013-11-02 17:31:31 +00:00
zzz
e23f3b4875 comments 2013-11-02 14:10:06 +00:00
zzz
06ea9af733 i2psnark: Log name of offending file causing IOException (ticket #1099) 2013-11-02 14:09:00 +00:00
zzz
884818f518 log tweaks, generics 2013-11-02 13:58:12 +00:00
zzz
3f39bd0f7b remove unused static log 2013-11-02 13:53:42 +00:00
48cce6435b routerconsole war dies with .jsp files in a subdir 2013-11-01 11:00:37 +00:00
zzz
777e08c8b6 * Transport: Fix GeoIPv6 (ticket #1096)
due to int/long problem, they were being corrupted
   and then looked up as IPv4
2013-11-01 01:44:29 +00:00
zzz
8c4b0b7c00 merge of '0af9bde8ae97c3b08f2c934236532121ce135817'
and 'b324a96172089b549e53fb1c0c2a01807fe64699'
2013-10-31 21:30:02 +00:00
zzz
dae8b25374 Transports:
- Increase threshold for idle timeout reduction from 33% to 60%.
   This was reduced from 75% to 33% in -10 and it caused significant
   tunnel build problems, for reasons that aren't entirely clear.
 - Don't change the SSU idle timeout quicker when firewalled.
 - log tweaks
2013-10-31 21:27:26 +00:00
2ae293444e Split routerconsole help into several files (no frontend change)
The old full-page translations of help.jsp are deprecated. The help text will
be tagged for translation on Transifex.
2013-10-31 21:22:24 +00:00
zzz
0f11d3566a log tweaks 2013-10-31 21:15:09 +00:00
zzz
fa70d439c3 minor optimization 2013-10-31 21:08:02 +00:00
zzz
0010581405 TunnelPoolSettings:
- Make dest hash final
 - Ensure allowZeroHop is always true for exploratory
2013-10-31 21:07:11 +00:00
zzz
1d659e4f8a i2psnark: Always verify file lengths at startup (ticket #1099) 2013-10-31 21:02:59 +00:00
509f00c5e2 Override toString() 2013-10-30 18:09:40 +00:00
aeb3241abb * i2psnark: Start torrents by default (ticket #1072) 2013-10-29 23:05:50 +00:00
zzz
8909df3c88 * i2psnark: Fix start and start-all buttons on text-mode browsers
and Opera (ticket #1093)
2013-10-29 21:49:20 +00:00
zzz
1cffcae36b merge of '2c288e0ac5d4a6039b3f08e6bbae9439bb038955'
and 'fa8975b2dbcb60d5f181bc21fc1245d5f82baef0'
2013-10-29 21:04:40 +00:00
zzz
d2ee5b96ad Log tweaks and minor cleanups, -15 2013-10-29 21:03:20 +00:00
zzz
0506a5915b * Tunnels:
- Build a new exploratory fallback tunnel in the BuildExecutor
     loop if we run out.
   - Don't use closest expl. tunnel as the paired tunnel for a build,
     use a random one instead (partially back out change from -12)
   - Log tweaks
2013-10-29 21:01:53 +00:00
zzz
91ef3fd0bc * InboundMessageDistributor:
- Don't discard an encrypted DSRM received
     down a tunnel, just strip the hashes like we do for unencrypted
   - Send a store of our own encrypted LS received down a tunnel to
     the InNetMessagePool so the FloodfillVerifyStoreJob will see it.
 * NetDB: Fix LS store verifies with encrypted replies
   by storing the tagset with the correct SKM for the inbound tunnel used.
   Broken since 0.9.7 when it was introduced.
2013-10-29 20:57:00 +00:00
79f5484f87 Fix history. 2013-10-29 20:38:32 +00:00
6afd2c4b97 * Adding no.i2p registrar 2013-10-29 00:05:06 +00:00
zzz
06b09f89de add SU3File bulksign CLI 2013-10-28 23:22:17 +00:00
zzz
bd0eee6aa9 * configstats: Page will now always reflect results of a previous
change, by querying the config instead of StatSummarizer to
   determine if a stat is graphed.
  - Don't append to a string in a loop
  - parseConfig() return a Set instead of List to avoid O(n**2) behavior
    when deteriming config changes
2013-10-28 21:48:02 +00:00
5bc13c16dc merge of '40e39576b76cc1261e0eda2c63a052544021f2e3' and '81c0ce21efaae02bbc2b5d3ce4e25b2d315dc2eb' 2013-10-28 20:09:57 +00:00
626daeb86e * I2PTunnel: Enable persistent keying for SOCKS tunnels (ticket #1088) 2013-10-28 19:15:46 +00:00
zzz
a92913da4c * Streaming:
- Ensure minimum randomized initial conn throttle period
   - Change order of throttle checks again
   - Don't continue throttle checks if throttled
2013-10-28 17:59:50 +00:00
zzz
f0f363e8c3 * Streaming: Fix instantiation failure with blacklist entries,
caused by bad fix for ticket #1070
2013-10-27 17:09:29 +00:00
zzz
7839c0fec3 * Tunnels:
- Don't use fallback expl. tunnels as the paired tunnel
     for a client tunnel build.
     This will cause more client tunnel breakage but it's
     really bad to use a zero-hop for this.
   - Fix selection of an expl. tunnel close to a hash
   - Don't update build generation stat if the generation failed
   - log tweaks
2013-10-26 20:52:56 +00:00
zzz
4d24d65c1f * Profiles: Ensure we select random peers even before the first reorganization -
we were picking the not-failing peers in-order for early expl. tunnel builds
2013-10-26 20:47:41 +00:00
zzz
ddf761b1f8 * Streaming: Randomize end of first conn limit period
to prevent correlation
2013-10-26 20:45:30 +00:00
zzz
2814fe75b1 sort custom options 2013-10-26 20:44:19 +00:00
zzz
7316c82ef3 * i2psnark: Display base name, not torrent file name (ticket #985) 2013-10-26 20:42:16 +00:00
zzz
e04646bd37 finals 2013-10-26 14:21:53 +00:00
zzz
8f8022347d * I2PTunnel HTTPServer:
New POST limiter
2013-10-26 14:21:26 +00:00
acc0ab66a3 My RSA 4096 pubkey for update signing 2013-10-26 11:25:07 +00:00
zzz
5a6acf1d85 * Router: Only log pingfile error once (ticket #1086) 2013-10-25 19:55:09 +00:00
zzz
ca45194c30 * Streaming:
- Check blacklist/whitelist before connection limits, so
     a blacklisted peer does not increment the counters
   - Don't increment total throttle if peer is throttled
   - Fix blacklist NPE after config change (ticket #1070)
2013-10-25 14:09:02 +00:00
zzz
102506ebe8 * Transports: Reduce connection idle time sooner 2013-10-25 14:05:50 +00:00
zzz
d06f1c4a30 /confighome: Remove config when restoring default so user will again see changes from updates 2013-10-24 21:46:03 +00:00
zzz
c732c1c038 I2PTunnel: Catch unchecked exceptions in server accept loop (ticket #1070) 2013-10-24 20:56:37 +00:00
zzz
4aa1bba575 * NetDB:
- We don't verify RI stores any more, so save RI-last-published time when we store it.
2013-10-24 20:54:21 +00:00
zzz
9d3925eb20 * i2psnark:
- Drop incoming connections on HTTP port
   - Define port 6881 in one place
   - Don't let random DHT port be 6881
   - Exception tweak
2013-10-24 20:52:37 +00:00
zzz
80fdf4e917 * I2PTunnel - fix anonymity characterization in dropdowns
(2 hops is not high anonymity)
2013-10-24 19:18:53 +00:00
zzz
35a86e603b * I2PTunnel standard, HTTP, and IRC servers:
Route connections to specific targets based on incoming I2P port
   with custom option targetForPort.xxxx=myserver:yyyy
   This allows multiple services on a single server tunnel (ticket #1066)
2013-10-24 11:38:28 +00:00
zzz
8f7b31aed3 * I2PTunnel standard and IRC clients:
- Allow host:port targets; set defaults in i2ptunnel.config (ticket #1066)
   - Don't fail start if hostname is unresolvable; retry at connect time (ticket #946)
   - Output IRC message on connect fail
   - Update target list on-the-fly when configuration changes
2013-10-23 20:20:54 +00:00
zzz
0f5a0b6b1b * NetDB:
- Increase RI publish interval to reduce the connection load on ffs
   - Save RI-last-published time; check it before publishing
   - Minor cleanups
2013-10-23 14:56:27 +00:00
zzz
4cf3906ed2 * Home page:
- Add salt.i2p. Icon from efkt, free to use.
   - Change icon for stats.i2p. Icon from Fat Cow, see license info in LICENSES.txt
2013-10-23 12:41:36 +00:00
zzz
57875586cf reduce same-country bonus, less countries 2013-10-19 22:10:03 +00:00
zzz
ad8ec011d0 more transport categories 2013-10-19 22:09:23 +00:00
zzz
0d93b86a56 sfv mime type 2013-10-19 22:09:07 +00:00
zzz
63712002e2 merge of '4eee3780cfb882747ad68e39ac08b721f91c48a7'
and 'cca89ae05036ab7a2fe0080fdd1cfac19968246a'
2013-10-19 21:27:59 +00:00
zzz
67af1a17c1 - Don't display UPnP info on peers page in Android
to prevent crash
2013-10-19 21:26:23 +00:00
zzz
9cac546547 add IPv6 categories to /netdb transport chart 2013-10-19 16:37:13 +00:00
zzz
3ffb321f46 * NetDB: Reinstate ExpireRoutersJob 2013-10-19 14:51:11 +00:00
zzz
14ea6d8d0a delay multiple ExploreJobs slightly 2013-10-19 14:47:27 +00:00
zzz
8e0dbf31ba * NetDB (ticket #1076)
- Reduce flood redundancy from 4 to 3
   - Reduce min part. tunnels for ff from 100 to 50
2013-10-19 14:45:52 +00:00
zzz
5187bf1eae * I2PTunnelHTTPServer: Start timer before reading the first line (ticket #1071) 2013-10-19 14:40:34 +00:00
zzz
99471d8e1b css tweak to fix i2ptunnel ssl box layout on firefox 2013-10-19 14:37:28 +00:00
zzz
012e999354 fix unit tests broken by previous checkin 2013-10-18 19:58:39 +00:00
zzz
bdd9900d0d * OutNetMessage: Remove setters, make fields final 2013-10-18 18:42:48 +00:00
zzz
c71b485083 mark ipv6 only as experimental on /confignet 2013-10-18 18:38:39 +00:00
zzz
a78d34ab4b * I2PTunnel SSL cleanup, log SSL exceptions as errors to help find cert problems 2013-10-18 18:37:25 +00:00
zzz
255ebe7efb * Streaming: Throw IOE if socket is closed (ticket #1077),
never return null from stream getters
2013-10-17 13:39:00 +00:00
zzz
5f7a761e42 * I2CP: Move SSL client socket code to util,
move cert location to certificates/i2cp.
 * I2PTunnel: Support SSL for connection to local server
   for Standard, HTTP, and IRC server tunnels.
   Put server cert in certificates/i2ptunnel if necessary.
2013-10-17 13:22:17 +00:00
zzz
09548358fa increase translate initial map size, clear on exit 2013-10-17 11:17:58 +00:00
zzz
df381c37ff 3gp mime type 2013-10-17 11:15:20 +00:00
31e96b416d Update Trac links: s|http://trac\.i2p2\.de|https://trac.i2p2.de|g 2013-10-16 23:12:11 +00:00
53b0f7b579 french updates 2013-10-16 23:11:06 +00:00
zzz
45deaa3a87 * open4you icon and text
from hosting@mail.i2p
   image free to use
2013-10-14 20:06:57 +00:00
zzz
0c8eabcdf6 merge of '2bb222d33ec817b78fcf506c32da44d10b1eff3b'
and '59e86e3176465259a67927b042c1307cd0a94aa4'
2013-10-14 17:10:55 +00:00
zzz
f9571740ae address check cleanup 2013-10-14 17:02:08 +00:00
zzz
eb2af2b5fd * ClientManager: Remove setters, make all fields final 2013-10-14 17:01:32 +00:00
zzz
ded00300b4 javadoc fixes 2013-10-14 17:00:14 +00:00
zzz
811819af69 * Tests:
- Fix LogSettingsTest broken by recent LogManager changes
   - Remove empty LogSettings.java
2013-10-14 16:58:50 +00:00
1804c852bb French language translation updates from Transifex 2013-10-14 15:43:39 +00:00
zzz
3ec602865d * Translations: Move country names to a new resource bundle 2013-10-14 15:29:12 +00:00
zzz
0c0a25b038 merge of 'ad0ab5020bb253c5233ac2f036c0cf4f40001d51'
and 'bc7c0fa32e955a7d8185456815652d4baab500ae'
2013-10-13 19:38:48 +00:00
zzz
208192f445 * I2CP: Fix bug in handling external I2CP clients, introduced in -2
by the immutable destination patch
2013-10-13 19:33:04 +00:00
d0f635e30c ticket #1062 - count duplicate packets towards RTT if we have
never sampled it
2013-10-13 17:05:59 +00:00
zzz
20b2f7dcb1 fix date, restore tunnel length changed in previous checkin 2013-10-13 12:03:57 +00:00
zzz
cf66951818 cleanup after prop, history for prop, -2 2013-10-13 11:55:23 +00:00
zzz
c6f41cc8fa crypto cleanup 2013-10-13 11:53:43 +00:00
zzz
45a579403a propagate from branch 'i2p.i2p.zzz.test2' (head 5c1b78bd78845b0c8b90fbb60412c68e7dc4f3e6)
to branch 'i2p.i2p' (head 8bdc25c8e6f40491f20b533d94eacab012adba35)
2013-10-13 11:48:12 +00:00
zzz
74a57abfb4 Streaming:
- Make I2PSocketFull.close() nonblocking; it will now cause any user-side
     writes blocked in I/O (Connection.packetSendChoke()) to throw
     an exception (tickets #629, #1041)
   - Don't ignore InterruptedExceptions; throw InterruptedIOException
   - Back out static disconnect exception
   - MessageInputStream locking fixes
   - Cleanups
 I2PSnark:
   - Close socket before closing output stream to avoid blocking in
     Peer.disconnect(), and prevent Peer.disconnect() loop
2013-10-12 17:39:49 +00:00
zzz
380783c1ba Snark DHT:
- Combine getPeers and announce into a single method, as we must announce to
     the closest from the getPeers, not the closest from the kbuckets
   - Stop getPeers when nothing closer is found
2013-10-09 21:09:34 +00:00
c8843a736d make _ackSinceCongestion atomic 2013-10-09 14:08:44 +00:00
e69fefda62 cleanup: remove boolean parameter that is always true 2013-10-09 14:06:16 +00:00
513da3b743 cleanup: remove no-op invocation 2013-10-09 14:04:34 +00:00
zzz
7513d42e9e Snark DHT:
- Increase dest lookup and search timeouts
   - Increase max search depth
   - Loop tracker client faster when in magnet mode
   - Loop tracker client faster if DHT announce fails
   - Don't return an empty peers list if we only know about the requestor
   - volatiles, log tweaks
   - Major fixes of getPeers() to follow
2013-10-09 13:06:47 +00:00
zzz
8872437caf Another snark refactoring bug, log tweaks 2013-10-08 01:17:36 +00:00
712c77a4b6 add my "su3" certificate 2013-10-08 00:17:41 +00:00
zzz
38cef14cf4 synch cleanup thx zab 2013-10-07 19:26:33 +00:00
zzz
05c3b0d391 Fix bug causing writes past end of file, introduced in refactoring, not in trunk 2013-10-07 15:47:44 +00:00
zzz
854090e9d8 - Console: Set per-connector acceptors back to 1, Jetty default changed to 2? 2013-10-07 14:51:49 +00:00
zzz
f035815f7a - Don't truncate initial news header if it appears in summary bar
(unlikely as we don't show the "hide news" button for initial news)
     Also prevent string IOOBE
2013-10-07 14:45:11 +00:00
zzz
df4302dda0 * Update:
- Thread news fetcher so it doesn't clog the scheduler
2013-10-07 14:43:18 +00:00
zzz
31f117e74c * Data Structures:
- Make Destination and RouterIdentity keys and cert immutable
   - Add Destination cache
2013-10-07 13:04:01 +00:00
zzz
890f40b2ac more log tweaks 2013-10-07 12:11:42 +00:00
zzz
3ac8083faf log tweaks 2013-10-07 12:10:10 +00:00
zzz
249319f76f * Disallow 2001:db8::/32 (RFC 3849) addresses 2013-10-07 11:22:54 +00:00
zzz
efe87060b4 add missing start.jar thx kytv 2013-10-06 22:55:59 +00:00
zzz
afe3ff57cf history for prop, -1 2013-10-06 17:13:29 +00:00
zzz
6bb1505d3b propagate from branch 'i2p.i2p.zzz.ecdsa' (head 1dd9522809f801ca68dd331cfba1c5c914dc1481)
to branch 'i2p.i2p' (head a1c2ba4663abc7470f427c6a14854707d58b486a)


 Prop from branch i2p.i2p.zzz.ecdsa:
 * Build:
   - Generate su3 file in release target
   - Add zzz's new RSA 4096 pubkey cert for updates
   - Fix checkcerts.sh
 * Console: Move advanced setting to HelperBase
 * DSAEngine changes:
   - Implement raw sign/verify for other SigTypes
   - Add sign/verify methods using Java keys
 * ECDSA Support:
   - Add ECConstants which looks for named curves and falls back to
     explicitly defining the curves
   - Add support for ECDSA to SigType, DSAEngine and KeyGenerator
   - Attempt to add BC as a Provider
   - genSpec: fallback to BC provider
 * EepGet:
   - Fix non-proxied PartialEepGet
   - Prevent non-proxied eepget for an I2P host
 * KeyGenerator changes:
   - Generate key pairs for all supported SigTypes
   - KeyPairGen: Catch ProviderException, fallback to BC provider
   - Add KeyGenerator main() tests
 * KeyRing and DirKeyRing added: simple backend for storing X.509 certs
 * KeyStoreUtil added:
   - Consolidate KeyStore code from SSLEepGet, I2CPSSLSocketFactory,
     SSLClientListenerRunner, and RouterConsoleRunner into new
     KeyStoreUtil and CertUtil classes in net.i2p.crypto (ticket #744)
   - Change default to RSA 2048 (ticket #1017)
   - Set file modes on written keys
   - Overwrite check in createKeys()
   - New getCert(), getKey()
   - Extend keygen max wait
   - Read back private key to verify after keygen
   - Validate cert after reading from file
   - Validate CN in cert
   - Specify cert signature algorithm when generating keys
 * NativeBigInteger: Tweak to prevent early context instantiation
 * RSA support added: constants, parameters, sig types, support in DSAEngine, KeyGenerator, SigUtil
 * SHA1Hash: Add no-arg constructor
 * SigType changes:
   - Add parameters (curve specs) to SigTypes
   - Add getHashInstance()
   - Add RSA, fix ECDSA
   - Renumber, rename, comment out types that are too short.
 * SigUtil added:
   - Converters from Java formats (ASN.1, X.509, PKCS#8)
     to I2P formats for Signatures and SigningKeys
   - Move ASN.1 converter from DSAEngine to SigUtil, generalize
     for variable length, add support for longer sequences,
     add more sanity checks, add more exceptions
   - Move I2P-to-Java DSA key conversion from DSAEngine to SigUtil
   - Add Java-to-I2P DSA key conversion
   - Add Java key import
   - New split() and combine() methods
 * SSLEepGet: Move all certificates to certificates/ssl, in preparation
   for other certificate uses by SU3File
 * SU3File changes:
   - Support all SigTypes
   - Implement keygen
   - Readahead to get sigtype on verify, as we need the hash type
   - Enum for content type
   - Add unknown content type, make default
   - Fix NPE if private key not found or sign fails
   - Store generated keys in keystore, and get private key from keystore
     for signing, in Java format
   - Use Java keys to sign and verify so we don't
     lose the key parameters in the conversion to I2P keys
   - Type checking of Java private key vs. type when signing
   - Use certs instead of public keys for verification
   - Fix arg processing
   - Improve validate-without-extract
   - New extract command
   - Change static fields to avoid early context init
   - Reduce PRNG buffer size for faster signing
 * Update: Preliminary work for su3 router updates:
   - New ROUTER_SIGNED_SU3 UpdateType
   - Add support for torrent and HTTP
   - Refactor UpdateRunners to return actual UpdateType
   - Deal with signed/su3 conflicts
   - Verify and extract su3 files.
   - Stub out support for clearnet su3 updating
   - New config for proxying news, separate from proxying update
   - PartialEepGet and SSLEepGet tweaks to support clearnet update
   - Remove proxy, key, and url config from /configupdate
   - More URI checks in UpdateRunner
   - Add https support for news fetch
   - Add su3 mime type
   - Reset found version in update loop so we don't fetch from
     the next host too.
   - Prevent NPE on version after SSL fetch
2013-10-06 17:09:56 +00:00
zzz
a1c8e3eae3 reduce search limit 2013-10-06 17:08:51 +00:00
zzz
aa171bbaa6 less scary message 2013-10-06 17:07:56 +00:00
zzz
845b70fe0c add missing sidebar 2013-10-06 17:07:27 +00:00
zzz
82b1eb7c18 * Update:
- Check proxy setting before calling runner for method
2013-10-06 16:39:30 +00:00
zzz
4bd27ea1d3 * Update:
- Reset found version in update loop so we don't fetch from
     the next host too.
   - Prevent NPE on version after SSL fetch
   - Fix su3 version check
 * EepGet:
   - Fix non-proxied PartialEepGet
   - Prevent non-proxied eepget for an I2P host
   - Fail if no hostname in URL
2013-10-06 16:02:33 +00:00
zzz
d0f6be3161 fix cert dir 2013-10-06 01:15:40 +00:00
zzz
7764257e41 more synching for coherence 2013-10-06 00:43:12 +00:00
zzz
af0e72ac4d * SSU: More efficient ImboundMessageState
(reduce ByteArray[] size where possible)
2013-10-05 18:38:55 +00:00
zzz
0534440695 - Treat 6bone 3ffe::/16 as local 2013-10-05 14:04:40 +00:00
zzz
c2fa2d0c5b * Logging:
- Require strict match of class name component
   - parseLimits() cleanup
2013-10-05 13:07:33 +00:00
zzz
887017b54c * Transport: Treat more IPs as local
25/8 - Hamachi (moved from 5/8 Nov. 2012)
   2620:9b::/32 - Hamachi
   0::/8 - Includes IPv4 compatibility addresses ::xxxx:xxxx
2013-10-05 12:56:39 +00:00
zzz
3a4f5a2f1b jetty 7.6.13.v20130916 2013-10-04 23:43:38 +00:00
zzz
3fb4643742 - Add https support for news fetch 2013-10-04 20:28:43 +00:00
zzz
a5e3bc9b85 Update:
- New config for proxying news, separate from proxying update
 - Default logic cleanup
2013-10-04 20:21:54 +00:00
zzz
8a0c3f10f4 Update:
- Stub out support for clearnet su3 updating
 - PartialEepGet and SSLEepGet tweaks to support clearnet update
 - Remove proxy, key, and url config from /configupdate
 - More URI checks in UpdateRunner
 - Add su3 mime type
 - Move advanced setting to HelperBase
2013-10-04 19:06:39 +00:00
zzz
e1d808a284 add msg when stopping tunnel on idle 2013-10-04 16:50:37 +00:00
zzz
e755051ebe * i2psnark:
- Add torrent auto-stop support; enable for update file
   - Add tunnel auto-close when no torrents are running
   - Log/msg tweaks on add/create failures
2013-10-04 16:40:14 +00:00
zzz
d7c3ffa4de 0.9.8.1 2013-10-02 14:14:18 +00:00
zzz
cba3b249dd * Startup: Fix rekeying on Windows (tickets #1056, 1057) 2013-10-01 14:22:17 +00:00
zzz
32f250003e NBI: Tweak to prevent early context instantiation 2013-09-30 19:25:21 +00:00
zzz
e004b0e6e9 Build:
- Generate su3 file in release target
  - Add my new RSA 4096 pubkey cert for updates
  - Fix checkcerts.sh
2013-09-30 19:21:25 +00:00
zzz
a5c5917a5f add key length to RSA SigType names 2013-09-30 17:13:35 +00:00
cbd24946b6 refresh patch, en po 2013-09-30 16:33:01 +00:00
zzz
9b4842931a 0.9.8 2013-09-30 12:57:13 +00:00
zzz
e04cf132cc HTTPServer: Log tweak for better diagnosis of delays 2013-09-29 16:40:50 +00:00
zzz
7d237b4cf6 Watchdog: Format messages better 2013-09-29 16:38:57 +00:00
zzz
3cbfd09722 Console: Tag strings on /jobs (ticket #969) 2013-09-29 16:36:32 +00:00
zzz
0ae774dd68 bump for review 2013-09-28 12:00:20 +00:00
zzz
2884df873e * Streaming: Major rework of connection disconnect process. Tickets 1040-1042.
- Prevent multiple calls or reentrancy in disconnect() (ticket #1041)
   - Implement processing of close to skip TIME-WAIT, and
     wait for all packets to be acked (not just the CLOSE) before
     doing so, if possible (ticket #1042)
   - Don't call disconnect() or disconnectComplete() from I2PSocketFull.destroy()
     so retransmissions and acks can still happen (removes some close loops)
   - Don't call disconnect() until we have both sent and received a CLOSE (ticket #1040)
   - Don't reset the connection from CPH just because we sent a CLOSE
     and it was acked (ticket #1040)
   - Ack packets even if we sent a CLOSE  (ticket #1040)
   - Retransmit CLOSE if not acked (ticket #1040)
   - Send received packets to the MessageInputStream even if we haven't received a SYN
   - Don't call MessageInputStream.messageReceived() for ack-only packets, that was pointless
   - Don't send a RESET after timeout of an outbound connection
   - Work around bugs on other end by limiting retransmission of CLOSE packets
   - Make _isInbound final
   - More cleanups, javadocs, log tweaks
2013-09-28 11:47:47 +00:00
d4d1424c4f update debian changelog 2013-09-27 20:15:02 +00:00
33827f9aaf switch from elipsis to three "."s 2013-09-27 20:14:36 +00:00
zzz
30a666c833 Streaming: Don't queue a message for an unknown connection on the SYN queue
if it has a send ID set, it must be for a recently closed connection
2013-09-27 01:50:38 +00:00
zzz
9a00621fa4 log tweaks 2013-09-27 01:48:12 +00:00
46bc479884 update geoip based on Maxmind GeoLite Country database from 2013-09-03 2013-09-26 21:47:53 +00:00
6ab6abf4dd French, German, Russian, and Swedish translation updates from Transifex 2013-09-26 21:47:06 +00:00
zzz
0c6a9ff2a0 proof delimiter tweak 2013-09-25 23:13:42 +00:00
zzz
aefc5b5317 javadoc fix 2013-09-25 17:42:37 +00:00
zzz
25682fdea7 log tweaks, javadoc 2013-09-25 17:42:13 +00:00
zzz
9318099845 * Streaming:
- Cleanups
   - Remove setCloseReceivedOn(), unused outside Connection
   - OR the isFlagSet parameter instead of multiple calls
   - Remove acked packets from _outboundPackets inside synced iterator
   - Short-circuit _outboundPackets iterator if empty
   - Small optimization if not logging in ConnectionPacketHandler
   - Stub out processing of close ack (ticket #1042)
2013-09-24 16:01:20 +00:00
zzz
fdf38a952d atomic default value cleanup 2013-09-24 14:45:30 +00:00
zzz
fb40ab1f00 * Streaming: Atomics for close/reset send/receive
so we only do things once. (Ticket #1041)
2013-09-24 14:01:48 +00:00
zzz
3499ed7bb0 * Streaming: Consolidate scheduling of DisconnectEvent, and ensure
we only do it once. (Ticket #1041)
2013-09-24 13:22:46 +00:00
zzz
b05906a3c2 SigType: Renumber, comment out all the types that are
too short or for testing. Turn off debug logging.
2013-09-24 12:55:22 +00:00
zzz
61d5f46295 * Streaming: Fix active stream counting so it doesn't count streams
that are closed and in TIME-WAIT state. Also, break out of the
   counting loop as soon as we know the answer. (Ticket #1039)
2013-09-24 12:40:35 +00:00
zzz
9ebfccd8f6 * Console: Add /proof page which can copied to prove you run a router 2013-09-23 16:39:40 +00:00
zzz
4fb3e86e4d Truncate and linkify magnet link in summary bar update message 2013-09-23 12:13:44 +00:00
zzz
837517e94e Update: Verify and extract su3 files.
untested...
2013-09-22 19:19:36 +00:00
zzz
f47ec65b8f Update: Preliminary work for su3 router updates:
- new ROUTER_SIGNED_SU3 UpdateType
   - Add support for torrent and HTTP
   - Refactor UpdateRunners to return actual UpdateType
   - Deal with signed/su3 conflicts
   - unpack/verify stubbed only
2013-09-22 18:03:56 +00:00
zzz
6fede7f524 log tweaks 2013-09-22 14:13:50 +00:00
zzz
bd0c18b2e3 * Console: Implement webapp state detection and stop button for webapps
on /configclients (Ticket #1025)
2013-09-21 16:11:55 +00:00
zzz
fba596c78c geoipv6 Sept 19 2013 from Maxmind 2013-09-21 12:30:06 +00:00
61f2b49022 another extraneous script name 2013-09-20 23:09:27 +00:00
e71a1a5c4d remove extraneous script name 2013-09-20 23:07:11 +00:00
683ce3254f testscripts build target: check shell scripts for validity
(also adding missing shebang lines)
2013-09-20 22:32:05 +00:00
df555731c4 minor script changes
- mbuild.sh: don't require bash
- Slackware/i2p/doinst.sh: add bash shebang
2013-09-20 22:17:48 +00:00
641fc0cae9 fix langbox alignment, bump build number 2013-09-20 21:06:57 +00:00
5ab1d6896a jbigi scripts: look in /usr/local (for *BSD) 2013-09-20 19:39:25 +00:00
zzz
0ae2d92fcd * Update: Support notification of updates that cannot be downloaded
due to "constraints". Add constraint checks for java version,
   router version, configuration, and base permissions. (ticket #1024)
2013-09-20 18:56:54 +00:00
zzz
26c8201e03 spellcheck off 2013-09-20 18:42:51 +00:00
37521c69a2 look for openjdk6 in OpenBSD if v7 isn't available 2013-09-20 18:33:11 +00:00
43383a5b3c changes to fix compilation on OpenBSD 2013-09-20 10:44:56 +00:00
bfea3e4dd6 translation updates from Transifex 2013-09-20 10:43:13 +00:00
35b02a52e1 redirect output of which command to /dev/null 2013-09-20 02:00:41 +00:00
8e3e566915 typo fix 2013-09-20 01:45:09 +00:00
968b9a0304 fix previous check-in 2013-09-20 01:38:20 +00:00
c97f0f3d22 OpenBSD compilation fix: set JAVAC in bundle targets if javac not found and require.gettext is set to true
This solves the following problem which was found on OpenBSD:

bundle:
     [exec] Generating net.i2p.desktopgui.messages_ar ResourceBundle...
     [exec] ERROR - msgfmt failed on locale/messages_ar.po, not updating translations
     [exec] msgfmt: Java compiler not found, try installing gcj or set $JAVAC
     [exec] msgfmt: compilation of Java class failed, please try --verbose or set $JAVAC
     [exec] 9 translated messages.


In OpenBSD 5.4, neither java nor javac are in the PATH.
2013-09-20 01:21:43 +00:00
65b1124d81 various updates to i2prouter
- check status of i2psvc with ldd
- only warn about libiconv in FreeBSD if the package isn't installed. In recent
  versions of FreeBSD, OpenJDK depends on libiconv so it should always be
  available.
2013-09-19 20:56:56 +00:00
zzz
89034e1f9d SU3File:
- Fix arg processing again
   - Change static fields to avoid early context init
   - Reduce PRNG buffer size for faster signing
2013-09-19 15:21:53 +00:00
zzz
9f2fa6a8be fix arg processing 2013-09-19 13:59:39 +00:00
zzz
19cf8787d8 - Allow getRawAlgo() for public keys
- SU3File better arg processing, implement content type arg
   - Type checking of Java private key vs. type when signing
   - Add unknown content type, make default
2013-09-18 16:53:38 +00:00
zzz
a80c34c1df * i2psnark:
- Refactor Storage file data structures
   - Sort files when creating torrents
2013-09-18 15:41:10 +00:00
zzz
ab8900f910 * I2PTunnelHTTPServer: Don't thread a receiver for GET or HEAD 2013-09-18 15:39:12 +00:00
zzz
ce2d0b0e12 - Revert expl. default back to 2 hops, wait for next release
- Eepsite index.html better help on redirects
   - Remove exotrack (again)
2013-09-17 13:53:20 +00:00
zzz
87d98781a9 Read back private key to verify after keygen
Validate cert after reading from file
   Validate CN in cert
   Javadoc fixes
2013-09-16 15:48:54 +00:00
zzz
79dc95dd66 Fix RSA_SHA384
Fix DSAEngine for RSA
   Fix KeyGenerator for RSA
   New split() and combine() methods in SigUtil
   Fix private key conversions for RSA
2013-09-15 16:49:59 +00:00
zzz
c6533202f7 Add RSAConstants
Specify RSA parameters
  Add RSA sig types
  Specify cert signature algorithm when generating keys
  Extend keygen max wait
  Catch NPE if sign fails in SU3File
  Fix signature conversion for RSA
  Fix public key conversion for RSA
2013-09-15 15:12:07 +00:00
zzz
b5dc9bc0ba DSAEngine: Add sign/verify methods using Java keys
SU3File: Use Java keys to sign and verify so we don't
           lose the key parameters in the conversion to I2P keys
2013-09-14 15:53:08 +00:00
zzz
79891c6677 open4you.i2p 2013-09-14 15:28:36 +00:00
zzz
68aa1aea8e stub out RSA 2013-09-13 15:26:38 +00:00
zzz
4ffaf4128e SU3File:
- enum for content type
  - fix NPE if private key not found
  - use certs instead of public keys for verification
  - improve validate-without-extract
  - new extract command
2013-09-13 13:02:37 +00:00
zzz
801ca47a0c add Koblitz curves for testing 2013-09-13 00:49:10 +00:00
zzz
43f5062169 SSLEepGet: Move all certificates to certificates/ssl, in preparation
for other certificate uses by SU3File
2013-09-12 21:47:25 +00:00
zzz
7ab4dd7f4b KeyStoreUtil:
- Overwrite check in createKeys()
  - New getCert(), getKey()
  SU3File:
  - Store generated keys in keystore
  - Get private key for signing from keystore
2013-09-12 20:22:30 +00:00
zzz
71c0104236 Add base algorithm type in prep for RSA 2013-09-12 18:23:28 +00:00
zzz
a608d21571 KeyStore: change keygen default to RSA 2048 (ticket #1017)
fix key length setting
2013-09-12 14:55:16 +00:00
zzz
935ddaa0b2 fix default expiration 2013-09-12 14:41:25 +00:00
zzz
945e7b75fd Crypto - prep for using certificates in SU3File:
Consolidate KeyStore code from SSLEepGet, I2CPSSLSocketFactory,
  SSLClientListenerRunner, and RouterConsoleRunner into new
  KeyStoreUtil and CertUtil classes in net.i2p.crypto (ticket #744)
2013-09-12 14:27:16 +00:00
5e90780590 jbigi/jcpuid build scripts: Look for OpenJDK7 in kFreeBSD (it has landed in Debian testing) 2013-09-11 14:04:58 +00:00
zzz
a8a21ea7ce propagate from branch 'i2p.i2p' (head 6667c4a9f9fcc0705e407006d1933dd31942ffb2)
to branch 'i2p.i2p.zzz.ecdsa' (head bf746450400fc5ffa0e727ed0cd6a3966f6ce51f)
2013-09-10 13:03:40 +00:00
zzz
23444e4b81 * Router: Log new router hash in event log after rekeying 2013-09-10 12:25:24 +00:00
zzz
a3ea1f9429 remove static log 2013-09-10 12:23:45 +00:00
zzz
78d4b6d8a7 - Simple DirKeyRing backend for testing 2013-09-09 19:46:24 +00:00
zzz
3e3399adc6 - Add Java key import to SigUtil
- Import priv key to SU3File in Java encoded format instead of I2P format
  - New KeyRing stub
2013-09-09 00:49:14 +00:00
zzz
1e554dd0fe - Move I2P-to-Java DSA key conversion from DSAEngine to SigUtil
- Add Java-to-I2P DSA key conversion to SigUtil
  - Export keys from SU3File in Java encoded format instead of I2P format
2013-09-08 21:47:48 +00:00
388e7088e1 Updating cert for reseed.info 2013-09-08 16:14:53 +00:00
e65289cd0d Document logCloseLoop() methods 2013-09-08 15:23:09 +00:00
c4d68a8352 minor cleanup 2013-09-08 15:21:25 +00:00
7be0a93251 Use AtomicBoolean to prevent multiple close()-s 2013-09-08 13:18:47 +00:00
175f47293a Ticket #1012 - remove nested locking on close() and
finishInboundEstablishment()
2013-09-08 13:13:14 +00:00
zzz
27936fce04 cache key conversion 2013-09-08 13:06:30 +00:00
592680302f make the logCloseLoop() methods members of the Log class
so they can be used everywhere
2013-09-08 12:55:05 +00:00
zzz
55318cf14b Crypto: Set file modes on written keys; don't overwrite existing files 2013-09-08 11:57:15 +00:00
zzz
83ead0c304 - SU3File: Readahead to get sigtype on verify, as we need the hash type 2013-09-07 20:24:40 +00:00
zzz
38ec55bc72 - DSAEngine: Implement raw ECDSA sign/verify
- SU3File: Implement keygen
2013-09-07 19:37:02 +00:00
zzz
c4f97ed65e - DSAEngine: Start of support for signing hashes with other SigTypes
- KeyGenerator: Measure sign and verify separately in test
 - SU3File: Start to support other SigTypes
 - SigType: Add getHashInstance(), fix hash length for ECDSA_SHA256_P192
 - SHA1Hash: Add no-arg constructor
2013-09-07 18:12:19 +00:00
zzz
78a426e9ac * Crypto: Don't use "short exponent" on faster platforms.
Rebuild router identity if key length doesn't match setting.
   This affects RI and LS encryption keys, and DH and YK.
   Faster = 64 bit with working jbigi, non-ARM, non-GNU (for now)
   Override default with crypto.elGamal.useLongKey=true/false
   LS key is built at client startup (Dest key unused)
   This will churn most of the RIs at the release.
 * SystemVersion: Add isARM()
2013-09-07 13:43:28 +00:00
zzz
928b4bbbe5 - genSpec: fallback to BC provider 2013-09-06 13:53:15 +00:00
zzz
d27c465371 - KeyPairGen: Catch ProviderException, fallback to BC provider 2013-09-06 13:30:47 +00:00
zzz
4d62f63c71 * Start of ECDSA branch:
- Add ECConstants which looks for named curves and falls back to
     explicitly defining the curves
   - Add SigUtil with converters from Java formats (ASN.1, X.509,
     PKCS#8) to I2P formats for Signatures and SigningKeys
   - Move ASN.1 converter from DSAEngine to SigUtil, generalize
     for variable length, add support for longer sequences,
     add more sanity checks, add more exceptions
   - Attempt to add BC as a Provider
   - Add parameters (curve specs) to SigTypes
   - Add support for ECDSA to DSAEngine and KeyGenerator
   - Add KeyGenerator main() tests
   - More javadocs

  All is Java 1.5 compatible but the actual algorithms, curves,
  and other support aren't necessarily present in any JVM.
  Todo: More tests, more fallbacks for various JVMs
2013-09-06 12:04:22 +00:00
zzz
f4039b085a * Crypto: SigType tweaks, prep for parameters, show type in toString()
* NativeBigInteger: Don't use native for negative arguments, which aren't supported in jbigi.c
2013-09-06 11:40:50 +00:00
53ed10cfc8 typo fix (s/lt/le/) 2013-09-04 01:42:12 +00:00
zzz
0859dbe57f * i2ptunnel: Reduce buffer size and use cache in HTTPServer
* Jetty: Increase maxIdleTime
2013-09-04 00:46:43 +00:00
zzz
42bc4bb1f4 reduce log level 2013-09-03 12:13:07 +00:00
zzz
caead8a3a4 consolidate maxMemory() calls 2013-09-03 11:37:36 +00:00
zzz
7394c7997b change pw restart warning to error so people dont miss it 2013-09-03 10:25:18 +00:00
zzz
0298e4ab4c use different sort for floodfill profiles display 2013-09-01 12:12:40 +00:00
zzz
e3a5cdbbc2 deprecate most of LeaseSetKeys 2013-09-01 12:12:05 +00:00
6ae46abac0 fix ticket number 2013-08-31 18:42:07 +00:00
615a5f3c39 update history 2013-08-31 18:40:39 +00:00
6812dc1db8 Ticket #1007 use only non-retransmitted packets in RTT
sampling.  (RFC 6298)
2013-08-31 18:39:29 +00:00
zzz
41595cafce * Addressbook: Don't write to log file on Android (ticket #859) 2013-08-31 15:35:57 +00:00
zzz
d6c4e411be highlight snark table rows on hover 2013-08-31 15:19:00 +00:00
zzz
6ca797ec1f * Console: Display "accepting tunnels" instead of "rejecting tunnels" after 20 minutes (ticket #902) 2013-08-30 12:07:42 +00:00
zzz
8655988c66 * NTCP: Handle race where peer's NTCP address goes away 2013-08-30 12:01:51 +00:00
zzz
de5f2940ce * SSU, confignet: Add support for specifiying multiple addresses 2013-08-30 10:27:22 +00:00
zzz
1933e6239b * SusiDNS: Don't require last subscription to be terminated by newline (ticket #1000) 2013-08-30 10:21:57 +00:00
zzz
8aec1e2eb6 * Addresses: Treat Teredo addresses 2001:0::/32 as local 2013-08-30 10:20:43 +00:00
def30c5903 javadoc update 2013-08-14 20:29:40 +00:00
193f0bbc42 More elegant 2013-08-11 20:21:06 +00:00
b7a3b7bf05 debian: add missing timestamp to changelog 2013-08-11 17:00:26 +00:00
a2bd45fa9b * Translation updates from Transifex
- French, Portugeuse, Russian, Spanish, and Turkish updates from Transifex
   - Start of Romanian translation from Transifex
   - Update English POs for sending to TX
 * Debian: Update changelog
2013-08-11 16:58:19 +00:00
fd297118f9 fix NPE if stats are not enabled 2013-08-11 11:58:51 +00:00
zzz
7171edad24 Jetty 7.6.12.v20130726 2013-08-11 11:28:33 +00:00
zzz
d8466333f3 more snark mime types 2013-08-11 11:26:57 +00:00
zzz
a5e4d586eb dont display jump server msg if we dont know any 2013-08-11 11:26:40 +00:00
28a1c22438 Update Java Service Wrapper to v3.5.20
- Windows: Self-compiled with VS2010 in Windows 7. The icon has been
      changed from Tanuki's default to Itoopie.
    - Linux ARMv6: Compiled on a RaspberryPi using gcc 4.6.3-14+rpi1,
      Icedtea6 6b27-1.12.5-1+rpi1 and stripped
    - All other binaries are from the "community edition" deltapack offered by
      Tanuki.
2013-08-11 01:26:19 +00:00
74e238322d bump version for testing 2013-08-10 21:53:47 +00:00
1f3227409b Reduce initial ack delay to 1000
Rework the logic for acking duplicate packets
2013-08-10 21:03:05 +00:00
afda1da9c3 volatile 2013-08-10 21:00:09 +00:00
zzz
f2857e8f97 bump after prop 2013-08-10 17:16:50 +00:00
zzz
4802b1e2cd propagate from branch 'i2p.i2p.0971' (head 6cb629b61e0177deda1e539b2f85a2473f3af7fb)
to branch 'i2p.i2p' (head 8e86ef70afbbbbdc2db06cec34f17dedd528c7e7)
2013-08-10 17:06:17 +00:00
zzz
0328304f04 dont specify i2p.i2p branch so we can release from a different branch 2013-08-10 16:23:23 +00:00
zzz
06d2db0046 0.9.7.1 2013-08-10 16:00:46 +00:00
0539610219 volatile 2013-08-09 21:06:39 +00:00
zzz
170be8f033 Extend IB tunnel expiration
applied changes from 2f2fc980d396aa295ce972afc4298e8f2e763fea
             through c2bc3b29484ec8a689c72f2ab4e823a2a72f6430

New update hosts, thx Meeh and dg
2013-08-08 22:13:38 +00:00
zzz
ca0bb1ab76 Plucks from trunk for 0.9.7.1:
Streaming RTO changes:
 apps/streaming/java/src/net/i2p/client/streaming/ConnectionOptions.java
 apps/streaming/java/src/net/i2p/client/streaming/TCBShare.java
 apps/ministreaming/java/src/net/i2p/client/streaming/I2PSocketOptionsImpl.java

new reseed:
 applied changes from dbfea0ca35dbf9df85b5703db6f97a9579beb364
             through 325a9ed6f0f47eeabb33710073edf973671c63c9

disable RI verifies:
 applied changes from 4ef48b93946923e3371ab62719a474d869520697
             through a77990850b3534101571c88db4704676645914df

i2prouter bashism fix:
 applied changes from b5a0148f96728466561ece9be0e50ac9ad3f1468
             through e301d0499f4c688ed3a5febe30bf8098c7f2cdf9

i2psnark increase max piece size, mime type updates:
 apps/i2psnark/java/src/org/klomp/snark/Storage.java
 apps/i2psnark/java/src/org/klomp/snark/web/I2PSnarkServlet.java
 apps/i2psnark/mime.properties

UPnP fix:
 applied changes from 3d4a5cd3d933f75fdff7696f560c569f4674bd73
             through 75e5f5d4e0f0dd44140908bb6e73830e3448bdde
2013-08-08 12:07:16 +00:00
zzz
cdccb51456 * Start of 0.9.7.1 branch
* i2psnark: Increase update-via-torrent to 30%
2013-08-07 17:36:55 +00:00
870ecb847f Updated Eclipse files 2013-08-04 00:02:22 +00:00
8ba493c60e debian: compress package with xz
All currently supported distros support this format.
2013-08-01 23:29:34 +00:00
f3affff5be Atomic 2013-07-31 16:01:26 +00:00
zzz
5941a52a0d * Tunnels: Extend local expiration of IB tunnels, to allow for
more clock skew and not drop valid messages at their destination
2013-07-30 22:10:02 +00:00
zzz
04e6beb43c javadoc, log, comment, and su3file help tweaks 2013-07-30 22:05:46 +00:00
zzz
1284c7ace0 * i2psnark: Increase max piece size to 4 MB (ticket #993) 2013-07-30 21:50:07 +00:00
63414f0348 Override prepareOutbound() in VerifiedEstablishState 2013-07-30 17:13:34 +00:00
c8f22fdfd0 Adding new reseed host. Thanks to isdf! 2013-07-29 23:01:04 +00:00
zzz
7737bf5212 * GeoIPv6: Fix NPE (ticket #992) 2013-07-29 14:02:08 +00:00
zzz
4340f70d72 * Signatures:
- Prep for new signature algorithms; new SigType enum;
     Signature, SigningPublicKey, SigningPrivateKey store type
   - New Hash384 and Hash512 classes
   - Remove length field in SimpleDataStructure
   - New SU3File generator/verifier/extractor
2013-07-29 13:49:05 +00:00
zzz
6dbd8a6d1a add mobi mime type 2013-07-28 13:21:01 +00:00
zzz
076871fe44 * NetDB: Disable RI verifies for now 2013-07-28 13:02:12 +00:00
zzz
be753d7a1a * Addresses: Treat RFC 4193 addresses fc00::/7 as local 2013-07-28 12:52:41 +00:00
zzz
e3f02553fd javadoc 2013-07-28 12:52:10 +00:00
zzz
767ef8c489 add webm mime type 2013-07-28 12:52:00 +00:00
zzz
482787fbc3 * Transports:
- Really fix IPv6-only option
   - Treat RFC 4193 addresses fc00::/7 as local
   - Log tweaks, javadocs
2013-07-26 22:39:35 +00:00
b2d72f90ce merge of '5ad8235a14f2f52799755969e5c877f4f1c159cc'
and 'f5d75b2ebc648c43182d685f30e96242e43caa69'
2013-07-25 20:08:31 +00:00
dd181a90e1 Fix NPE when cancelling PacketLocal's 2013-07-25 20:07:12 +00:00
zzz
19faa352e3 * Transports:
- Prefer IPv6 by default
   - Fix IPv6-only option
   - Don't try NTCP IPv6 addresses unless we have one
   - Fix non-%16 SSU padding in data and session confirmed packets; enable by default
   - Log tweaks
2013-07-25 18:52:45 +00:00
zzz
ffda7f6326 * Tunnels:
- Make expl. default 3 hops  (ticket #966)
   - Allow expl. fallback up to -2 hops
2013-07-25 18:49:22 +00:00
zzz
8ebacf4c10 log tweak 2013-07-25 18:47:47 +00:00
zzz
a02cc25844 UPnP Fix for devices that return base URLs with trailing '/' (ticket #986) 2013-07-24 18:03:50 +00:00
zzz
8aeca5b433 catch NPE in main when no state table available 2013-07-24 14:24:29 +00:00
zzz
7b4855d7cf * UPnP: main() tweaks for debugging 2013-07-24 12:38:15 +00:00
zzz
803d7ff282 * GeoIP: Fix lookups, broken in IPv6 branch 2013-07-24 12:36:36 +00:00
a1c724f866 reduce initialRTO to 9000 2013-07-23 14:18:51 +00:00
96609e9173 change default loglevel for duplicate close()s to INFO 2013-07-23 14:17:26 +00:00
zzz
f5518739e2 javadoc fixes 2013-07-23 00:49:37 +00:00
zzz
e7c8d28b99 * HashComparator:
- Don't pollute Hash cache with hashes
   - cleanups, less object churn
2013-07-22 23:07:37 +00:00
zzz
dff357a658 unit test compile fix 2013-07-22 15:14:58 +00:00
zzz
cc271de7df * BuildReplyHandler:
- Make non-static
   - Don't pollute Hash cache with build response record hashes
   - Use SimpleByteCache
   - cleanups
2013-07-22 14:25:30 +00:00
zzz
a7485ab5a3 * I2CP:
- Oops, must enforce property length limits even when inside router JVM
     as the properties are serialized for signing.
2013-07-21 20:17:42 +00:00
7133736702 Fix more NPEs ticket #984 2013-07-21 19:41:48 +00:00
2313d82369 toclet #984 : fix deadlock introduced in -4 (ticket #972) 2013-07-21 14:54:36 +00:00
zzz
1b42d99e66 * Console: Fix /peers table summary alignment
* I2CP:
   - Don't NPE when loglevel=warn
   - Don't enforce property length limits when inside router JVM
 * I2PSnark: Log uncaught error in ThreadedStarter to router log
 * I2PThread: Log uncaught error to wrapper log
2013-07-21 14:04:27 +00:00
d709f46183 Update unit test 2013-07-20 18:45:19 +00:00
97c1676bcb Rework locking and state management of NTCP connections
trac ticket #972
	up version to -4
2013-07-20 17:37:46 +00:00
zzz
02b92ac3fe fix compile for test 2013-07-20 13:46:50 +00:00
zzz
29eb1d5dc5 fixup after prop; history for prop; -3 2013-07-20 13:41:31 +00:00
zzz
a87fc68cfd propagate from branch 'i2p.i2p.zzz.ipv6' (head 5c147c6e394fae03752dcf497923a90e3f2db529)
to branch 'i2p.i2p' (head 7af6987d5546664f76589afe0cbeeb780f4b5d58)
2013-07-20 12:59:03 +00:00
zzz
bc1cf64df4 remove extra 2013-07-20 12:35:38 +00:00
zzz
b607d7b223 generic 2013-07-20 12:34:24 +00:00
zzz
4e00eaf9a3 checkpo fix; history for prop; -2 2013-07-20 12:25:31 +00:00
zzz
90cc71d14d propagate from branch 'i2p.i2p.zzz.test2' (head d80f8632ef0a2aa350eee9a38ba6a4c56471f5bc)
to branch 'i2p.i2p' (head e8b712c826e44211217f06eb3a4da2703323a42f)
2013-07-20 11:53:41 +00:00
zzz
554a3a6b0e * PRNG:
- Don't delay the refiller if we need more (don't limit max output)
   - Add FortunaRandomSource.main() to output to stdout for testing e.g. with dieharder
2013-07-19 21:31:25 +00:00
zzz
8505e8a1ca fix streaming property 2013-07-19 21:28:14 +00:00
54ec878698 merge of '90720c051863f44c6386493f3d5df546d988a663'
and 'fa509893effa9445a0833115160aed8fe6fed268'
2013-07-19 00:18:08 +00:00
ea4606fe79 Prepare for merge 2013-07-18 22:45:11 +00:00
96de87fdde compute rttDev in updateRTT 2013-07-18 22:33:23 +00:00
55d571ffec Hardcode TCP constants
Various suggestions by zzz
2013-07-18 22:25:10 +00:00
ae347c4fa1 sync getters 2013-07-18 15:52:40 +00:00
e93beb7c63 Updated .mtn-ignore 2013-07-18 13:48:36 +00:00
018098b8ef better loading from cache 2013-07-18 01:52:46 +00:00
1e2fb4bea5 propagate from branch 'i2p.i2p' (head e301d0499f4c688ed3a5febe30bf8098c7f2cdf9)
to branch 'i2p.i2p.979' (head 2dfdeb022c9495461b2ec1d90f28ef9cd0bd9e22)
2013-07-17 23:04:04 +00:00
171f0d2671 Implement RTT update on first ack 2013-07-17 21:13:19 +00:00
175cb0817e fix bashim in i2prouter 2013-07-17 19:45:43 +00:00
zzz
3b46acc285 * I2CP client session - improvements after review:
- Move more cleanups to finally block
   - Bounded wait
   - Don't ignore InterruptedExceptions, wrap in I2PSessionException and throw
   - More finals
   - Synch tweaks
2013-07-17 18:56:26 +00:00
zzz
d31ce49e77 change resource name 2013-07-17 18:55:12 +00:00
8937c4bf2a Store stdev of rtt in the TCB cache as per RFC 2140 2013-07-17 18:13:42 +00:00
2902a708f9 debian updates
- check script validity in build target
- refresh patch
- changelog update
2013-07-16 22:17:50 +00:00
zzz
20e152e79a 0.9.7 2013-07-15 14:15:43 +00:00
zzz
c1210b1c04 * Translations:
- Tag initialNews.xml for TranslateReader
   - Drop static translated initialNews pages
   - Add new routerconsole bundle for the news alone, shipped in the jar
   - Use TranslateReader in HTTP proxy for initial news
   - Initial translations created manually from translated xml filesx
   - Add translated proxy error pages and initial news to deletelist.txt
   TODO: ar translation fails checkpo.sh
2013-07-13 23:38:11 +00:00
zzz
71038c311f * Translations:
- New varargs method in Translate
   - New TranslateReader to translate static files on-the-fly using _("") tagging
   - Tag proxy error pages for TranslateReader
   - Drop static translated proxy error pages
   - Add new i2ptunnel bundle for the proxy alone, shipped in the jar
   - Use TranslateReader in HTTP proxy for error pages
   - Move HTTP proxy strings from the web *war) to proxy (jar) bundle so they will be loaded
   - Initial translations created by msgmerge from i2ptunnel and routerconsole po files, un-fuzzied
2013-07-13 19:58:11 +00:00
zzz
1cf9ae381d bump for review 2013-07-13 18:23:09 +00:00
4cb5a27a05 geoip update from 02-JUL-13 2013-07-11 21:52:00 +00:00
b0b0124138 Chinese, Russian, Spanish, and Turkish language updates from Transifex 2013-07-11 21:48:05 +00:00
9e12801503 susimail: Improvements to layout in mobile browsers 2013-07-11 00:19:31 +00:00
zzz
70a8ab1d1a * DHSessionKeyBuilder: Fix for session and mac keys if DH key is between 32 and 63 bytes.
Was: NPE. Now: mac key is hash of ssession key. Won't ever happen. (Ticket #963)
   javadocs
2013-07-10 18:59:46 +00:00
zzz
f3c4a26483 * I2CP/I2PTunnel locking fixes (partial fixes for tickets 650. 815, 946, 947, 953):
- I2PSocketManagerFactory: New createDisconnectedManager(), javadocs
   - I2PSessionImpl: Rewrite state management and locking, prevent multiple
     connect() calls, but allow disconnect() to interrupt connect()
   - I2PSimpleSession: Changes to match I2PSessionImpl
   - I2PTunnelServer: Don't connect in constructor, use createDisconnectedManager()
     for a final manager, finals and cleanups
   Lightly tested.
   Todo: I2PTunnelClientBase
2013-07-10 18:54:25 +00:00
zzz
9a1e1a92ca dont use == on doubles 2013-07-10 18:42:13 +00:00
zzz
732eddd1b9 toString() fix (NO_ACK) 2013-07-10 18:14:18 +00:00
zzz
2caa6ad975 * Router I2CP:
- Make classes extensible for router-side test stubs
   - Add router-side local-only test implementation, no full router required.
     Only tested with external clients, probably doesn't work in-JVM.
   - Don't start threads in ClientManager constructor
   - Remove unused Reader param in ClientMessageEventListener methods
   - Cleanups, volatiles, finals, javadocs
2013-07-10 18:12:47 +00:00
zzz
d3e0161a6b * Transports: Consolidate translation methods in super,
ngettext fix for "peers" string
2013-07-10 17:59:10 +00:00
67859f67b0 Make activeResends field atomic 2013-07-09 13:55:09 +00:00
b486ae5c26 bump for moar testin' 2013-07-07 20:13:42 +00:00
aab4a3ab44 Change criteria for resending on NACK to match comment 2013-07-07 20:13:11 +00:00
e9e550fb55 cleanup, sync, more logging 2013-07-07 19:15:08 +00:00
f80ea386a0 Log errors to logger if available 2013-07-07 17:20:06 +00:00
7429762d2e bump i2prouter-script version 2013-07-06 23:30:25 +00:00
zzz
aabbdc1c1b Hopefully fix SSU NPE (ticket #967) 2013-07-06 13:25:11 +00:00
zzz
3af766bd6e * TunnelPool: Don't reuse peers for exploratory tunnels 2013-07-06 13:18:19 +00:00
614b8b4cdd Russian and Portuguese translation updates 2013-07-05 22:42:34 +00:00
bec62c1be7 Remove unused field
Use atomics to manage closed state and IOExceptions
2013-07-05 19:48:31 +00:00
7f8efca0ba minor cleanup, more to follow 2013-07-05 19:05:54 +00:00
76de4faf62 better sync 2013-07-05 18:29:00 +00:00
dfc4948a6f cleanup & sync 2013-07-05 18:21:42 +00:00
ba0e58e66a fix compilation 2013-07-05 12:53:13 +00:00
18531f0c09 Log close() loops 2013-07-05 12:43:58 +00:00
93df048bd6 Cleanups, make I2PSocket a Closeable 2013-07-05 11:54:18 +00:00
2927382a2b refresh patch 2013-07-04 17:01:42 +00:00
b4780d16eb updated en (before pushing to tx) & ru (pulled from tx) pofiles 2013-07-04 16:52:00 +00:00
zzz
6f5f4d179b * Streaming:
- Don't stop timers when session disconnects (tickets #644, #810)
   - Throw exception on attempt to use destroyed socket manager
   - Clear TCBShare cache when stopped
   - Javadocs
2013-07-04 14:54:46 +00:00
zzz
b9a5dd48f6 Console: Hide dead tunnel pools on /tunnels 2013-07-03 19:14:21 +00:00
zzz
0db7e2873c * Updater: Fix plugin update checker (ticket #897)
* Utils: Reduce logging in wrapper log when extracting zip files
2013-07-03 17:12:32 +00:00
zzz
b84bfd575f bump 2013-07-03 12:44:19 +00:00
70bb81bcc3 merge of '3dbb3a0ff30032f71e1ef6dd6d90f3b8117f3cd1'
and 'ccdac8f0911b798c42e9079d47e07c0e7c652815'
2013-07-02 20:08:28 +00:00
7ebb26b734 refresh patch
This change is required after de-parameterizing the i2prouter script.  I
hardcoded the file name because the $0 variable isn't expanded (because of
single quotes). When using double-quotes (and escaping with back-slashes), the
strings weren't translated. I've decided to de-parameterize until I figure out
what the problem is.
2013-07-02 18:38:35 +00:00
fb93609d8b merge of '7d480c0749394d3ee1b10c1f714a1be3091596f8'
and '9cb464ed9b358b1e9807792b37f703977d6f5f96'
2013-07-02 18:17:02 +00:00
eb051d64c7 disapproval of revision 'fd10b04ca3a6cf66e669bfad32d3011ed9f7e33c' 2013-07-02 18:08:52 +00:00
58bb94a960 French, German, Portuguese, Russian, and Turkish translation updates from transifex 2013-07-02 17:41:27 +00:00
98d932a0f5 build.xml: minor tweak for jenkins
Jenkins' cobertura plugin wasn't finding the streaming source. This change
should correct that.
2013-07-02 16:58:40 +00:00
zzz
de4b0198b7 javadoc fixes 2013-06-30 17:13:53 +00:00
zzz
570f8526b0 getSession() cannot be null 2013-06-30 17:00:14 +00:00
zzz
d173b79949 drop build request with bad flags 2013-06-30 16:58:57 +00:00
67f73d7198 wip 2013-06-29 21:22:28 +00:00
6e36d374ea wip 2013-06-29 21:12:11 +00:00
740b37b70c wait until client thread finishes before declaring victory 2013-06-29 21:03:19 +00:00
782e38bdcf add TODO, make server thread daemon 2013-06-29 21:02:30 +00:00
937404b39c test seems to be hopelessly out of date 2013-06-29 20:35:27 +00:00
a0bf223031 return the Thread object for join()-ing 2013-06-29 20:34:57 +00:00
zzz
6b15caab4b drop ancient ministreaming doc 2013-06-29 15:14:04 +00:00
zzz
3aafea0d98 add ipv6 to /confignet 2013-06-29 15:13:05 +00:00
1c68852f45 Finish rename 2013-06-28 22:32:05 +00:00
4f6065b4fa refactoring most tests
remove standalone test from junit wildcard
2013-06-28 22:27:31 +00:00
14944982fb Trying to fix the Jenkins build.. 2013-06-28 20:50:38 +00:00
10bf74e045 add streaming lib tests to the top-level ant targets 2013-06-28 18:48:39 +00:00
a9d9e6b572 work on test 2013-06-28 18:43:36 +00:00
zzz
79f8e88e5f propagate from branch 'i2p.i2p' (head 2a2c708bf9fee43e69469bdf896dfe489c32bdea)
to branch 'i2p.i2p.zzz.ipv6' (head c33552d7026b0a445d1dd7e138bf454144130eb2)
2013-06-28 16:10:49 +00:00
bddfe3ed86 Convert most streaming tests to JUnit4 2013-06-28 16:00:47 +00:00
a308179d81 Fix and junit-ify tests 2013-06-28 15:21:02 +00:00
f8648ff4c4 Explicitly check the type of I2PSocketManager 2013-06-28 14:56:55 +00:00
zzz
552f91b6b8 dont start thread in constructor 2013-06-28 12:40:09 +00:00
zzz
726eb58724 * i2psnark:
- Show comment metadata on details page
   - Fix rar icon
   - Escape [] in URLs, chrome doesn't do it for us
   - Tweak column spacing
2013-06-28 12:19:56 +00:00
zzz
eb5a23fc5b finals, remove static log 2013-06-28 12:17:19 +00:00
zzz
d4c8e03f86 remove static log 2013-06-28 12:12:37 +00:00
zzz
46d13d2b08 divide by zero check 2013-06-28 12:10:34 +00:00
zzz
003dc37817 merge of 'bde6736c06f94ff24285aeff0a64ec7dc3a52a4b'
and 'f4b18bbf4329a48a182a57db594a58d4a32a9da7'
2013-06-28 12:06:22 +00:00
zzz
847a441d59 disapproval of revision '8611baad56e8e18941721b156256783ba996a3cd'
Revert 8611baad56e8e18941721b156256783ba996a3cd
Don't use intern() on externally-supplied strings
as it could be used to exhaust memory
2013-06-28 12:01:13 +00:00
a5f3220df0 merge of '6844f955ddd2febe54ce677ef19309712f55113c'
and '8611baad56e8e18941721b156256783ba996a3cd'
2013-06-27 19:23:54 +00:00
a5df6d419d use String.intern() instead of a homebrew equivalent 2013-06-27 19:04:28 +00:00
78a25f0b17 Updating certificate on 193.150.121.66. Will reload server to use
the new certificate on the next I2P release day.
2013-06-27 18:42:15 +00:00
dc7ea9c126 Removing the self-signed certificate. cowpuncher.drollette.com uses
a certificate signed by GlobalSign now.
2013-06-27 18:29:14 +00:00
70adc4df32 debug log the criteria for FF 2013-06-27 16:16:55 +00:00
c47f491e2f fail if cert expires within 60 days 2013-06-27 09:53:38 +00:00
1d9b89db23 volatiles, generics warning cleanup 2013-06-26 21:38:00 +00:00
ec70f2420c more volatiles 2013-06-26 21:03:18 +00:00
f525685765 volatiles, finals 2013-06-26 20:43:34 +00:00
zzz
4970fd22dc save a little space by avoiding BigInteger when possible 2013-06-23 17:52:36 +00:00
zzz
ac9392b9e6 * i2psnark: When receiving a metainfo via magnet and saving it to disk,
preserve all non-standard fields (such as those created by Robert) so the
   infohash doesn't change on restart, splitting the swarm.
   (http://zzz.i2p/topics/1327 thx 'backup')
2013-06-23 15:21:40 +00:00
zzz
5ba86ca254 * SSU:
- Pad all messages with random data instead of zeros
   - Implement non-mod-16 padding, disabled for now
2013-06-22 19:09:55 +00:00
zzz
87826daae9 mac static, final 2013-06-22 19:02:59 +00:00
7df52a155e Run the FloodfillMonitorJob more frequently 2013-06-22 17:17:17 +00:00
zzz
d2184f418f * NetDB: Increase upper limit on ffs again
* SSU: Pad session created message with random data instead of zeros
2013-06-22 13:51:50 +00:00
f91f81158f * Changing the default connect proxy after h2ik's AWOL. (Last seen 6th March 2013) 2013-06-22 12:05:34 +00:00
zzz
bb100de702 * SSU:
- Ignore padding beyond last multiple of 16 (prep for obfuscation)
  - Comment out xor with 0 (version)
  - Don't need to zero IV buf before overwriting
* AES:
  - Decrypt speedup by XOR in place
  - Log if decrypt not mod 16
2013-06-21 19:21:02 +00:00
zzz
322e76d2a9 speed up XORComparators 2013-06-21 15:13:37 +00:00
zzz
1444f1239f lookup stat tweak 2013-06-21 15:13:16 +00:00
zzz
5bd028bff5 i2psnark: Show start-all button even if tunnel is open,
if at least one torrent is stopped (ticket #808)
2013-06-20 21:21:07 +00:00
25feb745bc Volatil-ize some fields 2013-06-18 17:09:05 +00:00
zzz
7e0654ae0a * I2CP: Don't send SendMessageEndMessages from client to router if
in fast receive mode and the router doesn't require them.
2013-06-17 19:57:59 +00:00
zzz
00d1b7519f * Streaming: Flush debug pcap stream after closing connection 2013-06-17 19:54:22 +00:00
zzz
faadbf700d debug log tweak 2013-06-17 19:53:01 +00:00
zzz
180d42541a * NetDB:
- Don't instantiate unused success job for republish LS
   - Add debug setting to encrypt RI lookups
2013-06-17 19:47:04 +00:00
zzz
bdc4eff1c4 * NTCP: Extend interval for sending time sync messages,
might help expire idle conns
2013-06-17 19:45:46 +00:00
zzz
fa0b52fc3a * Console: Don't display 'unsupported' message on some config pages when restart/shutdown buttons clicked 2013-06-17 19:43:32 +00:00
zzz
f9f1391057 * SusiMail: Fix classpath problem when started manually (ticket #957)
- Remove a couple of dependencies
   - Add jetty-util.jar to console classpath just in case
2013-06-17 19:39:21 +00:00
zzz
34b7081303 change congestion cost increment back to 1 for now 2013-06-14 16:13:20 +00:00
zzz
e0cd71069f propagate from branch 'i2p.i2p' (head 1acb4077a56ccb4079538caa28648e27f0bf5b8b)
to branch 'i2p.i2p.zzz.ipv6' (head f87d396c445dc58e677a56d8ed69544c7f5ecab1)
2013-06-14 14:46:08 +00:00
zzz
36e898d668 * I2CP: Fix deserialization of new RVLSM; enable by default 2013-06-14 13:34:36 +00:00
zzz
a90827c9b2 * i2psnark: Fix bug creating torrent with a single file in a directory
(thx oskar/Nightweb)
2013-06-14 13:33:49 +00:00
dd451d3ccd po file fix / add i2prouter script's po files to checkpo.sh 2013-06-14 01:27:58 +00:00
937f4f2f40 parameterize & refresh patch 2013-06-13 18:48:58 +00:00
dev
e7718b1fba Threaded the calling of runRouter() to improve startup times. 2013-06-13 17:02:53 +00:00
dev
29b599bc8d merge of '80aa8cd653ef7ee96cd6603b9646c53b2ff84760'
and 'da25b770e65a36f3056b905cc6b96be431076a6b'
2013-06-13 15:05:54 +00:00
dev
6bbd34eed9 Fixed MultiRouter. Removed MultiRouterBuilder as it no longer serves any purpose. Added the router.rejectStartupTime property to allow for quicker testing with MultiRouter. 2013-06-13 14:38:13 +00:00
f939f689fc fix flag alignment 2013-06-13 01:01:08 +00:00
zzz
a48fba0102 * I2PTunnel: Add advanced quantity options 2013-06-12 15:07:39 +00:00
zzz
02923138d0 boom bye bye bad bwoy 2013-06-12 13:45:27 +00:00
zzz
87d142bace comment out main 2013-06-12 13:44:54 +00:00
zzz
933ad52398 * Console: Add missing jetty jars to classpath (ticket #952)
(tested with classpath from 0.7.4 wrapper.config)
 * JettyStart: ditto
 * Remove references to now-unused jars in build.xml files
2013-06-12 13:42:38 +00:00
9d52ef5fbe Explicit check for empty values 2013-06-11 13:21:49 +00:00
34748d23be Make TUnnelCreatorConfig._expiration volatile 2013-06-11 12:25:00 +00:00
15dae0fd92 *REALLY* add the Turkish language 2013-06-10 22:46:56 +00:00
ccf6cf5e20 TR & FR translation updates from Transifex 2013-06-10 22:22:24 +00:00
zzz
36d4b20bdc * NetDB:
- Let class N routers become floodfill
   - Scale max connections for non-O floodfills
2013-06-10 14:45:45 +00:00
zzz
a70810ffae log tweak 2013-06-10 14:20:33 +00:00
zzz
526df43233 * Transports: Reduce idle timeouts to mitigate conn limit issues 2013-06-10 14:06:43 +00:00
zzz
660be7d579 Installer: Don't install Windows service by default
Causes confusion and multiple instances when users start their own copy too.
2013-06-10 14:04:58 +00:00
zzz
876109d3a5 Fix bug in unused off/len version of siphash 2013-06-10 14:02:39 +00:00
zzz
39493e0f24 final and null check 2013-06-10 14:01:52 +00:00
zzz
62413331da Fix bug in last checkin in unused code
(thx zab)
2013-06-10 14:01:06 +00:00
zzz
68d25afcba * NetDB: Prep for leasesets with different expire times
- Add new I2CP RequestVariableLeaseSetMessage
   - Send RVLSM if client supports it; handle on client side;
     disabled by default for the moment.
   - Add LeaseSet.getLatestLeaseDate()
   - Check latest, not earliest, date too far in future in KNDF.validate()
   - Check latest date too far in past in KNDF.validate()
   - Only check gateway and tunnel ID for equality in OCMOSJ lease caching to reduce churn
   - Split up KNDF.validate(RI) for efficiency, don't need to check
     signature, netid, etc. before lookups, only on store
   - Remove enforeNetID config
   - Fix major bug causing newer leasesets to be treated as older, and not stored or published
   - Increase max adjustment time of earliest lease
   - TransientDataStore cleanups
   - RouterInfo and LeaseSet equals() speedups
2013-06-09 14:42:51 +00:00
zzz
182fe900b8 * BlockfileNamingService:
- Fix bug that kept reverse index from being updated
   - Bump DB version to 3 to trigger repopulation of the reverse index
   - Make metaindex final
   - Add freelist check to the main() test
2013-06-07 17:26:20 +00:00
zzz
0fb4f6ab6a javadocs 2013-06-07 02:03:36 +00:00
zzz
ebc5e72908 remove commented out setter not supported in jetty 7 2013-06-07 02:00:17 +00:00
081b692736 debian: refresh patch 2013-06-06 17:14:44 +00:00
zzz
e1c68d22a3 - Correct errors in the specification of the BuildResponseRecord.
The first 32 bytes are not random; they are the hash of the following 496 bytes.
- Don't waste entropy on bytes we are going to overwrite in the BRR
2013-06-06 15:24:01 +00:00
zzz
b7dc8f425e * DatabaseLookupMessage: Change format for encrypted reply request
to allow multiple bundled reply tags
2013-06-05 16:44:59 +00:00
zzz
4a65676738 throw ISE if LS changed after being signed 2013-06-05 16:39:50 +00:00
zzz
000ca7c7b7 finals, javadoc fixes 2013-06-05 16:36:23 +00:00
zzz
9386270b57 Save I2CP client version for future reference 2013-06-05 16:33:38 +00:00
zzz
f0886c5f6e drop unused netdb classes 2013-06-05 16:29:49 +00:00
zzz
239cd2b744 debug setting 2013-06-05 16:28:54 +00:00
zzz
db9827779e minor improvement 2013-06-05 16:28:10 +00:00
zzz
905eed6643 cleanups 2013-06-05 16:27:29 +00:00
5711d96744 propagate from branch 'i2p.i2p' (head a89e68077114f79902a76649affe78e8ab709787)
to branch 'i2p.i2p.729' (head 11fde36281469d5ac8757bca1d7f93f679e0cb74)
2013-06-02 12:41:02 +00:00
zzz
fc2734c484 compile fix 2013-06-01 17:10:32 +00:00
zzz
75261a0ce4 * EepGet: Used cached byte array in uncompressor 2013-06-01 17:00:33 +00:00
zzz
7fc2cd9cde javadoc 2013-06-01 16:59:06 +00:00
zzz
e72a763019 volatile 2013-06-01 16:58:21 +00:00
zzz
ff20174572 * i2psnark:
- Add idle detector, reduce tunnel count when idle (prep for torrent updates)
   - Cancel CoordinatorAcceptor cleaner when halted
   - Make PeerCoordinatorSet an Iterable
   - Reduce max protocol errors to 1
   - Disable unused PeerMonitorTask
2013-06-01 16:57:50 +00:00
zzz
7d08183334 doc fixes 2013-05-31 23:30:12 +00:00
zzz
66f7505baa * configclients.jsp: Allow more hops and tunnels when routerconsole.advanced=true 2013-05-31 23:28:41 +00:00
zzz
e54465b226 * i2psnark: Fix details page on Windows 2013-05-31 23:19:43 +00:00
zzz
78c17ba353 propagate from branch 'i2p.i2p.zzz.test2' (head 4af6fe141f9ba20b1b13fc5f3417146bc96aa035)
to branch 'i2p.i2p' (head 6edfb2af359351aeb5cf198b9ec4524b2b4a45e6)
2013-05-31 22:18:00 +00:00
zzz
bfac9e398d default the wizard to 3 hops also 2013-05-31 22:16:15 +00:00
zzz
eef5661008 * NetDB:
- Fix debug netDb.alwaysQuery setting so it works again, and always
    sends to that router first (move from FNDF to IterativeSearchJob)
  - Don't reuse DLM reply key/tag
  - FloodfillPeerSelector: Note unused kbucket param in javadocs
  - Debug logging for encrypted DSRM/DSM
2013-05-31 16:51:58 +00:00
zzz
4b9a7323ad propagate from branch 'i2p.i2p' (head 04337e47a38298a4035f48b830f6a2532767bd50)
to branch 'i2p.i2p.zzz.test2' (head 052c3194bd75846075a6b64a1f96cdca6eae33b4)
2013-05-30 19:11:02 +00:00
429ccf21b6 merge of '11286a0edca5afcb38a106793f52422247ae66aa'
and 'ac917c8e012d4f9917afce11433faaf1e6f12c10'
2013-05-30 12:15:47 +00:00
4805a77d40 -2 2013-05-30 12:06:31 +00:00
3a707a143d update wrapper to 3.5.19
- Windows: Self-compiled with VS2010 in Windows 7. The icon has been
  changed from Tanuki's default to Itoopie.
- Linux ARMv6: Compiled on a RaspberryPi using gcc 4.6.3-14+rpi1,
  Icedtea6 6b27-1.12.5-1+rpi1 and stripped
- All other binaries are from the "community edition" deltapack offered by
  Tanuki.
2013-05-30 12:04:42 +00:00
b4264063f4 merge of '57c27fdf450960a6379681666a721f09aadcfbf8'
and 'f99ead1ae78724f35d845623468e9b561d36bf3b'
2013-05-30 05:07:26 +00:00
535c782b7c Allow normal themes to be used with IE >= 10 2013-05-30 01:39:07 +00:00
zzz
3833ad534f restore exotrack 2013-05-29 19:48:45 +00:00
zzz
3d42946ff5 * Console: Remove I2PDigestAuthenticator workaround, as Jetty 7.6.11 has the fix
* Jetty 7.6.11
 * Tomcat 6.0.37
2013-05-29 16:30:00 +00:00
zzz
a1afa1c1b0 * i2ptunnel: Default to 3 hops (ticket #936) 2013-05-29 16:28:28 +00:00
8fb65292cf merge of '3adba0cec6f0291ae90747ab22535290e64e6606'
and 'fd10b04ca3a6cf66e669bfad32d3011ed9f7e33c'
2013-05-29 12:49:29 +00:00
29ce84ff33 disapproval of revision '2fccba5dbe1b538679f15727fd95295842ed8839' 2013-05-29 12:48:11 +00:00
zzz
378c5a0d4e propagate from branch 'i2p.i2p' (head fd10b04ca3a6cf66e669bfad32d3011ed9f7e33c)
to branch 'i2p.i2p.zzz.ipv6' (head 6f6e16f14691f359322e665a7ad5ab65cbe1ca5e)
2013-05-29 00:22:15 +00:00
ca569038e8 parameterize 2013-05-28 10:50:51 +00:00
4092eba606 checkcerts: look for both *.cert and *.crt 2013-05-28 10:46:41 +00:00
63e71d8a3d nbi: Add override for x86 Solaris
The jbigi binaries for Pentium II and Pentium III are identical on x86 Solaris.
2013-05-28 10:46:04 +00:00
278caf72e0 propagate from branch 'i2p.i2p' (head 138d50ea0e969564bef41201439c6a99e2a45fbb)
to branch 'i2p.i2p.729' (head 74c7169e5d428b5aeaf33a401b27c33d3d37907e)
2013-05-28 08:24:22 +00:00
zzz
ff5abfb4b7 0.9.6 2013-05-27 18:17:53 +00:00
4d6b7556c3 propagate from branch 'i2p.i2p' (head dddff6de3cdc4595886d57b5eceb63747b68c7d7)
to branch 'i2p.i2p.729' (head b0eb76504d798a791853a6d269795018c853eff9)
2013-05-27 10:34:53 +00:00
zzz
e5e7dbbb58 * TunnelPeerSelector: Cleanups 2013-05-26 20:38:31 +00:00
zzz
e394d3d4c5 * DatabaseLookupmessage:
- Add support for requesting an encrypted reply
* NetDB:
  - Add support for encrypted DatabaseSearchReplyMessage and DatabaseStoreMessage
    in response to a DatabaseLookupMessage
* PRNG: Cleanups using Collections.singletonMap()
* Router utils: New RemovableSingletonSet
* TransientSessionKeyManager:
  - Support variable expiration for inbound tag sets
  - Several efficiency improvements
* VersionComparator: Add static method, use most places
2013-05-26 17:25:02 +00:00
zzz
370d9dfea1 -24 2013-05-25 12:12:46 +00:00
2a00272efe debian: read /etc/default/i2p in /usr/bin/i2prouter
This will allow overrides to be set without editing /usr/bin/i2prouter.

i2prouter may be replaced during upgrades. /etc/default/i2p will only be
changed by debconf (e.g. "dpkg-reconfigure i2p").
2013-05-24 21:30:46 +00:00
zzz
6c62c1f362 enable IPv6 geoip lookup 2013-05-24 14:11:35 +00:00
zzz
3daf287de8 GeoIPv6:
- Handle gzipped input data in merge tool
  - Add script to generate compressed data
  - Add local additions
  - Add compressed data file, generated from Maxmind data fetched 2013-05-24
  - Include data in installer and updater
  - Update Maxmind license info, now CC-SA 3.0
2013-05-24 13:46:17 +00:00
5c4c02161c propagate from branch 'i2p.i2p' (head fd0e22a44acf6b018c394cdd42d75e2d1bdb4986)
to branch 'i2p.i2p.729' (head b5c7b5601c0b0e810ca6d93c1d249fe4e330a352)
2013-05-24 12:20:50 +00:00
1bd4937a4b geoip.txt update
Based on Maxmind GeoLite Country database from 2013-05-08
2013-05-24 09:13:46 +00:00
0ac2abd5eb debian: bump changelog version to 0.9.6 2013-05-24 09:10:00 +00:00
efe5098f24 Disabling HH's server for this version because it's down and I haven't got in contact with him. 2013-05-23 20:03:09 +00:00
ba859fc9ad propagate from branch 'i2p.i2p' (head e91e8d2eb4c76d5be04e48de9b678cb39b3d0694)
to branch 'i2p.i2p.729' (head c1bf6bf9381192395513aca841d6db507384a9a8)
2013-05-23 09:14:48 +00:00
c73163f525 merge of '56506455244b72ac03b5a5cb832496e367f454b2'
and '6aeeb6555b2fb4e69f167487ca20b143939c809c'
2013-05-22 19:51:04 +00:00
bf317f61c5 Updating the certificate for reseed.info 2013-05-22 19:50:02 +00:00
zzz
9a4cd11748 * SSU: "rectify" IPv4/v6 MTUs differently due to different header size (mod 16)
* Penalize addresses w/o IP in sort
2013-05-21 21:10:23 +00:00
b1b13c41f0 merge of '9f901bf6cca59e5a24595ef80a2fbb586e259281'
and 'e31714127884dc817acde4cf97cb9c7d8cebc92b'
2013-05-21 19:04:55 +00:00
47c3a56aca Ticket 928 - prevent a CKE during write 2013-05-21 19:03:58 +00:00
8acf5f3079 propagate from branch 'i2p.i2p' (head 879c55c825160c979491a99169a173145cf1d7ad)
to branch 'i2p.i2p.729' (head a0ba4c4c989ba71043b9671a56891688be41b50d)
2013-05-21 13:45:26 +00:00
zzz
2f39574123 log tweaks 2013-05-21 13:39:43 +00:00
8b1ab4b8d2 create ./build when "ant jbigi" is run by itself 2013-05-20 20:31:18 +00:00
zzz
c0350702fd * RouterAddress:
- Deprecate some setters
  - Add warning about setCost()
  - Change cost storage from int to short
  - Cost range checks
* NTCP:
  - Republish even if only changing cost
* Transports:
  - Sort multiple peer addresses by cost, with adjustment for local IPv6 preference
  - Add default IPv6Config for ease of changing later
2013-05-19 18:36:29 +00:00
zzz
55880844a5 * SSUDemo: Adapt for NTCP testing too
* RouterAddress and RouterInfo toString() cleanups; don't cache RI in _stringified
* NTCP: Fix publishing address when host specified but interface is not
* log tweaks
2013-05-19 15:18:45 +00:00
zzz
729282c0c4 * UDPAddress: Remove dependency in console; make package private 2013-05-18 20:10:10 +00:00
zzz
d603c3b5cd - UDPAddress reduce object churn, check intro key length,
don't look for ihost3, reject ports < 1024, cleanups
2013-05-18 19:58:10 +00:00
zzz
5cda1ec703 - Handle IPv6 in too-close checks 2013-05-18 19:24:16 +00:00
zzz
ec3756a69f * SSUDemo: Use IPv6; don't use System properties 2013-05-18 18:30:38 +00:00
zzz
0b49fa98f9 * SSU: Fixes for i2np.udp.allowLocal, log tweaks, sender/receiver thread name tweaks
* Limit tunnel GW pumper threads when testing
2013-05-18 18:00:17 +00:00
zzz
226c7eb8e3 * SSUDemo: configuration fixes, delete RI on exit, log tweaks 2013-05-18 14:27:11 +00:00
addffcffcb propagate from branch 'i2p.i2p' (head 27ab673e76ed77c38d22c06c807695f792473fb0)
to branch 'i2p.i2p.729' (head d03f39c7afc2214ef8c2f81486d4abc64049e825)
2013-05-17 16:10:34 +00:00
zzz
be262c6a70 * NetDb:
- Add floodfillEnabled() to NetworkDatabaseFacade so callers don't
    have to cast to FNDF, and Dummy NDF will work
  - Remove static FNDF.floodfillEnabled()
* SSUDemo: cleanups
2013-05-17 15:11:23 +00:00
zzz
a374f00613 * Fix UDPEndpointTestStandalone:
- init context
  - Add unit test buildPacket() method to PacketBuilder
  - Fix NPE in MessageHistory
* Minor PacketPusher optimization
2013-05-16 23:08:06 +00:00
zzz
fcdf837f33 * New buildTest and prepTest targets
* Fix UDPEndpoint usage in unit tests:
  - Restore receive()
  - Handle null UDPTransport
* Fix UDPEndpointTestStandalone compilation
2013-05-16 17:57:33 +00:00
zzz
febc0a5237 RouterContext: Fix disabling client manager with i2p.dummyClientFacade=true 2013-05-16 15:35:23 +00:00
2e0a1b9a0e German translation updates from tx, updated en po files for pushing to tx 2013-05-15 22:04:43 +00:00
zzz
4fae18a719 * UPnP: Detect devices without port forwarding capability (ticket #930) 2013-05-15 14:21:15 +00:00
zzz
d9beaa7591 * NetDB: Increase floodfill count for good 2013-05-15 14:19:01 +00:00
zzz
2ba5ad558b * i2psnark:
- Adjust target piece size calculation
   - Tweak to make it easier for new peers to connect
2013-05-15 14:18:24 +00:00
de6bb12b95 debian: refresh patches 2013-05-15 13:39:24 +00:00
aa2715cced i2prouter: abort immediately if I2P_CONFIG_DIR cannot be created 2013-05-15 13:38:34 +00:00
b096834a54 installer/resources/i2prouter: various bugfixes
- Explicitly specify shell when RUN_AS_USER is set. This allows I2P to start
  under limited accounts that do not have a defined shell.
- When installing as a service, point out that I2P_CONFIG_DIR may need to be
  set. I2P_CONFIG_DIR defaults to $HOME/.i2p for the user that installed I2P
  and when running as a service this may not be desired.
  (e.g., RUN_AS_USER=i2p & I2P_CONFIG_DIR=/root/.i2p)

(The RUN_AS_USER shell problem was spotted at https://github.com/mattias-ohlsson/i2p/blob/master/i2p.spec)
2013-05-15 13:04:46 +00:00
zzz
a19140e186 GeoIPv6 2013-05-13 20:43:30 +00:00
zzz
e0b25cdcf9 remove unused method 2013-05-13 20:39:32 +00:00
zzz
e332c8bc27 FloodfillPeerSelector, ProfileOrganizer: Use 8 bytes for IPv6 check
Transports:
- Add IPv6 column on /peers
- Other minor /peers cleanup
2013-05-13 13:57:15 +00:00
zzz
7318632db9 strip scope from returned address strings 2013-05-12 15:23:02 +00:00
zzz
1b38a6478b UPnP:
- Pass device IP back in forward port callback
 - Only declare success if forwarded IP is public

NTCP: Bad bind config not fatal

GeoIP:
 - Use cached IP in RouterAddresses
 - Use both NTCP and SSU addresses
 - Skip IPv6 for now

Blocklist:
 - Add IPv6 in-memory single list
 - Limit in-memory single list size
 - Fix dup check in getAddresses()
2013-05-12 14:44:42 +00:00
zzz
6ceea60c92 addresses:
- blocklist 192.88.88.0/24 6to4 anycast
- invalidate 2002::/16
2013-05-12 00:24:01 +00:00
c1da7f778b improvements to jbigi scripts
support for Solaris (tested with Solaris 11 x86)

mbuild-all.sh:
- output correctly formatted file names (tested in Solaris x86, FreeBSD (x86 and x64) and Linux (x86 & x64))
- switch from echo -e to the more portable printf
- more error checking, comments

debian/patches: refreshed based on changes to core/c/*
libjcpuid-x86_64-solaris.so: built in solaris 11 x86 with
                             java 1.7.0_07 and gcc 4.5.2, stripped
2013-05-12 00:08:52 +00:00
zzz
fcaebb4416 * Fix UPnP address received before startListening(),
broken by isAlive() check
* log tweakws
2013-05-11 22:11:02 +00:00
zzz
0be3beb30e * SSU fixes for per-address and IPv6 MTU
* MTU.main() print all interfaces
2013-05-11 21:39:25 +00:00
3210dd8d3e propagate from branch 'i2p.i2p' (head ea73fc80c4f4d89238aaa52a9189378e40db0b32)
to branch 'i2p.i2p.729' (head 148b359103beb356be4dd6833d4e6325703917d3)
2013-05-11 20:54:22 +00:00
zzz
5e51c6abef * CSFI compile fix
* Start transports in a standard order to make testing easier
* When transports learn of interface addresses before being started, save them
  and use them at startup
* Pick SSU random port before startListening() and have the TransportManager
  pass it to NTCP before starting
* Only restart NTCP after changing addresses when necessary;
  prevent thrashing at startup (ticket #459)
* Only call rebuildRouterInfo() once at startup
* More checking of min/max SSU port config
* Invalid SSU bind config no longer fatal
* Allow "true" for ipv6 config
* log tweaks
* javadocs
2013-05-11 19:22:20 +00:00
zzz
5e953b0857 * Fixes for IPv4 and other breakage after basic testing
* Catch exception from UPnP callback
* Log tweaks
2013-05-10 18:34:02 +00:00
zzz
c76c80043f * NTCP:
- Drop NTCPAddress, just use RouterAddress
  - Drop _myAddress field, use super's currentAddress
2013-05-09 17:32:29 +00:00
zzz
3a49d6d28f * NTCP:
Move SSU address notification handling from CSFI to NTCPTransport
2013-05-09 16:18:58 +00:00
zzz
94e34ff366 RouterAddress:
- Add new constructor
 - Add add getHost() and deepEquals()
 - Compare host string, not IP, in equals()

SSU:
 - Remove all _external* fields; use _currentAddresses in super
 - Big rework of externalAddressReceived(), rebuildExternalAddress(),
   needsRebuild(), and replaceAddress() for multiple addresses and IPv6
 - Add caching in UDPAddress
 - More IPv6 flavors of utility methods
 - Remove two-art replaceAddress()
2013-05-08 16:48:39 +00:00
zzz
af27c76b2c * Only treat IPv6 addresses as valid if we have a public IPv6 address
* SSU Introduction:
 - Document that Alice-Bob RelayRequest/RelayResponse may be IPv4 or IPv6,
   but don't implement IPv6 yet.
   Changes required in IntroductionManager and PacketBuilder to send Alice's
   IPv4 address in the RelayRequest packet over IPv6, and to publish
   IPv6 introducer IPs.
 - Bob-Charlie RelayIntro must be IPv4
 - Only offer/accept relay tags as Bob or Charlie if the Bob-Charlie session is IPv4
 - Alice-Charlie communication must be IPv4
 - javadocs
2013-05-07 22:46:55 +00:00
zzz
60336c9555 - Shuffle SSU addresses before picking one
- Change address sources to enum
2013-05-07 19:49:13 +00:00
zzz
a85b7aa9f8 - Hash IPv6 addresses in IPThrottler
- CSFI: Pass TransportManager instead of CSFI to GetBidsJob;
        remove unused methods
- Add i2np.disable property for testing
2013-05-07 18:22:20 +00:00
zzz
dca5e9889a finals 2013-05-07 13:49:31 +00:00
zzz
67beebf859 * HandleDatabaseLookupMessageJob: Improve efficiency by only looking up
Hash in the netDb once, then casting to correct type.
   Log cleanups.
2013-05-07 13:37:18 +00:00
zzz
16c8a19be8 * Streaming: Throw chained IOE from streams to get correct location 2013-05-07 13:09:03 +00:00
zzz
0c03b6ba82 i2psnark: More details page fixups;
List directories first
2013-05-06 15:11:02 +00:00
zzz
228e6d7d03 fixup after prop 2013-05-06 13:30:11 +00:00
zzz
cd6376e368 remove DOS line endings in jsps 2013-05-06 13:14:44 +00:00
zzz
c26eba9693 * Console: Fix Jetty thread pool policy and thread name 2013-05-06 12:29:18 +00:00
zzz
31531ee882 propagate from branch 'i2p.i2p' (head 17371fd6f9ef94bbb60a66c6bacb6828d6a4cde5)
to branch 'i2p.i2p.zzz.ipv6' (head 065a076899a2581b4196e626f2b0654c3d39518a)
2013-05-06 11:27:10 +00:00
zzz
b7fca3af42 * Transports: Clean up internal/external port confusion (ticket #873)
- Bind SSU to configured internal, not external, port at startup
   - Use only internal ports for UPnP (getRequestedPort() fixups)
   - Don't have NTCP follow frequent SSU port changes
   - Don't use external SSU port for internal NTCP port
   - Display internal SSU port on /confignet
2013-05-06 11:24:02 +00:00
zzz
368c2073b2 - Fix multiple-detection code in externalAddressReceived()
- Synchronize tracking of last IP/port
- Don't accept IPv6 address changes from peers
- Remove unused getLocalAddress()
- Pkg private getLocalPort()

Peer tests:
 - Use only IPv4 peer for Alice and Bob in peer tests; Charlie may be an IPv6 peer.
 - Enforce IPv4 (Alice's) address inside PeerTest packet
2013-05-05 12:08:28 +00:00
7527a02c60 build.xml: refactor "noExe check" to remove duplication 2013-05-04 19:00:39 +00:00
zzz
757df8c726 prep for multiple address discovery 2013-05-03 16:34:02 +00:00
zzz
c6121cb31e Prep for multiple SSU sockets:
- Change from single UDPEndpoint to a List of UDPEndpoints
 - Move (single) receive queue from UDPReceiver to PacketHandler
 - Multiple transmit queues (one for each UDPEndpoint/UDPSender),
   select queue in PacketPusher
 - Throw exception on UDPEndpoint.startup() failure
2013-05-03 15:03:55 +00:00
5e734088e3 reduce severity of CancelledKeyExceptions
trac ticket 928
2013-05-03 13:47:10 +00:00
zzz
eecab472eb IPv6 SSU MTU adjustments 2013-05-03 11:27:21 +00:00
zzz
b71631d2ec Fixes to isPubliclyRoutable() based on IPv6 config 2013-05-02 14:12:53 +00:00
zzz
3ec78e27b4 Start new IPv6 branch
- Add new TransportUtil for getting/setting IPv6 config
- Prep for supporting multiple RouterAddresses per-transport
- RouterAddress hashCode/equals tweaks
2013-05-02 12:55:35 +00:00
6265bdf026 merge of '00acf6715c7e3d5519672b335bb833f2f88f5ca1'
and '4790dff566ce61cb8a5bfefa0c423df44a784fa5'
2013-05-02 10:19:17 +00:00
0d78ddf872 HTML fixes in readme_ar.html 2013-05-01 22:23:42 +00:00
zzz
10efecaa9c * IRC Server tunnel: Reject bad protocols immediately 2013-05-01 20:52:50 +00:00
689b045a9b html validation fixes
xmllint didn't find these problems (but tidy did).
2013-05-01 19:52:21 +00:00
7692905ba5 fix viewmtn url
(*sigh*)
2013-05-01 18:07:20 +00:00
0ef3bb1deb debian: s/UNRELEASED/unstable/ due to updated packages being built 2013-05-01 17:51:17 +00:00
4c279a192a Switch viewmtn links from zzz's to mine 2013-05-01 17:48:14 +00:00
zzz
af7eaf1f05 * BuildRequestor: Slow down build loop if we have no exploratory tunnels
(ticket #926)
2013-05-01 17:26:07 +00:00
zzz
c198e216fd susidns css tweak 2013-05-01 17:24:09 +00:00
zzz
2325bffbcb enhance main() for debugging 2013-05-01 17:23:50 +00:00
3d3e05d43d debian: don't ship jasper-compiler.jar anymore
I didn't realize that non-existent jars specified in a classpath is not an
error.
2013-05-01 13:37:15 +00:00
c62ae69fe5 debian: bump standards version, don't package 'dummy jars'
note: jasper-compiler is kept due to it being referenced at http://www.i2p2.i2p/plugin_spec
2013-04-30 23:26:42 +00:00
686aa870ea Updates to readme_ar and a CSS tweak from hamada (ticket #489) 2013-04-30 12:35:45 +00:00
zzz
ecac69134d param fix 2013-04-30 01:21:23 +00:00
zzz
8a99be1db3 move page nav 2013-04-29 22:40:49 +00:00
zzz
26f0c98ef8 * Transports:
- Initial prep for multiple addresses per style
   - Simplify NTCP send pool
2013-04-29 18:09:21 +00:00
5375e425ac minor cleanup 2013-04-29 17:55:27 +00:00
650b920e11 I2PTunnel: break out of frame when using the "test server bypassing i2p" link 2013-04-29 17:09:25 +00:00
7a43bd87c2 remove unused param (javadoc fix) 2013-04-29 17:07:08 +00:00
ebb2f1396b Meeh's patch for trac ticket 729 2013-04-29 16:54:36 +00:00
zzz
3a4ac1fc4e one more param fix; javadoc fix 2013-04-29 11:50:23 +00:00
zzz
188ff3392d * i2psnark: Support HTTP request ranges so in-browser and other http-aware media players work better.
Single range only; no multipart
2013-04-28 16:46:52 +00:00
zzz
0cf7e91475 baseline class from Jetty 7.6.10 2013-04-28 16:44:30 +00:00
zzz
609bbac8d5 * i2psnark:
- Only show lower section on first page
   - Hide peer count if not connected
   - Dir page CSS tweaks
2013-04-28 16:43:40 +00:00
zzz
f4431b8d1e more parameter fixes 2013-04-27 22:34:59 +00:00
zzz
45bf2e0715 more classes pkg private 2013-04-27 22:34:39 +00:00
zzz
d7040a23e4 page count fix and cleanups 2013-04-27 16:08:35 +00:00
zzz
6f8fe0ecac add epub mime type 2013-04-27 14:51:07 +00:00
zzz
7181e3eb87 * i2psnark: Ensure current stats and correct event delivered in announce 2013-04-27 14:34:00 +00:00
zzz
011e91140c * i2psnark: Improve page nav 2013-04-27 13:14:43 +00:00
zzz
0f1224de98 * installer: Fix DOS line endings on misc. files (ticket #872)
* SusiDNS:
   - Trim and sort config form data
   - Fix DOS line endings on config files in Linux (ticket #872)
2013-04-26 20:32:58 +00:00
zzz
2e356172d4 document ignored RouterAddress expiration (ticket #832) 2013-04-26 17:12:37 +00:00
zzz
c6bf9a7cf6 deprecate isJobActive() ticket 670 2013-04-26 16:45:52 +00:00
zzz
0816cfe273 * Plugins: Track pending plugin clients better, don't hold references,
start delayed clients from SimpleTimer2 instead of Job queue (ticket #670)
2013-04-26 16:41:09 +00:00
zzz
1cea18346b * Console: Show log location on /logs even if not opened yet (ticket #905) 2013-04-26 13:36:38 +00:00
zzz
0d4bc500ee * HTTP proxy: Verify nonce count in digest auth 2013-04-26 13:02:56 +00:00
zzz
ff313e0301 * i2psnark: Use smaller piece size for small torrents 2013-04-26 13:01:16 +00:00
85001d2622 process debian/po/es.po with update-po 2013-04-25 15:10:40 +00:00
654b240e9d translation updates
* Portuguese, Russian, Spanish, and Swedish translation updates from Transifex
* ant poupdate run for EN for submission to tx
2013-04-25 15:06:27 +00:00
85f3f5615f Allow the "AUTHENTICATE" command in IRC tunnels (ticket #904) 2013-04-25 05:27:55 +00:00
zzz
813a1981d9 * Console, TunnelControllerGroup: Don't register shutdown hook if ClientAppManager is present
* JettyStart: Fixes for use by plugins
 * RouterAppManager: Add shutdown hook
2013-04-24 15:45:15 +00:00
57fd46d3a1 Updated i2p.c default classpath with new Jetty jars, fixed separator 2013-04-24 03:53:12 +00:00
ffbbfdfc0d merge of 'a58d3f77fd66a83579a9978f954077bc0cd3dfed'
and 'c61f304e5ee2d59c51c4e700ab47e61d479257d2'
2013-04-24 03:48:35 +00:00
31bc67a1cd Added launch.properties for i2pExe based on i2pstandalone.xml and doBuildEXE target 2013-04-24 00:30:39 +00:00
ec4f2d2100 merge of '3cff53ae6e9e995199ab4c7c4ce5fa78ec417768'
and 'e824a448e5e49d646a33e7be13f648f66b1b6a47'
2013-04-24 00:01:01 +00:00
5b40914552 Removed some unnecessary code from i2pExe 2013-04-23 21:19:28 +00:00
e8025f09bd merge of '3c164e606c1ed364a6caf2b5b77abbdf819a2bc7'
and 'ebe0842bec96b1e0ed3b8e0c18d4ea05ba7cb981'
2013-04-23 19:27:52 +00:00
zzz
aa547a1610 * i2ptunnel: Block b32.i2p supercookies 2013-04-23 18:23:38 +00:00
zzz
22025b0c3a * Console: Fix Jetty digest auth bug causing repeated password requests
I2P fixes for out-of-order nonce counts.
   Based on DigestAuthenticator in Jetty 7.6.10.
   Includes the nonce count verification code from Tomcat 7.0.35.
   ref: http://jira.codehaus.org/browse/JETTY-1468 which was closed not-a-bug.
   ref: https://bugs.eclipse.org/bugs/show_bug.cgi?id=336443 in which the
   Jetty implementation was introduced.
2013-04-23 18:22:48 +00:00
zzz
4358d11191 Baseline checkin of DigestAuthenticator from Jetty 7.6.10 before mods 2013-04-23 18:19:49 +00:00
5fd63c12a8 remove an ifdef that is not relevant to I2P 2013-04-23 18:05:43 +00:00
37ff4090b4 merge of '97f6b32a68c76e9cbe8832d250144facb6aa729e'
and 'd9b5e2fc62256d9dc0d320fe593d56f0252b7f48'
2013-04-22 20:38:52 +00:00
9550de6760 disapproval of revision '4747eea80e136e04c9a239f0b6ecd9ef134c4d5a' 2013-04-22 20:37:42 +00:00
f5838ffefb add new jetty7 jars to the i2p.exe classpath 2013-04-21 20:26:41 +00:00
zzz
2a374c9b22 bump to -12 after prop 2013-04-21 16:07:08 +00:00
zzz
59ba47eca5 propagate from branch 'i2p.i2p.zzz.winfix095' (head 7d31b90b87adb2c0cfb837e5b66cc4c223766331)
to branch 'i2p.i2p' (head b004014ccfbca6241a090d5b47f1228702f4dfcc)
2013-04-21 15:57:22 +00:00
zzz
60d0b2976b * AppManager:Add HTML debug output 2013-04-21 15:41:34 +00:00
zzz
a44e75201f * Streaming: Pcap window size fixes 2013-04-21 15:40:08 +00:00
zzz
eb3de929bf Pluck of 48ac112fe938c8e960413ad60f64d313a1e5c9ac and e415e24aca895c5a1f88380b1a3946e3b49749a9
* Add new *.i2p2.de certificate
* Added backup's ressed server. (Thanks backup!)
* Temporary removing h2ik's server since he's been AWOL since 06-03-2013 and he's reseed server is down.


applied changes from 185bc62d33224812060d2f68266a029935fb710d
             through 48ac112fe938c8e960413ad60f64d313a1e5c9ac

applied changes from 1194eb12084302380b4315b20e5ae0c574ce1be3
             through e415e24aca895c5a1f88380b1a3946e3b49749a9
2013-04-21 13:47:16 +00:00
d0fa9f8f1e And back to HTTP 403 for Bad URI (we are refusing to fulfill the request) 2013-04-21 13:36:59 +00:00
a3886b0080 Use HTTP 404 for Bad URI (c/f jetty, lighttpd) 2013-04-21 13:30:22 +00:00
b872764624 Use HTTP 400 for Bad URI 2013-04-21 13:27:28 +00:00
075b1fd6f6 Ticket #891 - return "Invalid Request URI" for URIs with illegal characters 2013-04-21 03:20:43 +00:00
zzz
2430e180f3 Add EXTRA version "win1" in prep for Windows-only point release.
We don't want to bump BUILD as it could cause confusion,
and would cause all installs to attempt update via torrent.
2013-04-20 19:07:11 +00:00
zzz
0c22af9578 Convert install.xml to use new utility.jar Main.main()
(ticket #912)
2013-04-20 19:03:38 +00:00
zzz
4976e52389 Pluck of 40d650b134e48bdb0bb636227381c22217365c47
* WorkingDir: Correctly strip DOS line endings while migrating,
              to fix eepsite location on 0.9.5 Windows installs (ticket #919)

applied changes from cc74155815c98674b74cd7d9abb59704005d6b85
             through 40d650b134e48bdb0bb636227381c22217365c47
2013-04-20 18:53:01 +00:00
zzz
88afb23a8c Backport of b6b65cd637f41758bfd38692772ffade3c8cbbbc
Installer: run fixperms.bat all Windows versions except XP/2003.
Wasn't being run on Windows 8.
2013-04-20 18:46:27 +00:00
zzz
a7a0ca87c9 Branch from 0.9.5 release.
Implement new Main wrapper class for utility.jar, to
work around izpack ticket #162 http://jira.codehaus.org/browse/IZPACK-162
which prevents us from specifying a main class as it fails on
Windows installations when a full path including a drive letter is specified
(ticket #912)
2013-04-20 18:42:55 +00:00
7371718afc Installer: run fixperms.bat all Windows versions except XP/2003. 2013-04-19 13:41:56 +00:00
zzz
1e5ffe636f * Updates:
- Notify manager about all available update methods at once, so the priority
     system works and it doesn't only update via HTTP
   - Start router update download at startup if available
   - Only check plugins when core version increases, not decreases, so we
     don't update plugins when downgrading
   - Limit length of URL shown on summary bar
2013-04-19 11:49:22 +00:00
zzz
ca1e8d09cc debug log 2013-04-19 11:47:05 +00:00
zzz
ddc5e2c23f * WorkingDir: Correctly strip DOS line endings while migrating,
to fix eepsite location on 0.9.5 Windows installs (ticket #919)
2013-04-19 11:44:57 +00:00
zzz
3086fd3ce0 * LogManager: Add support for saving properties added in recent releases 2013-04-19 11:42:32 +00:00
zzz
5ea2832ae0 * AppManager: Register jetty, console, and SAM with manager 2013-04-19 11:41:35 +00:00
zzz
5cb449efed * i2psnark: Disable spellcheck in more form fields 2013-04-19 11:40:36 +00:00
46f8344d30 Add new *.i2p2.de certificate 2013-04-18 15:51:17 +00:00
zzz
b370fe6838 * SusiMail: Fix loading of Jetty classes 2013-04-18 15:25:33 +00:00
zzz
d6b28a4eb1 * i2ptunnel: Set target=_top in all external links to break out of console iframe 2013-04-18 15:24:46 +00:00
zzz
72ead2bbcc * i2psnark: Fix params after P-R-G 2013-04-18 15:24:01 +00:00
zzz
648701afdd * Eepsite: Fix jetty.xml configuration of ThreadPool 2013-04-17 21:06:52 +00:00
zzz
389f540f44 less dots 2013-04-17 21:04:21 +00:00
ceda25fb36 added browser http proxy setup to initial news 2013-04-17 18:21:55 +00:00
zzz
c4e2019657 * SusiDNS: Set target=_top in all external links to break out of console iframe 2013-04-17 17:06:34 +00:00
zzz
b64b2629b9 * i2ptunnel: Fix default form action (ticket #882) 2013-04-17 17:04:34 +00:00
zzz
9443a96f0c * Systray: Better detection of 64-bit Windows (tickets #756, #912)
- Don't even instantiate systray unless on 32-bit Windows
2013-04-17 14:49:25 +00:00
zzz
6af73d087b * Console: Better handling of missing font for graphing (ticket #915)
- Remove unused imports
2013-04-17 14:45:24 +00:00
zzz
c61f2af8b3 * SAM: Implement ClientApp interface (ticket #347) 2013-04-16 21:07:00 +00:00
zzz
a3aee79e9c * ClientAppManager: Add method to look up clients by class and args
* Console: Implement stopping of clients using the ClientApp interface
            (ticket #347)
2013-04-16 14:59:18 +00:00
7d0f626fd5 remove mime types already set by jetty 2013-04-15 21:41:53 +00:00
zzz
e34a98620c merge of '186e5e48c613c85b8e11c61ec920a40837bfae8e'
and '3449c389b42e40b9c9a07848a868bb745c5c4540'
2013-04-15 20:59:28 +00:00
zzz
6c32a05378 2nd instance bootstraps DHT from 1st instance 2013-04-15 20:56:10 +00:00
ec4c830c09 i2psnark: update mime types 2013-04-15 20:28:22 +00:00
zzz
9e5d809650 trim form values 2013-04-15 20:23:39 +00:00
zzz
1746a81234 update servlet base after changing dir 2013-04-15 18:54:47 +00:00
zzz
efe7a7536d * i2psnark:
- Add data directory configuration to GUI (ticket #768)
   - Add page size configuration to GUI
2013-04-15 18:39:59 +00:00
zzz
11dd7f6b8c * Console: Move from deprecated Jetty SSL methods to SslContextFactory 2013-04-15 15:53:29 +00:00
zzz
e29bb5b88b * i2psnark:
- Mime type fixes
   - Remove web classes from jar
2013-04-15 12:12:35 +00:00
zzz
57b794f72a * Jetty logging: Fix logging using I2PLogger class;
log ignored messages at debug level
2013-04-14 14:02:43 +00:00
zzz
8bfe3f632e * i2psnark:
- Set unique tunnel nickname for additional instances
   - Increase page size to 50
   - Restore 1-arg SnarkManager constructor for compatibility
   - Add note about DHT file w/ multiple instances, to be fixed
   - Log tweak
2013-04-14 14:00:47 +00:00
zzz
21e47e61f0 * Console: Add /graph support for bw.combined, consolidate
rendering code (ticket #890)
2013-04-13 12:13:55 +00:00
zzz
49cc6b5100 * i2psnark:
- Limit number of torrents displayed; add previous/next page buttons
   - Only register one instance with UpdateManager
   - New icons from famfam/silk, same license
2013-04-13 12:12:22 +00:00
10a42c8b0d debian: add new jetty7 jars to package 2013-04-13 00:23:24 +00:00
zzz
f59ea790ca Javadoc fixups for Jetty 7 2013-04-12 13:53:54 +00:00
zzz
28f1170d95 history for prop, -1 2013-04-10 17:39:27 +00:00
zzz
8eb7cf7bae propagate from branch 'i2p.i2p.zzz.jetty7' (head 12e512b792594fe6a291ad3ab303fca30228391b)
to branch 'i2p.i2p' (head f3775dd82af85ba335258bd9f0fc06131a1daaa9)
2013-04-10 17:24:11 +00:00
zzz
1be0695a21 remove extra semicolon 2013-04-10 17:23:43 +00:00
zzz
65480456cd - I2NP: Ignore unused 7 bits of the Database Lookup Message,
so we can use them later
2013-04-10 17:22:51 +00:00
zzz
5962577b53 - I2NP: Ignore unused 7 bits of the Database Lookup Message,
so we can use them later
2013-04-10 17:06:32 +00:00
zzz
1222776da3 tweak proxy error page 2013-04-10 17:04:07 +00:00
zzz
13633a0532 remove debug id 2013-04-10 17:03:15 +00:00
zzz
1eda9e9053 set ethertype to IPv4 2013-04-10 17:01:54 +00:00
zzz
2557a0bd84 increase threads 2013-04-10 17:00:54 +00:00
e1c533e9de Fixed path to start.ico 2013-04-08 22:44:58 +00:00
zzz
bb8183d0ee - Backup up more Jetty 6 config files before migration
- Try to avoid zip file closed exceptions
  - Fix jetty.xml, switch from deprecated WebAppDeployer to WebAppProvider
2013-04-08 15:29:02 +00:00
zzz
9478a84af7 - Switch from Jetty 7.6.8 to 7.6.10; check in jars
- Re-enable web downloads for easy jetty updating
  - Add dependency checking in apps/jetty build
  - Other build.xml tweaks
2013-04-07 15:01:02 +00:00
zzz
56eba28a50 propagate from branch 'i2p.i2p' (head d30ab8d5835ca55d63913342f0d28169c88e5d77)
to branch 'i2p.i2p.zzz.jetty7' (head fdd1d82c4bb26ed934170c34dd803c342a183a91)
2013-04-07 13:33:13 +00:00
zzz
f8d323bc7b propagate from branch 'i2p.i2p' (head 5737078c5993e2fcf73520cc610a71125b12520b)
to branch 'i2p.i2p.zzz.jetty7' (head a93a47d79b1db119ec8c62b46a4a4e226043bd17)
2013-04-07 13:20:34 +00:00
8857fe5550 Set defaults based on installer/i2pstandalone.xml and build.xml/doBuildEXE 2013-04-04 22:25:05 +00:00
45a38a5425 Only use original argc/v if there are arguments, otherwise use launch.properties or defaults 2013-04-04 22:15:21 +00:00
7f471910ed Marked Windows-specific code in preparation for a cross-platform binary 2013-04-04 21:51:57 +00:00
f6190dd82d Get a simple I2P.exe working 2013-04-03 01:55:02 +00:00
51f072cc72 Migrated limewireExe to i2pExe 2013-04-03 01:52:14 +00:00
b65898e0dd Ticket #741 - Added limewireExe source 2013-04-03 01:39:33 +00:00
7b753c9d30 merge of '48ac112fe938c8e960413ad60f64d313a1e5c9ac'
and 'c4b1087c95c82bb9dde50c078a0c2c0e86c562bc'
2013-04-02 22:46:25 +00:00
dev
dc8d70102c merge of '185bc62d33224812060d2f68266a029935fb710d'
and '381b15133084a1b3e1c37f66a62a768fedefd3d4'
2013-04-02 22:12:57 +00:00
dev
2cbb157f2d add lists.i2p2.i2p 2013-04-02 22:10:08 +00:00
2c47c21038 * Added backup's ressed server. (Thanks backup!)
* Temporary removing h2ik's server since he's been AWOL since 06-03-2013 and he's reseed server is down.
2013-04-01 13:18:47 +00:00
5904d5764c Debian: update changelog 2013-03-31 12:51:20 +00:00
d5443a34ea Debian: explicitly set permissions in postinst on /etc/i2p/wrapper.config (fixes #906) 2013-03-31 12:47:53 +00:00
af79b74c8c checkcerts.sh: cross platform support on *NIX
- function to convert dates to Julian to perform date calculation if GNU date is
  not present.
2013-03-30 21:52:01 +00:00
bfc327833c checkcerts.sh: add some support for non-Linux systems
Date computations as performed in this script require the use of GNU date,
which is only available by default on Linux systems. With this check-in we
explicitly check for the existence of GNU date before continuing with the date
calculations.

Previous versions of this script relied on 'certtool' to print the expiration
dates but certtool isn't available by default on non-Linux systems either. The
previous check-in added support for using OpenSSL, retaining the old behavior
on non-Linux systems.

(Also a re-arrangement of the date warning logic)
2013-03-30 14:24:59 +00:00
427abb081c remove debug text 2013-03-30 02:26:37 +00:00
6992090cda various updates to checkcerts script
- add support for 'openssl'
- parse expiration date, failing if expired or if expires within 30 days
- warn at 60
2013-03-30 02:22:23 +00:00
zzz
9b0c481525 0.9.5 2013-03-08 13:03:50 +00:00
zzz
77cfe0be01 graphs.jsp: Fix saving settings (ticket #857) 2013-03-03 20:32:02 +00:00
041da814d2 merge of '4482eec8563d6ed220c2042b18fc09164aaa4404'
and 'ce2de3b5c7bc1fcd077ff9d6327eaf24758d2a13'
2013-03-03 18:42:46 +00:00
7b7f3ea025 update geoip based on the Maxmind GeoLite Country database from 2013-02-19 2013-03-03 17:22:09 +00:00
53d5c0854f removing email address per request 2013-03-03 17:15:06 +00:00
b2f1e78d62 Temporary removing ju1c3d's reseed server until it's up and working fine on the new system. 2013-03-03 17:08:26 +00:00
9ba17d2e90 French, German, Norwegian, Polish, and Portuguese translation updates from tx 2013-02-22 13:20:41 +00:00
cc18f62fb5 Add new syndie hostnames 2013-02-13 20:50:05 +00:00
8950cc48a6 Flag of Curaçao, courtesy of David Benbennick, released into the public domain 2013-02-13 20:47:29 +00:00
zzz
51edaed610 NetDB: Randomize delay before floodfill store verify 2013-02-12 14:58:52 +00:00
zzz
3a2accdebb * Update: Bump torrent update to 3% of routers 2013-02-10 16:38:09 +00:00
zzz
6cef4f90e1 * Logs: Again, fix setting log filename (ticket #805) 2013-02-10 16:37:06 +00:00
zzz
f5e416d6bf Wrapper 3.5.17 compiled on Raspberry Pi (ticket #826)
GPLv2
binaries stripped

gcc (Debian 4.6.3-12+rpi1) 4.6.3

java version "1.6.0_24"
OpenJDK Runtime Environment (IcedTea6 1.11.5) (6b24-1.11.5-1+rpi1)
OpenJDK Zero VM (build 20.0-b12, mixed mode)

Processor	: ARMv6-compatible processor rev 7 (v6l)
BogoMIPS	: 697.95
Features	: swp half thumb fastmult vfp edsp java tls 
CPU implementer	: 0x41
CPU architecture: 7
CPU variant	: 0x0
CPU part	: 0xb76
CPU revision	: 7

Hardware	: BCM2708
Revision	: 0002
2013-02-10 15:02:04 +00:00
zzz
5eba38a24e * NetDB:
- Encrypt DatabaseLookup messages out exploratory tunnels
     when we already have the RI of the ff
   - Don't use multiple routers from the same /16 in lookups or stores
2013-02-09 19:29:08 +00:00
zzz
7f5d6ca1c7 javadocs 2013-02-09 19:28:12 +00:00
e4318e95a5 German, Polish, Portuguese, Spanish, and Swedish translation updates from Transifex 2013-02-06 02:39:44 +00:00
eaa86664bd Fixed SOCKS mapping terminology, bumped history 2013-02-04 11:29:30 +00:00
5a1053e4fb Allow any domain name to be mapped to an IP
This enables .onion domain names to be accessed by clients that are being
routed through the SOCKS tunnel by e.g. proxychains (assuming that the SOCKS
tunnel has been configured with a SOCKS outproxy that exits into Tor). If the
.onion is not mapped to an IP address, the client would attempt a DNS lookup
which would of course fail to find the .onion.

Clearnet domain names can also be mapped to IPs, but this is irrelevant as DNS
lookups work through SOCKS (via the configured outproxy).
2013-02-04 11:21:26 +00:00
0052ebf334 Set SOCKS5 addressType to AddressType.DOMAINNAME on a successful mapping 2013-02-04 11:13:23 +00:00
d9f7b24cc7 use short name for diftracker 2013-01-31 18:18:48 +00:00
67ca0a4d20 Norwegian translations:
- enable Bokmål in router
- add to tx config
- add Bokmål translations from transifex
2013-01-31 17:51:01 +00:00
fea91a35f6 fix Norwegian translation, add to tx config 2013-01-31 16:42:57 +00:00
3214bc4f81 merge of '4e5a2d2f78b9a7603ece4e4b54720e83e062cbf4'
and '8bbaf8414a2475919844450aad53b325ee0f7e84'
2013-01-31 15:40:15 +00:00
zzz
a0befe59c3 * EepGet:
- Fix URL when not proxied to conform to RFC 2616
   - Add port to Host header to conform to RFC 2616
2013-01-31 12:54:23 +00:00
5f614db59b Adding a new reseed host. http(s)://netdb2.i2p2.no
Using certificate from cacert.org

Thanks to ju1c3d, ju1c3d@mail.i2p
2013-01-30 15:34:28 +00:00
cc4b03604d Adding Norwegian Bokmål translation to i2ptunnel. 2013-01-29 18:14:34 +00:00
zzz
573692dbdf * Console: Catch IllegalStateException storing nonces (ticket #852) 2013-01-29 13:48:00 +00:00
zzz
78dcfd830c * Translations:
- Use JVM language name if available
  - Correct Estonian language code from ee to et
2013-01-29 13:44:36 +00:00
zzz
95d0dc0419 fix BuildHandler NPE from previous checkin 2013-01-28 12:50:04 +00:00
zzz
9247dc898c * BuildHandler:
- Add early throttler based on previous hop
   - Limit concurrent next-hop lookups
2013-01-27 16:24:29 +00:00
zzz
bd900d8d55 increase ff count 2013-01-27 16:21:09 +00:00
zzz
a9eb48c4c6 javadoc 2013-01-27 16:20:26 +00:00
zzz
8afe7c261f * RandomSource: Seed from SecureRandom too 2013-01-27 16:18:56 +00:00
zzz
543870ff02 change injection errors to warns 2013-01-27 16:17:29 +00:00
92707efe8a history bump 2013-01-24 00:18:11 +00:00
42040eb6c8 Added IP -> I2P URL mapping support to SOCKS client tunnels
To use, add custom options to the SOCKS client tunnel like:

ipmapping.127.12.12.12=stats.i2p

Then save and restart the tunnel.
2013-01-24 00:14:03 +00:00
zzz
18e369bcf4 - Use servlet path everywhere, so the war can be renamed
- Use servlet path as base for config file and data directory names,
    so we may have multiple instances running together
  - Don't override service(), use doGet() and doPost() instead
2013-01-23 22:44:52 +00:00
zzz
4ba8f02f59 * Eliminate Jetty dependencies in i2psnark for good.
Required due to webapp classloader changes in Jetty 7,
  we can no longer access or extend Jetty classes.
  - Extend javax HttpServlet instead of Jetty's DefaultServlet
  - Implement BasicServlet to replace functions of DefaultServlet
  - Add MimeTypes implementation to add to servlet's defaults
  - Add local mime.properties file, remove checks in I2PSnarkServlet for those
    we were missing
  - Eliminate all use of Jetty utility classes including MimeType, Resource,
    Buffer, Cache, URIUtil, ...

TODO:
  - Use servlet path everywhere, so the war can be renamed
  - Don't override service()
2013-01-23 20:26:50 +00:00
a7fc8bdf53 Added a link to the summary bar for mobile users on /home 2013-01-21 08:38:00 +00:00
3710346764 history 2013-01-21 06:23:19 +00:00
bb0d2ef17c Added User Agent string for Opera Mobile
On tablets the UA is "Opera Tablet" so tablets will use the desktop console.
2013-01-21 06:01:42 +00:00
d5a870226c Added option to /configui to force the mobile console to be used 2013-01-21 05:59:53 +00:00
34aa3ac207 Updated history.txt 2013-01-19 03:51:42 +00:00
7d38041d23 Tweak so Android tablets use the normal routerconsole 2013-01-19 03:46:38 +00:00
e643d0a086 Fixed up mobile view of routerconsole with a mobile.css in each theme 2013-01-19 03:42:54 +00:00
dcd655fa4b * Translations
- Hungrarian, Italian, Portuguese, Russian, and Swedish translation updates
    from Transifex
  - Refresh of **/messages_en.po
2013-01-17 13:14:08 +00:00
zzz
f57f49c3c5 propagate from branch 'i2p.i2p' (head f33e0980fd48ba4acda12d2079f2a4834a710ae4)
to branch 'i2p.i2p.zzz.jetty7' (head bd1a64f7262ad5bbea3529675f1f055b9ad257a8)
2013-01-13 12:38:05 +00:00
zzz
4f146772e7 * I2CP: Failsafe check for delivery job requeueing forever (ticket #819) 2013-01-12 18:18:17 +00:00
zzz
083dffe8ed try again to prevent IllegalStateException on Java 5 2013-01-12 18:17:31 +00:00
zzz
c43a73e756 log and javadoc tweaks 2013-01-12 18:16:38 +00:00
zzz
0c94680a45 * NetDB: Split up files into subdirectories 2013-01-12 18:14:51 +00:00
zzz
832c0ff683 * SAM: Force i2cp.messageReliability=None (ticket #819) 2013-01-12 18:13:59 +00:00
zzz
95b4fe7378 * jobs.jsp: Add table of pending jobs 2013-01-12 18:13:19 +00:00
zzz
ed12bcefdb * EepGet:
- Fix format of last-modified header to use strictest RFC 822
  - Stop immediately if socket connection to proxy fails
  - Don't forget lastModified/etag headers after redirect
  - Note SocketTimeout API breakage for Syndie
2013-01-12 18:12:35 +00:00
41af00a7d6 don't run gettext if 'require.gettext' is set to false 2013-01-10 16:51:06 +00:00
e34cd0ba3f merge of '27711f734eca9313f7e0742dc1a6df964b744b86'
and '4d27e2149e5bb50280599426f3884dfcc04f920a'
2013-01-10 15:09:20 +00:00
18664d39f3 add bumpBuild target 2013-01-10 14:43:15 +00:00
zab
680c31b843 Fix/update/refactor InboundTest 2013-01-07 19:03:30 +00:00
zab
ba5005c467 Fix OutboundGatewayTest
Refactor as much as possible into GatewayTestBase
2013-01-07 18:38:13 +00:00
zab
7a8fde6637 Refactor common code between Inbound and Outbound Gateway tests in a base class
OutboundGatewayTest still fails, investigating...
2013-01-06 23:02:10 +00:00
zab
973e0e7448 Fix/update InboundGatewayTest 2013-01-06 21:42:15 +00:00
101702552f re-enable DataHelperTest since the jenkins test was a success 2013-01-06 02:41:42 +00:00
8aa7433a80 merge of '2246f1b81c19ddc2c058e68870f1445b9cca1598'
and '956cf5bff87f174141628efbad07e028e30fc4c9'
2013-01-06 02:24:09 +00:00
e7d48f1d3c - s/classpath/javac.classpath/ I'm fairly sure that this must have been added
in error.
- add jenkins.cobertura.report target. The jenkins plugin couldn't find the
  sources, so I'm hoping this helps it out.
- add debug lines cobertura needs
2013-01-06 02:22:10 +00:00
zab
7e7a68a61d fix BandwidthLimiterTest 2013-01-05 23:21:04 +00:00
zab
c558f5af85 Update FragmentTest to expect an IAE.
Update {Batched}FragmentTest to JUnit 4
	Use a single instance of I2PAppContext
2013-01-05 23:08:00 +00:00
zab
a33457ff7f Rename BuildMessageTest so it doesn't match the JUnit wildcard.
Add note that the test (most likely) needs to be re-written fom scratch.
2013-01-05 21:52:33 +00:00
16be8deb00 regex tidying
(fixed version of revision 5135b9e8fb88986fdc130971ebe75c3ab0665dcc)
2013-01-05 20:12:35 +00:00
dfcf1c1575 disapproval of revision '5135b9e8fb88986fdc130971ebe75c3ab0665dcc' 2013-01-05 16:22:28 +00:00
d1dc7cd269 tidy up version # regexes 2013-01-05 16:18:41 +00:00
88c2b3da58 merge of '3c30547c23e641e3cc7a7927d956997c0187aa5c'
and 'd0f6b1e4566b9690b60fa0fb686aadc3ad629a31'
2013-01-05 00:31:14 +00:00
0bfd747c95 Exclude from router cobertura anything that isn't net.i2p.* 2013-01-05 00:30:37 +00:00
zab
d150403395 Rename a non-junit test so it doesn't fall under the junit wildcard 2013-01-04 23:44:26 +00:00
zab
1939aaca93 Fix test and make it actually test something 2013-01-04 20:57:18 +00:00
zab
d0cb714f69 add installer/resources to the classpath for eclipse and junit task
do not use hardcoded filesystem path in junit test 
	(test still fails for different reason)
2013-01-04 20:17:35 +00:00
zab
54a35df9e9 merge of '3cd63a1366e2ca171fb8c348927047e0c0b7393d'
and 'a461c087d600d3fa0b5da2085d1dd97aff721d44'
2013-01-04 19:31:35 +00:00
zab
b1a29c9514 enable more output for easier debugging of tests 2013-01-04 19:28:37 +00:00
af21093012 javadoc fixes 2013-01-04 19:20:08 +00:00
zab
cea1b08a98 Update javadoc to specify non-null payload for datagrams 2013-01-04 18:46:00 +00:00
zab
c7f1329c04 get rid of two tests that don't make sense 2013-01-04 18:38:32 +00:00
a02f9313ff fix javadoc-test target 2013-01-04 02:47:10 +00:00
5a7d975ed6 speed up datahelper test (thanks zab) 2013-01-04 01:17:29 +00:00
455618dc26 merge of '9a6aaa59a51ac9c26f4a1a1a1db90feb17819a22'
and 'b5f4c5514ac1fbd9f7b61180c7874ddcac422c11'
2013-01-04 00:36:02 +00:00
bddfc5b526 Turn BuildMessageTest into a JUnit TestCase 2013-01-04 00:33:03 +00:00
zzz
bcbf7e6270 - Speed up crypto tests, reduce memory usage, use common context 2013-01-04 00:31:28 +00:00
83886cdcfb merge of '9cd70f6c6a5d8100782f92785a0082b09248e6b0'
and 'e6b29f8caf5730bada39b1296ff3eb3b5f363f0e'
2013-01-04 00:20:03 +00:00
zab
dbfb4cbbbb Remove test that does nothing anyway 2013-01-04 00:19:08 +00:00
fe477f0a0b merge of '96801f1975a618da3caa8943bc186ad78449ee94'
and 'fa2d2cb834d3792b816984bc44da70ad903e40e8'
2013-01-04 00:10:56 +00:00
dd24ab6f70 Create a new RouterContext for net.i2p.router.tunnel tests (can't cast I2PAppContext) 2013-01-04 00:07:15 +00:00
zab
47592377f2 Make test expect an UOE 2013-01-03 23:58:18 +00:00
zzz
e3ecc42e88 - Fix delivery instructions test 2013-01-03 23:13:47 +00:00
999b8d3c68 merge of '7b3e55d16589c2194327677322fca98e2ce056ad'
and '85eec7bc28af462eca4a83562771af846cb2b91c'
2013-01-03 22:58:46 +00:00
8e5c26270e cross platform unit test hostname faking not relying
on external tools

The original method failed on Archlinux. This should work everywhere.
2013-01-03 22:58:21 +00:00
zab
e67aa430cd merge of '616d36fc49bb03f28c56540cdd475e2f7e9e3663'
and '7a64fceed49d038439e050a81f45b1e6abb2ad19'
2013-01-03 22:55:56 +00:00
zab
8e57a2e386 Fix most of the test cases, reduce the runtime of the test
using LogManager.flush()
2013-01-03 22:55:40 +00:00
zzz
d28184ce72 - Test data strucure equals() for everything except I2CP 2013-01-03 22:05:10 +00:00
94827d6d55 merge of '4e4692d229faefe5a1a891b9e7e89302117d2970'
and '90cf0bde41018fcb22d53d168c8d6f56294d8660'
2013-01-03 20:12:47 +00:00
6c676869a0 change an ant 1.8ism to one supported in 1.7 2013-01-03 20:12:18 +00:00
zab
2c8f2ae404 Change the Rate.equals(..) method to work for Rates w/o a parent RateStat
Change the RateStat.equals(..) method to work with deserialized RateStats
	Update and fix the JUnit tests for both
2013-01-03 20:08:54 +00:00
3eb00c526d remove extranous reference (that I added) to junit; fix a bit more of the
router tests
2013-01-03 19:36:39 +00:00
zzz
83e25ef26c merge of '78c1ef42cf8e75cb54df7c34644855f54428565c'
and 'd37cf6a7b286442b886dbfd6f74ac948eee5b3fc'
2013-01-03 16:11:29 +00:00
zzz
8f4f7a677f - Fix junit path typo
- Fix several router unit test compile errors.
  They all compile now.
- Move SubmitMessageHistoryJob to i2p.scripts, it is not a unit test
2013-01-03 16:10:49 +00:00
b54c5f8545 renable slow tests
these tests are only slow with cobertura enabled
2013-01-03 14:15:56 +00:00
zzz
17ac0e4b5f - Fix last three I2CP message junit test failures caused by the removal of equals().
- Fix RouterAddress test failure caused by removal of expiration
2013-01-03 12:50:28 +00:00
zzz
4730690978 - Fix most of the I2CP message junit test failures caused by the removal of equals().
Still a few left where the test is overridden.
- Fix DestLookupMessage test failure caused by missing data.
2013-01-03 12:13:48 +00:00
9d77cd7761 allow setting hamcrest and junit locations with properties
Defaults to the ant library path (the previously hardcoded path) if not set.
2013-01-03 11:53:08 +00:00
5b81a1a6d5 catch unset classpath prop 2013-01-03 10:43:31 +00:00
f788ef97de remove cobertura.ser when ant clean is called 2013-01-03 02:43:51 +00:00
zzz
e4ec046363 - Add separate top-level junit.test and scalatest.test targets, so
you can run whichever you have the libs for
 - Add router to test target (if we don't run it, it won't get fixed)
2013-01-02 23:46:14 +00:00
cdc3682baa Fixes to JUnit tests under net.i2p.router.transport 2013-01-02 22:05:12 +00:00
dae66d7f73 Updated JUnit tests in net.i2p.router.tunnel - almost all bugs fixed 2013-01-02 21:29:54 +00:00
d6d1b51970 Set up build.xml test harness to run the JUnit4 tests as well
You will need junit4.jar, hamcrest-core.jar and hamcrest-library.jar in your
Ant library path (probably /usr/share/ant/lib)
2013-01-02 21:06:59 +00:00
zzz
6f301f01dc * Logs: Fix setting log filename (ticket #805) 2013-01-02 14:12:02 +00:00
zzz
71607fff2d javadoc 2013-01-02 14:02:02 +00:00
zzz
6ed602309f - Local mods and wrapper for SipHashInline
- Convert SessionTag.hashCode() to SipHash to prevent collision attacks
     in the SessionKeyManager; cache for speed
2013-01-02 14:01:29 +00:00
zzz
20cc48cd87 SipHash inline implementation and junit test, unmodified.
As pulled from https://github.com/nahi/siphash-java-inline
Last commit was 5be5c84851
2012-11-06

Copyright 2012  Hiroshi Nakamura <nahi@ruby-lang.org>
Apache 2 license

25%-35% faster than reference implementation in my tests.
2013-01-02 13:54:49 +00:00
zzz
f2331b0603 * New getASCII() for use in findbugs cleanups for 7-bit strings
This code was supplied by zab
2013-01-02 13:31:41 +00:00
zzz
8c2ddec400 add shortcut in equals() for speed 2013-01-02 13:27:24 +00:00
zzz
c8e12b9ac9 * Transport: Fix early NPE (ticket #824) 2013-01-02 13:23:23 +00:00
zzz
452d1d01b8 * SAM: Synchronize dissector 2013-01-02 13:21:45 +00:00
zzz
e375ffe8f1 * I2CP:
- Fix leak if nonce = 0 but reliability != none
   - More work on failure codes (ticket #788)
   - Fix race with _finished indication in OCMOSJ
2013-01-02 13:19:40 +00:00
zzz
2ea9fc5d61 I2CP: Remove static logs; Fix thread ID counter 2013-01-02 13:17:02 +00:00
zzz
912e29f8af - Remove unused equals() methods for I2CP message classes,
most did not have hashCode() implementations.
     These are never used as keys in a Set or Map or checked for equality.
     Fixes findbugs issues (ticket #379)
2013-01-02 13:13:35 +00:00
zzz
72054a7d30 reorder synch and loop 2013-01-02 13:08:34 +00:00
ab2c5ef9bb postinstall: delete both OSX scripts if we're not on OSX 2013-01-01 18:26:08 +00:00
ab0b4936ec refresh patch 2013-01-01 18:22:18 +00:00
2dd1aaab63 Update wrapper to v3.6.17 (ticket #826) 2013-01-01 10:39:08 +00:00
c05cd07ff7 Fixing two potential NPEs found by findbugs 2013-01-01 00:02:18 +00:00
adfc22499c Remove outdated javadoc reference & explicitly specify locale 2012-12-31 21:45:49 +00:00
44498ca8c7 installer: extra checks & add to findbugs target 2012-12-31 18:00:42 +00:00
a40566eefb improve installer javadocs; add minimalist package.html 2012-12-30 00:36:14 +00:00
zzz
77f0dd653a - Fix handling of duplicate participating tunnel IDs
- Reduce chance of generating duplicate IDs for our tunnels
   (ticket #812)
 - Stat cleanup
 - Comment out effectively unused countProactiveDrops()
2012-12-29 13:40:55 +00:00
zzz
8ed70084db catch iterator exception on java 5 2012-12-29 13:31:31 +00:00
zzz
2f4e3862e3 cleanups 2012-12-29 13:23:57 +00:00
zzz
667393e8cf * Javadocs: Fix javax links; add installer utils 2012-12-29 13:19:09 +00:00
zzz
c6dd7b4cc5 * i2psnark: Redirect after post
Button spacing on config form
2012-12-29 13:17:27 +00:00
db0501f31b explicitly specify encoding 2012-12-29 00:10:38 +00:00
3be5002f15 ant debian-tarball target: set .sh to mode 755 2012-12-28 21:17:56 +00:00
4389f277d6 * windows installer fixes / improvements
- move deprecated installer-only classes (Exec, Delete, and Copy) from
    i2p.jar into installer/
  - replace installer/resources/fixpaths.cmd with an improved method in java
  - combine the installer-only utility classes into a single jar and call the
    classes from within izpack
2012-12-28 20:59:17 +00:00
cf10cb1c09 Fixed out-of-date references to wrapper.jar and jbigi.jar so that the justBOB target works 2012-12-27 11:59:48 +00:00
zzz
38214cf5be * I2CP:
- Prep for delivery of detailed failure codes to the client (ticket #788)
   - Store session ID as an int instead of a long
   - Clean up some duplicate createRateStat calls (ticket #787 comment 2)
   - Other optimizations, cleanups, final
2012-12-26 14:29:49 +00:00
zzz
f4740d2639 * Stats: Clean up some duplicate createRateStat calls (ticket #787 comment 2) 2012-12-26 14:22:30 +00:00
zzz
48309c0f6d * NetDB: Split routerInfo files into subdirectories, disabled for now,
enable with router.networkDatabase.flat=false
2012-12-26 14:19:52 +00:00
zzz
cf1f42ebf8 * Tunnels: Catch rare BuildExecutor IAE only in Java 7 (ticket #811) 2012-12-26 14:16:49 +00:00
zzz
7c8bb0ba69 comment out main 2012-12-26 14:15:19 +00:00
zzz
14eedaa029 * i2psnark: Create torrent form tweaks 2012-12-26 14:14:43 +00:00
73e25aad76 * Add EOL modifications
- set eol for certain files in installer targets (since editing *.config and *.xml in windows is practically impossible without an externally installed editor such as vim or notepad++ and of course we want people to be able to read the licenses if they desire...etc.)
  - try to prevent user error by ensuring that the proxy/*.ht files have eol set to crlf in the prepConsoleDocs target
2012-12-25 00:13:32 +00:00
f3f4529d84 use ant features instead of Unix commands where possible in the installer2app target. Also make izpack2app a settable property 2012-12-24 22:09:10 +00:00
5dbe6294fb debian-binary: don't assume that noAutoDebchange will be set by people that know that debian/changelog needs to be set 2012-12-24 19:55:16 +00:00
91c9bfed3a add additional arm types to the 'noExe' condition & add reference the cybergarage javadocs revision in history.txt 2012-12-24 19:46:40 +00:00
420ccad91b javadoc fixes for the upstream cybergarage UPnP library. Upstream ticket #3598391 has been filed for this issue. 2012-12-24 19:44:25 +00:00
1d0f8b4c6d Add missing shebang lines to bundle-messages scripts 2012-12-23 17:35:07 +00:00
3396626a0c * new ant targets
- trimMtnRev: create a new property with the revision trimmed to  8 characters.
  - getExtendedVersion: create a new property that includes the full version with the shortened MTN revision tacked on
  - debchange:  automatically update debian/changelog with the I2P version. Called by the "debian" target unless the property noAutoDebchange is set.
  - debian-tarball: export i2p.i2p branch to a new directory, remove the binaries like jbigi and launch4j, and create a tarball.
* move packages created by "ant debian" to ${basedir}
* add debian/changelog to .mtn-ignore since it is now automatically updated (by default).
* add *.deb to .mtn-ignore
2012-12-23 17:30:56 +00:00
8c13d32036 debian: add repack script and update watch file to use repack.sh 2012-12-23 17:20:15 +00:00
zzz
5d523723ed merge of '2e3c8b51430edfa3ce0e82bc4b49ea7c21c0606b'
and 'c643595f81605fc5534465da3f1655e4c23345a1'
2012-12-22 19:59:06 +00:00
zzz
6d2fa690dc quoting fixups 2012-12-22 19:30:36 +00:00
zzz
470b8c59e7 minor console/update cleanups 2012-12-22 18:37:26 +00:00
zzz
81975e919b propagate from branch 'i2p.i2p.zzz.test2' (head f33dbe1499b84cf6192b1a7bd494eaf081a047c0)
to branch 'i2p.i2p' (head 4e5bd2836592b95e1eff01d8e83f2690da386ef8)
2012-12-22 18:34:51 +00:00
zzz
436d8f0785 - Add support for announce-list (BEP 12) to TrackerClient (ticket #778)
- Refactor dup tracker detection
2012-12-22 18:05:42 +00:00
fa235d97af enable i2prouter translations in the debian package & refresh patch 2012-12-22 17:51:15 +00:00
42f8c71d4e update .mtn-ignore 2012-12-22 17:50:46 +00:00
9a241af241 enable translations for 'i2prouter' 2012-12-22 15:10:57 +00:00
69d22b84f9 i2prouter: integrate modifications from upstream (Tanuki) 2012-12-22 14:57:28 +00:00
zzz
7ea1bffea2 rename Tracker class for clarity 2012-12-22 14:13:16 +00:00
c1f4155cd8 French language update from transifex + updated EN po files that were uploaded to transifex 2012-12-21 23:50:08 +00:00
85fda3ed7f minor regex tweak 2012-12-21 21:17:33 +00:00
8998bdec17 remove another reliance on external UNIX-only tools (and fixing formatting of my earlier commit) 2012-12-21 21:13:31 +00:00
c9b6a3f01c Instead of deleting the empty directory placeholders, let's just not copy them to pkg-temp to begin with. 2012-12-21 20:53:51 +00:00
05c5f66012 fix my getBuildNumber regex 2012-12-21 20:46:02 +00:00
7fd59c4f10 add more excludes to 'sloccount.report' and make the report location configurable 2012-12-21 20:45:05 +00:00
6fe127286f add armv6 and armv7 to the "do not build EXE" list 2012-12-20 07:25:28 +00:00
406bcbef9d remove dependencies on external tools for getReleaseNumber and getBuildNumber
getReleaseNumber and getBuildNumber were *NIX only targets that relied on the external tools grep, cut, awk, and tr. These targets have been rewritten to use ant features.
2012-12-20 07:23:01 +00:00
9eb25f60c3 add sloccount report target 2012-12-20 07:16:39 +00:00
b7c10d2adb remove a few more files with "ant clean" 2012-12-20 07:13:26 +00:00
816149efd3 debian: refresh patches 2012-12-19 21:31:02 +00:00
aa6eefcc76 debian: add commented entries required for PPA builds & update "debianhowto" target
If someone runs "ant debian" to make installable packages, they do not need to
have their own wrapper or commons-logging  jars. The PPA builds, however, do
require them. During the last release I made the mistake of overwriting my "PPA
debian/control" file with the one from MTN that did not include these
dependencies.

Also updating "debianhowto" to reflect the fact that we no longer use
Debian's/Ubuntu's Jetty pkgs since Jetty6 appears to be leaving their repos in
the near future.
2012-12-19 21:25:04 +00:00
9ef9e48da9 remove executable bit 2012-12-19 21:09:17 +00:00
166e36aaef move taskdefs to targets
The directory installer/lib/ will be removed if a 'stripped' source tarball is
required. Without the changes in this commit, removing this directory will
require hackery to be performed on the I2P source in order for any of the ant
targets to work.
2012-12-19 21:08:57 +00:00
zzz
667b548d3b * Update: Hide the update buttons when router.updateDisabled=true, as is the case
for Debian packages. Broken in 0.9.4. (Ticket #817)
           Remove unused shouldInstall() method.
2012-12-19 14:58:37 +00:00
5dfef69688 Add dummy placeholder files to empty eepsite directories
git and a few other vcses don't store empty directories....but now these directories
are no longer empty.
2012-12-18 20:50:29 +00:00
zzz
c3ae3f2895 build fix 2012-12-17 15:29:26 +00:00
zzz
8b41956091 0.9.4 2012-12-17 14:52:02 +00:00
264e27ab3f Correct url for forum.i2p 2012-12-16 03:23:16 +00:00
zzz
74f6abc97a bump 2012-12-15 14:54:32 +00:00
zzz
8edbfc5198 replace call to Arrays.copyOf(), not in Java 5 2012-12-15 14:41:42 +00:00
8513d1f22b merge of '482fcb3afd2e52160588dbf9e253ff594e0d5ce3'
and 'a63132b861cf363158a5ac2e1897b4636321d536'
2012-12-15 00:37:09 +00:00
cb75e3dc7e Documented required and optional test-related properties in build.properties 2012-12-14 22:33:37 +00:00
a8926dae57 ship all of the *BSD jcpuid files in the installer 2012-12-14 22:20:20 +00:00
c5502737f2 Debian: changelog and minor initscript updates 2012-12-14 16:14:46 +00:00
206cea8b56 update geoip.txt
Update geoip.txt based on Maxmind GeoLite Country database from 2012-12-04
2012-12-14 16:00:09 +00:00
003a8b07e1 German and Swedish translation updates from Transifex 2012-12-14 15:58:59 +00:00
zab
c5d69eb231 jenkins test passed! 2012-12-14 08:34:27 +00:00
zab
78864ab380 test to see if the jenkins server by skydrome detects broken compilation 2012-12-14 08:29:08 +00:00
zzz
ec22a6ec6b copy armv6 wrapper in preppkg-linux target 2012-12-13 12:33:53 +00:00
b435857e15 don't try to copy armv7 wrapper in preppkg-linux target 2012-12-12 20:34:37 +00:00
zzz
8198419156 build fixup 2012-12-12 15:43:42 +00:00
zzz
60718dbf72 Drop custom-built armv7 wrapper.
Tanuki-built arm wrapper works on armv5 and armv7 but not on Raspberry Pi armv6.
Wrapper we built for Raspberry Pi does not work on Trimslice armv7.
2012-12-11 19:27:56 +00:00
zzz
4e558320a9 - i2psnark: Add announce list support (BEP 12) (ticket #778)
Preliminary. Still todo: TrackerClient
2012-12-10 22:48:44 +00:00
zab
1fa00a5738 Restore javadocs 2012-12-10 18:05:52 +00:00
zzz
9f6ebd8e10 longer tunnel options for servers; fix spacing issue 2012-12-10 17:39:02 +00:00
zzz
c4a0fcbf43 propagate from branch 'i2p.i2p' (head 99b582d7fcc9d377341809a5fe580b439b37fea6)
to branch 'i2p.i2p.zzz.test2' (head f620dc8ce09657b3bfe0d87b5ee09c1bc33c31d1)
2012-12-10 17:23:29 +00:00
zzz
8104cb40cd Apache Tomcat 6.0.36 2012-12-10 17:23:07 +00:00
zab
d2b2600e5e VersionComparator w/o object churn, ticket #789
tests
2012-12-10 10:07:34 +00:00
zab
d062db3c17 Object churn improvements, ticket #787 2012-12-10 09:46:05 +00:00
zab
32a8bb7a3e more VersionComparator tests 2012-12-09 16:59:51 +00:00
zab
d8417cbf71 more tests for VersionComparator 2012-12-09 13:28:06 +00:00
zzz
863a05b33d * susimail: Button CSS spacing tweak 2012-12-08 12:12:29 +00:00
3fc3abe7a5 Moved susimail.properties out of the build path, and set build.xml to copy it in 2012-12-08 02:02:04 +00:00
zzz
96fcaf9385 javadoc 2012-12-07 14:21:30 +00:00
zzz
0b14981163 fix forum urls 2012-12-07 14:20:43 +00:00
zzz
87a56a6fac * RouterClock: Reduce log level (ticket #790) 2012-12-07 14:20:02 +00:00
0fa938e096 merge of '60726592fdfe50d6d8051846e0034b4b40a6761e'
and 'ad92f5811a7ff6ceab5ab09572d716f00f9100ea'
2012-12-06 00:17:13 +00:00
b7e3a60fbc Ticket #802
Added https://euve5653.vserver.de/netDb/ to reseed host list.
Certificate using www.cacert.org, so no need to add a new crt file.
2012-12-05 20:57:33 +00:00
653ccaae49 typo fix + updated UK translation 2012-12-05 14:38:56 +00:00
zzz
ca00b34314 * I2CP: Fix external I2CP apps, including i2ping, caused by 0 nonce value,
broken in 0.9.2 (tickets #799, #801). Allow nonces == 0.
   Javadocs and cleanups.
2012-12-05 00:03:27 +00:00
zzz
0c5811801f * SSU: Fix rare NPE (ticket #798) 2012-12-05 00:01:49 +00:00
zzz
d9727c901c * Reseed: Don't go on to the next host if we have enough http://zzz.i2p/topics/1287 2012-12-05 00:00:55 +00:00
zzz
63b8e7101f * GarlicMessage: Fix notes and log in GarlicMessageHandler and HandleGarlicMessageJob,
they are used for netdb messages received by floodfills http://zzz.i2p/topics/1282
2012-12-05 00:00:06 +00:00
4f5da775d4 Chinese, French, Italian, Polish, and Ukrainian translation updates from
Transifex.
2012-11-28 23:27:16 +00:00
3464ad6e5e remove extraneous space 2012-11-28 19:39:31 +00:00
d28480dd92 bumping build to -12 2012-11-28 10:34:19 +00:00
4902b4ecba merge of '32a936bfa4c9048f8d96461990da03f7f35cb676'
and '9c7cae316969219b1f2d74c20dbb4a12a94857a9'
2012-11-28 10:28:30 +00:00
zab
0e0a38460e Revert to using ArrayList in RouterInfo 2012-11-28 08:19:34 +00:00
4266a10ffb Added more tests to VersionComparatorSpec to further cover the implementation 2012-11-26 00:29:02 +00:00
31fc55eca7 Added tests for VersionComparator 2012-11-25 02:44:01 +00:00
4d389f75a2 Changed summary bar ordering <input type="image">s to <button>s
Fixes a bug which caused the ordering to be non-functional.
2012-11-25 02:39:49 +00:00
zzz
abe29e044f Remove org.mortbay.http.Version.paranoid property not recognized by Jetty 6. 2012-11-24 20:01:07 +00:00
zzz
8d2eff76f2 fix jetty system properties 2012-11-24 19:56:58 +00:00
zzz
c5a6ed3179 final 2012-11-24 17:30:20 +00:00
zzz
99058ee135 * Codel: Make stats non-required (ticket #786) 2012-11-24 16:41:55 +00:00
zzz
b2e335fbba * Profiles: Small optimization in coalesceOnly() (ticket #765)
javadoc, detab
2012-11-24 16:41:12 +00:00
zzz
1d3bbfd250 * Addressbook: Disable unused wakeup via http 2012-11-24 13:56:45 +00:00
zzz
916e328e10 javadoc, volatile 2012-11-24 13:55:47 +00:00
zzz
fe02145fed typo 2012-11-24 13:53:12 +00:00
ad41b25be5 merge of '138eae0135999a3f8e20b08183500a2318287cd4'
and '314f5c9d4fc6b5dd82d6ee09a207686f52e66a2c'
2012-11-23 20:12:11 +00:00
d2b1103e26 Removed a hard-coded jsp link I missed 2012-11-23 20:10:52 +00:00
0b05cd761c i2prouter: fix block location (thanks k0e) 2012-11-23 18:08:04 +00:00
28ba7880e4 merge of '15d44385349738e5c84f8efcdb797d98b4fbaed0'
and '586f7a71f1e187cb041d873c013fbe91d0184b08'
2012-11-23 18:07:07 +00:00
4680fd118b Added remaining .project and .classpath files
The project files for jetty are in the apps/jetty folder. Dependencies will be
resolved once the project has been built normally once via e.g. "ant updater".
2012-11-23 12:31:02 +00:00
9dcfe98437 Added .project and .classpath Eclipse files to most sections of the source
To import a branch of trunk into Eclipse, create a new workspace based in the
root directory of the checked-out branch, and then select "File -> Import..."
then "General -> Existing Projects into Workspace", then for "Select root
directory" choose the root directory of the branch (and of the workspace).
Select all projects that appear, so that dependencies are satisfied.

Currently left out are i2psnark, routerconsole and susimail, because they all
depend on jars in apps/jetty/jettylib, which seems to be auto-generated. Need
to check whether the existence of that folder (from having Eclipse files in it)
will prevent the jars being populated or not.
2012-11-23 12:20:26 +00:00
zab
55c264916b kill a string allocation hotspot 2012-11-23 07:52:03 +00:00
zab
0ec77f5514 Use the cached iterator list to remove Iterator allocation hotspots 2012-11-23 07:22:58 +00:00
zab
f238d0514f test removal 2012-11-23 07:13:21 +00:00
zab
d8613d2285 more appropriate junit test 2012-11-23 07:06:01 +00:00
zzz
009b0bfdde more empty jars not to pack 2012-11-23 01:30:48 +00:00
zzz
924963eba0 fix class cast exception 2012-11-22 23:14:08 +00:00
zzz
de175b80fe updates 2012-11-22 22:54:11 +00:00
zab
1e83028702 An ArrayList that reuses a single iterator 2012-11-22 21:50:48 +00:00
zzz
9fc7258537 - Update non-default xml files
- Update DTD
2012-11-22 21:42:15 +00:00
zzz
50df4b53db - Clean up WebAppconfiguration
- Fix eepsite xml files
- First cut at updating migration code (untested)
2012-11-22 21:17:50 +00:00
zab
e974d3bc55 propagate from branch 'i2p.i2p.zab.782' (head 64415601890b9c494a8f06379f9feefbc855e07c)
to branch 'i2p.i2p' (head 0e92cf3a3844e7b738ca9c2486112867fc663b6f)
2012-11-22 20:53:03 +00:00
zab
7c96044d18 javadoc 2012-11-22 20:47:54 +00:00
zzz
d5d70f1b40 Wrapper 3.5.16 compiled on Raspberry Pi:
GPLv2
binaries stripped

gcc (Debian 4.6.3-12+rpi1) 4.6.3

java version "1.6.0_24"
OpenJDK Runtime Environment (IcedTea6 1.11.5) (6b24-1.11.5-1+rpi1)
OpenJDK Zero VM (build 20.0-b12, mixed mode)

Processor	: ARMv6-compatible processor rev 7 (v6l)
BogoMIPS	: 697.95
Features	: swp half thumb fastmult vfp edsp java tls 
CPU implementer	: 0x41
CPU architecture: 7
CPU variant	: 0x0
CPU part	: 0xb76
CPU revision	: 7

Hardware	: BCM2708
Revision	: 0002
2012-11-22 00:36:45 +00:00
zzz
02ad4d5200 fix NPE 2012-11-21 22:53:22 +00:00
zzz
56ae54c2ff Jetty 7 license info copied from jetty-distribution-7.6.8.v20121106 2012-11-21 22:20:05 +00:00
zzz
a70e040e33 susimail compile fixes for Jetty 7.
Untested.
2012-11-21 21:21:38 +00:00
zzz
c0d82fe83f i2psnark compile fixes for Jetty 7.
Untested.
2012-11-21 21:09:31 +00:00
34e0b36401 updates to 'i2prouter' based on changes to Tanuki's example script 2012-11-21 21:03:55 +00:00
2fbe0e8bb1 update wrapper to v3.5.16
- Windows: Self-compiled with VS2010 in Windows 7. The icon has been
  changed from Tanuki's default to Itoopie.
- FreeBSD: Self-compiled in FreeBSD 7.4 to eliminate the dependency on the
  compat6x port and stripped.
- Linux PPC32: Self-compiled in Debian Squeeze and stripped
- Linux x86, Linux x64, Linux ARMv5, MacOSX & Solaris: Binares are from the
  "community edition" deltapack offered by Tanuki. The Linux binaries have
  been stripped.
2012-11-21 21:01:45 +00:00
zzz
f1dd77982a RouterConsole compile fixes for Jetty 7.
Convert LocaleWebAppHandler from extending WebAppContext to
extending HandlerWrapper, since handle() is now final in WebAppContext.
Untested.
2012-11-21 20:49:18 +00:00
zzz
be8697cb9a jetty 7 first cut 2012-11-21 18:05:50 +00:00
zab
33ee8a38ca Ticket #765 - optimize locking during profile reorg 2012-11-21 15:45:38 +00:00
zzz
5f4562467e * Transport: Fix bug that inadvertently reduced default max
SSU connections in 0.9.2, cutting network capacity in half and
   harming tunnel build success rates
2012-11-20 01:17:02 +00:00
56ef4cda82 Addi an exception for core2 & corei to NBI on 32-bit kFreeBSD, NetBSD, and OpenBSD
These binaries are identical on 32-bit kFreeBSD, NetBSD, and OpenBSD systems.
If a corei CPU is found on these systems we'll use the core2 jbigi binary.

194868,ad47c3d909d0fb85242566f3c7b4be5b,libjbigi-kfreebsd-core2.so
194868,ad47c3d909d0fb85242566f3c7b4be5b,libjbigi-kfreebsd-corei.so
202848,57aa013ca310f3aae990f5ee78c100bd,libjbigi-netbsd-core2.so
202848,57aa013ca310f3aae990f5ee78c100bd,libjbigi-netbsd-corei.so
207657,01483211b6e077057302e256f185f7e7,libjbigi-openbsd-core2.so
207657,01483211b6e077057302e256f185f7e7,libjbigi-openbsd-corei.so

The I2P project does not currently ship these binaries, but they can be found
in unofficial jbigi packages.
2012-11-19 23:47:55 +00:00
5975b69b42 Add jcpuid binaries for OpenBSD, NetBSD, and kFreeBSD.
Support for these has already been added to CPUID.java.
2012-11-19 22:44:58 +00:00
d0a3c7256a Improved support for GNU/kFreeBSD
- add kFreeBSD to NBI and CPUID
- add kFreeBSD to jcpuid/jbigi build scripts
- refresh debian patches to compensate for kFreeBSD changes
- i2prouter: Detect kFreeBSD and normalize its name
- clean up osid (switching to "elif") and adding support for detecting kFreeBSD
- update postinstall.sh; I2P cannot be installed using gij so postinstall.sh
  will not be run. If/when openjdk finally comes to kFreeBSD, we'll be ready for it.
2012-11-19 22:41:54 +00:00
zzz
d94c14967c move HashDistance to router/util 2012-11-19 16:22:09 +00:00
zzz
f15828fa95 * NetDB: Add negative lookup cache 2012-11-19 16:10:02 +00:00
zzz
f64eacefe3 * BuildHandler: Disable CoDel, wasn't helping 2012-11-19 16:06:59 +00:00
zzz
c8f2effca8 * Profiles: Split up files into subdirectories 2012-11-19 16:04:33 +00:00
74f4859e13 explicitly prefer openjdk-*-headless over default-jre-headless.
On Debian Squeeze the default-jre-* packages point to gij/gcj which is suboptimal.
Openjdk cannot be forced since not all platforms--such as kFreeBSD--have it as
an available option.
2012-11-18 18:52:13 +00:00
zab
8c987fc0d2 Add javadocs to getters
Make setters package-private
	Small noop tweak to the computeAverages
2012-11-18 15:01:43 +00:00
zab
efc202d2ee more use of the new methods 2012-11-17 19:22:23 +00:00
zab
3cbca7c0ac more use of the computeAverages method 2012-11-17 18:51:28 +00:00
zab
82e4244473 more refactoring 2012-11-17 18:36:55 +00:00
zab
836620c375 javadoc 2012-11-17 18:03:10 +00:00
zzz
addfff8626 * Tunnels: Set default priorities for tunnels (ticket #719)
Exploratory: +30
   IRC: +15
   HTTP Proxy: +10
   I2PSnark: -10
2012-11-17 17:32:24 +00:00
zzz
3836742e7d stat cleanup 2012-11-17 17:24:44 +00:00
zzz
74fd171131 * i2psnark: Clear PEX peers set after use, cause of bad peer counts 2012-11-17 17:11:39 +00:00
zzz
d511bf2cd8 * error500.jsp: Add servlet version 2012-11-17 17:10:31 +00:00
zzz
0cbbedd250 javadoc fix 2012-11-17 17:09:37 +00:00
zab
4824cae36c Properly synchronize the Rate class
Add a new class to store results from rate calculations
	Add a new method to compute average, last and current measurements
	Use the new method in RouterThrottleImpl
2012-11-17 00:04:08 +00:00
b67359aca6 Match *FreeBSD* instead of just FreeBSD*.
(spotted at http://pastethis.i2p/show/2280/ and jcpuid already matches
*FreeBSD* so this fixes a minor consistency issue. Thanks to the anonymous
paster.)
2012-11-16 21:24:03 +00:00
zzz
99179edae2 add reseed to event log 2012-11-16 15:33:38 +00:00
zzz
ae6dad6e48 * NetDB:
- Implement automatic reseeding (ticket #521)
   - Increase minimum routers from 15 to 50
2012-11-16 14:47:55 +00:00
zzz
6902a8392f * i2psnark: Fix rare IOOBE (ticket #777) 2012-11-16 14:45:05 +00:00
zzz
4991c5a1ad * Tunnels: Fix outbound tunnel message priority (ticket #719)
(copy/paste error)
2012-11-16 14:43:46 +00:00
zab
a3e3001d49 * Sync fixes to Frequency
* Removal of warnings related to generics in StatManager
2012-11-14 21:53:54 +00:00
zzz
4fdf1c2411 * stats.jsp: Link to graph page, not single image 2012-11-13 20:40:15 +00:00
zzz
ea00c0af50 * SSU: Fix bug that would drop 512 byte messages
The bug has been there forever but never happened before
   0.9.3 because the buffers were all 32KB and the largest
   fragment was about 1500 bytes. In 0.9.3, there are multiple
   buffer sizes, the smallest is 512 bytes, and a packet
   of exactly 512 bytes would be silently dropped.
   Thanks zab for finding it.
2012-11-13 20:39:29 +00:00
zzz
e6dbd7ddda * SOCKS: Reduce log level of connect errors 2012-11-13 20:36:42 +00:00
zzz
9741d127a9 * NTCP:
- Fix NPE with more syncing (hopefully) (ticket #770)
   - Use ByteCache for 16KB buffers
2012-11-13 20:35:47 +00:00
zzz
8efc7e9369 * HTTP Proxy: Store referrer of new addresses in address book 2012-11-13 20:33:37 +00:00
zzz
da009f8d22 * Bandwidth Limiter: Fix stats broken in -1 2012-11-13 20:32:39 +00:00
zzz
f8133b7abf log tweak 2012-11-13 20:30:56 +00:00
2362862f31 eepget: If java binary is not found, try to determine where java.exe is located.
In my testing:
32 bit Windows (and, of course, 32 bit JRE) = Java added to the PATH
64 bit Windows and 64 bit JRE = Java added to the PATH
64 bit Windows and 32 bit JRE = Java *not* added to the PATH.

So...with this check-in:

- If the environment variable JAVA is set in the script, we'll use that
  manually specified Java. We will not look in the registry, but we'll check to
  make sure that the binary exists.
- If Java is found in the system path, we'll use it instead. We will not look in the
  registry.
- If the variable is not set manually and Java is not in the system path we'll
  look in the registry to find the java binary.

I've tested this in Windows XP, Vista, and 7 but it should work in any supported version
of Windows.
2012-11-09 23:53:02 +00:00
f287ed48ed merge of '6f719ac61e6f1afbd935f3fdab862c2e5cc7f5d8'
and 'fd3c457f0a834ba87fead3cbdf22e31253cd4e7c'
2012-11-07 19:29:34 +00:00
b8a9caeb4c Cleanup in reseed list, also removed HH's ssl host, since it expires 21-11-2012 22:34:10 GMT+1. And
I've failed to get in contact with him for a renewal of his certificate. Errors might appear in logs 
on installs after that date, just remove https://euve5653.vserver.de from /configreseed in console 
and you wont get errors.
2012-11-06 22:00:00 +00:00
dccd8445e6 More changes to finish first test in UpdateBehaviors 2012-11-06 11:23:57 +00:00
c5fb009c83 merge of 'd09201283ea0356bf5b1d3aedc4795a202414930'
and 'e2f50f8cb50f8593ca882e94cb661c54b87d2468'
2012-11-05 21:40:35 +00:00
4d8973b0a5 Assorted fixes to router Junit tests for changes in the source 2012-11-05 21:31:40 +00:00
f57d91ac16 Added missing DateAndFlagsTest - no errors in core junit tests now 2012-11-05 21:00:20 +00:00
ccc5923ab3 Drop unused DummyPooledRandomSource, moved to i2p.scripts 2012-11-05 20:43:47 +00:00
31debe6bbf CryptixRijndael_Algorithm._BLOCK_SIZE is private, so specify value directly 2012-11-05 19:53:00 +00:00
40d1507237 Fixed imports on core JUnit tests to use Hamcrest matchers provided with Junit4 2012-11-05 19:50:32 +00:00
zzz
ea2be02a29 * RequestLeaseSetJob: Only disconnect client after multiple dropped
lease set requests; reduce timeout, other cleanups
2012-11-05 17:23:32 +00:00
zzz
c21a6a54f8 * PeerManager: Don't reorganize as often if it takes too long (ticket #765) 2012-11-05 17:20:47 +00:00
zzz
70a2e330ef * i2psnark:
- More DHT limits
   - Announce to backup trackers if DHT is empty
   - Use PEX and DHT info in torrent peer count
   - Don't use temp files for announces
   - TrackerClient refactoring
   - cleanups
2012-11-05 17:20:07 +00:00
zzz
d5c70676b0 * Console:
- Fix NPE after restart (ticket #763)
   - Move more nonces out of system properties
2012-11-05 17:17:31 +00:00
zzz
202c92a42d * Unsigned Update: Fix notification on failure 2012-11-05 17:16:02 +00:00
3cb4d35cee propagate from branch 'i2p.i2p.zzz.update' (head 1ca3b931ebecd4ec80e7e135b634d085934c092b)
to branch 'i2p.i2p' (head c917793878189c29441f69133e029cfdfe3c0895)
2012-11-05 10:38:54 +00:00
3d35984cf5 Started filling out UpdaterBehaviors 2012-11-05 10:37:18 +00:00
2217d1ab95 Moved *streaming and i2ptunnel tests to match convention 2012-11-04 11:23:12 +00:00
75ddc12390 de, pt, and se updates from Transifex. Updated en po files to push to tx. 2012-11-02 19:54:49 +00:00
zzz
d48fab9d98 * I2CP:
- Better fix for logging dropped messages (ticket #758)
   - Implement fast receive to reduce per-message handshakes
   - Make messageReliability=none the default
2012-11-02 16:37:23 +00:00
zzz
d30aeb3902 * KeyManager: Eliminate races, buffer I/O, eliminate periodic syncing 2012-11-02 16:01:44 +00:00
zzz
d479c4ae7d * configstats: Fix group sorting, translate groups 2012-11-02 16:00:41 +00:00
zzz
9c220e08f8 * i2ptunnel:
- Better privkey backup file name
   - Revert increment of privkey tunnel name
   - Move deleted privkeys to backup dir
   - Fix jsp build dependencies
   - Fix layout issue on Chrome (ticket #757)
2012-11-02 15:59:51 +00:00
zzz
eee38a626d * i2psnark:
- Split buckets correctly
   - More exploration fixes
2012-11-02 15:58:26 +00:00
zzz
f29a45a2c2 * PriBlockingQueue: Enforce max size 2012-10-31 16:15:32 +00:00
zzz
a5b68d4fb0 * I2CP: Reduce log level when outbound queue is full (ticket #758) 2012-10-31 16:09:28 +00:00
zzz
8a7d119962 * FIFOBandwidthRefiller: Reduce refill interval to smooth output 2012-10-31 16:07:11 +00:00
zzz
84a0793a10 * Streaming: New disableRejectLogging option (default false), enable for snark 2012-10-31 15:56:02 +00:00
zzz
2f4eeda397 * i2ptunnel: Fix NPE in zzzot plugin 2012-10-31 15:53:57 +00:00
zzz
96ed7abdc5 javadoc, final, private, volatile 2012-10-31 15:52:12 +00:00
6a91918e6f Stubbed out Specs for net.i2p.router.update.* in routerconsole
*Behaviors.scala should really go in net.i2p.update.* in core, but ScalaTest
doesn't seem to be picking up the cross-dependency properly and just ignores
any Spec which includes them; they will move once the build.xml is fixed.
2012-10-31 00:22:15 +00:00
2c3edc0503 merge of '2b4768d9966695ad845dad4e28ef426d781e718f'
and '8489000cfeee5a6aa5a250b48bda4f6e2fb16b03'
2012-10-30 19:41:47 +00:00
f6bac8a08e redirect output to /dev/null (in case /proc/1/comm doesn't exist) 2012-10-30 19:41:35 +00:00
zzz
4ce11a174a * SSU:
- Adjust RTT/RTO calculations
   - Better bandwidth tracking
   - Cleanup of OutboundMessageState
   - Stat tweaks
 * Transports: Increase min peer port to 1024
2012-10-30 18:16:37 +00:00
zzz
d92f5e6508 merge of 'b2b4c1ba1f799d81d6d164698cb28aa9b837d390'
and 'c2b60a59c73835b51357a706da377862d8bd5ebc'
2012-10-30 15:06:38 +00:00
zzz
513821123e remove space in javascript urls 2012-10-30 13:18:54 +00:00
f56c804e86 cleanups as requested 2012-10-30 11:03:11 +00:00
fb50f7adb4 Adding two new reseed hosts. Thanks to h2ik and SWAT
* reseed.info - SWAT
* i2p.feared.eu - h2ik
2012-10-30 02:27:16 +00:00
a99bf60cea Added Mockito to ScalaTest classpath, and removed unneeded entry
Put mockito-all.jar (or a link to the actual version) in the same directory
as the ScalaTest lib files (passed in the command line as scalatest.libs).
2012-10-29 22:30:53 +00:00
zzz
40d981df25 * OutNetMessage: Properly clean up when dropped by codel (but unused for now
since codel is disabled for ONM)
 * Tunnels: Implement per-client outbound tunnel message priority (ticket #719)
 * ClientTunnelSettings cleanup
2012-10-29 22:21:50 +00:00
zzz
f5165cfae5 log tweak 2012-10-29 22:17:38 +00:00
zzz
055bae0450 * StatisticsManager: Publish stats less often 2012-10-29 22:16:29 +00:00
zzz
74e5ea6e20 * Installer: Drop news.xml and old certs 2012-10-29 22:12:30 +00:00
zzz
32f3ca0568 * logs.jsp:
- Don't display dup message if last
   - Spacing tweaks
2012-10-29 22:10:42 +00:00
zzz
fd3423fe09 * i2ptunnel:
- Create backup privkey files (ticket #752)
   - Fix NPE in Android startup
2012-10-29 22:09:55 +00:00
zzz
05d299816b * i2psnark:
- Add kbucket debugging
   - Eliminate redundant explore keys
   - Add more limits to DHT tracker
   - Delay expiration at startup
   - Only enable updates for dev builds and 1% of release builds
 * Update Manager: Warn on dup registration
2012-10-29 22:08:38 +00:00
zzz
2b80d450fa drop old fortuna build script 2012-10-29 22:06:03 +00:00
9a31115eff Classpath change in router build.xml to get routerconsole test harness to work 2012-10-29 12:14:04 +00:00
zzz
4baf3b6913 Fixups after props from:
i2p.i2p.zzz.pcap
	i2p.i2p.zzz.test
	i2p.i2p.zzz.test2
	i2p.i2p.zzz.update
Javadoc fixes
Checklist tweak
-1
2012-10-28 13:08:02 +00:00
zzz
5e48331eae propagate from branch 'i2p.i2p.zzz.update' (head 267311f29e501fcc8b3d674a93e78b5520ac985e)
to branch 'i2p.i2p' (head edeca2ab47e734c2314ff394609292d8bd3d5293)
2012-10-28 12:48:35 +00:00
zzz
5766db2c09 propagate from branch 'i2p.i2p.zzz.pcap' (head fff5fc864e5905ed77f8d60f7d0892ed5c2447b4)
to branch 'i2p.i2p' (head cc74e6e08096cc7fdb8563b2eae82df2a000ab01)
2012-10-28 12:26:52 +00:00
zzz
c4f6f48eeb propagate from branch 'i2p.i2p.zzz.test2' (head a002e8957b5bf3a44149203d6842ef4b35107aa7)
to branch 'i2p.i2p' (head 0f6e2b3b8643fe7797e8727329345c1ed4cf741b)
2012-10-28 12:24:07 +00:00
zzz
943e2d7fe7 propagate from branch 'i2p.i2p.zzz.test' (head 48448fc896d1e0859f481e98d0e80e764cc40736)
to branch 'i2p.i2p' (head aedb9b8335d6de72dd633e79716fff6ffec263a1)
2012-10-28 12:17:38 +00:00
zzz
c4fa8fabb2 - Continue work to use priorities in FIFOBandwidthLimiter
- Log tweaks
2012-10-28 12:10:24 +00:00
zzz
6868047ee4 * i2ptunnel:
- Refactor TCG to use ClientApp interface
  - Remove 'reload config' button
  - Synchronization fixes
  - Don't instantiate early, to allow router to hold
    a reference. TCG.getInstance() may now
    return null when in RouterContext.
  - Jsps display message when TCG not initialized
2012-10-27 18:51:50 +00:00
zzz
80e7ee46fb enable pw when adding one 2012-10-27 18:45:16 +00:00
zzz
61ee957add pcap:
- Buffer output
 - Separate methods for inbound and outbound, so we
   don't need to use PacketLocal for inbound
 - Cleanups after prop
 - Finals etc.
2012-10-27 18:03:54 +00:00
6e66d377f6 changelog/patch updates 2012-10-27 18:00:10 +00:00
zzz
99e759a5be propagate from branch 'i2p.i2p' (head 6e6de141ddbaddfcecf8a66ad8cf65f247f41f94)
to branch 'i2p.i2p.zzz.pcap' (head ae8977bcc33f75ee36505e739e9e4a194f5d9074)
2012-10-27 16:12:57 +00:00
zzz
eafca84717 0.9.3 2012-10-27 13:03:14 +00:00
zzz
0e2fd0c6f5 tweak 2012-10-27 12:47:07 +00:00
zzz
0ccf65fcf8 banlist 2012-10-26 16:24:31 +00:00
zzz
af06fded73 - Add password enabled property
- Bypass nonce checking if passwords enabled
  - Add message about cookies if nonce fails
  - Minor susidns cleanup
2012-10-26 13:08:23 +00:00
zzz
0bfe8ff41d * BuildHandler: Fix "too slow" rejections due to internal clock skew 2012-10-25 18:58:12 +00:00
804f0294bb Bumped router to -21 for previous commit 2012-10-25 02:51:18 +00:00
7a4430856d Tweaked default value of lastLine in susimail to make a no-response error clearer to users 2012-10-25 02:49:13 +00:00
6bd40e253a Bumped router to -20 for previous commit 2012-10-24 19:55:35 +00:00
c2d178efc3 Fixed a very stupid bug >_< 2012-10-24 19:51:54 +00:00
zzz
97da508df5 * I2PSnark:
- Fix (again) partial piece avoidance for seeds
   - Fix several partial piece (temp file) leaks,
     some uncovered by previous rarest-first fixes, some in end game
   - Don't lose all DHT peers if we stop quickly (backport from update branch)
   - Explore a kbucket if it's less than 3/4 full (backport from update branch)
2012-10-24 17:38:20 +00:00
211128f128 i2ptunnel: Truncate long client destinations (ticket #581) 2012-10-24 02:30:19 +00:00
zzz
2f69d16828 - Thread magnet start if not connected
- Don't lose all DHT peers if we stop quickly
- Explore a kbucket if it's less than 3/4 full
- Change release torrent file names
2012-10-23 19:34:35 +00:00
zzz
bb2363f68a - Fix DummyHandler
- Notes on news.xml enhancements
- Fix handling existing torrent
- Add dn to magnet link generation
- Fix progress info
2012-10-23 14:09:14 +00:00
fc461931bd Adding a new reseed host. 2012-10-23 14:08:12 +00:00
zzz
724f4f9b37 - Several plugin install fixes
- Remove unused UpdateTypes
- Only try applicable updaters when updating
- Javadoc fixes
2012-10-23 02:34:24 +00:00
zzz
6f790d99c9 exit 1 on failure 2012-10-22 22:56:40 +00:00
zzz
efb986ffd9 - Handle case where we already have torrent
- New Storage.main() for use in the release process
- Make torrent files in release process
- Stop tunnel after fatal if no snarks are running
2012-10-22 22:55:36 +00:00
zzz
bd9ad9982b - Fix spacing in summary bar
- Add start() in UpdateTask so things happen in the right order
- Add toString() in UpdateTask for better debugging
- Fix getID() for plugin UpdateTasks
2012-10-22 20:25:01 +00:00
e5a8a6aba4 merge of '7ca37d4f5e443834de23ebd2cf306b6fe3aeca87'
and 'f9d82ac84936c56dc92691842757e8cc354511e2'
2012-10-22 20:24:53 +00:00
da835fbd6b h2ik don't have static ip anymore. 2012-10-22 19:52:21 +00:00
zzz
1538e6ec4e - Fix VersionComparator (thx zab)
- Add debug output
2012-10-22 17:13:23 +00:00
zzz
95e0c37222 - Add fail timers
- Add progress indication
- Listener cleanup
2012-10-22 14:51:41 +00:00
zzz
95870df45b * Watchdog: Don't dump threads too often (ticket #519) 2012-10-21 17:21:49 +00:00
zzz
8b2889e317 - Only fail after all URLs are tried
- Move registration from servlet to manager and delay
- Fix plugin updates
- More logging
2012-10-21 17:14:54 +00:00
zzz
0fc452b683 - Improved parsing of news file
- Add magnet links to news file
2012-10-21 14:59:52 +00:00
zzz
6e19854e4c - NPE fix on signed udpates
- More work on snark updater
- Clean up imports
2012-10-21 13:34:23 +00:00
zzz
6331cb2374 stub of a torrent updater 2012-10-21 03:13:31 +00:00
zzz
983537b0fd refactor CompleteListener out of Snark.java 2012-10-21 02:34:46 +00:00
zzz
58fd2dddf8 refactor magnet parsing out of servlet 2012-10-21 02:08:34 +00:00
zzz
49b2fbd2b0 tweak 2012-10-20 22:52:11 +00:00
zzz
68814e31e7 * Console:
- Store form handler nonces in the servlet session instead of system properties,
    to prevent cross-session interference
2012-10-20 21:28:17 +00:00
zzz
429739837b * Console:
- Consolidate all the jsp formhandler boilerplate in the new
    formhandler.jsi, in preparation for further improvements
2012-10-20 20:52:45 +00:00
zzz
fef1440865 * Transport:
- Add a simple network monitor
  - Add new reachability state for network disconnected
  - Prevent any tunnel building when disconnected (ticket #519)
  - Don't unleash watchdog when disconnected
2012-10-20 17:28:00 +00:00
zzz
afd29715fa * Addresses:
- Add methods for connectivity detection
  - Remove Hamachi restriction
2012-10-20 15:30:12 +00:00
zzz
e329742c8d * Transport: Back out CoDel for SSU PeerState and NTCP 2012-10-20 11:37:31 +00:00
zzz
5695d0e94a build fix 2012-10-20 03:38:54 +00:00
zzz
5a964dacbb * UDP: Fix peer test NPE (ticket # 748) 2012-10-19 22:03:41 +00:00
zzz
fea3bb63c1 - Save available unsigned version across restarts
- Fix status display after downloaded
- Don't display update buttons unless HTTP proxy is up
- Pass the manager down thru the constructors
2012-10-19 20:26:08 +00:00
580c940d42 More pt trans updates from tx 2012-10-19 07:49:36 +00:00
7ea8cd4a09 Geoip update 2012-10-18 22:37:50 +00:00
zzz
4f936f958d add the other getProperty(); more tweaks 2012-10-18 21:07:36 +00:00
a6ca962fcb Portuguese and Spanish updates from Transifex 2012-10-18 15:19:13 +00:00
zzz
0b4401e64b - Lots of fixes for notifying when updates and checks are complete
- Fixes for NewsHelper stored timestamps
- Add getProperty(String, long) to context for sanity
- New methods and types
- Logging improvements
- Add failsafe TaskCleaner
2012-10-18 14:28:14 +00:00
zzz
2b50c5aaf4 comment out test code 2012-10-18 14:26:30 +00:00
zzz
da4ea77c2a more fixes 2012-10-18 02:20:39 +00:00
zzz
af4786ce0e fixes 2012-10-18 01:29:14 +00:00
zzz
f9b8f0528d - Straighten out some confusion on versions, RFC 822 dates,
etc. on news and unsigned updates. Stored versions are always
  Long.toString(modtime). Only convert to RFC 822 for eepget or display.
2012-10-17 23:45:44 +00:00
zzz
b9d717b9f9 - Split up Updater and Checker interfaces
- Update router after check
2012-10-17 22:24:15 +00:00
zzz
cbc9165afd - Add a jetty starter that can be stopped later
- Include jetty-i2p.jar in the updaters
2012-10-17 17:37:45 +00:00
zzz
a9e18620b9 - Convert HTTP and CONNECT proxies to MD5 authentication
- Allow multiple users
  - Migrate passwords on first save
2012-10-16 19:17:06 +00:00
zzz
613dd77d2c only display tracker error if no peers 2012-10-15 21:30:46 +00:00
zzz
9b6d5daeef more work on proxy digest auth 2012-10-15 21:04:49 +00:00
b816ecc7e3 Italian and Swedish updates from Transifex 2012-10-15 18:05:38 +00:00
zzz
d01aae7860 HTTP Proxy:
- Move error page methods to base
 - Preliminary code for digest auth
2012-10-15 15:37:13 +00:00
zzz
50cb427377 split out md5Sum for use in i2ptunnel 2012-10-15 13:57:09 +00:00
zzz
977cdee046 - Move MD5 functions to core util where i2ptunnel can use them 2012-10-15 12:28:45 +00:00
zzz
4db4010abf propagate from branch 'i2p.i2p' (head 2da3b585b42d058e25909bc303d72277ae2463b5)
to branch 'i2p.i2p.zzz.update' (head ebbad994215dc2822e9a1776399864ed77a0e5a0)
2012-10-14 22:42:00 +00:00
zzz
ba37839adf fixes while rechecking storage 2012-10-14 20:05:04 +00:00
zzz
c9196fda03 compile fixes after prop 2012-10-14 20:03:56 +00:00
zzz
b03b4745db propagate from branch 'i2p.i2p' (head 2da3b585b42d058e25909bc303d72277ae2463b5)
to branch 'i2p.i2p.zzz.test' (head 2785f3832a7d1b8adb2f106d049949beb9b88838)
2012-10-14 19:50:51 +00:00
zzz
8df2a2d00a * i2psnark: Fix request tracking bug preventing piece requests 2012-10-14 16:38:36 +00:00
zzz
184220f4c5 minor optimization 2012-10-14 13:54:38 +00:00
zzz
5d6d27907d * Console: Use non-nio connector for Java 5 and JamVM/gij
(tickets #715 and #743)
 * SystemVersion: Centralize more methods here
2012-10-14 13:54:08 +00:00
zzz
5e5dc35a1e moved i2cp password to PasswordManager 2012-10-13 22:42:26 +00:00
zzz
24b7b6fabd - Don't migrate any plaintext passwords to obfuscated, it's too messy 2012-10-13 21:42:52 +00:00
zzz
c5ab6b9993 * Passwords:
- Add remove method
    - Add console password form to configui.jsp
    - Consolidate multiple setSettings()/getJettyString() in FormHandler
    - Some form message tweaks
2012-10-13 21:20:16 +00:00
zzz
05740f7903 - Fix MD5 passwords after testing
- Remove unused password fallback in FormHandler
2012-10-13 15:41:57 +00:00
zzz
fc7f995bd2 propagate from branch 'i2p.i2p' (head 2ab4ae45aa60b379e85fca378522966c090a1a27)
to branch 'i2p.i2p.zzz.test' (head 220477e37d4df782b9a8bb30d12669d146dc6226)
2012-10-13 14:23:29 +00:00
zzz
d99a39e5d5 convert to ClientApp interface. Untested. 2012-10-13 13:54:30 +00:00
zzz
0b897fdc98 * RouterConsoleRunner:
- Prep for ClientApp interface by storing context in a field,
      shuffle around what's static and what's not
      (ticket #347)
    - Remove ports from port mapper on shutdown, other changes to
      track actual ports better
      (ticket #731)
    - Hook in password manager using MD5, untested.
      (ticket #731)
2012-10-13 13:06:22 +00:00
zzz
a475a912e6 * New password manager for storing passwords in router.config
in consitent ways, including salting and hashing if possible.
    Not hooked in to console yet, lightly tested.
    (ticket #731)
2012-10-13 12:56:43 +00:00
zzz
8f17b73091 changes due to LoadClientAppsJob changes for ClientApp interface 2012-10-13 12:51:24 +00:00
cb56b76ef9 i2prouter: check /proc/1/comm for systemd (thanks k0e) 2012-10-13 12:45:25 +00:00
zzz
d198ae9ef1 * New interface for clients started via clients.config, and a new
manager to track the lifecycle and start/stop clients on demand.
    Not hooked in to console yet, untested.
    (ticket #347)
2012-10-13 12:45:08 +00:00
eff238e85c i2prouter: In Slackware, check for existence of /etc/rc.d/rc.i2p when installing as a daemon 2012-10-12 17:26:03 +00:00
a436e60fb8 Italian translation updates / updated EN po files 2012-10-12 00:52:09 +00:00
2c570f8d4e remove internel I2P link
Let's not direct people to see how to configure their browser at
http://www.i2p2.i2p/htproxyports when you need to have your proxy configured to go there!
2012-10-11 22:48:06 +00:00
6f23bdd331 remove another link to forum.i2p2.de 2012-10-11 22:43:51 +00:00
b797f9e26d remove link to forum.i2p2.de 2012-10-11 22:42:03 +00:00
2b13973eca debian: refresh patches 2012-10-10 23:32:27 +00:00
9331b229fe addressing a few concerns from #681 2012-10-10 23:32:04 +00:00
ccd0795a4e turn off executable bit 2012-10-10 23:31:07 +00:00
1f98493dbd i2prouter: add initscript support to Slackware 2012-10-10 22:44:42 +00:00
f20d906b67 i2prouter: Add systemd support for Arch Linux and SuSE Linux. 2012-10-10 21:33:05 +00:00
zzz
65757dee1c * ShellCommand: Fix launching all browsers at startup (ticket #453) 2012-10-10 19:12:30 +00:00
zzz
b259a3ac3d * stats.jsp: Sort groups by translated name 2012-10-10 19:11:18 +00:00
zzz
ca1f816ad9 remove colombo 2012-10-10 15:06:51 +00:00
zzz
6f509967bf Making FIFOBandwithLimiter.Request unidirectional, static,
remove logging, other cleanups (ticket #719)
2012-10-09 14:15:04 +00:00
zzz
56574c41be propagate from branch 'i2p.i2p' (head cbca70618d2083a5fcdead2390e9d30060080e74)
to branch 'i2p.i2p.zzz.test' (head 1affab2e83613f326d269370de6e5aed40ecae52)
2012-10-09 13:36:32 +00:00
zzz
3cdfc2d33a Split up NTCPConnection's single _bwRequests Set into inbound and outbound,
in prep for making FIFOBandwithLimiter.Request unidirectional
and support priorities (ticket #719)
2012-10-09 13:36:14 +00:00
zzz
1b154551a2 EventLog: add more events 2012-10-09 10:35:47 +00:00
zzz
c419016a12 * SSU:
- Add peer test throttling
   - Peer test packet count fixes
   - Adjust peer test timeouts and add backoff
   - Reject relays and peer tests from same /16
   - More peer test cleanup and log tweaks
 * Transports:
   - Enforce minimum peer port
   - Warn on low router ports
2012-10-09 10:20:45 +00:00
zzz
f10478ceef comment out test 2012-10-09 10:16:05 +00:00
zzz
d477773054 * NetDB: Increase floodfills again 2012-10-09 10:15:44 +00:00
zzz
8ed280ebf4 * RouterInfo: Exit 1 on error in main() 2012-10-09 10:14:56 +00:00
zzz
762e96b8a6 2 more for cache 2012-10-09 10:13:59 +00:00
zzz
23c77fbe4b * Console, i2ptunnel: Warn on low ports 2012-10-09 10:13:10 +00:00
zzz
e99dd72cb6 * SSU:
- Fix relay request handling bug from -10
   - Fix peer test reply handling bug from -10
   - Fix NPE from -6
2012-10-08 09:32:04 +00:00
zzz
b095b7e769 * i2ptunnel:
- Set default read timeout in standard server
   - Reduce header timeout, enforce total header timeout
     in IRC and HTTP servers (ticket #723)
 * Streaming: Don't ignore option or force connect timeout to 5 minutes
 * Streaming javadocs
 * SocketTimeout cleanup
2012-10-07 20:57:35 +00:00
zzz
6b97e1bfaf * Logs:
- Flush buffers in logs.jsp
   - Add dup message to buffers, was in file only
2012-10-07 20:50:26 +00:00
zzz
3ceb83d40e * I2PAppContext: Improved synching in constructor 2012-10-07 20:48:25 +00:00
zzz
d80340f0ae * UPnP: Workaround NPE (ticket #728)
root cause TBD
2012-10-07 20:47:22 +00:00
zzz
3acc2fb160 - Much improved peer test defenses
- Minor improvements to relay defenses
2012-10-06 22:47:17 +00:00
zzz
034db1a282 Validate port/IP in received peer tests 2012-10-06 14:58:42 +00:00
zzz
b07b9bf0b9 * SSU:
- Throttle outbound destroys on shutdown
   - Limit outbound introduction offers
2012-10-06 13:44:57 +00:00
zzz
97460e7d99 * configlogging.jsp: Fix IAE
* error500.jsp: Fix whitespace
2012-10-06 13:42:48 +00:00
zzz
ddc750469c * i2psnark:
- Add allocating and checking indications
   - Add bandwidth message at startup
   - More checks at torrent creation
2012-10-06 13:41:50 +00:00
zzz
0448537509 make inbound and exploratory settings final 2012-10-05 13:38:27 +00:00
zzz
583463ab42 * configservice.jsp: Add GC button 2012-10-05 13:09:34 +00:00
zzz
b20e298f6e * SSU:
- More synchronization fixes
   - Reduce chance of dup acks in a single message
   - Reduce max unsent acks to 50
   - Use last ack time in ping decision too
   - Reduce ack delay
2012-10-05 13:08:05 +00:00
zzz
090d59fcb7 * DataHelper: Sanity checks in storeProps(), use
storeProps() for router config again
2012-10-05 13:00:52 +00:00
zzz
1d174d6797 * TunnelPoolManager: Fix early NPE (ticket #724) 2012-10-05 12:59:30 +00:00
zzz
15a47b5612 import 2012-10-03 19:17:55 +00:00
zzz
4d1ea6e4cd * SSU:
- Increase max outbound establishments based on bandwidth
   - Synchronization fix for Java 5
   - Use multiple buffer sizes in OutboundMessageState to
     reduce memory usage
   - Adjust skew calculation, synchronize too
   - Ping loop improvements
2012-10-03 19:05:56 +00:00
zzz
13ef00cb2e add hasWrapper() 2012-10-03 17:41:33 +00:00
zzz
d2c1641569 * NTCP: Reduce conLock contention 2012-10-03 17:40:59 +00:00
zzz
a1873e74e5 cleanup 2012-10-03 17:40:31 +00:00
8be86fe80c debian: rework oom patch 2012-10-02 19:26:04 +00:00
zzz
4dc90ef5da * SSU:
- Fix memory leak in _peersByRemoteHost map caused by not
     removing peers that change IP or port
   - Send keepalives if firewalled
   - Handle peers that change ports on an established session
   - Synchronize adds and drops
   - Don't use peers with high RTTs in clock skew calculation
   - Reduce initial RTT/RTO
2012-10-02 18:36:06 +00:00
zzz
e130264254 * NTCP: Only set keepalive if firewalled 2012-10-02 12:41:31 +00:00
zzz
93039a6813 * OOMListener: Dump threads on OOM 2012-10-02 12:40:00 +00:00
zzz
07b3c8a7b4 * PRNG, LogWriter: Use I2PThread to catch OOM 2012-10-02 12:38:05 +00:00
zzz
83fe635438 * i2ptunnel: Fix log message 2012-10-02 12:37:16 +00:00
zzz
3ee96fb663 * i2psnark: Fix delete download message 2012-10-02 12:36:34 +00:00
zzz
6684ba1b1d * I2CP: Delay after sending disconnect message to
help it get through
2012-10-02 12:35:45 +00:00
zzz
466778875d * SimpleByteCache: Fix ABQ/LBQ selection 2012-10-02 12:34:29 +00:00
zzz
a71e8fae00 * i2psnark:
- Fix bugs in rarest-first tracking
   - Fix requesting of partial piece when there are multiple seeds
   - Synch fix in BitField
2012-09-28 19:25:31 +00:00
zzz
f58bf3028a javadoc 2012-09-28 19:08:00 +00:00
zzz
595556c39f * SessionKeyManager: Store original tagset size for debugging 2012-09-28 19:06:39 +00:00
zzz
eeaa4fbbb4 * peers.jsp: Remove SSU "Dev" column 2012-09-28 18:48:58 +00:00
zzz
49b11e1f84 * Streaming: Don't send RST on globally-blackisted conns 2012-09-28 18:48:16 +00:00
zzz
e3133d88d7 javadoc 2012-09-28 18:42:17 +00:00
zzz
1a50b6243d volatile 2012-09-28 18:41:19 +00:00
zzz
076558d4f5 * i2ptunnel: Fix wrong server IP in log message 2012-09-28 18:40:49 +00:00
zzz
fb5d0cd760 Boolean.valueOf(x).booleanValue() -> Boolean.parseBoolean(x) 2012-09-28 17:50:41 +00:00
zzz
7c8ba61f03 fix date 2012-09-26 20:03:10 +00:00
zzz
20e463e41b * Streaming:
- Implement changing connection limits on a running session
   - Implement global blacklist
2012-09-26 20:02:36 +00:00
zzz
5d3984e353 * Addresses: Reject numeric IPs of the form n, n.n, and n.n.n
* Console, i2ptunnel: More validation of address and port in forms
2012-09-26 20:00:59 +00:00
zzz
941aea80bb javadoc 2012-09-26 19:58:19 +00:00
zzz
0533aa7f6f * RFC822Date: Synchronization fix 2012-09-26 19:58:08 +00:00
zzz
568e2d5063 tweak to port field CSS 2012-09-26 19:57:37 +00:00
zzz
86c7aa8b8a * i2psnark: Enable DHT by default 2012-09-26 19:57:01 +00:00
zzz
f61e7a193f * ConvertToHash:
- Add support for b64hash.i2p (output in jetty logs)
   - Cleanup and use cache
2012-09-26 19:56:33 +00:00
567dae8ced merge of '6ccace0742effd1eaadcc151f428825fa3215e12'
and 'dc06981e777b7e1c191937d6d8190b26a8f6bbc7'
2012-09-25 22:26:47 +00:00
02f483a873 Modified susimail footer so <hr> is hidden as well 2012-09-25 21:57:22 +00:00
zzz
7051e1c5f6 * UPnP: Cleanup & final 2012-09-25 19:30:49 +00:00
zzz
87295b4bfd * URLLauncher: Add xdg-open (ticket #617); minor refactor 2012-09-25 19:25:01 +00:00
zzz
23ca6b4fac * SimpleByteCache: Concurrent fix 2012-09-25 19:24:11 +00:00
zzz
9e3559625c * OutboundEstablishState: Cleanup (ticket #671) 2012-09-25 19:22:36 +00:00
zzz
351d582c8f * Jetty: Add non-NIO selector option (ticket #715) 2012-09-25 19:21:28 +00:00
zzz
5b1ea6187f * EventLog: Fix IAE on portable 2012-09-25 19:20:15 +00:00
zzz
211782fae4 * Context: Make files final 2012-09-25 19:19:27 +00:00
zzz
20279d1597 propagate from branch 'i2p.i2p' (head 52d5a19210a344e0de43f6fe4d898d34f6c41829)
to branch 'i2p.i2p.zzz.update' (head d88c6abf9b4988ba892e435594cd74917ab9ab7f)
2012-09-25 15:04:49 +00:00
44466aa769 Modified susidns footer so <hr> is hidden as well 2012-09-24 22:17:05 +00:00
d27d014eb0 Show susi footer on susimail and susidns when displayed standalone
Footer hidden when embedded because of margin issues, and out-of-place-ness.
Have confirmed that susi's opinion when the themes were initially updated was
"do what you want", so no legal problem.
2012-09-22 23:47:57 +00:00
zzz
e884ca54ef -1 2012-09-21 17:54:46 +00:00
zzz
336420cf50 propagate from branch 'i2p.i2p.zzz.test' (head 5dadb7923797a3e6d9ead4d4b17ab7e0e0201b2b)
to branch 'i2p.i2p' (head 703251aaf19111efe6fac5a4ae49f00a1aac1e9e)
2012-09-21 17:50:59 +00:00
zzz
f16e83f21b 0.9.2 2012-09-21 14:24:53 +00:00
zzz
0eedc3aa19 intern strings 2012-09-19 20:47:50 +00:00
zzz
f232775161 CoDel for build handler 2012-09-19 19:00:06 +00:00
zzz
bd57463d42 fix NTCP backlogged indication 2012-09-18 12:37:30 +00:00
zzz
2c4910e9e7 * ByteCache, ByteArray:
- Cleanups and javadocs
    - Prevent release of a wrong-sized array
2012-09-17 21:57:16 +00:00
zzz
2b14d32bea use ByteCache for chunks in/out 2012-09-17 21:32:05 +00:00
ee66747def Fix after review and install on fresh osx (lession learned: test clean installs) 2012-09-17 20:33:03 +00:00
zzz
259c28f8c1 startup/shutdown synchronization in several places 2012-09-16 15:47:36 +00:00
zzz
b6a5360390 log/stat tweaks 2012-09-16 15:46:36 +00:00
zzz
0b7b947786 increase flush interval 2012-09-16 15:43:36 +00:00
zzz
147e257cee comment out main() 2012-09-16 15:43:06 +00:00
zzz
ccb8483766 * Build: Fix unpack problem on Java 5: http://forum.i2p/viewtopic.php?t=7334 2012-09-15 13:12:00 +00:00
zzz
68ccb3a944 cleanup 2012-09-14 13:53:36 +00:00
zzz
b317eca5e3 * SSU: Fix shutdown NPE (ticket #709) 2012-09-14 13:50:06 +00:00
zzz
5ffacccdd7 update geoip license 2012-09-14 13:49:32 +00:00
zzz
a41936af94 typo 2012-09-14 13:49:09 +00:00
0991adc291 GeoIPdb update based on Maxmind GeoLite Country database from 2012-09-05 2012-09-13 16:15:09 +00:00
zzz
b9aceb895d * SSU:
- Increase initial and max RTO
    - Don't count ack-only packets in bandwidth allocation
    - Unused method cleanup
2012-09-12 21:55:15 +00:00
zzz
8633ef9513 * Streaming: Don't send a RST to an hour/day limited peer,
or blacklisted, or non-whitelisted, to not waste outbound bandwidth
2012-09-12 21:52:12 +00:00
7820cef60a Czech language translation updates from transifex
(and updated en po files)
2012-09-12 12:04:43 +00:00
zzz
4666454482 improve dup log message 2012-09-11 19:50:59 +00:00
zzz
db42d9ec37 * FortunaRandomSource:
- Fix bug that wasted entropy in nextInt()
    - Improved synchronization
2012-09-11 19:40:20 +00:00
zzz
d7b48a2256 change what we call imminent so we dont display ms 2012-09-10 22:40:21 +00:00
zzz
50ec279917 use partial match for dups; add config for dups 2012-09-10 22:38:18 +00:00
zzz
e8a8f3c210 * TunnelGateway: Implement pushback from a backlogged transport
queue to the pre-fragmentation queue
2012-09-10 21:30:54 +00:00
zzz
e0fc642fc3 reduce _jobLock contention 2012-09-10 17:27:18 +00:00
zzz
835ed6d9bb boost priority of shutdown thread 2012-09-10 17:25:00 +00:00
zzz
3781928693 logging cleanups 2012-09-10 17:22:51 +00:00
cb39006f6c minor corrections after review
The newly added OSX bits by meeh (thanks!) do not require Izpack to perform
substitutions, so I'm removing those files from the <parseable> tags.
2012-09-10 10:51:17 +00:00
52447096f2 Added a fix for a startup issue in newer versions of launchd. Setting Disabled
in configfile will only work on older launchd version. Ref manpage:
  (-w Overrides the Disabled key and sets it to false. In previous ver-
      sions, this option would modify the configuration file. Now the
      state of the Disabled key is stored elsewhere on-disk.)
2012-09-10 03:14:09 +00:00
zzz
2f98d05e7c * Clock: Synchronization, log large shifts to event log 2012-09-09 15:45:29 +00:00
zzz
74e753934c * SystemVersion: New util, to consolidate duplicate code,
and determine Java version on Android
2012-09-09 15:40:14 +00:00
zzz
9bc54f27cf * ClientManager:
- Concurrent client map for faster lookup
    - Add by-hash client map for faster lookup by hash
    - More cleanups
2012-09-08 21:56:05 +00:00
zzz
d9e6c06b22 * I2CP: Buffer output streams
* ClientConnectionRunner: More cleanups and edge cases
2012-09-08 20:45:11 +00:00
zzz
e02d82981a - Run HandleJob inline for speed
- Remove payload from message map if availability announce fails
- Cleanups
2012-09-08 15:10:27 +00:00
zzz
98da06cd83 limit queue size, make nonblocking 2012-09-08 14:25:04 +00:00
zzz
0d62266008 * ClientConnectionRunner: Run MessageReceivedJob inline for speed 2012-09-08 14:04:01 +00:00
zzz
1ae0c2e312 add -test 2012-09-08 13:15:58 +00:00
zzz
61629080b2 propagate from branch 'i2p.i2p' (head 86f3e7e668b7ec9f2ddf75be7586719944bbc37f)
to branch 'i2p.i2p.zzz.test' (head da9536c250bc4c0b7523ed748574de1cc97f3028)
2012-09-08 12:57:09 +00:00
zzz
4cf104720c * PumpedTunnelGateway:
- Move OBGW queue to CoDelPriority
    - Move IBGW queue to CoDel
    - Reduce max pumped per cycle for IBGW
2012-09-08 12:47:17 +00:00
zzz
2c866e205b * NTCP: Move NTCPConnection outbound queue to CoDelPriority
* SSU:
    - Separate PeerState outbound message list into a queue for unsent messages
      and a list for sent messages awaiting ack
    - Implement PeerState outbound queue as CoDelPriority
    - Implement backlogged indication like in NTCP
2012-09-08 12:40:27 +00:00
zzz
ca91ad3188 * SSU: Move MessageReceiver queue to CoDel 2012-09-08 12:34:34 +00:00
zzz
33de6beab3 * SSU: Move UDPSender and UDPReceiver queues to CoDel 2012-09-08 12:29:55 +00:00
zzz
871f046755 adjust target and interval, and backlogged indication 2012-09-08 12:23:43 +00:00
zzz
aef021dcd1 * I2CP: Limit router/client queue sizes and queue wait times 2012-09-07 22:49:24 +00:00
zzz
489f43529c booleanValue() -> parseBoolean() 2012-09-07 20:13:49 +00:00
zzz
78203aac9a * i2psnark:
- Implement blacklist for unreachable DHT peers
    - Reduce threshold for unreachable
    - Log tweaks
2012-09-07 20:10:01 +00:00
zzz
3c95f0b66b * LogWriter: Duplicate log message removal 2012-09-07 18:53:24 +00:00
zzz
3347788712 add isBacklogged() 2012-09-06 19:53:01 +00:00
zzz
0c5b4c05c6 minor cleanups 2012-09-06 19:25:31 +00:00
5056706742 Added command scripts for osx to install i2p as a daemon in launchd.
.command extension make it possible to double click on it like bat files
in windows. Daemon is runned as the user who executes the command file.
2012-09-05 21:36:24 +00:00
zzz
b8949eafe2 Non-codel version of priority blocking queue, so we can
implement priority queues without necessarily committing to codel.
2012-09-05 15:50:11 +00:00
zzz
9286d6a7b8 * IP Lookup:
- Add caching in RouterAddress with secondary caching
      in Addresses; use caches to speed up transport bids,
      blocklist checks, geoip lookups, and profile organizer checks
      (ticket #707)
    - Limit IP cache size in TransportImpl
    - Clear caches at shutdown
  * RouterAddress: Remove unused expiration field to save space
2012-09-04 20:33:04 +00:00
zzz
9fd2f1e6a7 SSU: Fix some issues with queueing outbound establishments 2012-09-04 13:51:55 +00:00
zzz
b98474880d OutNetMessage: Speedup after profiling (ticket #707 - thx dg, kytv, zab) 2012-09-04 13:50:24 +00:00
zzz
5347d296dc log tweak 2012-09-04 13:46:52 +00:00
zzz
666a387d1b log fix 2012-09-04 13:46:31 +00:00
zzz
bb66e16b69 I2PTunnelServer: Clean shutdown after session exception 2012-09-04 13:46:10 +00:00
zzz
2cddf1405f log tweaks 2012-09-04 00:27:04 +00:00
zzz
8575437626 * LHMCache: New util, replacing several private versions 2012-09-03 15:33:12 +00:00
zzz
c965a3dca0 add drainAllTo() 2012-09-02 14:41:21 +00:00
zzz
c48aca8d5c ByteCache: Move all 16/32 byte users to SimpleByteCache;
increase SimpleByteCache default size.
2012-09-02 12:31:08 +00:00
zzz
4360284355 stat and log tweaks 2012-09-02 00:45:58 +00:00
zzz
f44eeaf7dd TunnelGateway: Refactor TunnelGateway.Pending to its own file PendingGatewayMesasge 2012-09-01 21:39:14 +00:00
zzz
a0418bec59 OutNetMessage:
- Centralize priority definitions
  - Raise netdb store and reply priority
GarlicMessage:
  - Add notes about GarlicMessageHandler and HandleGarlicMessageJob
    being unused in practice
2012-09-01 20:47:22 +00:00
zzz
5eff26e40e add minimum priority check 2012-09-01 20:17:37 +00:00
zzz
4e78517651 TunnelGateway:
- Limit queue sizes
  - Add stat for overflow
  - Remove some stats
  - Change pumper to LinkedHashSet for efficiency
    (like NTCP Reader/Writer)
  - Limit messages pumped per cycle to increase
    round-robin fairness
  - Comment out some unused code
  - Javadoc
2012-09-01 17:20:52 +00:00
zzz
10d9eb70c8 CoDel:
- Add logging of drops
  - Set drop stat to delay of dropped item
  - Add no-drop priority
2012-09-01 16:30:12 +00:00
0ba3aad666 Disable i2jump.i2p from the tunnel wizard since it's been disabled elsewhere 2012-09-01 15:02:38 +00:00
zzz
8bfbe855a1 one last SimpleTimer 2012-09-01 13:40:38 +00:00
zzz
3fbf60ee21 Codel:
- Override poll() and drainTo()
  - Tweak stats
  - Add PriorityBlockingQueue version
2012-09-01 13:21:25 +00:00
zzz
6bfd916fef SimpleTimer (ticket #653):
- Move all remaining uses to SimpleTimer2
    - Deprecate
2012-09-01 13:14:15 +00:00
zzz
a5e4b15349 add irc.killyourtv.i2p 2012-08-31 14:47:14 +00:00
zzz
94f370e76c propagate from branch 'i2p.i2p' (head 871765966dc474b763ff0d5c017bed7535981c1e)
to branch 'i2p.i2p.zzz.test' (head 096242c22aa550274cb383a6a0c984cef07ae08c)
2012-08-31 14:41:18 +00:00
zzz
7cc353ab04 javadoc 2012-08-31 14:36:53 +00:00
zzz
506626d6b1 i2psnark: Remove * from magnet and download names 2012-08-31 13:58:37 +00:00
zzz
26898f38ad Startup: Don't complain about clients.config missing on Android 2012-08-31 13:57:24 +00:00
zzz
4fdff1bf13 Router: Lengthen shutdown spinner life 2012-08-31 13:56:24 +00:00
7d4a6e74d2 Report no bugs in Android BitSet 2012-08-31 03:53:19 +00:00
b33a01cf26 use index instead of upper and lower, it's the same thing, but makes more sense. 2012-08-31 02:37:15 +00:00
zzz
0689b03603 - Prevent crashes at update caused by event log starting timestamper thread 2012-08-30 15:29:35 +00:00
zzz
ee8cd29da9 New AQM blocking queue using CoDel reference implementation - untested. 2012-08-30 14:20:37 +00:00
zzz
c4a3159b33 Replace ident log with new, general-purpose event log.
Use for stops, starts, and updates, and others.
Mark all restarts on graphs using the event log.
2012-08-30 14:06:06 +00:00
a4511ca2ab typo fix 2012-08-29 19:17:40 +00:00
zzz
17b4ab6151 message cleanup 2012-08-29 14:16:19 +00:00
zzz
d2a7af2884 refactor trimmers to their own files 2012-08-29 14:05:02 +00:00
zzz
d05f1ca2c8 RandomIterator: Workaround for Android bug (ticket #703)
Include test case
2012-08-29 13:59:44 +00:00
zzz
832d66bfb9 NTCP: Reduce lock contention (ticket #697) 2012-08-29 13:47:05 +00:00
zzz
c8a46dac5d i2psnark:
- Add new flood-resistant KBucket trim policy
   - Limit received MsgID size
2012-08-29 13:45:29 +00:00
zzz
7005376061 - Fix NPE on destroy() if init() failed 2012-08-29 13:29:13 +00:00
zzz
ab213f45e2 cleanups 2012-08-29 13:28:03 +00:00
zzz
fa504ae8a3 - Fix cases where we weren't using the session for b32 lookup 2012-08-27 21:36:39 +00:00
zzz
d305eb6a9c * SSU:
- Limit UDPSender queue size
   - Increase UDPSender max packet lifetime
   - Clear UDPSender queue before sending destroys to all
   - Increase PeerState queue size so large streaming windows
     don't get dropped right away, especially at slow start
   - Various improvements on iterating over pending outbound
     messages in PeerState
2012-08-27 20:39:00 +00:00
zzz
f8bc6f8612 * Streaming: Limit amount of slow-start exponential growth 2012-08-27 20:36:24 +00:00
zzz
9099937119 * Reseed: Remove forum.i2p2.de 2012-08-27 20:35:02 +00:00
zzz
b827468e2f * i2psnark: Notify threads awaiting DHT replies at shutdown 2012-08-27 20:34:19 +00:00
zzz
587795552e Wrapper files for armv7.
Compiled on trimslice:
    gcc version 4.5.2 (Ubuntu/Linaro 4.5.2-8ubuntu4) 
    java version "1.6.0_18"
    OpenJDK Runtime Environment (IcedTea6 1.8.13) (6b18-1.8.13-0ubuntu1~11.04.1)
    OpenJDK Zero VM (build 14.0-b16, mixed mode)
    Wrapper 3.5.15 GPLv2
    All binaries stripped.
2012-08-27 17:43:04 +00:00
0a1ff9b6bd Update Java Service Wrapper to v3.5.15.
- Windows: Self-compiled with VS2010 in Windows 7. The icon has been
   changed from Tanuki's default to Itoopie.
 - FreeBSD: Self-compiled in FreeBSD 7.4 to eliminate the dependency on the
   compat6x port.
 - Linux ARMv5 & PPC32: Self-compiled in Debian Squeeze
 - Linux x86, Linux x64, MacOSX & Solaris: Binares are from the "community
   edition" deltapack offered by Tanuki. The x86 and x64 binaries for Linux
   have been stripped.
2012-08-27 13:49:18 +00:00
zzz
b01cf32321 * SendMessageOptions: Increase tag fields to 4 bits and use
table lookup for more flexibility
 * Streaming: Use packet type and current window size to adjust
              number of tags sent and tag threshold, to improve
              efficiency and reliability
2012-08-26 13:02:11 +00:00
zzz
9ba6c293ed * DataHelper: Trim trailing whitespace when loading properties 2012-08-26 12:54:49 +00:00
zzz
99681e1d1e * NetDB: Increase floodfills, decrease flood redundancy 2012-08-26 12:47:31 +00:00
96775acf5a Dutch and German translation updates from TX 2012-08-25 19:43:25 +00:00
ba992067ad typo fixes (ticket #701), thanks vz 2012-08-25 19:05:45 +00:00
zzz
2552d99308 * Other object churn cleanups (ticket #699) 2012-08-25 14:48:39 +00:00
zzz
e99e25b3b9 minor cleanup 2012-08-25 14:45:31 +00:00
zzz
70820d7be6 * SDSCache: Reduce min and increase max size
* SimpleByteCache: Change from LBQ to ABQ to reduce object churn
2012-08-25 14:44:52 +00:00
zzz
38fda46d44 javadoc 2012-08-25 14:42:04 +00:00
zzz
9d383d6aef * i2psnark:
- Use extended I2CP options for datagrams
   - Fix timeout for sent datagrams
   - Reduce token timeout
   - Check token age before use
   - Limit incoming token size
2012-08-24 22:13:08 +00:00
zzz
ba0408a741 * I2CP:
- Add methods for sending a message with extended options
   - Fix cases where the efficient sendNoEffort() wasn't being used
 * OCMOSJ:
   - Implement per-message overrides for tag threshold,
     tags to send, and bundle leaseset
   - Fix bug adjusting timeouts
   - Warn on client expiration time bugs
2012-08-24 22:11:02 +00:00
zzz
07c21c3bfd - Add link for local torrent file on details page
- Show totals line even if only one torrent
2012-08-24 22:07:00 +00:00
zzz
5ffefd2a19 * Crypto: Rename bouncycastle HMAC libs so they don't conflict
with older Android versions which bundle them
2012-08-23 19:11:55 +00:00
zzz
e3e15850bb * SSU:
- Don't relay or introduce to/from privileged ports
   - Various spoof detections
2012-08-23 19:10:36 +00:00
zzz
54b367b153 * NTCP: Reduce lock contention 2012-08-23 19:08:45 +00:00
zzz
b61127270e * SSU:
- Fail establishment immediately on SessionCreated
     validation fail
   - Defer outbound DH generation until required
   - Validate address/port in RelayIntro messages
   - Throttle hole punches
   - More cleanups
2012-08-22 17:43:09 +00:00
zzz
1d41c2fd19 SSU: Workaround for Android ICS bug 2012-08-22 17:41:43 +00:00
zzz
7c7e131dc0 * SimpleTimer2: Synchronization improvements (ticket #653) 2012-08-22 17:40:47 +00:00
zzz
85fbbf8980 * NetDB: Add hash collision detection 2012-08-22 17:40:25 +00:00
zzz
612fab1b2a * SSU:
- Use external, not internal port to sign SessionCreated message.
     Together with previous fix to allow external port change, this
     should fix session establish fails when NAT changes our port
   - Track outbound establishments by both Hash and IP/port,
     to improve lookups of establishments in progress
   - Fix expiration of outbound establishments
   - Validate address/port in RelayResponse messages
   - Change RemoteHostID to store Hash instead of byte[] for the peer hash
   - Log tweaks
2012-08-21 19:53:08 +00:00
zzz
fbd8c69eea * NetDB: Decrease stat publish probability 2012-08-21 19:49:43 +00:00
zzz
8fcac04aad javadoc 2012-08-21 19:48:18 +00:00
zzz
7d902cca1e log tweak 2012-08-21 19:48:04 +00:00
ddc1d7c6bc disapproval of revision 'acc7942148f44d32fc600d2f5784d1a43496eada' 2012-08-20 21:26:12 +00:00
5bb90c6185 * Fixed the FIXME in createInstance where the method failed to ensures that there will be only one naming service instance. 2012-08-20 18:28:20 +00:00
zzz
9452547204 * SSU: Allow port change if firewalled
* UPnP:
   - Prep for UPnP returning different external port
   - Better logging of errors
2012-08-20 12:22:00 +00:00
zzz
34c09583b4 do not use 8887 default in UI 2012-08-20 12:14:43 +00:00
zzz
38b0927d01 * I2CP: MessageStatus cleanup 2012-08-20 12:13:26 +00:00
zzz
715bde5ecf * Streaming: Increase max connection timeout 2012-08-20 12:12:48 +00:00
zzz
6c2eb317fe * I2PTunnelRunner: Remove unnecessary lock (ticket #690) 2012-08-20 12:10:10 +00:00
zzz
05516f3260 * i2psnark: Add minimum tracker and DHT announce intervals 2012-08-20 12:09:20 +00:00
264df83943 fix hang during uninstallation (#656) 2012-08-18 13:06:07 +00:00
zzz
3a546612d9 * SSU:
- Use remote MTU when published (ticket #687)
   - Queue outbound msgs during inbound establish
   - IntroManager cleanups
   - More synchronization
   - More log tweaks
2012-08-17 14:15:01 +00:00
zzz
3cac01ff27 * i2psnark:
- Adjust DHT timeouts
   - Add max peers per-torrent in tracker
   - Remove duplicate clean task for nodes
   - Fix another DHT warning message
2012-08-17 14:09:49 +00:00
e01521618f BOB: just some cleanup 2012-08-17 05:39:02 +00:00
zzz
ee63f3b86d minor NTCP cleanup 2012-08-16 19:02:38 +00:00
zzz
a900511d5e * Utils: Drop unused BufferedRandomSource, PooledRandomSource,
EepGetScheduler, EepPost and HTTPSendData, moved to i2p.scripts
2012-08-16 18:25:49 +00:00
zzz
3fe092d788 tab cleanup 2012-08-16 18:24:59 +00:00
zzz
e2fe5004e7 javadoc fixes 2012-08-15 14:39:52 +00:00
zzz
442af031eb propagate from branch 'i2p.i2p.zzz.upnp' (head fbd68f812db1e891f96e212b3a5938beec0233b5)
to branch 'i2p.i2p' (head a8d4956565f7c58736c2a3001f2b08ecff59ab57)
2012-08-15 14:29:30 +00:00
zzz
e22882bd02 - More fixups from merge
- Remove local address from thread names for thread dump anonymity
2012-08-15 14:24:40 +00:00
zzz
523d39b3bb * i2psnark:
- Fix bug preventing completion announcement, broken in 0.9.1
   - Fix setting short retry time after initial announce failure
   - Fix DHT announce and getPeers
   - Fix DHT warning message
   - log tweaks
2012-08-15 12:44:46 +00:00
zzz
65efefb094 propagate from branch 'i2p.i2p' (head 51b3351f42e7ff6e2f2bd8512e4b4402e08631f4)
to branch 'i2p.i2p.zzz.upnp' (head d28cfe73c2741ea264f73a7317f8a9919e108170)
2012-08-14 13:50:15 +00:00
zzz
44edf70842 * SSU EstablishmentManager: Fix bug with OB establishment via introducers
- log tweaks
2012-08-13 23:06:07 +00:00
zzz
16a46b3211 * SSU EstablishmentManager:
- Remove use of outbound timers in EstablishmentManager; drive all events in Establisher thread
   - Don't change nonces when retransmitting intro packets
   - More synchronization in EstablishmentManager
   - Increase establishment timeouts and implement timeouts for individual phases (ticket #669)
   - Fix bug where InboundEstablishState.createdPacketSent() wasn't being called,
     so SessionCreated packets weren't retransmitted
   - Increase retransmission timeout for SessionCreated and implement backoff
   - Send destroy if establishment times out in the middle
   - Fix code that pulls outbound states off a deferred queue
   - Improve UDPPacket.toString() for debugging
   - More logging of packets dropped in EstablishmentManager
   - Change establish states to enums
2012-08-13 15:12:33 +00:00
zzz
e9cc85141c comparator cleanups 2012-08-13 15:08:06 +00:00
zzz
cfcafd2ba3 * SSU:
- Reject some packet types if they came in via fallback introKey
   - Increase retransmission timeout for SessionRequest, SessionConfirm,
     and RelayRequest; implement backoff
   - Move UDPFlooder to test
   - More volatiles, finals, cleanups, stat removals, log tweaks
2012-08-12 11:24:15 +00:00
zzz
e67dd15308 * PeerManager: Fix NPE on Android (ticket #687) 2012-08-12 11:19:49 +00:00
zzz
a76f840ff8 remove finalize 2012-08-12 11:18:24 +00:00
zzz
269a36c549 * Jetty: Don't use direct byte buffers that may be leaking (ticket #679) 2012-08-12 11:11:45 +00:00
36bf248385 Removed unnecessary <p></p> around <img> on /graph 2012-08-12 00:35:09 +00:00
046135f8e3 merge of '8027b8544962ebd34af3edfe73bbc8195f8c1e90'
and '871249c3be5c8d8ce83a539ba8c5409876ef3a44'
2012-08-11 14:47:43 +00:00
97e469da7b command safari does not exist. using command "open" instead. 2012-08-11 14:34:20 +00:00
zzz
01beb015dc merge of '52c0538bb3404f46ac4fde538794a547852d5d44'
and 'e40ee84836983c85a8985c0a76e9e5a7635002cd'
2012-08-11 13:55:55 +00:00
zzz
50d5692884 snark build fix sorry 2012-08-11 13:51:52 +00:00
0ea6513e9c Changed my reseed url to contain a subpath, /netDb/. also updated the certificate (forgot to copy out of conf folder when i changed webserver and deleted config). 2012-08-11 13:43:48 +00:00
zzz
e2b683556b merge of '15095538e7b5c72468863e969541571ade1796f9'
and '39af5d31a13c5d5b71107e2caa0c234b84827c03'
2012-08-11 12:26:32 +00:00
zzz
14587ebb59 dash six 2012-08-11 12:16:43 +00:00
zzz
be3cf44608 get rid of one more UnsupportedOperationException 2012-08-11 11:41:29 +00:00
zzz
1538cd84a9 * DataHelper: toString(byte[]) cleanup and javadoc 2012-08-11 11:40:41 +00:00
f5b808b997 OSX: Fixed a bug in OS_VER variable.
the old version (grep -o '[0-9]*\.[0-9]*\.[0-9]*') won't detect versions as 10.8, or 10.7
added cut -d: -f2 | sed -e 's/[^0-9]*//' , matching both 10.8, 10.7.4, etc.
2012-08-11 11:40:05 +00:00
zzz
f92d8aed3d make context list concurrent 2012-08-11 11:34:32 +00:00
zzz
f6c769187e fix 2012-08-11 11:33:43 +00:00
zzz
c70e3727be * SSU MTU (ticket #682):
- Use local MTU detection
   - i2np.udp.mtu now sets max MTU, not initial MTU
   - Put local MTU in netDb 
   - Fix receive MTU calculations
   - Track remote MTU based on actual received packet size
   - Display local MTU on peers page
2012-08-11 11:27:28 +00:00
zzz
a6a0228ef8 * i2psnark: Fix DHT nodes not being saved at shutdown
Log infohashes in hex
             Don't write out nodes if we don't have any
2012-08-11 11:23:27 +00:00
d2a5595df2 Added new reseed host, and a self signed certificate for that host. 2012-08-11 01:14:58 +00:00
e9c07a123a German and Greek translation updates from Transifex 2012-08-11 00:25:43 +00:00
1e8e2a197b A fix for ticket #684 2012-08-10 23:55:14 +00:00
zzz
39d9d3f5b6 * SAM: Don't use direct byte buffers for streams (ticket #679)
DatagramServer one stays as it is a singleton.
2012-08-09 15:12:17 +00:00
zzz
8bada7f882 merge of '01c1a5c0e70a460534e66dd487aa8676d666168d'
and '441b352d1cef1c64ee96f55692be67cfc4b4abf1'
2012-08-09 15:03:01 +00:00
a940062255 add ')' missing from str4d's checkins 2012-08-09 11:35:41 +00:00
93efd31a5b merge of '62c3f266fd9443e9d7b3f71be8f4b36b4952f96b'
and 'd71795fa9a3d5fa0349f46eef4062670755b2cff'
2012-08-09 02:37:19 +00:00
2e9fdc6d9f Updated history.txt 2012-08-09 02:36:39 +00:00
zzz
b9f5f230a2 stub out local MTU detection (ticket 682) 2012-08-08 23:36:11 +00:00
zzz
0a751a303f post-0.9 cleanup 2012-08-08 17:09:28 +00:00
zzz
b2da629034 * Datagrams: Remove static logs 2012-08-08 17:07:28 +00:00
zzz
37a542c009 NTCP stat cleanup 2012-08-08 17:06:33 +00:00
zzz
0451ee7f08 * SSU: More cleanups; don't send a packet that exceeds the MTU 2012-08-08 17:05:42 +00:00
zzz
d8dd76c6e0 * SAM: Volatiles and finals 2012-08-08 17:01:59 +00:00
zzz
9cee0ee504 * i2psnark:
- Remove static SnarkManager instance
   - Allow DHT-only torrents
   - DHT debugging
2012-08-08 17:00:33 +00:00
b464ef0ac3 propagate from branch 'i2p.i2p.unittests' (head 58a62605ce8542f7e5d5daf0c2e171ed0c7e1a74)
to branch 'i2p.i2p.zzz.update' (head 269547972f0e02fe545296823602995465bb0691)
2012-08-08 00:15:55 +00:00
7f09206a47 Fixed jarScalaTest targets to actually package all classes 2012-08-08 00:07:17 +00:00
65573eafac Use ScalaTest jars in routerconsole tests 2012-08-07 23:12:37 +00:00
58a545d30c Snark: explicitly check if universal theme is "classic", and use "light" if so 2012-08-07 23:08:37 +00:00
dfb0b7801d Updates to classic console theme from dr|z3d 2012-08-07 23:03:34 +00:00
aab2c0601d propagate from branch 'i2p.i2p.unittests' (head fb681c6fa25bcf9f7287a661b3ce626fd5a280bb)
to branch 'i2p.i2p.zzz.update' (head f3c8cb8ad1d68cc6a66d544f1e287eead786c5ce)
2012-08-07 12:42:48 +00:00
a21175d903 propagate from branch 'i2p.i2p' (head b1fe8f8037e6dd8a1f6be6e30151ad0ca92e6689)
to branch 'i2p.i2p.str4d.fux' (head 723929af49930ca764fe4befb3621a036a3f99b8)
2012-08-07 12:28:30 +00:00
9c7f4cc604 merge of '6014a9321bb2362ffc628a351c1db19922384f76'
and 'd68b6ad6b4308d8dbe27d1faac089cb15358bfa2'
2012-08-07 12:24:33 +00:00
3017e4f51a Fixed .mtn-ignore to ignore build dirs properly 2012-08-07 12:18:16 +00:00
5355e5bbfd Added targets to build i2p.jar and router.jar with ScalaTest classes included 2012-08-07 11:58:11 +00:00
5ed1ec681f Updates to classic console theme from dr|z3d 2012-08-07 11:42:22 +00:00
0a4031cd7b Updates to midnight console theme from dr|z3d 2012-08-07 06:03:35 +00:00
31ea4a7093 Changed universal theming prop key (so not mistaken as a theme name by routerconsole) 2012-08-07 04:29:50 +00:00
0ca2d33ee1 New midnight theme for susidns from dr|z3d 2012-08-07 04:24:41 +00:00
48bcd3a8c2 Updates to console and snark themes from dr|z3d 2012-08-07 04:22:40 +00:00
zzz
1ab8200c7f * Clone System properties before iterating to avoid
ConcurrentModificationException (ticket #680)
2012-08-06 14:45:37 +00:00
zzz
91e61dbd5c fix flag links so language selection returns to the same page 2012-08-06 14:13:15 +00:00
zzz
fb4ef57148 propagate from branch 'i2p.i2p.zzz.dhtsnark' (head d4f16babae7cb0156609b211f5bb0310b03aaf57)
to branch 'i2p.i2p' (head 7bcd2f192b0f571374cc9882eca407095eb97c17)
2012-08-06 14:05:09 +00:00
zzz
ced0129e03 * libjbigi.so for ARMv6
GMP 4.3.2
    Compiled on Raspberry Pi with gcc version: gcc (Debian 4.6.3-8+rpi1) 4.6.3
    java version "1.6.0_24"
    OpenJDK Runtime Environment (IcedTea6 1.11.3) (6b24-1.11.3-2+rpi1)
    OpenJDK Zero VM (build 20.0-b12, mixed mode)
    Stripped.
    Had a report that the ARMv5 jbigi worked on the RPi but it didn't for me.
    See NativeBigInteger for more info.
    /proc/cpuinfo:

Processor	: ARMv6-compatible processor rev 7 (v6l)
BogoMIPS	: 697.95
Features	: swp half thumb fastmult vfp edsp java tls 
CPU implementer	: 0x41
CPU architecture: 7
CPU variant	: 0x0
CPU part	: 0xb76
CPU revision	: 7

Hardware	: BCM2708
Revision	: 0002
2012-08-06 14:04:32 +00:00
740b6501cd Updated history.txt 2012-08-06 12:38:00 +00:00
07e18c07ac Added ScalaTest support to routerconsole build.xml
To run (once tests exist) execute something like

ant -Dclasspath=/usr/share/java/mockito-core.jar
    -Dscalatest.libs=./lib
    -Dwith.cobertura=/usr/share/java/cobertura.jar
    fulltest
2012-08-05 22:20:19 +00:00
zzz
67f16b0de4 javadocs 2012-08-05 16:55:39 +00:00
zzz
fd3d92d3b2 merge of '1045fe48c576267959eae499a22776d9f9acafc3'
and 'bed1572eff55282ffcb5a2b92d02813eb04c0548'
2012-08-05 15:16:45 +00:00
zzz
5ba5d537b5 * UDP:
- Limit PacketHandler threads to 1 (ticket #660)
   - Limit queue sizes between UDPReceiver and PacketHandler,
     and between PacketHandler and MessageReceiver, to prevent OOMs
     and/or excessive queue delays
   - Increase UDPPacket cache size based on max mem
   - Remove more stats
2012-08-05 14:24:14 +00:00
zzz
4efa87d6bf * i2ptunnel, I2CP, EepGet: Buffer socket input streams (ticket #666)
* I2PSessionImpl: One more volatile (ticket #659)
2012-08-05 13:33:28 +00:00
442897ba5b merge of '48ea7675889a36bfb253833a66c22275abcee355'
and '925b1411e60b0e76e2421becd84d6c63832b69bb'
2012-08-05 07:40:05 +00:00
2b79da5c35 Debian: update patch to compensate for last commit
At the same time I'm making more Debian-specific changes, such as
 - not checking for Gentoo (this is obviously never going to be true :P)
 - not mentioning IzPack replacing variables (also not applicable)
 - inform about dpkg-reconfigure i2p in the event someone tries to remove or
   install an initscript with "i2prouter install|remove|uninstall"
 - remove the manual wrapper instructions
2012-08-04 17:44:09 +00:00
cc3a8e5d62 have izpack expand %USER_HOME in i2prouter
This will solve the issue of I2P_CONFIG_DIR being set incorrectly if another
user runs i2prouter once, such as when installing the initscript.
2012-08-04 17:32:11 +00:00
zzz
280a708afe - Change secure Node ID requirements again
- Protect against null DHT races
- Add message about restarting tunnel when DHT config changes
- Add DHT size to table totals
2012-08-04 17:11:11 +00:00
f5a348a863 propagate from branch 'i2p.i2p.str4d.test' (head 190d9be59620f8c6f80e0cb2fc4d9fa839edbb4f)
to branch 'i2p.i2p' (head c884db74f90a9d1c33deca6e2fd2e29f6c1ac8fa)
2012-08-03 21:30:29 +00:00
85a4e9cb5c Clarified purpose of the default IRC tunnel (it's not a "proxy") 2012-08-03 21:26:09 +00:00
zzz
4715dbdbd0 fixup after prop 2012-08-03 20:40:31 +00:00
zzz
afad77af19 propagate from branch 'i2p.i2p' (head d2198c4bc21a9d06194cdb2dce24945ebc9d1542)
to branch 'i2p.i2p.zzz.dhtsnark' (head 59fc0206608a5d1323a0acfbcb151d862fe95f95)
2012-08-03 20:29:31 +00:00
zzz
94d51bd56f log tweaks 2012-08-03 19:58:38 +00:00
zzz
72ed1bc1ac fixups after prop 2012-08-03 18:56:53 +00:00
zzz
4a1b83961d propagate from branch 'i2p.i2p' (head d2198c4bc21a9d06194cdb2dce24945ebc9d1542)
to branch 'i2p.i2p.zzz.update' (head 88ac67dc4e166b7e9dec0d3224e58bec4894440d)
2012-08-03 18:30:39 +00:00
zzz
b4a50ed03a replace SimpleScheduler.getInstance() calls 2012-08-03 17:13:17 +00:00
zzz
00f9fea98c replace SimpleTimer2.getInstance() calls 2012-08-03 16:23:31 +00:00
zzz
501651125f * UDP:
- Catch some cases where UDPPackets were not returned to the cache (ticket #675)
   - Fix inverted logging logic (ticket #663)
   - Remove check in UDPPacket.getLifetime() (ticket #664)
   - RemoteHostID cleanup, cache hashcode
   - Remove udp.fetchRemoteSlow stat
   - Remove some time stamping in UDPPacket
   - Other cleanups - see http://zzz.i2p/topics/1198
2012-08-03 14:25:32 +00:00
zzz
18e8d35910 * LogManager: Add logger.logBufferSize and logger.dropOnOverflow options (ticket #662) 2012-08-03 13:42:40 +00:00
zzz
9e4d231285 final 2012-08-03 11:23:09 +00:00
zzz
2972e79f9e * OutNetMessage: Fix NPE when log level = INFO (ticket #676) 2012-08-03 11:22:48 +00:00
zzz
4d32eaa036 * JobQueue: Synch fix (ticket #670) 2012-08-03 11:21:28 +00:00
zzz
e4f141b94c * build.xml: Add buildI2PTunnelJar target for Android 2012-08-03 11:20:28 +00:00
zzz
ccf36abd30 * i2psnark: Finish migration to I2P logging to reduce object churn (ticket #673) 2012-08-03 11:19:52 +00:00
d147db3382 Only call SaveConfig once in ConfigUIHandler 2012-08-03 03:49:46 +00:00
9d29dc6b68 Fixed bugs introduced while reverting 2012-08-01 05:54:07 +00:00
6562b33bbc Removed readConfigFile and writeConfigFile from I2PAppContext (unnecessary now) 2012-08-01 03:05:18 +00:00
f58f297cdb Reverted susimail to storing theme itself, but checking routerconsole for universal theming 2012-08-01 03:00:23 +00:00
376b991b63 Reverted i2psnark to storing theme itself, but checking routerconsole for universal theming 2012-08-01 02:44:18 +00:00
120d31244e Reverted i2ptunnel to reading theme from routerconsole 2012-08-01 02:26:26 +00:00
679549cbf2 Reverted susidns to storing theme itself, but checking routerconsole for universal theming 2012-08-01 02:04:00 +00:00
a623d924fa Reverted routerconsole to storing theme itself, also store universal theming boolean 2012-08-01 01:50:59 +00:00
95fb141ad9 0.9.1 debian changelog 2012-08-01 00:34:17 +00:00
fad6f54794 propagate from branch 'i2p.i2p.unittests' (head 0c5ea65761d9127f160bccb3d1d157f8947ca050)
to branch 'i2p.i2p' (head e36d5669f32ad1a0f66ab84f7f9ff8fa2937680b)
2012-07-31 21:49:31 +00:00
e1525d98cd Fixed paths to JUnit tests in javadoc targets 2012-07-31 21:26:46 +00:00
3d69d2bf63 If the theme set for susidns doesn't exist, use the default instead 2012-07-31 12:56:23 +00:00
cb2dd03e77 Refactored writeConfigFile to use DataHelper.storeProps, tidied up logging 2012-07-31 12:52:31 +00:00
3253f82900 Added ScalaTest support to router build.xml 2012-07-31 00:06:28 +00:00
zzz
33a00efd82 * RoutingKeyGenerator: Cleanups (ticket #672) 2012-07-30 22:39:47 +00:00
zzz
8bcbf24713 propagate from branch 'i2p.i2p.zzz.test' (head 5474e1a513fc8144a3d855e9c85d8b235f7f9816)
to branch 'i2p.i2p' (head 5932d3923108572b22a8a7a600f0f9e62ecac347)
2012-07-30 22:29:02 +00:00
52ba727664 line ending fixes
These CSS files improperly contain a mixture of Windows *and* UNIX line
endings. Some lines had ^M after them but most didn't.
2012-07-30 17:01:12 +00:00
a1cfacd8da merge of '3347c631d86a2ccf634321b74e24b9a58e490a15'
and '95d885a94cdde7ad40bbef11ec76f86d1ea7b798'
2012-07-30 16:51:05 +00:00
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
39d954d56a merge of '00209f1054786667de66adbd6038fccf8825260f'
and '180794b6e2aad94450e102b4ac346f8172811ba1'
2012-07-28 22:22:07 +00:00
78b1922dd7 "11th hour" de & es translation updates from TX 2012-07-28 21:18:56 +00:00
639253e9bb Fixed a bug in a console_big.css override in light and dark themes 2012-07-28 13:45:12 +00:00
f8fe2a295f Fixed icon column width being too large in snark filemanager 2012-07-28 13:38:40 +00:00
9d2831f520 Updated history and bumped build number 2012-07-28 12:47:42 +00:00
c2438a7508 Fixed an i2ptunnel button regression in the dark console theme 2012-07-28 12:33:36 +00:00
zzz
4298958952 comment out tests 2012-07-27 15:49:46 +00:00
zzz
54a80d6bdc javadoc 2012-07-27 15:31:20 +00:00
zzz
aba655a9c7 move default properties from build.xml to build.properties 2012-07-27 15:30:11 +00:00
b6eef94383 Tweaked console themes so console error pages look alright in iframe
This fixes the issue where, when an iframed app was not running, the summary
bar would be displayed inside the iframe as well as outside it.
2012-07-27 12:41:45 +00:00
7526db9e6c minor update to reflect the other systems that we support 2012-07-26 21:11:42 +00:00
c853337d41 merge of '3b6726af78088f84c156c7d5cb40aa0b73946465'
and '5b76774cf78d7a3537006860fc78c00c191c9cb0'
2012-07-26 20:50:39 +00:00
00dd72e284 July 2012 GeoIP db update 2012-07-26 20:32:04 +00:00
05850371a6 Finnish, French, German, Spanish and Swedish translation updates from TX 2012-07-26 20:31:01 +00:00
c285cb84bd BOB Fix static references to Log 2012-07-26 20:30:42 +00:00
a4a0e1def3 Replaced a few more /home icons 2012-07-25 23:38:25 +00:00
fea7a42ece Reset spin flag in BOB 2012-07-24 18:38:36 +00:00
72f74b7f6e Disabled the iframe fallback for the summary bar
HTML compliance wins out over summary bar refresh for users with JS disabled,
for now - get user feedback after release.
2012-07-24 13:15:11 +00:00
a92456e144 Updated history.txt 2012-07-24 12:47:21 +00:00
7f7a82802d Added CC attribution for Creative Commons Cat 2012-07-24 12:07:09 +00:00
93097ab630 Moved RestartStatus back above LocalDestinations in default /home summary bar 2012-07-24 12:05:34 +00:00
d3d22a8f4b Added license for new /home icons 2012-07-24 05:32:40 +00:00
7a1b082216 Updated /home icon for git.repo.i2p 2012-07-24 05:18:20 +00:00
0e907c5ad0 Replaced 16x16 /home icons with 32x32 ones 2012-07-24 05:17:13 +00:00
59b8dc4f41 Update to dark console.css - more space efficient on /home, "0px" -> "0" 2012-07-24 03:23:51 +00:00
299109433c merge of '03b8e025ba8c54efe24644ee68500ae2ff0ea2de'
and 'b45f7b28764f452bbd5f58ebd598f465565cab5c'
2012-07-23 23:30:39 +00:00
zzz
9823d761d9 dont create router.ping file on Android to reduce flash wear 2012-07-23 23:21:20 +00:00
db6b8d3b6b debian: minor improvements to the build script
- Tighten setting of Debian version in I2P
- Ensure the clean target will remove .so and .o files
2012-07-23 23:20:23 +00:00
c61a18545e Debian: Use our Jetty/Tomcat libs instead of the ones from Debian/Ubuntu (for now at least).
Tomcat6 & Jetty6 are going to be dropped from the next release of Debian stable
(Wheezy) in favor of Tomcat7 and Jetty8.
2012-07-23 23:13:28 +00:00
zzz
c1181f855a remove unused dirs 2012-07-23 23:11:50 +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
7f18d25d0d Re-add alt="" to some icons in snark to prevent double text in text browsers 2012-07-23 21:49:30 +00:00
314817242b If the theme set for susimail doesn't exist, use the default instead 2012-07-23 11:01:39 +00:00
945a0f30aa If the theme set for snark doesn't exist, use the default instead 2012-07-23 10:39:11 +00:00
a7c8a7201a When fetching a theme, if theme config key is not found, write out the default
This is required in order to get the theme config keys of the various apps into
themes.config; this way, the routerconsole requires no knowledge of what apps
support universal theming, and can just blanket apply themes to all known keys.
2012-07-22 13:13:43 +00:00
6be94658a7 Use router console theme setting from themes.config in i2ptunnel 2012-07-22 11:33:20 +00:00
490dcc5020 Bugfix: update SnarkManager._theme each time getTheme() is called
FIXME: ensure that _theme is only read from the config file once per page load.
2012-07-22 06:59:43 +00:00
8e6bade42b Added checkbox to console to set theme universally across all apps 2012-07-22 06:53:43 +00:00
c145e4267c Fixes to light/console_ar.css 2012-07-22 00:18:07 +00:00
a4064190dd merge of '5aab7ebb6f496024fff1cc4b87e39475a7277db0'
and 'b2e508dbe3e9c7c67bb38d3f573481ae3fb8c9b3'
2012-07-21 20:59:01 +00:00
f97213630c Reverted susimail and snark links in /home and summarybar to point directly at app
The iframing pages remain accessible in the console, so this may be reverted in future,
or made configurable. The /webmail link buried in the text of the several readme.html
files has been left.
2012-07-21 20:57:46 +00:00
6a21e22bf1 Moved dark snark theme out of bundled themes dir due to an image issue
dr|z3d is happy for the problem image to be replaced and the theme reinstated
when universal theming support is added (likely 0.9.2)
2012-07-21 20:43:33 +00:00
zzz
77f8729257 new cowpuncher cert 2012-07-21 19:26:29 +00:00
zzz
39d4e1be72 SSU: Remove excessive exception creation (ticket #665) 2012-07-21 13:04:50 +00:00
zzz
ebe55aba61 remove dark as requested 2012-07-21 13:03:27 +00:00
3c4f1b7814 Store susimail theme setting in themes.config 2012-07-21 12:33:42 +00:00
ce024ff006 Store susidns theme setting in themes.config 2012-07-21 11:39:13 +00:00
e603b120c3 Store snark theme setting in themes.config 2012-07-21 11:06:24 +00:00
b17af505c2 Replaced a hard-coded string that was missed in previous commit 2012-07-21 10:22:12 +00:00
5d5a3b80e5 Store router console theme setting in themes.config 2012-07-21 10:11:32 +00:00
c8a73b63fd Added methods to read and write properties in arbitrary config files 2012-07-21 10:07:04 +00:00
ce7a46bbed Open Previewed http dests with target="_parent" in i2ptunnel
Before iframing i2ptunnel, clicking the Preview button would open the site in the parent
window. This change will cause the sites to open in the parent window from
within the iframed page.
2012-07-20 19:20:18 +00:00
eee67f09e1 en PO files updated and pushed to tx 2012-07-20 17:59:39 +00:00
ab7246565c Reverted alt tags in status column of snark 2012-07-20 04:16:53 +00:00
096d067d6c Updated history and bumped build version 2012-07-20 01:18:24 +00:00
9d2709be19 Update to light theme to increase top margin of iframes 2012-07-20 01:13:01 +00:00
3cce978e26 New light snark theme from dr|z3d (integrates well with light console theme) 2012-07-20 00:59:13 +00:00
8f30a74c7d Split up status and show/hide peers headings into separate columns 2012-07-20 00:57:53 +00:00
a86a2ba04a Moved text from headings in snark filemanager into tooltips (in line with main page)
Directory column could do with a different icon.
2012-07-20 00:36:43 +00:00
f4ffb30153 Added iframed fixes to default.css in classic, light and midnight console themes 2012-07-19 23:05:25 +00:00
ecdaa6f2b3 Removed text headings and status text from main snark page to reduce visual clutter
The header icons are self-explanatory (but tooltip also has header text); the
status text is available from the tooltip.
2012-07-19 21:39:17 +00:00
2b8b406f9d Added title and alt tags to Status and Torrent columns in snark main view 2012-07-19 13:06:45 +00:00
212a794c65 Give div.app fixed height for classic and midnight console themes
This stops app icons getting "stuck" on the right-hand side of /home
2012-07-19 00:41:52 +00:00
0e2dede168 Replaced itoopie with a dedicated icon for eepsite links on /home with no favicon 2012-07-19 00:08:29 +00:00
c1f3fa6004 Updates to dark susi themes and new light newsbullet from dr|z3d 2012-07-18 23:44:55 +00:00
e2be19039f Added missing git.repo.i2p and id3nt.i2p entries to hosts.txt 2012-07-18 12:33:30 +00:00
zzz
846f6f2190 * Home page: Add colombo-bt.i2p, remove keys.i2p
Icon created and contributed by colombo-bt.i2p
2012-07-18 12:00:42 +00:00
zzz
37716f34de * i2psnark: Clear rate stats when restarting torrent 2012-07-18 11:52:20 +00:00
f01ccf9797 Update to dark susimail theme from dr|z3d 2012-07-18 03:56:35 +00:00
074baa63f5 Fixed /home tooltip to not break page 2012-07-18 02:50:13 +00:00
763eb08dad Added git.repo.i2p and id3nt.i2p to /home eepsite list 2012-07-17 21:27:22 +00:00
1d40a88166 Fix snark Ajax JS (wrong level of escaping of quotes) 2012-07-17 20:55:36 +00:00
5766b36b33 Give the summary bar sections string names (some already translated) 2012-07-17 20:36:57 +00:00
4cea0b6099 US spelling 2012-07-17 19:44:44 +00:00
43fd5caf30 Fixed snark initAjax method so it runs (I'm SURE it did before...) 2012-07-17 19:32:22 +00:00
5c1a1b13f4 Update to dark susimail theme from dr|z3d 2012-07-17 12:22:52 +00:00
109e1a75bf Improved alignment of news headings in classic and midnight themes 2012-07-17 11:40:44 +00:00
99f8384129 merge of '9fdbbb81553e767812b7a8634edd867cb1ca8438'
and 'cc04809f72ea9e8f0e0427484d65f613838f65d7'
2012-07-17 10:56:51 +00:00
f3cb399605 Update to dark susidns theme from dr|z3d 2012-07-17 10:56:20 +00:00
c94ce79e68 Added links inside <iframe> tags on iframed pages to corresponding apps 2012-07-17 01:20:08 +00:00
744930a090 Consolidated Ajax calls for summary.jsi into a single summaryajax.jsi 2012-07-17 00:47:08 +00:00
be7aa991d7 Consolidated the common iframing JS into /js/iframed.js 2012-07-16 23:39:44 +00:00
c815bc2996 Removed spurious UTF8 chars from dark/console_ar.css 2012-07-16 21:36:48 +00:00
924520955e merge of '369340479baf15d01ba95519145edddba22634ca'
and '3b7088110cf55db67e72b7e9bfbf8cd832daac06'
2012-07-16 21:34:41 +00:00
0bff0a4998 Removed backup favicon.ico from css.jsi (all current themes have favicons) 2012-07-16 21:32:47 +00:00
691c003e95 merge of '762f90d57bd57a4e0b122dff85484774b0105d93'
and 'd02235b886c4e596e3c980dcb0b8df9d3547d103'
2012-07-16 21:29:04 +00:00
a28dab9bdc Bumped build number to -22 2012-07-16 21:04:11 +00:00
c33c0259a7 Only set extraversion in Unix since Windows doesn't have awk available
I need to investigate a cross-platform method.
2012-07-16 17:47:48 +00:00
77d40f8d31 propagate from branch 'i2p.i2p.str4d.fux' (head 48cafeb29fb3408078a8b93c0bab0fc9d766a8bc)
to branch 'i2p.i2p' (head 47f04ff21e8edd00134a0fd68219f86fd3caba36)
2012-07-16 16:17:19 +00:00
619b766c85 Removed CSS hiding susimail Cancel button (it might be hiding other buttons) 2012-07-16 16:13:03 +00:00
693ffed9be Updated history.txt 2012-07-16 16:11:03 +00:00
c175d5470f Updates to dark console theme from dr|z3d 2012-07-16 14:50:56 +00:00
42e6d06559 Whitespace fixes to dark susimail theme 2012-07-16 14:04:58 +00:00
25da127d02 Whitespace fixes for light susimail theme 2012-07-16 13:58:22 +00:00
00b88675ea Whitespace fixes in light susidns theme 2012-07-16 13:56:31 +00:00
c552db59e4 Whitespace fixes in dark susidns theme 2012-07-16 13:53:54 +00:00
763116fb24 Updates to dark susidns theme from dr|z3d 2012-07-16 13:50:21 +00:00
f3531f1c2c Updates to dark console theme from dr|z3d 2012-07-16 13:47:03 +00:00
a2a67d82ab Some updates to ieshim.css in classic theme to fix some IE console regressions 2012-07-16 13:44:58 +00:00
zzz
69cdcc8226 * XORComparator: Reduce object churn (Ticket #658) 2012-07-15 15:04:58 +00:00
5e11e51f6a Added "theme" to list of susidns config options 2012-07-15 13:13:57 +00:00
a419347eba Added preliminary dark susimail and susidns themes
Add "theme=dark" to susidns config page, or "susimail.theme=dark" to
susimail.config file, to enable the dark themes.
2012-07-15 11:03:51 +00:00
ab42e47385 Added iframing pages for susimail and susidns 2012-07-14 21:56:38 +00:00
50cfd52c23 Moved susidns CSS into themes dir (required moving loadConfig into BaseBean.java) 2012-07-14 06:27:23 +00:00
e0ff0c63c8 Moved susimail CSS into themes dir 2012-07-14 03:46:23 +00:00
a123def967 Inter-browser fixes for dark snark theme from dr|z3d 2012-07-14 01:38:14 +00:00
8360a2f4e7 Console theme hacks from dr|z3d to target specific Opera oddity 2012-07-14 01:29:04 +00:00
f13a1b2aed Tweak to snark dark theme from dr|z3d 2012-07-14 00:54:05 +00:00
cec5838649 Added newsbullets from dr|z3d to the other themes 2012-07-14 00:48:28 +00:00
2c0de05e9d Updates to dark console and snark themes from dr|z3d 2012-07-14 00:18:16 +00:00
f782afef8d Add scrollbar width to iframe height, so vertical scrollbar doesn't appear
FIXME: add horizontal scrollbar detection so only adding the extra height
when it is actually needed.
2012-07-14 00:13:33 +00:00
a45688867d Add README.Debian to the package
Previously, README.Debian use to be installed to /u/s/d/i2p. A while ago I
split I2P into smaller packages and symlinked /usr/share/doc/libjbigi-jni and
/usr/share/doc/i2p to /usr/share/doc/i2p-router. I didn't noticed that
README.Debian wasn't being included after the split, so now I'm explicitly
adding it.
2012-07-13 00:41:44 +00:00
6104cfa56a el & nl after poupdate
I nearly always run ant poupdate before checking in language files; I neglected
to do it for the last check-in.
2012-07-13 00:35:25 +00:00
6869ed937b Translation updates from tx
- Add Greek language
- Update Dutch translation
- Adjust flag rows
2012-07-13 00:28:06 +00:00
945cc55b54 move check for binary down since osx binaries are no longer 'fat' 2012-07-12 22:43:12 +00:00
7e7cabfdc2 Added getElementsByClassName shim for IE 2012-07-12 21:47:09 +00:00
cbd61e2fce Tweak to get rid of iframe scrollbars in dark snark theme 2012-07-12 14:21:37 +00:00
ffdac3ce2c Added some non-breaking spaces to error.jsp where JSP was eating the spaces 2012-07-12 13:40:54 +00:00
eaa64cb02f Removed superfluous "Updating:" from update status (section has a heading now) 2012-07-12 13:39:32 +00:00
b36a418dff More changes to dark snark theme from dr|z3d - close to RTM 2012-07-12 13:37:51 +00:00
46ca3ab51d Used JS changes to fix iframed i2ptunnel scrollbar issue in CSS
Also added comments to the JS to point out that the issue is that
offsetHeight doesn't include the very top or bottom margins.
2012-07-12 13:34:19 +00:00
0deaab7c1a Improvements to resizing JS in iframed app container pages 2012-07-12 13:07:48 +00:00
c6d45b22b6 Added links to iframed pages to open them in new tabs (as per old console) 2012-07-12 10:32:00 +00:00
69bcc9d012 Dark snark theme updates from dr|z3d 2012-07-11 21:47:50 +00:00
182409ce3a Corrected titles of iframed pages 2012-07-11 21:44:02 +00:00
c45dc0c838 Moved add and delete buttons into sidebar config table, and removed unnecessary ones 2012-07-11 21:20:35 +00:00
7d175678ab CSS for the sidebar config table from dr|z3d 2012-07-11 12:06:59 +00:00
dd86515d2e Tweaks to dark snark theme from dr|z3d 2012-07-11 12:02:58 +00:00
b1a4b8bfed Rearanged columns of summary bar config table 2012-07-10 23:35:54 +00:00
ac9bdab78e Added class to summary bar config table 2012-07-10 22:48:59 +00:00
177b6e2d48 Link both icon and text for tracker and magnet entries in snark torrent info 2012-07-10 22:48:07 +00:00
b48014f8e6 Use favicon from theme in I2PTunnel if it exists 2012-07-10 21:29:49 +00:00
f1881352c8 Further tweaks to ubergine and vanilla themes by dr|z3d for new layouts 2012-07-10 21:10:58 +00:00
d6572fd027 Give update status section a heading to draw attention to it, display total size 2012-07-10 21:07:36 +00:00
7e5edc2f6e Changes to snark themes from dr|z3d to work with new layouts
(and a tweak to dark console theme)
2012-07-10 19:30:42 +00:00
709c75c517 Reordered torrent info section in snark filemanager - reduced to 4 info lines 2012-07-10 19:03:48 +00:00
ebc4d53fa9 Corrected output of message to notice instead of error on summary bar config page 2012-07-10 12:05:07 +00:00
dbd95c5c64 Added extra column to keep ordering buttons in line 2012-07-10 11:57:40 +00:00
42565f19fc Use image buttons for ordering summary bar sections (images courtesy of dr|z3d) 2012-07-10 11:42:20 +00:00
8d9909acfb To improve themability, make torrent info table in snark filemanager a single column 2012-07-09 21:17:02 +00:00
9c7f9a935b Only add new summary bar sections to the bottom 2012-07-09 20:35:58 +00:00
c9fc3f11a6 Replaced text fields for ordering summary bar with movement buttons (CSS styling needed) 2012-07-09 07:59:41 +00:00
75046d11fb Separated disabling of iframe refresh from the refresh time 2012-07-09 00:39:52 +00:00
bb39d9ddcf Integrated summary bar preset buttons into main edit form as restore buttons 2012-07-08 22:11:05 +00:00
fb629404c6 Split torrent info and dir info on snark filemanager into two separate tables 2012-07-08 21:35:49 +00:00
78691ba344 Updates to dark console theme from dr|z3d 2012-07-08 12:07:54 +00:00
f41fde8471 Updates to dark snark theme from dr|z3d 2012-07-08 12:05:17 +00:00
319d217dc1 Slight simplification of class injection for iframed app pages 2012-07-05 13:04:45 +00:00
ec80501977 Remaining size in snark filemanager reads GB instead of Gbyte etc (consistency) 2012-07-05 13:01:00 +00:00
4a0319389b A few more newlines to improve HTML readability 2012-07-05 12:22:56 +00:00
ebcc304642 Fixed a few colspans that were missed when adding icon/thumbnail td 2012-07-05 11:49:36 +00:00
c695a51883 Tidy up layout of rendered HTML for one row of snark filemanager 2012-07-05 11:47:41 +00:00
3cc447c5f2 Put icon/thumbnail for snark filemanager in separate td 2012-07-05 11:36:10 +00:00
52742ceeca Moved "View or change bandwidth" link inline to tidy up vertical alignment 2012-07-05 02:55:28 +00:00
08d86019e4 Uncommented input.default CSS (to hide extra Add button) in dark snark theme 2012-07-05 02:50:01 +00:00
582a62d75b Added classes to and removed hard-coded layouts from snark config page (stubbed in CSS) 2012-07-05 02:48:45 +00:00
8ebadf5236 propagate from branch 'i2p.i2p' (head 5b24a07e8a843d03ea45e664c59b93937c5efc42)
to branch 'i2p.i2p.str4d.fux' (head 0bfff6086d6f72df836909ae379a95ebbe4b6933)
2012-07-05 00:48:41 +00:00
814f5ca194 Arabic-specific console theming for dark from dr|z3d 2012-07-05 00:36:32 +00:00
3da63182cd Updates to dark snark theme from dr|z3d 2012-07-05 00:35:09 +00:00
029a903d79 Expanded resizeFrame() to prepare for more intelligent iframe-sizing 2012-07-04 12:49:54 +00:00
zzz
e2588a5379 move DecayingBloomFilter, DecayingHashSet, and xlattice filters from core to router 2012-07-02 19:22:33 +00:00
zzz
0d8bcd5dad * i2psnark:
- Don't send a keepalive to a peer we are going to disconnect
   - Disconnect peer when idle a long time
   - PeerCheckerTask cleanup
   - Static ref cleanup
   - Don't show a downloaded torrent file as "seeding"
   - Better torrent file download icon (from Silk, same license as the others)
2012-07-01 16:16:08 +00:00
zzz
63f22a54e1 fix unsafe initialization of super constructor calling override 2012-06-29 17:21:57 +00:00
zzz
ab18550711 * Update: Increase eepget timeouts to reduce retries 2012-06-29 16:25:22 +00:00
zzz
4092f61898 * Streaming:
- Allow at least 3 packets and up to half the window to be active resends
     instead of just 1, to reduce stall time after a packet drop
   - Increase fast retransmit threshold back to 3 to reduce retransmissions
   - Don't fast retransmit if we recently retransmitted it already
   - Allow double the window as long as gaps are less than the window
   - Don't set the MSS in a resent packet (saves 2 bytes)
   - Remove redundant calls to updateAcks()
   - Update activity timer when resending a packet
   - Reset unackedPacketsReceived counter at all places where acks are sent
     so it isn't wrong
   - Fix some places where the activeResends count could become wrong
   - Prevent storm of CLOSE packets
   - Never resend the whole packet in ackImmediately(), just send an ack
   - Cancel flusher timer in MessageOutputStream when closed
   - Move some createRateStats to ConnectionManager to reduce repeated calls
   - Cleanups, javadocs, logging, volatile, finals
2012-06-29 14:53:53 +00:00
zzz
ebb6609a2b fix SimpleTimer logging 2012-06-29 14:05:39 +00:00
820345f84d Changes to dark theme from dr|z3d to improve look of tunnel wizard 2012-06-29 13:49:37 +00:00
zzz
5a1d52d82c * HTTP Proxy: Change the error code for unknown host from 404 to 500. 2012-06-29 13:30:24 +00:00
9adb97d300 Tweak to dark console theme .iframed .panel margins 2012-06-28 03:36:31 +00:00
eae4d704a1 Copied body.iframed CSS from dark i2ptunnel.css to dark snark.css 2012-06-27 03:26:22 +00:00
84cc6711b4 Dark theme for i2psnark from dr|z3d - for better integration with router console 2012-06-27 03:19:30 +00:00
5be02b1592 Fixed JS for iframed apps so the CSS class is injected on page change 2012-06-27 02:16:21 +00:00
255894e241 Embed /i2psnark/ in an iframe like /i2ptunnel/ 2012-06-27 02:00:30 +00:00
zzz
6c8c87b2dd javadocs 2012-06-25 19:29:51 +00:00
zzz
dba3fee477 - Concurrent PeerCoordinatorSet
- final infoHash in Snark
2012-06-25 18:20:18 +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
ff0bfb9f12 * i2psnark: Don't create a new PeerCoordinator after restart, as the
TrackerClient holds on to the old one and that causes it
             to not get peers. Possibly fixes ticket #563.
2012-06-24 19:26:23 +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
588799a2ff Update to dark theme from dr|z3d 2012-06-24 01:15:06 +00:00
zzz
d5a1e0b1c6 - Add kad lib, from i2p.zzz.kademlia branch (without the history),
which is a rewrite of the netdb kad
- Drop now-unused SHA1Comparator
- Efficiency tweak to NodeInfoComparator
2012-06-22 17:39:41 +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
8522779df1 - Switch to real kad with lib from i2p.zzz.kademlia (not checked in yet)
- Bootstrap only once in explore thread
- Add exploring to explore thread
- Don't store default DHT setting in config file, so we can switch default to true later
- Add new enforce-protocol streaming config, sorry locks out < 0.7.1 peers
- Log tweaks
2012-06-22 15:12:43 +00:00
7976ba1dff Only display summary bar "Show news" link on /home (/console already has one) 2012-06-22 01:32:07 +00:00
e88ca3048c Removed unnecessary extra sentences from summary bar tooltips 2012-06-22 00:08:43 +00:00
8412bafc5c Use JS injection to allow iframe-specific I2PTunnel styling 2012-06-21 23:47:49 +00:00
zzz
2a8adcb89a * IRC Client: Don't flush output unless out of input, so the
streaming messages don't get split up unnecessarily
2012-06-21 21:16:54 +00:00
zzz
829e3f47ff Store context in the PeerSelector so we don't have to pass it around 2012-06-21 20:52:39 +00:00
zzz
4e4634496a * TunnelPool: Fix bug where a tunnel was marked as reused when it wasn't 2012-06-21 20:26:29 +00:00
zzz
d148efd458 * TunnelPoolManager: Use one ClientPeerSelector for all pools 2012-06-21 20:08:02 +00:00
zzz
f7656b0401 * TunnelInfo: Change msg counter from long to int 2012-06-21 19:59:29 +00:00
zzz
6635448bda * I2CP: Make separate message ID counters per-destination, use atomic,
increase max (could have caused "local loopback" problems)
2012-06-21 19:52:00 +00:00
zzz
baa89c5bbf * OCMOSJ, ElG, Streaming: log tweaks 2012-06-21 19:10:14 +00:00
ab1144865f propagate from branch 'i2p.i2p' (head 204c786941e233e9ed0e447499049f5c21103f40)
to branch 'i2p.i2p.str4d.fux' (head 5bc2b4f4713087086e44eca6678d880651fa717a)
2012-06-21 04:05:48 +00:00
4348ff2689 Added custom bullet to newsheadings li 2012-06-21 01:54:28 +00:00
33c4b321db Fix up alignment of news headings in other themes 2012-06-20 12:56:00 +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
99eb49e347 Added favicons to resident themes (dr|z3d's dark favicon for dark and midnight themes) 2012-06-20 02:55:44 +00:00
11f111790e Use a theme-specific favicon.ico if it exists 2012-06-20 02:48:24 +00:00
zzz
f8e470c7f4 propagate from branch 'i2p.i2p' (head a38c8874bc61e9bf11c4d43666ad72cd5eecbf8a)
to branch 'i2p.i2p.zzz.dhtsnark' (head 028e93195ce28c8b6fbe573e6c660d5c329df42a)
2012-06-20 01:19:25 +00:00
zzz
d8a2e39006 from last checkin - fix enforce proto default, fix http client delayed start 2012-06-20 01:19:05 +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
e383477b01 * Socks: Pass remote port through
* I2PTunnel: More javadoc warnings on default options
2012-06-19 21:48:31 +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
48f29ff1b8 - Hide buttons while stopping all 2012-06-19 20:24:30 +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
d368937bce dash sixteen 2012-06-18 21:40:05 +00:00
zzz
4b3ccabb44 - Thread task to open tunnel and improve UI feedback while open is pending 2012-06-18 21:07:34 +00:00
zzz
4dcfe3e434 * i2psnark:
- Improve torrent shutdown handling to maximize chance of
     announces getting to tracker
   - Clean up delete-torrent messages
   - Remove redundant shutdown hook
   - Avoid NPE in PEX message handling
   - Log tweaks
2012-06-18 18:06:47 +00:00
zzz
273d7399a0 jump table tweak 2012-06-15 01:30:58 +00:00
zzz
5ce0479268 tweaks 2012-06-15 01:29:29 +00:00
zzz
de3ce6cdb7 handle jump servers with ports 2012-06-14 22:08:40 +00:00
zzz
3e192cc57e remove text about restart 2012-06-14 22:07:28 +00:00
zzz
6c5902837c * NetDB: Only publish stats every so often, to improve
anonymity while preserving the ability to monitor
          the network (effective next release)
2012-06-14 19:48:12 +00:00
zzz
e522ffad4e * I2PTunnel:
- More client options cleanups
   - Options changes now propagate to running
     socket managers and sessions, and through to the router
 * SocketManager:
   - Simplify factory, use 4-arg constructor,
     make fields final, deprecate 0-arg constructor
   - Improve how options are updated
   - Javadocs
2012-06-14 19:44:47 +00:00
zzz
64221fb3fb * I2PSocketEepGet: Use specified port
* I2PTunnel:
   - Don't strip port from an I2P URL
2012-06-14 19:42:07 +00:00
zzz
c73044b6b4 * Streaming:
- Channel cleanups and comments
   - New I2PSocketAddress
2012-06-13 19:08:49 +00:00
zzz
ad1b356879 * i2psnark: Possible fix for piece-after-choke 2012-06-13 19:04:11 +00:00
zzz
07caf2e316 * I2PSocketEepGet: Set port to 80
* I2PTunnel:
   - Pass port through HTTP client proxy
   - HTTP server proxy sets host header to
     the value of "spoofedhost.xx" option for port xx
   - Set client options more efficiently
2012-06-13 19:02:09 +00:00
zzz
c2137a2a80 - Add explore thread
- More checks for stopping
- Add xor of port to secure NID
2012-06-12 21:38:25 +00:00
zzz
44da37f009 - Timeout if can't find b32
- Refactor ReplyWaiter
2012-06-12 19:22:31 +00:00
zzz
d0b967388a rework DHTNodes to hide the CHM implementation, in prep for real Kad 2012-06-12 18:30:58 +00:00
zzz
41096c7f23 - Add heardAbout() and call for receive peers
- Move last-seen tracking from NodeInfo to NID, add fail tracking
- Make NodeInfo fields final
- Remove nodes on consecutive failures
- Only persist nodes heard from recently
- Implement NID verification for security
2012-06-12 18:09:42 +00:00
4f6fb6993d Pass requestURI through to xhr1.jsp so forms work and correct summary bar is chosen 2012-06-12 00:12:51 +00:00
fa3e3e0764 Enforcing minimum refresh rate better, and reducing it to 3 seconds
This does mean that the iframe don't-refresh state (= refresh rate of 0 seconds)
doesn't hold if the page is changed (in fact, the refresh rate becomes the
minimum) - so maybe better to have a different config var for that?
2012-06-11 23:33:33 +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
6e52ae307c * Router: Don't let shutdown tasks hang the shutdown 2012-06-11 20:09:31 +00:00
zzz
6e077ee621 * i2psnark:
- Reduce TrackerClient threads
   - Reduce delay between peer adds for faster startup
   - Thread the announces and reduce timeout when stopping
2012-06-11 19:38:33 +00:00
zzz
30e2f73d5f * i2psnark:
- Display torrent file downloads in torrent area
   - Sort magnets and downloads first
   - Fix sorting problem when torrent dir is a symlink
   - Reduce max file idle time
   - arrow_down icon copied from console css
2012-06-11 12:04:40 +00:00
zzz
7469e9c63d * NativeBigInteger: Workaround for Raspberry Pi to load the correct lib 2012-06-11 11:48:34 +00:00
296ddbe930 Removed some unnecessary <hr>s 2012-06-11 05:32:53 +00:00
e20f2d0bf6 Summary bar for /home defaults to reduced preset, everywhere else to full preset 2012-06-11 05:29:27 +00:00
cc61f4eb61 Some changes to enable per-page sidebar configuration from the config file 2012-06-09 13:48:26 +00:00
0a61b8052c propagate from branch 'i2p.i2p' (head 44d553e8644f01d5e5af3c3145210bdb0a923d3c)
to branch 'i2p.i2p.str4d.fux' (head 51022349e906bd393602b558861bcaaac4d56c89)
2012-06-09 06:11:40 +00:00
cbcbfea6e8 Shorten /i2ptunnelmanager to /i2ptunnelmgr (/i2ptunnel is surplanted by /i2ptunnel/) 2012-06-09 06:08:44 +00:00
57abfe7653 Set position: absolute for div.routersummaryouter so /home app icons don't clear past it 2012-06-09 04:33:29 +00:00
zzz
e0313814b8 disable private config for default trackers 2012-06-08 16:39:10 +00:00
zzz
59df524a91 * i2psnark:
- Move private tracker config from create box to torrent config
   - Refactor private and open tracker configuration
   - Add private indication on details page
2012-06-08 16:11:55 +00:00
zzz
b304393bc3 * netdb.jsp: Don't show our info on summary page since there's a tab for it now 2012-06-08 16:10:26 +00:00
f6304ccd4d Commented out "All times are UTC" blurb because all graphs are labeled UTC 2012-06-08 12:58:50 +00:00
9d241cc0d4 Added tooltips to the various sections of the summary bar 2012-06-07 14:14:13 +00:00
a46ca210f5 Added some spaces to notification messages on /configsidebar 2012-06-07 11:11:37 +00:00
328857f97f Tweaks to config nav bar in dark theme from dr|z3d 2012-06-07 10:39:14 +00:00
b00fbfa23d Centre box for order of new section, and add default value 2012-06-07 10:26:44 +00:00
3a75f8d7d1 Modifying section addition to show an option list
Also adding form handler class that I forgot to commit earlier.
2012-06-07 04:42:52 +00:00
84344b6789 Added a config page for summary bar 2012-06-07 02:51:22 +00:00
b75d28fd0d Added /i2ptunnelmanager which wraps /i2ptunnel/ in an IFrame
/i2ptunnelmanager redirects to /i2ptunnel/ if the browser doesn't support IFrames.
2012-06-05 15:19:40 +00:00
a8424e59b0 propagate from branch 'i2p.i2p' (head ab5f37b28e499d49e108e8e6869164d107c7049e)
to branch 'i2p.i2p.str4d.fux' (head fb4425cd3e38762f211f73d91c7a173972e7145c)
2012-06-05 13:38:02 +00:00
420bf851b5 Added Ajax script to every routerconsole page that includes summary.jsi 2012-06-05 13:37:10 +00:00
83c8233812 Insert routerconsole.summaryRefresh config value into Ajax script
This way, both Ajax and IFrame get their refresh time from config (though
IFrame one can still be modified live).
2012-06-05 13:00:40 +00:00
52a3860717 Rearrange summary bar code to consolidate Ajax and IFrame, and /home and /console
Now, Ajax will be used first, and will fall back to IFrame if JS is disabled,
and a separate page if on a text or mobile browser.
Also, /home and /console (and everywhere) now all have the same summary bar
content, which currently defaults to the original full listing.
2012-06-05 12:44:17 +00:00
531c6c0f4c Implementation of customisable summary bar via routerconsole.summaryBar property
The initial attempt using mapping of strings to methods is shorter and neater,
but also doesn't work so is commented out.
2012-06-05 07:36:24 +00:00
5699b4515b Preparations for making the summary bar customisable 2012-06-05 02:12:30 +00:00
zzz
6a1b90f8f8 hash caching 2012-06-05 01:03:39 +00:00
ceedc9c645 Moved rendering of news headings into SummaryBarRenderer
An instance of NewsHelper needs to be passed in to get output.
2012-06-04 23:46:03 +00:00
zzz
3f40487c99 - Add persistent local DHT storage
- Shutdown now closes tunnel
- Delay after sending stop announces at shutdown
- Stub out using Hash cache
- Implement stop for all cleaners
- Log tweaks
2012-06-04 22:34:56 +00:00
zzz
a6f7761544 propagate from branch 'i2p.i2p' (head ab5f37b28e499d49e108e8e6869164d107c7049e)
to branch 'i2p.i2p.zzz.dhtsnark' (head afa1bbfb0882c9c1946ec32b87300e127c9928b2)
2012-06-04 14:26:10 +00:00
zzz
e1c9cd6cdc * i2psnark: Take tracker out of opentracker list when removed 2012-06-04 14:25:53 +00:00
zzz
d5cb443925 - Switch back from storing NID to full NodeInfo for outgoing tokens so they don't get expired early
- Announce only to the single closest DHT peer
- Increase random port range
- Decrease max local tracker and DHT size
2012-06-04 14:15:38 +00:00
9333cd56f9 Moved calls to external renderers into separate methods to match the rest 2012-06-04 13:28:52 +00:00
910001e3a1 Split HTML rendering of summary bar into separate methods
This solidifies the summary bar design pattern of modular sections separated by
<hr>s which in future could be reordered or hidden without affecting the theme.
2012-06-04 13:10:12 +00:00
zzz
121491a3be - B32 lookup if required for non-announce queries only
- Token timeout tweaks
- Most classes package private
2012-06-03 16:05:38 +00:00
zzz
152b2152cb - Fix node ID / node info confusion
- Fix updating node ID when receiving pong
- Fix getting DHT enable setting from config file
- Fix handling of get_peers replies
- Fix sending and receiving announces without signing
- Fix incoming/outgoing token handling
- Set cleanup timer for all queries
- More debug logging
2012-06-03 15:25:51 +00:00
0abbe45a6d correct flag country (I copied the line and changed all but the flag) 2012-06-03 15:02:27 +00:00
403d6a322a Italian language updates from tx & debconf updates
-10
2012-06-03 14:34:39 +00:00
4ec20ef796 typo fix (*facepalm*) 2012-06-03 14:09:41 +00:00
3b7eaa107e s/$ENGLISHNAME/$NATIVENAME/g 2012-06-03 13:52:27 +00:00
8375e9129d enable Hungarian in another spot 2012-06-03 13:46:33 +00:00
53fbece6b5 Hungarian language translation by AdminLMH from TX
Thanks!
2012-06-03 13:46:07 +00:00
69d909d3eb Added <hr>s to separate the various logs on /logs 2012-06-03 00:22:03 +00:00
zzz
4346c90aa2 lower log level 2012-06-02 21:45:00 +00:00
zzz
f8c185d09f prep for merging 2012-06-02 21:44:23 +00:00
zzz
558bb2f4f3 select proto on UDP send 2012-06-02 18:56:10 +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
bec33cad87 propagate from branch 'i2p.i2p' (head f005cd64cce03cf3a301359f94380bc20eaa7c61)
to branch 'i2p.i2p.zzz.dhtsnark' (head 0562e4f429dcebf3f623d0975bd3a63d7645c0b7)
2012-06-02 15:16:14 +00:00
zzz
eb6217add9 add failsafe check for job queue sort order 2012-06-02 13:49:38 +00:00
zzz
7d94f9fb19 improve opentracker configuration 2012-06-02 13:49:14 +00:00
zzz
324e9c960d fix partially-complete torrent not announcing 2012-06-01 14:12:32 +00:00
zzz
96575e61f2 * Console: Tab the netdb and profile pages 2012-06-01 13:30:38 +00:00
zzz
8d57cba762 * NetDB: Reduce flood redundancy from 8x to 6x 2012-06-01 13:27:53 +00:00
zzz
e1823ece68 whitespace fix 2012-06-01 13:27:01 +00:00
b23414eab1 Reordered /home summarybar, added <hr> after update download button 2012-06-01 01:21:57 +00:00
zzz
38a4f05000 * i2psnark:
- Close connection immediately if bad protocol,
     this makes blacklist work better too
   - Stop adding peers when we hit the limit
   - Lower limit for outbound connections so we give
     new peers a better chance in large swarms
2012-05-31 15:20:50 +00:00
zzz
041c87a2c9 * i2psnark:
- Add per-hour conn limit
   - Blacklist peer after two bad handshakes
   - Reduce connect timeout
2012-05-31 12:19:27 +00:00
ef06fc758c Show news headings in the /home sidebar when the main news div is hidden
Note: this now refreshes along with the rest of the sidebar, so the news.xml
file is read once every 15s - it may be better to cache the headings somewhere,
though it's debatable whether reading the cache file is better than reading the
news.xml file...
2012-05-31 09:30:30 +00:00
9f1c95c829 rework patch to deal with my earlier changes to jcpuid's build.sh 2012-05-30 20:42:06 +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
ddc329e8f1 Handle URI encoding, UTF-8, and multiple trackers in magnet links 2012-05-30 19:45:45 +00:00
zzz
8453c34bfc Improve rarest-first behavior by not favoring a partial piece
held by multiple peers when requesting from a seed
2012-05-30 15:21:37 +00:00
zzz
c6fcdf967c increase per-minute conn limit from 6 to 8 2012-05-30 14:10:03 +00:00
zzz
1427c502c0 Reduce log level to warn for normal EofException when generating graphs 2012-05-30 14:09:16 +00:00
zzz
4e84370128 Increase max upstream form field to 4 digits (9999) ticket #645 2012-05-30 14:06:45 +00:00
zzz
5314d886be merge of '539c9ff2992eb584e2c311924370437f167f0b99'
and 'b355f1862601a6a192c42f1f50743f2a4f0b4c22'
2012-05-28 22:20:19 +00:00
zzz
829af21c49 javadoc fix 2012-05-28 18:04:11 +00:00
c9406b8f96 document changes for Arch 2012-05-28 17:01:31 +00:00
af398632f3 Add initscript support to i2prouter for ArchLinux
With this commit, ArchLinux users can run "i2prouter install" to install an
initscript to /etc/rc.d.
2012-05-28 16:59:47 +00:00
e574b5e61a minor updates to jbigi/jcpuid scripts
- use my find-java-home stub script when building jcupid
- move find-java-home to core/c
- add support for ArchLinux to find-java-home
2012-05-28 16:56:08 +00:00
d946fda859 Replace reseed host i2pbote.net with euve5653.vserver.de (http://trac.i2p2.i2p/ticket/445) 2012-05-26 07:25:44 +00:00
df3771e791 merge of '60890b0ffbf109b297bd6dd66a28d8179322331a'
and '7e63908db8b78229f8f0c963050b062ce0f6dd96'
2012-05-25 21:09:25 +00:00
zzz
df00725077 compile fixup after merge 2012-05-25 20:30:06 +00:00
zzz
26846d592c merge of '10bd7656ab9a474e3bb2d405d50261f147690ce4'
and 'c3f96ef85962a5e9a3896e117036cc83b37fe3a8'
2012-05-25 20:11:28 +00:00
zzz
21466e017f explicit merge of 'dd3f93f7ec59e6a7f967945a75c5d4d7b53539ed'
and 'e99d32aef6da4112890ebe09c3f7d8fcb8b647e5'
2012-05-25 19:55:02 +00:00
zzz
b033db969c Revert all changes to the org/cybergarage library
in the 2009-08-11 whitespace cleanup at ef1c23821d433903124f7612cbc46ac096fc985b
to make merging with the newer library easier.
2012-05-25 19:52:39 +00:00
zzz
d18e4d430c explicit merge of '59eae97dbb470d8c4a1e4dba3a9763e134bb0c53'
and 'aeec86a504a5fd67dff12d6775411a9c865d42ad'


Merge to aeec86a504a5fd67dff12d6775411a9c865d42ad
which is just before the 2009-08-11 whitespace cleanup at ef1c23821d433903124f7612cbc46ac096fc985b
2012-05-25 19:36:22 +00:00
zzz
14ac5ac03e Cyberlink for Java v2.1 (2011-09-16) from SVN,
with extra parsers in xml/parsers removed.
Diverging from original v1.7 checkin in prep for merging.
2012-05-25 17:47:18 +00:00
464279ca1c German, Spanish, and Swedish translations from Transifex 2012-05-25 12:40:12 +00:00
6014de9cd5 Italian translation updates from Transifex (thanks colombo-bt!) 2012-05-25 11:05:22 +00:00
e7c3e07626 A few more CSS changes to finish tweaking /home.jsp for the other themes 2012-05-25 05:27:46 +00:00
c4057bb5a0 A few trivial CSS changes to get /home.jsp looking better with the other themes 2012-05-25 01:27:48 +00:00
34f0420753 Changes to dark theme
- improve /home.jsp
- general theme tweaks and fixes
2012-05-25 00:58:29 +00:00
10bd1343c3 Changes to structure of /home.jsp to bring it back in line with /console.jsp 2012-05-25 00:43:29 +00:00
zzz
4979f8dace - Custom tracker map AIOOBE fix, thx kytv 2012-05-23 22:40:03 +00:00
zzz
b2846de94f propagate from branch 'i2p.i2p' (head 8066e0ff00b526c6971e77de44ff2d322f25069a)
to branch 'i2p.i2p.zzz.dhtsnark' (head f857dd921a7c806c85eb80419f4f9fdd3b6428a2)
2012-05-23 16:56:13 +00:00
zzz
501f2f85d5 * jobs.jsp: Add more queue diagnostics 2012-05-23 16:37:43 +00:00
zzz
580bb5a6fe * i2psnark:
- Fixes when complete except for skipped files
     (ticket #447) status in UI, don't connect outbound,
     disconnect seeds when done
   - More classes pkg private
2012-05-23 16:36:37 +00:00
zzz
e27df771aa - Fix deadlock when changing file priorities 2012-05-22 19:26:37 +00:00
zzz
0f321f1597 - Refactor tracker map 2012-05-22 18:19:52 +00:00
zzz
10872f751e - Prevent torrent shutdown when changing file priority to skip 2012-05-22 18:18:30 +00:00
zzz
20567ae75e * RoutingKeyModifier: Update after large clock shift 2012-05-22 18:16:51 +00:00
zzz
f06d99480d javadoc fixes 2012-05-21 12:53:56 +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
6972d9d02b change stat name, log tweak 2012-05-20 18:18:58 +00:00
zzz
d8b3d2c508 * i2psnark:
- Create sparse files at torrent creation and delay
     "ballooning" until first write (ticket #641)
   - Redo clear messages button
   - Concurrent message queue
2012-05-20 18:15:36 +00:00
zzz
1da1dce981 * Profiles: reduce same-country bonus 2012-05-20 18:13:11 +00:00
zzz
c4f9485e13 * Console: Add full file path to thread dump message 2012-05-20 18:12:41 +00:00
zzz
9cff4d5a42 final 2012-05-20 18:12:20 +00:00
zzz
6ca4b519bf * i2psnark:
- Store received chunks in temp files
   - Don't allocate from heap for unneeded chunks
   - Remove peer count restriction for torrents with large pieces
   - Use priorities and rarest calculations to sort partials
   - Preserve p parameter in clear messages link
2012-05-19 13:27:02 +00:00
zzz
3685bf04d0 add X-Frame-Options to console headers 2012-05-13 13:05:17 +00:00
zzz
fc5e30e6ae better throttle log msgs 2012-05-09 21:07:33 +00:00
zzz
047c668ee1 dont include wrapper .txt files in installer 2012-05-09 21:06:59 +00:00
zzz
e55a1f608a comment out unused text summaries 2012-05-09 21:05:34 +00:00
cbbf82a4ae Stricter match by matching 'Version:' 2012-05-09 02:18:20 +00:00
81d9e2f164 update changelog 2012-05-06 10:36:22 +00:00
8397296286 Add 'graceful' / comment out stanza not needed on Ubuntu 2012-05-06 10:35:59 +00:00
06d0412558 Spanish & German translation updates from transifex
(These were sent to transifex too late to make it into 0.9)
2012-05-05 20:30:08 +00:00
ffde067c5e s/Reunion/Réunion/ 2012-05-05 16:00:37 +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
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
377aa9bca1 In core build.xml, tell junit to look for the hamcrest libraries
hamcrest-core.jar, hamcrest-library.jar and hamcrest-integration.jar should be
present in $ANT_HOME/lib/ (real or symlinked).
2012-03-20 00:29:14 +00:00
67da35ab35 Commented out test for net.i2p.data.Lease.getNumSuccess() / getNumFailure 2012-03-16 05:08:31 +00:00
136d77a8aa Fix YKGenerator test - methods no longer static 2012-03-16 04:51:55 +00:00
bf0b59b3b3 Remove DHSessionKeyBuilderTest from CryptoTestSuite 2012-03-16 03:18:53 +00:00
f19bc6a4b0 Moved DHSessionKeyBuilderTest to net.i2p.router.transport.crypto 2012-03-16 03:08:10 +00:00
79ab065500 propagate from branch 'i2p.i2p' (head e1c79060790ae24b2a96aff2857477d6528ae7c6)
to branch 'i2p.i2p.unittests' (head 357abd51672dd9950cbac6dd30ded117fe5695e0)
2012-03-16 02:30:42 +00:00
9d07bc241c Replace hostname included by junit in reports with "i2ptester"
The fake hostname can be overridden by setting the host.fakename property.
2012-03-16 01:41:23 +00:00
786a261a70 Fixed usage of assertEquals - should be assertEquals(expected, got) 2012-02-29 05:34:13 +00:00
a226d25dc6 Test getters etc. in RateStat 2012-02-29 05:01:21 +00:00
d436c846ac Temporarily exclude slow core tests for dev purposes 2012-02-27 03:29:13 +00:00
24268c5130 Exclude classes from code coverage report that aren't in net.i2p.*
The classes are specifically excluded rather than only including net.i2p.*
so that only classes we know we want to exclude get excluded.
2012-02-27 03:26:58 +00:00
22900a0d91 Fixed RouterAddressTest.testToString to actually test the returned String 2012-02-26 09:30:27 +00:00
e7922c4ded Added some tests of setOptions to RouterAddressTest 2012-02-26 04:57:31 +00:00
f19ef3e486 Fix test that would always pass 2012-02-26 03:01:48 +00:00
4148aa54f3 Need to run clean and prepareTest before test in router build.xml 2012-02-25 01:48:31 +00:00
204440b06b Run full test reports with fulltest target, not just junit report 2012-02-25 01:46:46 +00:00
6a26c0b621 Edited router build.xml to match core build.xml (inc. clover, cobertura stuff) 2012-02-25 01:43:15 +00:00
c955adf7f6 Set up report targets properly in main build.xml 2012-02-25 01:29:08 +00:00
c68d53faf3 Removed fullclovertest target from main build.xml
Clover usage is triggered by setting with.clover instead.
2012-02-25 01:23:17 +00:00
ceda7c9ca0 Fix jbigi.jar path in test target of router build.xml 2012-02-25 01:21:31 +00:00
849c407712 Added clover targets to core build.xml as well, so either will work
Pass in the absolute location of clover.jar as the with.clover property
to activate the clover targets.
2012-02-21 04:05:27 +00:00
a2217b2b36 Fiddle with cobertura definitions a bit in core build.xml
To run with cobertura, execute the following in "core/java/":
ant -Dwith.cobertura=/usr/share/java/cobertura.jar cobertura.report
2012-02-20 03:44:23 +00:00
c7d473a7eb Shuffle round mkdirs and deletes in router build.xml to match core build.xml
batchtest has a todir config option that makes manual copying unnecessary.
2012-02-18 02:13:46 +00:00
d1a03f500f Moved mkdir above delete in core build.xml and removed mkdir from base build.xml
mkdir does nothing if the directory exists, whereas delete fails by default
if the directory doesn't exist. Also, mkdir creates parent dirs as needed.
2012-02-16 02:58:25 +00:00
8a32aad6c3 Shuffled build targets around to group together ones related to unit tests 2012-02-16 00:08:27 +00:00
zzz
d8080278b3 initial DHT code, needs work 2011-02-06 00:12:54 +00:00
zzz
9d91b90d3c propagate from branch 'i2p.i2p' (head d32b82100cf6076e8f3de30b6a0edfbb034caac7)
to branch 'i2p.i2p.zzz.pcap' (head 551957edb05526df88ff3a2b3c717faed4aac906)
2009-12-27 15:07:45 +00:00
zzz
9203663abf propagate from branch 'i2p.i2p' (head 3f19ceea830345f8c34cbccfef3c759d48cd2f7e)
to branch 'i2p.i2p.zzz.pcap' (head fe70e551db5af3ebac9564b4868a28a1ebab7227)
2009-11-23 13:39:27 +00:00
zzz
d078ed396f move init, add config 2009-11-06 19:16:23 +00:00
zzz
7c36c0c8e7 add TCP options block 2009-11-06 16:39:05 +00:00
zzz
404754bc90 streaming lib packet capture first cut 2009-11-06 12:47:21 +00:00
2136 changed files with 324527 additions and 249947 deletions

48
.gitignore vendored Normal file
View File

@ -0,0 +1,48 @@
# Just to try and prevent some noob disasters.
# Use git add -f foo.jar to ignore this ignore list
# generated release files
*.exe
*.[gx]z
*.bz2
*.[rwjt]ar
*.sig
*.su[d23]
*.deb
*.zip
*.torrent
*~
web-fragment.xml
web-out.xml
*.out
# Temporary/build dirs
build/
pkg-temp/
classes/
dist/
/installer/resources/locale/mo
/tmp
/apps/jetty/jettylib
*_jsp.java
*.class
# Debian-related
/debian/copyright
/debian/changelog
.pc/
# Build property overrides
/override.properties
# Reporting
*.fba
sloccount.sc
/reports/
# Don't allow patches
*.(diff|patch)
# but allow debian/patches
!/debian/patches/*.(patch|diff)

View File

@ -1,7 +1,10 @@
# Just to try and prevent some noob disasters.
# Use mtn add --no-respect-ignore foo.jar to ignore this ignore list
# Temporary/build files
_jsp\.java$
\.bz2$
\.tar$
\.class$
\.diff$
\.exe$
@ -13,14 +16,35 @@ _jsp\.java$
\.sig$
\.sud$
\.su2$
.\su3$
\.tar$
\.war$
.\deb$
\.zip$
\.torrent$
^\.
^build/
^pkg-temp/
~$
/build/
/classes/
web-fragment.xml
web-out.xml
# Temporary/build dirs
^build
^pkg-temp
/build
/classes
/dist
^installer/resources/locale/mo
/tmp
^apps/jetty/jettylib
# Debian-related
^debian/copyright
^debian/changelog
^.pc/
# Build property overrides
override.properties
# Reporting
sloccount.sc
^reports/

View File

@ -7,14 +7,43 @@ trans.da = apps/i2ptunnel/locale/messages_da.po
trans.de = apps/i2ptunnel/locale/messages_de.po
trans.es = apps/i2ptunnel/locale/messages_es.po
trans.fr = apps/i2ptunnel/locale/messages_fr.po
trans.hu = apps/i2ptunnel/locale/messages_hu.po
trans.it = apps/i2ptunnel/locale/messages_it.po
trans.ja = apps/i2ptunnel/locale/messages_ja.po
trans.nb = apps/i2ptunnel/locale/messages_nb.po
trans.nl = apps/i2ptunnel/locale/messages_nl.po
trans.ru = apps/i2ptunnel/locale/messages_ru.po
trans.pl = apps/i2ptunnel/locale/messages_pl.po
trans.pt = apps/i2ptunnel/locale/messages_pt.po
trans.pt_BR = apps/i2ptunnel/locale/messages_pt_BR.po
trans.ru_RU = apps/i2ptunnel/locale/messages_ru.po
trans.sk = apps/i2ptunnel/locale/messages_sk.po
trans.sv_SE = apps/i2ptunnel/locale/messages_sv.po
trans.uk_UA = apps/i2ptunnel/locale/messages_uk.po
trans.vi = apps/i2ptunnel/locale/messages_vi.po
trans.zh_CN = apps/i2ptunnel/locale/messages_zh.po
[I2P.proxy]
source_file = apps/i2ptunnel/locale-proxy/messages_en.po
source_lang = en
trans.ar = apps/i2ptunnel/locale-proxy/messages_ar.po
trans.cs = apps/i2ptunnel/locale-proxy/messages_cs.po
trans.de = apps/i2ptunnel/locale-proxy/messages_de.po
trans.es = apps/i2ptunnel/locale-proxy/messages_es.po
trans.fr = apps/i2ptunnel/locale-proxy/messages_fr.po
trans.hu = apps/i2ptunnel/locale-proxy/messages_hu.po
trans.it = apps/i2ptunnel/locale-proxy/messages_it.po
trans.nb = apps/i2ptunnel/locale-proxy/messages_nb.po
trans.nl = apps/i2ptunnel/locale-proxy/messages_nl.po
trans.pl = apps/i2ptunnel/locale-proxy/messages_pl.po
trans.pt = apps/i2ptunnel/locale-proxy/messages_pt.po
trans.pt_BR = apps/i2ptunnel/locale-proxy/messages_pt_BR.po
trans.ro = apps/i2ptunnel/locale-proxy/messages_ro.po
trans.ru_RU = apps/i2ptunnel/locale-proxy/messages_ru.po
trans.sv_SE = apps/i2ptunnel/locale-proxy/messages_sv.po
trans.uk_UA = apps/i2ptunnel/locale-proxy/messages_uk.po
trans.vi = apps/i2ptunnel/locale-proxy/messages_vi.po
trans.zh_CN = apps/i2ptunnel/locale-proxy/messages_zh.po
[I2P.routerconsole]
source_file = apps/routerconsole/locale/messages_en.po
source_lang = en
@ -22,19 +51,75 @@ trans.ar = apps/routerconsole/locale/messages_ar.po
trans.cs = apps/routerconsole/locale/messages_cs.po
trans.da = apps/routerconsole/locale/messages_da.po
trans.de = apps/routerconsole/locale/messages_de.po
trans.et_EE = apps/routerconsole/locale/messages_ee.po
trans.el = apps/routerconsole/locale/messages_el.po
trans.es = apps/routerconsole/locale/messages_es.po
trans.et_EE = apps/routerconsole/locale/messages_et.po
trans.fi = apps/routerconsole/locale/messages_fi.po
trans.fr = apps/routerconsole/locale/messages_fr.po
trans.hu = apps/routerconsole/locale/messages_hu.po
trans.it = apps/routerconsole/locale/messages_it.po
trans.ja = apps/routerconsole/locale/messages_ja.po
trans.nb = apps/routerconsole/locale/messages_nb.po
trans.nl = apps/routerconsole/locale/messages_nl.po
trans.pl = apps/routerconsole/locale/messages_pl.po
trans.ru = apps/routerconsole/locale/messages_ru.po
trans.pt = apps/routerconsole/locale/messages_pt.po
trans.pt_BR = apps/routerconsole/locale/messages_pt_BR.po
trans.ro = apps/routerconsole/locale/messages_ro.po
trans.ru_RU = apps/routerconsole/locale/messages_ru.po
trans.sv_SE = apps/routerconsole/locale/messages_sv.po
trans.tr_TR = apps/routerconsole/locale/messages_tr.po
trans.uk_UA = apps/routerconsole/locale/messages_uk.po
trans.vi = apps/routerconsole/locale/messages_vi.po
trans.zh_CN = apps/routerconsole/locale/messages_zh.po
[I2P.welcome]
source_file = apps/routerconsole/locale-news/messages_en.po
source_lang = en
trans.ar = apps/routerconsole/locale-news/messages_ar.po
trans.de = apps/routerconsole/locale-news/messages_de.po
trans.es = apps/routerconsole/locale-news/messages_es.po
trans.fr = apps/routerconsole/locale-news/messages_fr.po
trans.he = apps/routerconsole/locale-news/messages_he.po
trans.ja = apps/routerconsole/locale-news/messages_ja.po
trans.it = apps/routerconsole/locale-news/messages_it.po
trans.nl = apps/routerconsole/locale-news/messages_nl.po
trans.pl = apps/routerconsole/locale-news/messages_pl.po
trans.pt = apps/routerconsole/locale-news/messages_pt.po
trans.pt_BR = apps/routerconsole/locale-news/messages_pt_BR.po
trans.ro = apps/routerconsole/locale-news/messages_ro.po
trans.ru_RU = apps/routerconsole/locale-news/messages_ru.po
trans.sk = apps/routerconsole/locale-news/messages_sk.po
trans.sv_SE = apps/routerconsole/locale-news/messages_sv.po
trans.tr_TR = apps/routerconsole/locale-news/messages_tr.po
trans.zh_CN = apps/routerconsole/locale-news/messages_zh.po
[I2P.countries]
type = PO
source_file = apps/routerconsole/locale-countries/messages_en.po
source_lang = en
trans.da = apps/routerconsole/locale-countries/messages_da.po
trans.de = apps/routerconsole/locale-countries/messages_de.po
trans.el = apps/routerconsole/locale-countries/messages_el.po
trans.es = apps/routerconsole/locale-countries/messages_es.po
trans.et_EE = apps/routerconsole/locale-countries/messages_et.po
trans.fi = apps/routerconsole/locale-countries/messages_fi.po
trans.fr = apps/routerconsole/locale-countries/messages_fr.po
trans.hu = apps/routerconsole/locale-countries/messages_hu.po
trans.it = apps/routerconsole/locale-countries/messages_it.po
trans.ja = apps/routerconsole/locale-countries/messages_ja.po
trans.nb = apps/routerconsole/locale-countries/messages_nb.po
trans.nl = apps/routerconsole/locale-countries/messages_nl.po
trans.pl = apps/routerconsole/locale-countries/messages_pl.po
trans.pt = apps/routerconsole/locale-countries/messages_pt.po
trans.pt_BR = apps/routerconsole/locale-countries/messages_pt_BR.po
trans.ro = apps/routerconsole/locale-countries/messages_ro.po
trans.ru_RU = apps/routerconsole/locale-countries/messages_ru.po
trans.sk = apps/routerconsole/locale-countries/messages_sk.po
trans.sv_SE = apps/routerconsole/locale-countries/messages_sv.po
trans.tr_TR = apps/routerconsole/locale-countries/messages_tr.po
trans.vi = apps/routerconsole/locale-countries/messages_vi.po
trans.zh_CN = apps/routerconsole/locale-countries/messages_zh.po
[I2P.i2psnark]
source_file = apps/i2psnark/locale/messages_en.po
source_lang = en
@ -43,11 +128,15 @@ trans.cs = apps/i2psnark/locale/messages_cs.po
trans.de = apps/i2psnark/locale/messages_de.po
trans.es = apps/i2psnark/locale/messages_es.po
trans.fr = apps/i2psnark/locale/messages_fr.po
trans.hu = apps/i2psnark/locale/messages_hu.po
trans.it = apps/i2psnark/locale/messages_it.po
trans.nb = apps/i2psnark/locale/messages_nb.po
trans.nl = apps/i2psnark/locale/messages_nl.po
trans.pl = apps/i2psnark/locale/messages_pl.po
trans.pt = apps/i2psnark/locale/messages_pt.po
trans.ru = apps/i2psnark/locale/messages_ru.po
trans.ro = apps/i2psnark/locale/messages_ro.po
trans.ru_RU = apps/i2psnark/locale/messages_ru.po
trans.sk = apps/i2psnark/locale/messages_sk.po
trans.sv_SE = apps/i2psnark/locale/messages_sv.po
trans.vi = apps/i2psnark/locale/messages_vi.po
trans.zh_CN = apps/i2psnark/locale/messages_zh.po
@ -59,12 +148,18 @@ trans.ar = apps/susidns/locale/messages_ar.po
trans.cs = apps/susidns/locale/messages_cs.po
trans.da = apps/susidns/locale/messages_da.po
trans.de = apps/susidns/locale/messages_de.po
trans.el = apps/susidns/locale/messages_el.po
trans.es = apps/susidns/locale/messages_es.po
trans.fr = apps/susidns/locale/messages_fr.po
trans.hu = apps/susidns/locale/messages_hu.po
trans.it = apps/susidns/locale/messages_it.po
trans.ja = apps/susidns/locale/messages_ja.po
trans.nl = apps/susidns/locale/messages_nl.po
trans.pl = apps/susidns/locale/messages_pl.po
trans.ru = apps/susidns/locale/messages_ru.po
trans.pt = apps/susidns/locale/messages_pt.po
trans.pt_BR = apps/susidns/locale/messages_pt_BR.po
trans.ro = apps/susidns/locale/messages_ro.po
trans.ru_RU = apps/susidns/locale/messages_ru.po
trans.sv_SE = apps/susidns/locale/messages_sv.po
trans.uk_UA = apps/susidns/locale/messages_uk.po
trans.vi = apps/susidns/locale/messages_vi.po
@ -77,14 +172,21 @@ trans.ar = apps/desktopgui/locale/messages_ar.po
trans.cs = apps/desktopgui/locale/messages_cs.po
trans.da = apps/desktopgui/locale/messages_da.po
trans.de = apps/desktopgui/locale/messages_de.po
trans.el = apps/desktopgui/locale/messages_el.po
trans.es = apps/desktopgui/locale/messages_es.po
trans.fr = apps/desktopgui/locale/messages_fr.po
trans.hu = apps/desktopgui/locale/messages_hu.po
trans.it = apps/desktopgui/locale/messages_it.po
trans.ja = apps/desktopgui/locale/messages_ja.po
trans.nl = apps/desktopgui/locale/messages_nl.po
trans.pl = apps/desktopgui/locale/messages_pl.po
trans.ru = apps/desktopgui/locale/messages_ru.po
trans.pt_BR = apps/desktopgui/locale/messages_pt_BR.po
trans.ro = apps/desktopgui/locale/messages_ro.po
trans.ru_RU = apps/desktopgui/locale/messages_ru.po
trans.sk = apps/desktopgui/locale/messages_sk.po
trans.sv_SE = apps/desktopgui/locale/messages_sv.po
trans.uk_UA = apps/desktopgui/locale/messages_uk.po
trans.tr_TR = apps/desktopgui/locale/messages_tr.po
trans.vi = apps/desktopgui/locale/messages_vi.po
trans.zh_CN = apps/desktopgui/locale/messages_zh.po
@ -95,11 +197,16 @@ trans.cs = apps/susimail/locale/messages_cs.po
trans.de = apps/susimail/locale/messages_de.po
trans.es = apps/susimail/locale/messages_es.po
trans.fr = apps/susimail/locale/messages_fr.po
trans.hu = apps/susimail/locale/messages_hu.po
trans.it = apps/susimail/locale/messages_it.po
trans.ja = apps/susimail/locale/messages_ja.po
trans.nl = apps/susimail/locale/messages_nl.po
trans.ru = apps/susimail/locale/messages_ru.po
trans.ru_RU = apps/susimail/locale/messages_ru.po
trans.sv_SE = apps/susimail/locale/messages_sv.po
trans.pl = apps/susimail/locale/messages_pl.po
trans.pt = apps/susimail/locale/messages_pt.po
trans.pt_BR = apps/susimail/locale/messages_pt_BR.po
trans.ro = apps/susimail/locale/messages_ro.po
trans.uk_UA = apps/susimail/locale/messages_uk.po
trans.vi = apps/susimail/locale/messages_vi.po
trans.zh_CN = apps/susimail/locale/messages_zh.po
@ -109,12 +216,65 @@ source_file = debian/po/templates.pot
source_lang = en
trans.cs = debian/po/cs.po
trans.de = debian/po/de.po
trans.el = debian/po/el.po
trans.es = debian/po/es.po
trans.fr = debian/po/fr.po
trans.it = debian/po/it.po
trans.hu = debian/po/hu.po
trans.ja = debian/po/ja.po
trans.ko = debian/po/ko.po
trans.pl = debian/po/pl.po
trans.ru = debian/po/ru.po
trans.pt = debian/po/pt.po
trans.ro = debian/po/ro.po
trans.ru_RU = debian/po/ru.po
trans.sk = debian/po/sk.po
trans.sv_SE = debian/po/sv.po
trans.uk_UA = debian/po/uk.po
trans.tr_TR = debian/po/tr.po
trans.zh_CN = debian/po/zh.po
[I2P.i2prouter-script]
source_file = installer/resources/locale/po/messages_en.po
source_lang = en
trans.de = installer/resources/locale/po/messages_de.po
trans.es = installer/resources/locale/po/messages_es.po
trans.fr = installer/resources/locale/po/messages_fr.po
trans.it = installer/resources/locale/po/messages_it.po
trans.pl = installer/resources/locale/po/messages_pl.po
trans.ja = installer/resources/locale/po/messages_ja.po
trans.pt = installer/resources/locale/po/messages_pt.po
trans.pt_BR = installer/resources/locale/po/messages_pt_BR.po
trans.ro = installer/resources/locale/po/messages_ro.po
trans.ru_RU = installer/resources/locale/po/messages_ru.po
trans.sk = installer/resources/locale/po/messages_sk.po
trans.sv_SE = installer/resources/locale/po/messages_sv.po
trans.tr_TR = installer/resources/locale/po/messages_tr.po
trans.zh_CN = installer/resources/locale/po/messages_zh.po
[I2P.getopt]
source_file = core/java/src/gnu/getopt/MessagesBundle.properties
source_lang = en
type = PROPERTIES
trans.cs = core/java/src/gnu/getopt/MessagesBundle_cs.properties
trans.de = core/java/src/gnu/getopt/MessagesBundle_de.properties
trans.es = core/java/src/gnu/getopt/MessagesBundle_es.properties
trans.fr = core/java/src/gnu/getopt/MessagesBundle_fr.properties
trans.hu = core/java/src/gnu/getopt/MessagesBundle_hu.properties
trans.it = core/java/src/gnu/getopt/MessagesBundle_it.properties
trans.ja = core/java/src/gnu/getopt/MessagesBundle_ja.properties
trans.nl = core/java/src/gnu/getopt/MessagesBundle_nl.properties
trans.nb = core/java/src/gnu/getopt/MessagesBundle_nb.properties
trans.pl = core/java/src/gnu/getopt/MessagesBundle_pl.properties
trans.pt_BR = core/java/src/gnu/getopt/MessagesBundle_pt_BR.properties
trans.ro = core/java/src/gnu/getopt/MessagesBundle_ro.properties
trans.ru_RU = core/java/src/gnu/getopt/MessagesBundle_ru.properties
trans.sk = core/java/src/gnu/getopt/MessagesBundle_sk.properties
trans.zh_CN = core/java/src/gnu/getopt/MessagesBundle_zh.properties
[I2P.streaming]
source_file = apps/ministreaming/locale/messages_en.po
source_lang = en
[main]
host = http://www.transifex.net
host = https://www.transifex.com

View File

@ -11,8 +11,8 @@ you may use:
lynx http://localhost:7657/
to configure the router.
If you're having trouble, swing by http://forum.i2p2.de/, check the
website at http://www.i2p2.de/, or get on irc://irc.freenode.net/#i2p
If you're having trouble, swing by http://forum.i2p/, check the
website at https://geti2p.net/, or get on irc://irc.freenode.net/#i2p
I2P will create and store files and configuration data in the user directory
~/.i2p/ on Linux and %APPDATA%\I2P\ on Windows. This directory is created
@ -39,7 +39,10 @@ To uninstall I2P:
rm -rf $I2PInstallDir ~/.i2p
Supported JVMs:
Windows: Latest available from http://java.com/download (1.5+ supported)
Linux: Latest available from http://java.com/download (1.5+ supported)
FreeBSD: 1.5-compatible (NIO required)
Other operating systems and JVMs: See http://trac.i2p2.de/wiki/java
All platforms: Java 1.6 or higher required; 1.7 or higher recommended
Windows: OpenJDK or Oracle from http://java.com/download
Linux: OpenJDK or Oracle from http://java.com/download
FreeBSD: OpenJDK or Oracle from http://java.com/download
Raspberry Pi: Oracle 8 Early Access https://jdk8.java.net/download.html
PowerPC: IBM SDK 7 http://www.ibm.com/developerworks/java/jdk/linux/download.html
Other operating systems and JVMs: See https://trac.i2p2.de/wiki/java or https://geti2p.net/download

View File

@ -2,7 +2,7 @@ I2P source installation instructions
Prerequisites to build from source:
Java SDK (preferably Oracle/Sun or OpenJDK) 1.6.0 or higher
Non-linux operating systems and JVMs: See http://trac.i2p2.de/wiki/java
Non-linux operating systems and JVMs: See https://trac.i2p2.de/wiki/java
Apache Ant 1.7.0 or higher
The xgettext, msgfmt, and msgmerge tools installed
from the GNU gettext package http://www.gnu.org/software/gettext/

View File

@ -36,7 +36,7 @@ Public domain except as listed below:
Copyright (c) 2003, TheCrypto
See licenses/LICENSE-ElGamalDSA.txt
SHA256 and HMAC-SHA256:
SHA256 and HMAC:
Copyright (c) 2000 - 2004 The Legion Of The Bouncy Castle
See licenses/LICENSE-SHA256.txt
@ -72,6 +72,14 @@ Public domain except as listed below:
Copyright (c) 2006, Matthew Estes
See licenses/LICENSE-BlockFile.txt
SipHashInline:
Copyright 2012 Hiroshi Nakamura <nahi@ruby-lang.org>
See licenses/LICENSE-Apache2.0.txt
Getopt:
Copyright (c) 1998 by Aaron M. Renn (arenn@urbanophile.com)
See licenses/LICENSE-LGPLv2.1.txt
Router (router.jar):
Public domain except as listed below:
@ -79,11 +87,13 @@ Public domain except as listed below:
From freenet
See licenses/LICENSE-GPLv2.txt
UPnP subsystem 1.7:
Copyright (C) 2003-2006 Satoshi Konno
UPnP subsystem (CyberLink) 2.1:
Copyright (C) 2003-2010 Satoshi Konno
See licenses/LICENSE-UPnP.txt
GeoIP data free to use, courtesy http://www.maxmind.com/
GeoIP: GeoLite databases are licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
http://creativecommons.org/licenses/by-sa/3.0/
This product includes GeoLite data created by MaxMind, available from http://www.maxmind.com/
Installer:
@ -127,7 +137,7 @@ Installer:
Java Service Wrapper Community Edition 32-bit 3.5.13:
Java Service Wrapper Community Edition 32-bit 3.5.19:
Copyright (C) 1999-2011 Tanuki Software, Ltd. All Rights Reserved.
See licenses/LICENSE-Wrapper.txt
@ -172,10 +182,11 @@ Applications:
By welterde.
See licenses/LICENSE-GPLv2.txt
Jetty 6.1.26:
Copyright 1995-2009 Mort Bay Consulting Pty Ltd
See licenses/LICENSE-Jetty.txt
Jetty 8.1.15.v20140411:
See licenses/ABOUT-Jetty.html
See licenses/NOTICE-Jetty.html
See licenses/LICENSE-Apache2.0.txt
See licenses/LICENSE-ECLIPSE-1.0.html
See licenses/NOTICE-Commons-Logging.txt
JRobin 1.5.9.1:
@ -195,17 +206,23 @@ Applications:
- Jersey and EU flag icons: public domain, courtesy Xrmap flag
collection http://www.arvernes.com/wiki/index.php/Xrmap
- Guernsey and Isle of Man flags from the Open Clip Art Library, released into the public domain
- Curaçao, courtesy of David Benbennick, released into the public domain
- All other flag icons: public domain, courtesy mjames@gmail.com http://www.famfamfam.com/
Silk icons: See licenses/LICENSE-SilkIcons.txt
FatCow icons: See licenses/LICENSE-FatCowIcons.txt
GeoIP Data:
Copyright (c) 2008 MaxMind, Inc. All Rights Reserved.
This product includes GeoLite data created by MaxMind, available from http://www.maxmind.com/
See licenses/LICENSE-GeoIP.txt
Router Console and I2PSnark themes:
"Man with hat over face" & related images licensed under a Creative Commons 2.0 license.
Original photos by Florian Kuhlmann. http://www.flickr.com/photos/floriankuhlmann/3117758155
I2PSnark light theme:
"Creative Commons Cat" licensed under a Creative Commons Attribution 3.0 Unported License.
Original photo by Boaz Arad. http://www.luxphile.com/2011/01/creative-commons-cat.html
SAM:
Public domain.
@ -231,8 +248,8 @@ Applications:
Bundles systray4j-2.4.1:
See licenses/LICENSE-LGPLv2.1.txt
Tomcat 6.0.35:
Copyright 1999-2011 The Apache Software Foundation
Tomcat 6.0.41:
Copyright 1999-2014 The Apache Software Foundation
See licenses/LICENSE-Apache2.0.txt
See licenses/NOTICE-Tomcat.txt

View File

@ -1,6 +1,6 @@
Prerequisites to build from source:
Java SDK (preferably Oracle/Sun or OpenJDK) 1.6.0 or higher
Non-linux operating systems and JVMs: See http://trac.i2p2.de/wiki/java
Non-linux operating systems and JVMs: See https://trac.i2p2.de/wiki/java
Apache Ant 1.7.0 or higher
The xgettext, msgfmt, and msgmerge tools installed
from the GNU gettext package http://www.gnu.org/software/gettext/
@ -15,24 +15,24 @@ To build:
ant installer-osx
Run 'ant' with no arguments to see other build options.
See INSTALL.txt or http://www.i2p2.de/download.html for installation instructions.
See INSTALL.txt or https://geti2p.net/download for installation instructions.
Documentation:
http://www.i2p2.de/how
https://geti2p.net/how
API: run 'ant javadoc' then start at build/javadoc/index.html
Latest release:
http://www.i2p2.de/download.html
https://geti2p.net/download
To get development branch from source control:
http://www.i2p2.de/newdevelopers.html
https://geti2p.net/newdevelopers
FAQ:
http://www.i2p2.de/faq.html
https://geti2p.net/faq
Need help?
IRC irc.freenode.net #i2p
http://forum.i2p2.de/
http://forum.i2p/
Licenses:
See LICENSE.txt

View File

@ -1,30 +1,70 @@
ou will need atleast monotone > = 0.41 to get the most recent build source
and connect it to an already running i2p router.
Getting the sources
===================
OR:
Monotone
--------
You may download the actual "stable" source from
http://code.google.com/p/i2p/downloads/list
The bleeding-edge source code is available both within and outside of I2P. The
I2P project uses Monotone to maintain the codebase.
You will need to follwing tools to build the i2p and i2p-base packages:
Information on retrieving the source with monotone is available within I2P at
http://i2p-projekt.i2p/monotone and from the internet at https://geti2p.net/monotone.
bash >= 3.1.017
requiredbuilder >= 0.16.3 ( http://www.stabellini.net/requiredbuilder.html )
jre >= 6u11
jdk >= 6u11
apache-ant >= 1.7.1
perl >= 5.10.0
python >= 2.5.2
Monotone 1.0 Slackbuilds are available at http://slackbuilds.org/.
Reccomended:
monotone >= 0.41 ( http://pkgs.dr.ea.ms )
Git
---
See also:
Git is also an option to retrieve the I2P source code. That said, the I2P
Monotone servers are *the* authoritative source.
i2p/readme.txt
Public Git repositories hosting the I2P source and managed by I2P project team members include
AND
- https://github.com/i2p/i2p.i2p
- http://git.repo.i2p/w/i2p.i2p.git (mirrored from Github)
- http://sourceforge.net/p/i2p/code/
i2p-base/readme.txt
for information and handy tips.
Tarball
-------
The latest stable release is always available from the I2P homepage at
https://geti2p.net/get/.
This SlackBuild
===============
Requirements
-------------
The following are needed to build the i2p package:
* jre >= 6
* jdk >= 6
* gettext
* apache-ant >= 1.7.1
If you don't care about bundling the translations, the gettext requirement can
be avoided by adding -Drequire.gettext=false to the ant lines in
i2p/i2p.SlackBuild
A JRE >= v6 is the only requirement to run I2P.
Building
--------
As the root user, run either $I2PSRC/Slackware/i2p/i2p.SlackBuild or `ant slackpkg` to create a package
in $I2PSRC/Slackware/i2p which can be installed using the Slackware packaging tools.
See also
========
Please also take a look at
* i2p/README
* eepget(1)
* i2prouter(1)
* http://i2p-projekt.i2p / https://geti2p.net
for additional information and tips.

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<project basedir="." default="slackpkg">
<target name="slackpkg">
<echo message="Building Slackware package." />
<exec executable="./i2p-base.SlackBuild">
</exec>
</target>
</project>

View File

@ -1,157 +0,0 @@
#!/bin/sh
#
#
# Now in the future we only need to look for '#I2P' and '#/I2P'
# for modifications to rc.local and rc.local_shutdown.
# I was a moron for not doing it this way in the first place :-) -- Sponge
#
#
touch /etc/rc.d/rc.local
touch /etc/rc.d/rc.local_shutdown
echo
echo -n "Check 1: /etc/rc.d/rc.local "
I2PRCA=`grep -c /etc/rc.d/rc.local -e '/etc/rc.d/rc.i2p'`
if [ $I2PRCA -eq 0 ] ; then
echo '#I2P' >> /etc/rc.d/rc.local
echo '( cd /tmp ; rm -Rf i2p-*.tmp )' >> /etc/rc.d/rc.local
echo "if [ -x /etc/rc.d/rc.i2p ] ; then" >> /etc/rc.d/rc.local
echo " sh /etc/rc.d/rc.i2p start" >> /etc/rc.d/rc.local
echo "fi" >> /etc/rc.d/rc.local
echo '#/I2P' >> /etc/rc.d/rc.local
echo "modified."
else
echo -n "looks OK so far,"
# Fix old installs, or where people have modified.
echo -n " Check 1A: "
I2PRCC=`grep -c /etc/rc.d/rc.local -e 'i2p-\*\.tmp'`
if [ $I2PRCC -eq 0 ] ; then
DATA=$(cat /etc/rc.d/rc.local | sed -re 's/if \[ -x \/etc\/rc\.d\/rc\.i2p \] ; then/#I2P\n\( cd \/tmp ; rm -Rf i2p-*.tmp \)\nif \[ -x \/etc\/rc.d\/rc.i2p \] ; then/')
echo "${DATA}" > /etc/rc.d/rc.local
echo -n "additional modifications applied,"
else
echo -n "looks OK so far,"
fi
echo -n " Check 1B: "
I2PRCE=`grep -c /etc/rc.d/rc.local -e 'i2p-\*\.tmp'`
if [ $I2PRCE -eq 0 ] ; then
DATATOP=$(cat /etc/rc.d/rc.local | sed -n '0,/i2p-\*\.tmp/p' | sed '$d' )
DATABOT=$(cat /etc/rc.d/rc.local | sed -n '/i2p-\*\.tmp/,$p' | sed -n '/^fi/,$p' | sed "1d")
echo "${DATATOP}" > /etc/rc.d/rc.local
echo '#I2P' >> /etc/rc.d/rc.local
echo '( cd /tmp ; rm -Rf i2p-*.tmp )' >> /etc/rc.d/rc.local
echo "if [ -x /etc/rc.d/rc.i2p ] ; then" >> /etc/rc.d/rc.local
echo " sh /etc/rc.d/rc.i2p start" >> /etc/rc.d/rc.local
echo "fi" >> /etc/rc.d/rc.local
echo '#/I2P' >> /etc/rc.d/rc.local
echo "${DATABOT}" >> /etc/rc.d/rc.local
echo -n "additional modifications applied,"
else
echo -n "looks ok so far,"
fi
echo -n " Check 1C: "
I2PRCF=`grep -c /etc/rc.d/rc.local -e '#/I2P'`
if [ $I2PRCF -eq 0 ] ; then
DATATOP=$(cat /etc/rc.d/rc.local | sed -n '0,/^#I2P/p' | sed '$d' )
DATABOT=$(cat /etc/rc.d/rc.local | sed -n '/^#I2P/,$p' | sed -n '/^fi/,$p' | sed "1d")
echo "${DATATOP}" > /etc/rc.d/rc.local
echo '#I2P' >> /etc/rc.d/rc.local
echo '( cd /tmp ; rm -Rf i2p-*.tmp )' >> /etc/rc.d/rc.local
echo "if [ -x /etc/rc.d/rc.i2p ] ; then" >> /etc/rc.d/rc.local
echo " sh /etc/rc.d/rc.i2p start" >> /etc/rc.d/rc.local
echo "fi" >> /etc/rc.d/rc.local
echo '#/I2P' >> /etc/rc.d/rc.local
echo "${DATABOT}" >> /etc/rc.d/rc.local
echo -n "additional modifications applied,"
else
echo -n "looks ok so far,"
fi
echo " Done."
fi
echo -n "Check 2: /etc/rc.d/rc.local_shutdown "
I2PRCB=`grep -c /etc/rc.d/rc.local_shutdown -e '/etc/rc.d/rc.i2p'`
if [ $I2PRCB -eq 0 ] ; then
echo "#I2P" >> /etc/rc.d/rc.local_shutdown
echo "if [ -x /etc/rc.d/rc.i2p ] ; then" >> /etc/rc.d/rc.local_shutdown
echo " sh /etc/rc.d/rc.i2p stop" >> /etc/rc.d/rc.local_shutdown
echo "fi" >> /etc/rc.d/rc.local_shutdown
echo "#/I2P" >> /etc/rc.d/rc.local_shutdown
echo "modified."
else
echo -n "looks OK so far,"
# Fix old installs
echo -n " Check 1A: "
I2PRCG=`grep -c /etc/rc.d/rc.local_shutdown -e '#I2P'`
if [ $I2PRCG -eq 0 ] ; then
DATATOP=$(cat /etc/rc.d/rc.local_shutdown | sed -n '0,/^if \[ -x \/etc\/rc\.d\/rc\.i2p \] ; then/p' | sed '$d' )
DATABOT=$(cat /etc/rc.d/rc.local_shutdown | sed -n '/^if \[ -x \/etc\/rc\.d\/rc\.i2p \] ; then/,$p' | sed -n '/^fi/,$p' | sed "1d")
echo "${DATATOP}" > /etc/rc.d/rc.local_shutdown
echo '#I2P' >> /etc/rc.d/rc.local_shutdown
echo "if [ -x /etc/rc.d/rc.i2p ] ; then" >> /etc/rc.d/rc.local_shutdown
echo " sh /etc/rc.d/rc.i2p stop" >> /etc/rc.d/rc.local_shutdown
echo "fi" >> /etc/rc.d/rc.local_shutdown
echo "#/I2P" >> /etc/rc.d/rc.local_shutdown
echo "${DATABOT}" >> /etc/rc.d/rc.local_shutdown
echo -n "additional modifications applied,"
else
echo -n "looks OK so far,"
fi
echo -n " Check 1B: "
I2PRCH=`grep -c /etc/rc.d/rc.local_shutdown -e '#/I2P'`
if [ $I2PRCH -eq 0 ] ; then
DATATOP=$(cat /etc/rc.d/rc.local_shutdown | sed -n '0,/^#I2P/p' | sed '$d' )
DATABOT=$(cat /etc/rc.d/rc.local_shutdown | sed -n '/^#I2P/,$p' | sed -n '/^fi/,$p' | sed "1d")
echo "${DATATOP}" > /etc/rc.d/rc.local_shutdown
echo '#I2P' >> /etc/rc.d/rc.local_shutdown
echo "if [ -x /etc/rc.d/rc.i2p ] ; then" >> /etc/rc.d/rc.local_shutdown
echo " sh /etc/rc.d/rc.i2p stop" >> /etc/rc.d/rc.local_shutdown
echo "fi" >> /etc/rc.d/rc.local_shutdown
echo "#/I2P" >> /etc/rc.d/rc.local_shutdown
echo "${DATABOT}" >> /etc/rc.d/rc.local_shutdown
echo -n "additional modifications applied,"
else
echo -n "looks OK so far,"
fi
echo " Done."
fi
if [ -f /etc/rc.d/rc.i2p ] ; then
if [ -x /etc/rc.d/rc.i2p ] ; then
chmod +x /etc/rc.d/rc.i2p.new
fi
# Hopefully get admin's attention.
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -e "\007" ; sleep 0.3
echo "It apears that you already have /etc/rc.d/rc.i2p"
echo "You should replace it with /etc/rc.d/rc.i2p.new as soon as possible"
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -ne "\007" ; sleep 0.3
echo -e "\007" ; sleep 0.3
else
mv /etc/rc.d/rc.i2p.new /etc/rc.d/rc.i2p
echo
echo "Installation finished. The i2p start/stop script has been"
echo "installed in /etc/rc.d . You should chmod +x"
echo '/etc/rc.d/rc.i2p to start it on boot.'
echo
fi
exit

View File

@ -1,57 +0,0 @@
#!/bin/sh
#
# Heavily based on the Slackware 12.2 SlackBuild
# Slackware build script for I2P
#
# PLEASE READ THIS:
# How to start I2P:
# After installpkg command, doinst.sh will execute a post-installation script
# needed by I2P. After that you have to chmod +x /etc/rc.d/rc.i2p and start
# I2P service with /etc/rc.d/rc.i2p start.
#
# Now tell your browser to user this proxy: localhost on port 4444 and open
# this page: http://localhost:7657/index.jsp
#
# Here you can configure I2P, watch network status and navigate anonimously.
# It's suggested to subscribe to various dns host, like i2host.i2p
# For any additional information, visit i2host.i2p and forum.i2p
#
CWD=$(pwd)
TMP=/tmp
PKG=/$TMP/package-base-i2p
NAME=i2p-base
VERSION=0.0.4
BUILD=1sponge
ARCH=noarch
INSTALL_DIR=opt
# Less than slackware 13?
SLKPLT=$(cat /etc/slackware-version | sed -re "s/(Slackware )([0-9]*)(.*)/\2/")
if [ $SLKPLT -lt 13 ] ; then
EXT=tgz
else
EXT=txz
fi
rm -rf $PKG
mkdir -p $PKG
cd $PKG
chown -R root:root .
mkdir -p $PKG/etc/rc.d
mkdir -p $PKG/install
sed "s|directory|/$INSTALL_DIR/i2p/i2prouter|g" "$CWD/rc.i2p_def" > $PKG/etc/rc.d/rc.i2p.new
chmod 644 $PKG/etc/rc.d/rc.i2p.new
cat "$CWD/doinst.sh" > $PKG/install/doinst.sh
cat "$CWD/slack-desc" > $PKG/install/slack-desc
cd $PKG
#
# Not really that important to exec this
# as there aren't any deps we don't know.
#
# requiredbuilder -v -y -s $CWD $PKG
#
cat "$CWD/slack-required" > $PKG/install/slack-required
makepkg -l y -c n $CWD/${NAME}-$VERSION-$ARCH-$BUILD.$EXT

View File

@ -1,68 +0,0 @@
#!/bin/sh
# Start/stop i2p service.
i2p_start() {
# Check if router is up first!
/bin/su - -c "/bin/bash -l -c '( export PATH=\"$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin\" ; directory status )'" > /dev/null
if [ $? -eq 0 ] ; then {
# I2p is already running, so tell the user.
echo "I2P is already running..."
i2p_status
}
else
{
# Just in-case there are leftover junk in /tmp...
rm -Rf `grep /tmp/hsperfdata_root/* -le i2p` /tmp/i2p-*.tmp /tmp/router.ping
# Now that all junk is cleaned up, start.
/bin/su - -c "/bin/bash -l -c '( export PATH=\"$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin\" ; directory start )'"
}
fi
}
i2p_stop() {
/bin/su - -c "/bin/bash -l -c '( export PATH=\"$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin\" ; directory stop )'"
rm -Rf `grep /tmp/hsperfdata_root/* -le i2p` /tmp/i2p-*.tmp /tmp/router.ping
}
i2p_restart() {
# We want a FULL cycle here, not the wrappers idea of this!
i2p_stop
i2p_start
}
i2p_status() {
/bin/su - -c "/bin/bash -l -c '( export PATH=\"$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin\" ; directory status )'"
}
i2p_console() {
/bin/su - -c "/bin/bash -l -c '( export PATH=\"$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin\" ; directory console )'"
}
i2p_dump() {
/bin/su - -c "/bin/bash -l -c '( export PATH=\"$PATH:/usr/lib/java/bin:/usr/lib/java/jre/bin\" ; directory dump )'"
}
case "$1" in
'start')
i2p_start
;;
'stop')
i2p_stop
;;
'restart')
i2p_restart
;;
'status')
i2p_status
;;
'console')
i2p_console
;;
'dump')
i2p_dump
;;
*)
echo "usage $0 start|stop|restart|status|console|dump"
;;
esac

View File

@ -1,10 +0,0 @@
An rc file called rc.i2p has been placed into the /etc/rc.d directory.
If you want to change installation dir, change the variable INSTALL_DIR
on base-i2p.SlackBuild and rebuild the package. You also will need to do the
same for the i2p package.
The install script will insert everything needed into /etc/rc.d/rc.local and
into /etc/rc.d/rc.local_shutdown automatically.
If you want to start I2P at boot you have to chmod +x /etc/rc.d/rc.i2p

View File

@ -1,19 +0,0 @@
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|' on
# the right side marks the last column you can put a character in. You must make
# exactly 11 lines for the formatting to be correct. It's also customary to
# leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
base-i2p: base-i2p (I2P anonymizing network base config files)
base-i2p:
base-i2p: I2P is an anonymizing network, offering a simple layer that
base-i2p: identity-sensitive applications can use to securely communicate. All
base-i2p: data is wrapped with several layers of encryption, and the network is
base-i2p: both distributed and dynamic, with no trusted parties.
base-i2p: Many applications are available that interface with I2P, including
base-i2p: mail, peer-peer file sharing, IRC chat, and others.
base-i2p:
base-i2p: This package provides the startup files.
base-i2p:

View File

@ -1 +0,0 @@
bash >= 3.1.017

89
Slackware/i2p/README Normal file
View File

@ -0,0 +1,89 @@
The I2P package will be installed to /opt/i2p.
To install to another location, set the variable INSTALL_DIR in i2p.SlackBuild
and rebuild the package.
Installing and Upgrading:
=========================
I2P has an auto-update function but generally speaking packages are managed by
packaging systems. Changing a package's files outside of the package system can
cause problems. To upgrade when there's a new I2P release, retrieve the new
source, re-run the SlackBuild, then use upgradepkg to update.
To ignore all this and upgrade "in-network", simply change the permissions of the installation
directory (/opt/i2p by default). Something like the following would suffice:
chown -R USERNAME /opt/i2p
Starting and using I2P
======================
Using the initscript
--------------------
To start I2P at boot, set the executable bit on /etc/rc.d/rc.i2p, add this
script to rc.local*, and set the variable "RUN_AS_USER" in /etc/rc.d/rc.i2p.
Optionally, create a new user/group with limited rights to run I2P.
Something like the following would work to start I2P at system boot, running under the
"i2p" account:
echo '[ -x /etc/rc.d/rc.i2p ] && /etc/rc.d/rc.i2p start' >> /etc/rc.d/rc.local
echo '[ -x /etc/rc.d/rc.i2p ] && /etc/rc.d/rc.i2p stop' >> /etc/.rc.d/rc.local_shutdown
sed -i .bak 's/^.*\(RUN_AS_USER\)=.*/\1=i2p/' /etc/rc.d/rc.i2p
chmod 755 /etc/rc.d/rc.i2p
Unless running as a user named "i2psvc", I2P's config directory defaults to
$HOME/.i2p. In the case of the "i2psvc" user, the default config directory is
/var/lib/i2p/i2p-config.
It should not need to be said that using the "root" account is not recommended.
When running using the initscript, I2P will write its logs to /var/log/i2p.
Starting I2P "on-demand"
------------------------
As with a normal installation, I2P can be started with "i2prouter start". The
i2prouter and eepget scripts hve been installed to /usr/bin so they'll be
accessible in the default system PATH.
When running using the i2prouter script, I2P will write its logs to $HOME/.i2p.
Configuring your browser
------------------------
In order to access eepSites (I2P-internal web sites) your web browser needs to
be configured. Set the HTTP Proxy to 127.0.0.1 and port 4444. For more information, see
https://geti2p.net/en/about/browser-config
The I2P router console is reachable at http://127.0.0.1:7657.
Addressbook subscriptions
-------------------------
Please see the FAQs at http://i2p-projekt.i2p/faq or https://geti2p.net/faq for information about
the various addressbook services.
Chatting on IRC
---------------
I2P comes preconfigured with a tunnel pointing to the I2P-only IRC network,
Irc2P. Signing on is easy, just connect to 127.0.0.1 on port 6668. Do not
configure a proxy in your IRC client.
Additional information
======================
Within I2P: http://i2p-projekt.i2p/, http://forum.i2p/, http://zzz.i2p/, http://trac.i2p2.i2p/
On the Internet: https://geti2p.net/, https://trac.i2p2.de
Manpages: i2prouter(1), eepget(1)

View File

@ -2,7 +2,7 @@
<project basedir="." default="slackpkg">
<target name="slackpkg">
<echo message="Building Slackware package." />
<exec executable="./i2p.SlackBuild">
</exec>
<chmod file="./i2p.Slackbuild" perm="755" />
<exec executable="./i2p.SlackBuild" failifexecutionfails="true" />
</target>
</project>

View File

@ -1,72 +1,60 @@
#!/bin/sh
# Abort on error or unset variables
set -e
set -u
# This is changed by i2p.SlackBuild
INST_DIR=directory
PKGNAME="%pkg"
( cd install
config() {
NEW="$1"
OLD="$(dirname $NEW)/$(basename $NEW .new)"
if [ ! -r $NEW ]; then
# If we get here there's a flaw in the packaging. We'll just return so that
# we don't emit a spurious error for the user. (It's not the user's problem).
return
fi
echo
for i in *.config ; {
if [ -f $INST_DIR/$i ] ; then
echo "Please check ${INST_DIR}${i}, as there is a new version."
cp $i $INST_DIR/$i.new
else
cp $i $INST_DIR/$i
fi
# If this file doesn't exist yet, drop the .new extension.
if [ ! -r $OLD ]; then
mv $NEW $OLD
return
elif [ "$(md5sum $OLD | cut -d' ' -f1)" = "$(md5sum $NEW | cut -d' ' -f1)" ]; then
# If there are no differences in the files, remove the file with the .new extension.
rm $NEW
return
fi
# Alert the admin if they differ, but let's not be terribly obnoxious about it.
echo "WARNING: The files $OLD and $NEW differ." >&2
}
)
# Unlike previous versions of the package, we install i2prouter and eepget to /usr/bin
# to make them available within the system PATH.
( cd $INST_DIR
if [ -f blocklist.txt ] ; then
echo "Please check ${INST_DIR}blocklist.txt, as there is a new version."
else
mv blocklist.txt.new blocklist.txt
fi
)
# Users might still want to /opt/i2p/i2prouter or /opt/i2p/eepget so we'll create symlinks
# in the installation directory.
ln -sf /usr/bin/eepget $INST_DIR
ln -sf /usr/bin/i2prouter $INST_DIR
(cd /usr/doc/$PKGNAME; ln -sf $INST_DIR/history.txt changelog)
( cd $INST_DIR/eepsite
if [ -f jetty.xml ] ; then
echo "Please check ${INST_DIR}/eepsite, as there are new files."
else
find $PKG/$INSTALL_DIR/i2p -name "*.xml.new" -exec sh -c 'mv "$0" "${0/.new}"' {} \;
fi
)
( cd $INST_DIR/eepsite/docroot
if [ -f index.html ] ; then
rm index.html.new
else
mv index.html.new index.html
fi
if [ -f favicon.ico ] ; then
rm favicon.ico.new
else
mv favicon.ico.new favicon.ico
fi
)
echo
echo "FINISHING I2P INSTALLATION. PLEASE WAIT."
cd $INST_DIR
OS_ARCH=`uname -m`
X86_64=`echo "$OS_ARCH" | grep x86_64`
if [ "X$X86_64" = "X" ]; then
wrapperpath="./lib/wrapper/linux"
if $(uname -m | grep -q '64'); then
(cd $INST_DIR; ln -sf i2psvc-linux-x86-64 i2psvc)
else
wrapperpath="./lib/wrapper/linux64"
(cd $INST_DIR; ln -sf i2psvc-linux-x86-32 i2psvc)
fi
cp $wrapperpath/libwrapper.so ./lib/
cp $wrapperpath/wrapper.jar ./lib/
cp $wrapperpath/i2psvc .
rm -rf ./lib/wrapper
chmod 744 ./i2psvc
echo
echo "Installation finished."
echo
config /etc/rc.d/rc.i2p.new
config $INST_DIR/wrapper.config.new
exit
if [ -e /var/log/packages/i2p-base* ]; then
echo "Warning: This package supercedes the 'i2p-base' package." >&2
echo
echo "You may want to 'removepkg i2p-base'" >&2
echo "and check the contents of /etc/rc.d/rc.local*" >&2
echo "for correctness" >&2
fi
# Remove extraneous 'sh' from sponge's set-up
sed -i 's|sh /etc/rc\.d/rc\.i2p|/etc/rc.d/rc.i2p|g' /etc/rc.d/rc.local*

View File

@ -3,135 +3,124 @@
# Heavily based on the Slackware 12.2 SlackBuild
# Slackware build script for I2P
#
# PLEASE READ THIS:
# Probably you will never have to update I2P packages with upgradepkg,
# just because I2P has an auto-update function.
# Really you should not ever use any "upgrade" method.
#
# The correct way to upgrade is to:
# 1: install the upgrade
# 2: remove the old package
#
# It is a terrible shame that upgradepkg doesn't do this, infact,
# it would actually be the correct way for *any* package!
# Packages are generally prohibited from being updated outside
# of the package manager; this I2P SlackBuild is no different.
#
# If you'd like to use the I2P "in-network" updates anyway, you'll need to
# grant the user that I2P will run as write permission to the installation directory
# (/opt/i2p by default).
#
# For safety's sake, a user's I2P config files will *never* be overwritten by any upgrade method.
# In the future this SlackBuild may alert when a default config file is updated.
##
BUILD=1sponge
# Make sure makepkg and friends can be found
PATH=$PATH:/sbin
# abort on error and unset variables (same as set -e and set -u, respectively)
set -o errexit
set -o nounset
if [ $(id -ur) -ne 0 ]; then
echo "ERROR: SlackBuilds require root access." >&2
exit 1
fi
BUILD=1kytv
# INSTALL_DIR is referenced from /, don't prefix it with a '/'
INSTALL_DIR=opt
NAME=i2p
ARCH=noarch
# Less than slackware 13?
SLKPLT=$(cat /etc/slackware-version | sed -re "s/(Slackware )([0-9]*)(.*)/\2/")
if [ $SLKPLT -lt 13 ] ; then
EXT=tgz
else
EXT=txz
fi
#
# This mess is here due to the totally moronic way i2p does versioning.
# We correct it here.
#
ROUTER=$(echo -ne "_")$(cat ../../router/java/src/net/i2p/router/RouterVersion.java | grep -e "public final static long BUILD" | cut -f2 -d"=" | cut -f1 -d";" | sed -re "s/ //g")
if [ "$ROUTER" == "_" ] ; then
ROUTER="_0"
fi
#
# That was the easy one, now for the tough one.
#
CORE=$(cat ../../core/java/src/net/i2p/CoreVersion.java | grep -e "public final static String VERSION" | cut -f2 -d'"' | sed -re "s/ //g")
CORE1=$(echo -n $CORE.x.x | sed -re "s/(.*)\.(.*)\.(.*)\.(.*)/\1/")
CORE2=$(echo -n $CORE.x | sed -re "s/(.*)\.(.*)\.(.*)\.(.*)/\1/")
if [ "$CORE.x.x" == "$CORE1" ] ; then
CORE=$(echo -ne $CORE".0.0")
fi
if [ "$CORE.x" == "$CORE2" ] ; then
CORE=$(echo -ne $CORE".0")
fi
VERSION=$(echo $CORE$ROUTER)
#
# Whew!
# OK, let's build i2p
#
CWD=$(pwd)
CWD=$(readlink -m $(dirname $0))
I2PSRC=$(readlink -m $CWD/../../)
TMP=/tmp
PKG=$TMP/package-i2p
rm -rf $PKG
mkdir -p $PKG
cd $CWD/../../
if [ -e "/etc/slackware-version" ]; then
# Older than Slackware 13?
SLACKVER=$(sed -e "s/Slackware\s\+\([0-9]\+\)\.\?\([0-9]\+\)\?/\1/" /etc/slackware-version)
if [ $SLACKVER -lt 13 ] ; then
EXT=tgz
else
EXT=txz
fi
else
echo "ERROR: This script is only intended for use on Slackware systems.">&2
exit 1
fi
# Extract version strings
I2PBUILD=$(sed -e '/^.\+long\s\+BUILD/!d' -e 's/^.\+long\s\+BUILD\s\+=\s\+\([0-9]\+\);/\1/' $I2PSRC/router/java/src/net/i2p/router/RouterVersion.java)
# Thanks to user "ihavei2p" for the second awk statement
# If the version is x.y, it'll be set to x.y.0. Otherwise the version string will be unchanged
CORE=$(awk -F'"' '/static\s+String\s+VERSION/{print $2}' $I2PSRC/core/java/src/net/i2p/CoreVersion.java | \
awk -F. '{ if (NF > 3) { print; exit } else if ($3 == "") { $3=0; print $1"."$2"."$3 } else print }')
VERSION="${CORE}_${I2PBUILD}"
[ -d $PKG ] && rm -rf $PKG
mkdir -p $PKG/$INSTALL_DIR $PKG/install
cd "$I2PSRC"
ant distclean
#ant dist
ant tarball
ant jbigi-linux-x86-only preppkg-unix
tar xjvf i2p.tar.bz2 -C $TMP
chown -R root:root $I2PSRC/pkg-temp
cp -a $I2PSRC/pkg-temp $PKG/$INSTALL_DIR/i2p
cd $TMP/i2p
chown -R root:root .
mkdir -p $PKG/$INSTALL_DIR/
cp -a ../i2p $PKG/$INSTALL_DIR/
mkdir -p $PKG/install
#############################################################################
# Preconfigureation to make package smaller, and...
# we keep as much as reasonable in the installation directory.
# This makes the install map fairly well to the standard installation.
# It also makes it easier to find the log and pid files!
#############################################################################
# $INSTALL_DIR is used by this SlackBuild.
# [%$]INSTALL_PATH , [%$]SYSTEM_java_io_tmpdir, and [%$]USER_HOME have the correct paths set
# by the IzPack installer.
cd $PKG/$INSTALL_DIR/i2p
for file in wrapper.config eepget i2prouter runplain.sh; do
sed -i "s|[%$]INSTALL_PATH|/$INSTALL_DIR/i2p|g;s|[$%]SYSTEM_java_io_tmpdir|$TMP|g;s/[%$]USER_HOME/\$HOME/g" $file
done
mv wrapper.config wrapper.config.new
# wrapper.config $INSTALL_PATH and $SYSTEM_java_io_tmpdir
sed "s|\$INSTALL_PATH|/$INSTALL_DIR/i2p|g" wrapper.config > a
sed "s|\$SYSTEM_java_io_tmpdir|/$INSTALL_DIR/i2p|g" a > wrapper.config
# eepget %INSTALL_PATH
sed "s|\$INSTALL_PATH|/$INSTALL_DIR/i2p|g" eepget > a
rm eepget
mv a eepget
# runplain.sh %INSTALL_PATH and %SYSTEM_java_io_tmpdir
sed "s|%INSTALL_PATH|/$INSTALL_DIR/i2p|g" runplain.sh > a
sed "s|%SYSTEM_java_io_tmpdir|/$INSTALL_DIR/i2p|g" a > runplain.sh
# i2prouter %INSTALL_PATH and %SYSTEM_java_io_tmpdir
sed "s|%INSTALL_PATH|/$INSTALL_DIR/i2p|g" i2prouter > a
rm i2prouter
mv a i2prouter
sed "s|%SYSTEM_java_io_tmpdir|/$INSTALL_DIR/i2p|g" i2prouter > a
sed "s|#ALLOW_ROOT=true|ALLOW_ROOT=true|g" a > i2prouter
install -d $PKG/usr/bin
install -d $PKG/usr/doc/$NAME-$VERSION
install -d $PKG/etc/rc.d
mv licenses LICENSE.txt -t $PKG/usr/doc/$NAME-$VERSION
chmod 744 ./i2prouter
chmod 744 ./osid
chmod 744 ./runplain.sh
chmod 744 ./eepget
chmod 744 ./scripts/i2pbench.sh
chmod 744 ./scripts/i2ptest.sh
rm -Rf ./lib/*.dll ./*.bat ./*.exe ./installer ./icons ./a postinstall.sh
# runplain.sh will live in the installation directory. eepget and i2prouter will go to /usr/bin
# with symlinks in INST_DIR (created in doinst.sh)
install -m755 i2prouter $PKG/usr/bin
install -m755 eepget $PKG/usr/bin
chmod 755 ./runplain.sh
mv $PKG/$INSTALL_DIR/i2p/*.config $PKG/install
mv $PKG/$INSTALL_DIR/i2p/blocklist.txt $PKG/$INSTALL_DIR/i2p/blocklist.txt.new
find $PKG/$INSTALL_DIR/i2p -name "*.xml" -exec mv {} {}.new \;
mv $PKG/$INSTALL_DIR/i2p/eepsite/docroot/index.html $PKG/$INSTALL_DIR/i2p/eepsite/docroot/index.html.new
mv $PKG/$INSTALL_DIR/i2p/eepsite/docroot/favicon.ico $PKG/$INSTALL_DIR/i2p/eepsite/docroot/favicon.ico.new
sed "s|directory|/$INSTALL_DIR/i2p/|g" $CWD/doinst.sh > $PKG/install/doinst.sh
cat $CWD/slack-desc > $PKG/install/slack-desc
if [ $INSTALL_DIR != 'opt' ]; then
sed "s|\(The I2P package\)\s\+will be\s\+\(installed to\).+|\1 has been \2 $INSTALL_DIR/i2p|g" $CWD/README > $PKG/usr/doc/$NAME-$VERSION/README
else
sed "s|will be installed|has been installed|" $CWD/README > $PKG/usr/doc/$NAME-$VERSION/README
fi
install -d $PKG/usr/man/man1
gzip -9 man/*.1
install -m644 man/*.1.gz $PKG/usr/man/man1
rm -rf ./man
# We install all x86 wrapper binaries.
# The i2prouter script will try to determine the OS (linux), the bits (32 VS 64) and should be able
# to figure out the correct wrapper binary to use.
# However: In case the i2prouter script's detection fails, "$INST_DIR/i2psvc" will point to
# what 'we' think the correct binary is.
#
# A good reason for installing all binaries: in case the user, for whatever reason, switches from an
# x64 JRE to an x86 JRE, I2P should continue to work without needing to be reinstalled.
install -m755 $I2PSRC/installer/lib/wrapper/linux/i2psvc ./i2psvc-linux-x86-32
install -m644 $I2PSRC/installer/lib/wrapper/linux/libwrapper.so ./lib/libwrapper-linux-x86-32.so
install -m755 $I2PSRC/installer/lib/wrapper/linux64/i2psvc ./i2psvc-linux-x86-64
install -m644 $I2PSRC/installer/lib/wrapper/linux64/libwrapper.so ./lib/libwrapper-linux-x86-64.so
install -m644 $I2PSRC/installer/lib/wrapper/all/wrapper.jar ./lib/wrapper.jar
install -m644 $I2PSRC/build/jbigi.jar $PKG/$INSTALL_DIR/i2p/lib/jbigi.jar
rm -f ./postinstall.sh ./osid ./INSTALL-*.txt
sed "s|directory|/$INSTALL_DIR/i2p|" $CWD/doinst.sh > $PKG/install/doinst.sh
sed -i "s|%pkg|$NAME-$VERSION|" $PKG/install/doinst.sh
sed "s|%INST_DIR|/$INSTALL_DIR/i2p|" $CWD/rc.i2p> $PKG/etc/rc.d/rc.i2p.new
cp $CWD/slack-desc $PKG/install/slack-desc
cd $PKG
#
# requiredbuilder fucks up REALLY bad, and thinks java is perl?!
# It also did not catch the shell requirements! BOOOOOOOOOOO! HISSSSSSSS!
#
# requiredbuilder -v -y -s $CWD $PKG
#
cat $CWD/slack-required > $PKG/install/slack-required
cp $CWD/slack-required $PKG/install/slack-required
makepkg -l y -c n $CWD/${NAME}-$VERSION-$ARCH-$BUILD.$EXT

185
Slackware/i2p/rc.i2p Normal file
View File

@ -0,0 +1,185 @@
#!/bin/sh
# Abort on errors
set -e
##
# This *must* be configured. Set this to the user that will run I2P.
# Note: If you don't want I2P to start automatically at boot,
# use "i2prouter start" as a non-root user to start I2P.
#RUN_AS_USER=
##
##
# Set the locale as desired.
# Note: this is not the same as the language shown in the I2P router console.
# This affects the locale used in wrapper.log. For best results, use a
# unicode enabled locale. This is especially important for foreign language torrents.
#
# If not set the user's configured locale will be used.
#RCLOCALE=
##
#####################################################
# Nothing below this point should need to be edited #
#####################################################
# %INST_DIR is set by i2p.SlackBuild
INSTALL_DIR="%INST_DIR"
# Make sure the package is installed and that the wrapper can be found
[ -d $INSTALL_DIR ] && [ -x $INSTALL_DIR/i2psvc ] || (echo "The I2P package is not installed" >&2 ; exit 1)
if [ -z $RUN_AS_USER ]; then
echo "ERROR: RUN_AS_USER not configured in $0" >&2
exit 1
fi
if [ $(id -ur) -ne 0 ]; then
echo 'ERROR: You must be root to start this service.' >&2
echo
exit 1
fi
if [ -z $RCLOCALE ]; then
if [ ! $(locale -a |grep -q "en_US\.utf8") ]; then
RCLOCALE="en_US.utf8"
fi
fi
# Abort this script if any referenced variables haven't been set
set -u
if $(uname -m |grep -q '64'); then
BITS='64'
else
BITS=''
fi
PATH="$PATH:/usr/lib$BITS/java/bin:/usr/lib$BITS/java/jre/bin"
RUN=/var/run/i2p
PIDFILE="$RUN/i2p.pid"
WRAPPER_CONF="$INSTALL_DIR/wrapper.config"
WRAPPERLOG=/var/log/i2p/wrapper.log
I2PTEMP="/tmp/i2p-daemon"
DESC="The I2P daemon"
JAVABINARY=$(awk -F'=' '/^ *wrapper\.java\.command/{print $2}' "$WRAPPER_CONF")
if [ ! $(which $JAVABINARY 2>/dev/null) ]; then
for rc in /etc/profile.d/*jdk*.sh /etc/profile.d/*java*.sh; do
[ -r $rc ] && . $rc
done
if [ ! $(which $JAVABINARY 2>/dev/null) ]; then
echo "ERROR: Cannot find java. Please set the path to java in $WRAPPER_CONF" >&2
exit 1
fi
fi
JAVA=$(which $JAVABINARY 2>/dev/null)
I2P_ARGS="$WRAPPER_CONF \
wrapper.java.additional.1=-DloggerFilenameOverride=/var/log/i2p/log-router-@.txt \
wrapper.java.additional.10=-Dwrapper.logfile=$WRAPPERLOG \
wrapper.java.additional.11=-Di2p.dir.pid=$RUN \
wrapper.java.additional.12=-Di2p.dir.temp=$I2PTEMP \
wrapper.java.command=$JAVA \
wrapper.logfile=$WRAPPERLOG \
wrapper.pidfile=$PIDFILE \
wrapper.daemonize=TRUE"
LC_ALL=$RCLOCALE
LANG=$RCLOCALE
export LC_ALL LANG
is_running() {
if [ -r $PIDFILE ]; then
PID="$(cat ${PIDFILE})" 2>/dev/null 2>&1
if ! kill -0 $PID >/dev/null 2>&1; then
rm "$PIDFILE"
return 1
else
return 0
fi
else
return 1
fi
}
start() {
if is_running; then
echo "ERROR: $DESC is already running." >&2
fi
for DIR in $RUN $I2PTEMP; do
test -d $DIR && rm -rf $DIR
mkdir -p $DIR
chown -R $RUN_AS_USER $DIR
done
[ -d /var/log/i2p ] || mkdir /var/log/i2p
chown -R $RUN_AS_USER /var/log/i2p
echo -n "Starting $DESC..."
TZ=UTC su $RUN_AS_USER -c "$INSTALL_DIR/i2psvc $I2P_ARGS"
is_running
echo "[pid: $PID]"
}
stop(){
if is_running; then
echo -n "Stopping $DESC [pid: $PID] (this could take a while)."
kill "$PID" >/dev/null 2>&1
while kill -0 "$PID" > /dev/null 2>&1; do
echo -n .
sleep 1
done
rm -rf "$RUN" "$I2PTEMP"
echo done.
return 0
else
echo "$DESC is not running." >&2
return 1
fi
}
# Unset +u to allow the 'usage' text to be displayed
set +u
case "$1" in
start)
start
;;
status)
if is_running; then
echo "$DESC is running [pid: $PID]" >&2
else
echo "$DESC is not running." >&2
fi
;;
stop)
stop
;;
graceful)
if is_running; then
kill -HUP $PID
echo "Graceful shutdown of $DESC initiated." >&2
echo "This may take up to 11 minutes." >&2
fi
;;
dump)
if is_running; then
kill -3 $PID
echo "Threads dumped to $WRAPPERLOG" >&2
else
echo "$DESC is not running." >&2
fi
;;
restart)
if is_running; then
stop
start
else
echo "$DESC is not running." >&2
fi
;;
*)
echo "usage: $0 start|stop|status|restart|graceful|dump"
;;
esac

View File

@ -1,47 +0,0 @@
Building:
The i2p package will be installed in /opt/i2p
If you want to change installation dir, change the variable INSTALL_DIR
on i2p.SlackBuild and rebuild the package. You will also need to do the same
in the base-i2p package.
Installation and Upgrade:
Probably you will never have to update i2p packages. However if you do,
be sure to installpkg first, then removepkg or custom config files can
be lost with upgradepkg. I2P has an auto-update function. However using
installpkg then removepkg lowers the demand on the I2P network as a
whole, and is by far faster.
After installpkg command, doinst.sh will execute a postinstallation script
needed by I2P. Be sure to also install the base-i2p package.
Optional:
chmod +x /etc/rc.d/rc.i2p only if you want it to start on boot and stop on
shutdown.
How to start I2P:
Start I2P service with-
sh /etc/rc.d/rc.i2p start
Now tell your browser to user this proxy: localhost on port 4444 and open
this page: http://localhost:7657/index.jsp
Here you can configure I2P, watch network status and navigate anonimously.
It's suggested to subscribe to various addressbook hosts so that you can
get to the many available eepsites and other service on I2P. These are not
set up by default for security reasons.
Please see the faqs on http://www.i2p2.i2p/ or http://www.i2p2.de/ on how
to subscribe to the various addressbook services.
To stop I2P:
/etc/rc.d/rc.i2p stop
For any additional information:
Within I2P- http://www.i2p2.i2p/, http://forum.i2p/, http://zzz.i2p
Internet (not reccomended!) - http://www.i2p2.de/, http://forum.i2p2.de/

View File

@ -6,7 +6,7 @@
# leave one space after the ':'.
|-----handy-ruler----------------------------------------------------------|
i2p: i2p (an anonymizing network)
i2p: I2P (an anonymizing network)
i2p:
i2p: I2P is an anonymizing network, offering a simple layer that
i2p: identity-sensitive applications can use to securely communicate. All
@ -14,6 +14,6 @@ i2p: data is wrapped with several layers of encryption, and the network is
i2p: both distributed and dynamic, with no trusted parties.
i2p: Many applications are available that interface with I2P, including
i2p: mail, peer-peer file sharing, IRC chat, and others.
i2p: WARNING: To upgrade installpkg FIRST _THEN_ removepkg.
i2p: For more information, see: http://www.i2p2.de/
i2p:
i2p: For more information, see: https://geti2p.net/
i2p:

View File

@ -1,4 +1 @@
jre >= 5
i2p-base >= 0.0.1
bash >= 3.1.017
jre >= 6

8
apps/BOB/.classpath Normal file
View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry combineaccessrules="false" kind="src" path="/i2p_sdk"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry combineaccessrules="false" kind="src" path="/ministreaming"/>
<classpathentry kind="output" path="build"/>
</classpath>

17
apps/BOB/.project Normal file
View File

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>BOB</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB.Demos.echo.echoclient;
@ -55,7 +47,7 @@ public class Main {
// exit on anything not legal
break;
}
c = (char)(b & 0x7f); // We only really give a fuck about ASCII
c = (char)(b & 0x7f); // We only care about ASCII
S = new String(S + c);
}
return S;

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB.Demos.echo.echoserver;
@ -52,7 +44,7 @@ public class Main {
if(b < 20) {
break;
}
c = (char)(b & 0x7f); // We only really give a fuck about ASCII
c = (char)(b & 0x7f); // We only care about ASCII
S = new String(S + c);
}
return S;

View File

@ -83,7 +83,7 @@
<pathelement path="${javac.classpath}" />
</path>
</copy>
<copy todir="${dist.dir}/lib" file="../../installer/lib/jbigi/jbigi.jar" />
<copy todir="${dist.dir}/lib" file="../../build/jbigi.jar" />
<!-- Extract the classes inside the jar files -->
<unjar dest="${dist.dir}/classes" >

View File

@ -30,11 +30,11 @@ excludes=**/*.html,**/*.txt
file.reference.build-javadoc=../../i2p.i2p/build/javadoc
file.reference.i2p.jar=../../core/java/build/i2p.jar
file.reference.i2ptunnel.jar=../i2ptunnel/java/build/i2ptunnel.jar
file.reference.jbigi.jar=../../installer/lib/jbigi/jbigi.jar
file.reference.jbigi.jar=../../build/jbigi.jar
file.reference.mstreaming.jar=../ministreaming/java/build/mstreaming.jar
file.reference.router.jar=../../router/java/build/router.jar
file.reference.streaming.jar=../streaming/java/build/streaming.jar
file.reference.wrapper.jar=../../installer/lib/wrapper/linux/wrapper.jar
file.reference.wrapper.jar=../../installer/lib/wrapper/all/wrapper.jar
includes=**
jar.compress=true
javac.classpath=\

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,10 +11,12 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
import static net.i2p.app.ClientAppState.*;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
@ -33,12 +27,17 @@ import java.net.InetAddress;
import java.net.ServerSocket;
import java.net.Socket;
import java.net.SocketTimeoutException;
import java.net.URL;
import java.util.Arrays;
import java.util.Properties;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.jar.Attributes;
import java.util.jar.Manifest;
import net.i2p.I2PAppContext;
import net.i2p.app.*;
import net.i2p.client.I2PClient;
import net.i2p.util.Log;
import net.i2p.util.I2PAppThread;
import net.i2p.util.SimpleScheduler;
import net.i2p.util.SimpleTimer2;
@ -113,58 +112,76 @@ import net.i2p.util.SimpleTimer2;
*
* @author sponge
*/
public class BOB {
public class BOB implements Runnable, ClientApp {
private final static Log _log = new Log(BOB.class);
public final static String PROP_CONFIG_LOCATION = "BOB.config";
public final static String PROP_BOB_PORT = "BOB.port";
public final static String PROP_BOB_HOST = "BOB.host";
public final static String PROP_CFG_VER = "BOB.CFG.VER";
private static NamedDB database;
private static Properties props = new Properties();
private static AtomicBoolean spin = new AtomicBoolean(true);
private static BOB _bob;
private NamedDB database;
private Properties props = new Properties();
private AtomicBoolean spin = new AtomicBoolean(true);
private static final String P_RUNNING = "RUNNING";
private static final String P_STARTING = "STARTING";
private static final String P_STOPPING = "STOPPING";
private static AtomicBoolean lock = new AtomicBoolean(false);
private AtomicBoolean lock = new AtomicBoolean(false);
// no longer used.
// private static int maxConnections = 0;
/**
* Log a warning
*
* @param arg
*/
public static void info(String arg) {
System.out.println("INFO:" + arg);
_log.info(arg);
}
private final Logger _log;
private final ClientAppManager _mgr;
private final String[] _args;
private volatile ClientAppState _state = UNINITIALIZED;
/**
* Log a warning
*
* @param arg
*/
public static void warn(String arg) {
System.out.println("WARNING:" + arg);
_log.warn(arg);
}
/**
* Log an error
*
* @param arg
*/
public static void error(String arg) {
System.out.println("ERROR: " + arg);
_log.error(arg);
}
private volatile ServerSocket listener;
private volatile Thread _runner;
/**
* Stop BOB gracefully
* @deprecated unused
*/
public static void stop() {
spin.set(false);
_bob.shutdown(null);
}
/**
* For ClientApp interface.
* Does NOT open the listener socket or start threads; caller must call startup()
*
* @param mgr may be null
* @param args non-null
* @throws Exception on bad args
* @since 0.9.10
*/
public BOB(I2PAppContext context, ClientAppManager mgr, String[] args) {
// If we were run from command line, log to stdout
boolean logToStdout = false;
URL classResource = BOB.class.getResource("BOB.class");
if (classResource != null) {
String classPath = classResource.toString();
if (classPath.startsWith("jar")) {
String manifestPath = classPath.substring(0, classPath.lastIndexOf("!") + 1) +
"/META-INF/MANIFEST.MF";
try {
Manifest manifest = new Manifest(new URL(manifestPath).openStream());
Attributes attrs = manifest.getMainAttributes();
String mainClass = attrs.getValue("Main-Class");
if ("net.i2p.BOB.Main".equals(mainClass))
logToStdout = true;
} catch (IOException ioe) {}
}
}
_log = new Logger(context.logManager().getLog(BOB.class), logToStdout);
_mgr = mgr;
_args = args;
_state = INITIALIZED;
database = new NamedDB();
loadConfig();
}
/**
@ -173,8 +190,22 @@ public class BOB {
* @param args
*/
public static void main(String[] args) {
database = new NamedDB();
ServerSocket listener = null;
try {
_bob = new BOB(I2PAppContext.getGlobalContext(), null, args);
_bob.startup();
} catch (RuntimeException e) {
e.printStackTrace();
throw e;
} catch (Exception e) {
e.printStackTrace();
throw new RuntimeException(e);
}
}
/**
* @since 0.9.10
*/
private void loadConfig() {
int i = 0;
boolean save = false;
// Set up all defaults to be passed forward to other threads.
@ -185,114 +216,144 @@ public class BOB {
SimpleTimer2 Y2 = SimpleTimer2.getInstance();
i = Y1.hashCode();
i = Y2.hashCode();
try {
{
File cfg = new File(configLocation);
if (!cfg.isAbsolute()) {
cfg = new File(I2PAppContext.getGlobalContext().getConfigDir(), configLocation);
}
try {
FileInputStream fi = new FileInputStream(cfg);
props.load(fi);
fi.close();
} catch (FileNotFoundException fnfe) {
warn("Unable to load up the BOB config file " + cfg.getAbsolutePath() + ", Using defaults.");
warn(fnfe.toString());
save = true;
} catch (IOException ioe) {
warn("IOException on BOB config file " + cfg.getAbsolutePath() + ", using defaults.");
warn(ioe.toString());
}
{
File cfg = new File(configLocation);
if (!cfg.isAbsolute()) {
cfg = new File(I2PAppContext.getGlobalContext().getConfigDir(), configLocation);
}
// Global router and client API configurations that are missing are set to defaults here.
if (!props.containsKey(I2PClient.PROP_TCP_HOST)) {
props.setProperty(I2PClient.PROP_TCP_HOST, "localhost");
save = true;
}
if (!props.containsKey(I2PClient.PROP_TCP_PORT)) {
props.setProperty(I2PClient.PROP_TCP_PORT, "7654");
save = true;
}
if (!props.containsKey(PROP_BOB_PORT)) {
props.setProperty(PROP_BOB_PORT, "2827"); // 0xB0B
save = true;
}
if (!props.containsKey("inbound.length")) {
props.setProperty("inbound.length", "1");
save = true;
}
if (!props.containsKey("outbound.length")) {
props.setProperty("outbound.length", "1");
save = true;
}
if (!props.containsKey("inbound.lengthVariance")) {
props.setProperty("inbound.lengthVariance", "0");
save = true;
}
if (!props.containsKey("outbound.lengthVariance")) {
props.setProperty("outbound.lengthVariance", "0");
save = true;
}
if (!props.containsKey(PROP_BOB_HOST)) {
props.setProperty(PROP_BOB_HOST, "localhost");
save = true;
}
// PROP_RELIABILITY_NONE, PROP_RELIABILITY_BEST_EFFORT, PROP_RELIABILITY_GUARANTEED
if (!props.containsKey(PROP_CFG_VER)) {
props.setProperty(I2PClient.PROP_RELIABILITY, I2PClient.PROP_RELIABILITY_NONE);
props.setProperty(PROP_CFG_VER,"1");
save = true;
}
if (save) {
File cfg = new File(configLocation);
if (!cfg.isAbsolute()) {
cfg = new File(I2PAppContext.getGlobalContext().getConfigDir(), configLocation);
}
try {
warn("Writing new defaults file " + cfg.getAbsolutePath());
FileOutputStream fo = new FileOutputStream(cfg);
props.store(fo, cfg.getAbsolutePath());
fo.close();
} catch (IOException ioe) {
error("IOException on BOB config file " + cfg.getAbsolutePath() + ", " + ioe);
}
}
i = 0;
boolean g = false;
FileInputStream fi = null;
try {
info("BOB is now running.");
listener = new ServerSocket(Integer.parseInt(props.getProperty(PROP_BOB_PORT)), 10, InetAddress.getByName(props.getProperty(PROP_BOB_HOST)));
Socket server = null;
listener.setSoTimeout(500); // .5 sec
while (spin.get()) {
//DoCMDS connection;
try {
server = listener.accept();
server.setKeepAlive(true);
g = true;
} catch (ConnectException ce) {
g = false;
} catch (SocketTimeoutException ste) {
g = false;
}
if (g) {
DoCMDS conn_c = new DoCMDS(spin, lock, server, props, database, _log);
Thread t = new Thread(conn_c);
t.setName("BOB.DoCMDS " + i);
t.start();
i++;
}
}
fi = new FileInputStream(cfg);
props.load(fi);
} catch (FileNotFoundException fnfe) {
_log.warn("Unable to load up the BOB config file " + cfg.getAbsolutePath() + ", Using defaults.", fnfe);
save = true;
} catch (IOException ioe) {
error("IOException on socket listen: " + ioe);
ioe.printStackTrace();
_log.warn("IOException on BOB config file " + cfg.getAbsolutePath() + ", using defaults.", ioe);
} finally {
if (fi != null) try { fi.close(); } catch (IOException ioe) {}
}
}
// Global router and client API configurations that are missing are set to defaults here.
if (!props.containsKey(I2PClient.PROP_TCP_HOST)) {
props.setProperty(I2PClient.PROP_TCP_HOST, "localhost");
save = true;
}
if (!props.containsKey(I2PClient.PROP_TCP_PORT)) {
props.setProperty(I2PClient.PROP_TCP_PORT, "7654");
save = true;
}
if (!props.containsKey(PROP_BOB_PORT)) {
props.setProperty(PROP_BOB_PORT, "2827"); // 0xB0B
save = true;
}
if (!props.containsKey("inbound.length")) {
props.setProperty("inbound.length", "1");
save = true;
}
if (!props.containsKey("outbound.length")) {
props.setProperty("outbound.length", "1");
save = true;
}
if (!props.containsKey("inbound.lengthVariance")) {
props.setProperty("inbound.lengthVariance", "0");
save = true;
}
if (!props.containsKey("outbound.lengthVariance")) {
props.setProperty("outbound.lengthVariance", "0");
save = true;
}
if (!props.containsKey(PROP_BOB_HOST)) {
props.setProperty(PROP_BOB_HOST, "localhost");
save = true;
}
// PROP_RELIABILITY_NONE, PROP_RELIABILITY_BEST_EFFORT, PROP_RELIABILITY_GUARANTEED
if (!props.containsKey(PROP_CFG_VER)) {
props.setProperty(I2PClient.PROP_RELIABILITY, I2PClient.PROP_RELIABILITY_NONE);
props.setProperty(PROP_CFG_VER,"1");
save = true;
}
if (save) {
File cfg = new File(configLocation);
if (!cfg.isAbsolute()) {
cfg = new File(I2PAppContext.getGlobalContext().getConfigDir(), configLocation);
}
FileOutputStream fo = null;
try {
_log.warn("Writing new defaults file " + cfg.getAbsolutePath());
fo = new FileOutputStream(cfg);
props.store(fo, cfg.getAbsolutePath());
} catch (IOException ioe) {
_log.error("IOException on BOB config file " + cfg.getAbsolutePath(), ioe);
} finally {
if (fo != null) try { fo.close(); } catch (IOException ioe) {}
}
}
}
/**
* @since 0.9.10
*/
private void startListener() throws IOException {
listener = new ServerSocket(Integer.parseInt(props.getProperty(PROP_BOB_PORT)), 10, InetAddress.getByName(props.getProperty(PROP_BOB_HOST)));
listener.setSoTimeout(500); // .5 sec
}
/**
* @since 0.9.10
*/
private void startThread() {
I2PAppThread t = new I2PAppThread(this, "BOBListener");
t.start();
_runner = t;
}
/**
* @since 0.9.10
*/
public void run() {
if (listener == null) return;
changeState(RUNNING);
_log.info("BOB is now running.");
if (_mgr != null)
_mgr.register(this);
int i = 0;
boolean g = false;
spin.set(true);
try {
Socket server = null;
while (spin.get()) {
//DoCMDS connection;
try {
server = listener.accept();
server.setKeepAlive(true);
g = true;
} catch (ConnectException ce) {
g = false;
} catch (SocketTimeoutException ste) {
g = false;
}
if (g) {
DoCMDS conn_c = new DoCMDS(spin, lock, server, props, database, _log);
Thread t = new Thread(conn_c);
t.setName("BOB.DoCMDS " + i);
t.start();
i++;
}
}
changeState(STOPPING);
} catch (Exception e) {
if (spin.get())
_log.error("Unexpected error while listening for connections", e);
else
e = null;
changeState(STOPPING, e);
} finally {
info("BOB is now shutting down...");
_log.info("BOB is now shutting down...");
// Clean up everything.
try {
listener.close();
@ -315,7 +376,7 @@ public class BOB {
database.releaseReadLock();
database.getWriteLock();
nickinfo.getWriteLock();
nickinfo.add(P_STOPPING, new Boolean(true));
nickinfo.add(P_STOPPING, Boolean.valueOf(true));
nickinfo.releaseWriteLock();
database.releaseWriteLock();
} else {
@ -323,8 +384,8 @@ public class BOB {
database.releaseReadLock();
}
}
info("BOB is now stopped.");
changeState(STOPPED);
_log.info("BOB is now stopped.");
}
}
@ -376,4 +437,86 @@ public class BOB {
waitjoin(groups[i], level + 1, groups[i].getName());
}
}
////// begin ClientApp interface
/**
* @since 0.9.10
*/
@Override
public void startup() throws IOException {
if (_state != INITIALIZED)
return;
changeState(STARTING);
try {
startListener();
} catch (IOException e) {
_log.error("Error starting BOB on"
+ props.getProperty(PROP_BOB_HOST)
+ ":" + props.getProperty(PROP_BOB_PORT), e);
changeState(START_FAILED, e);
throw e;
}
startThread();
}
/**
* @since 0.9.10
*/
@Override
public void shutdown(String[] args) {
if (_state != RUNNING)
return;
changeState(STOPPING);
spin.set(false);
if (_runner != null)
_runner.interrupt();
else
changeState(STOPPED);
}
/**
* @since 0.9.10
*/
@Override
public ClientAppState getState() {
return _state;
}
/**
* @since 0.9.10
*/
@Override
public String getName() {
return "BOB";
}
/**
* @since 0.9.10
*/
@Override
public String getDisplayName() {
return "BOB " + Arrays.toString(_args);
}
////// end ClientApp interface
////// begin ClientApp helpers
/**
* @since 0.9.10
*/
private void changeState(ClientAppState state) {
changeState(state, null);
}
/**
* @since 0.9.10
*/
private synchronized void changeState(ClientAppState state, Exception e) {
_state = state;
if (_mgr != null)
_mgr.notify(this, state, null, e);
}
////// end ClientApp helpers
}

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -39,7 +31,6 @@ import net.i2p.client.I2PClientFactory;
//import net.i2p.data.DataFormatException;
import net.i2p.data.Destination;
//import net.i2p.i2ptunnel.I2PTunnel;
import net.i2p.util.Log;
// needed only for debugging.
// import java.util.logging.Level;
// import java.util.logging.Logger;
@ -54,7 +45,7 @@ public class DoCMDS implements Runnable {
// FIX ME
// I need a better way to do versioning, but this will do for now.
public static final String BMAJ = "00", BMIN = "00", BREV = "0F", BEXT = "";
public static final String BMAJ = "00", BMIN = "00", BREV = "10", BEXT = "";
public static final String BOBversion = BMAJ + "." + BMIN + "." + BREV + BEXT;
private Socket server;
private Properties props;
@ -64,7 +55,7 @@ public class DoCMDS implements Runnable {
private ByteArrayOutputStream prikey;
private boolean dk, ns, ip, op;
private NamedDB nickinfo;
private Log _log;
private Logger _log;
private AtomicBoolean LIVE;
private AtomicBoolean lock;
/* database strings */
@ -172,7 +163,7 @@ public class DoCMDS implements Runnable {
* @param database
* @param _log
*/
DoCMDS(AtomicBoolean LIVE, AtomicBoolean lock, Socket server, Properties props, NamedDB database, Log _log) {
DoCMDS(AtomicBoolean LIVE, AtomicBoolean lock, Socket server, Properties props, NamedDB database, Logger _log) {
this.lock = lock;
this.LIVE = LIVE;
this.server = server;
@ -396,7 +387,7 @@ public class DoCMDS implements Runnable {
* Does the base64 information look OK
*
* @param data
* @return
* @return OK
*/
private boolean is64ok(String data) {
try {
@ -614,7 +605,7 @@ public class DoCMDS implements Runnable {
break die;
}
} catch (I2PException ipe) {
BOB.error("Error generating keys" + ipe);
_log.error("Error generating keys", ipe);
out.println("ERROR generating keys");
}
@ -673,7 +664,7 @@ public class DoCMDS implements Runnable {
break die;
}
try {
nickinfo.add(P_QUIET, new Boolean(Boolean.parseBoolean(Arg) == true));
nickinfo.add(P_QUIET, Boolean.valueOf(Arg));
} catch (Exception ex) {
try {
wunlock();
@ -825,10 +816,10 @@ public class DoCMDS implements Runnable {
try {
database.add(Arg, nickinfo);
nickinfo.add(P_NICKNAME, Arg);
nickinfo.add(P_STARTING, new Boolean(false));
nickinfo.add(P_RUNNING, new Boolean(false));
nickinfo.add(P_STOPPING, new Boolean(false));
nickinfo.add(P_QUIET, new Boolean(false));
nickinfo.add(P_STARTING, Boolean.valueOf(false));
nickinfo.add(P_RUNNING, Boolean.valueOf(false));
nickinfo.add(P_STOPPING, Boolean.valueOf(false));
nickinfo.add(P_QUIET, Boolean.valueOf(false));
nickinfo.add(P_INHOST, "localhost");
nickinfo.add(P_OUTHOST, "localhost");
Properties Q = new Properties();
@ -997,7 +988,7 @@ public class DoCMDS implements Runnable {
prt = Integer.parseInt(Arg);
if (prt > 1 && prt < 65536) {
try {
nickinfo.add(P_INPORT, new Integer(prt));
nickinfo.add(P_INPORT, Integer.valueOf(prt));
} catch (Exception ex) {
try {
wunlock();
@ -1084,7 +1075,7 @@ public class DoCMDS implements Runnable {
prt = Integer.parseInt(Arg);
if (prt > 1 && prt < 65536) {
try {
nickinfo.add(P_OUTPORT, new Integer(prt));
nickinfo.add(P_OUTPORT, Integer.valueOf(prt));
} catch (Exception ex) {
try {
wunlock();
@ -1363,7 +1354,7 @@ public class DoCMDS implements Runnable {
break die;
}
nickinfo.add(P_STOPPING, new Boolean(true));
nickinfo.add(P_STOPPING, Boolean.valueOf(true));
try {
wunlock();

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -30,7 +22,6 @@ import net.i2p.I2PException;
import net.i2p.client.streaming.I2PServerSocket;
import net.i2p.client.streaming.I2PSocket;
import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.util.Log;
/**
* Listen on I2P and connect to TCP
@ -40,8 +31,7 @@ import net.i2p.util.Log;
public class I2Plistener implements Runnable {
private NamedDB info, database;
private Log _log;
// private int tgwatch;
private Logger _log;
public I2PSocketManager socketManager;
public I2PServerSocket serverSocket;
private AtomicBoolean lives;
@ -54,7 +44,7 @@ public class I2Plistener implements Runnable {
* @param database
* @param _log
*/
I2Plistener(I2PServerSocket SS, I2PSocketManager S, NamedDB info, NamedDB database, Log _log, AtomicBoolean lives) {
I2Plistener(I2PServerSocket SS, I2PSocketManager S, NamedDB info, NamedDB database, Logger _log, AtomicBoolean lives) {
this.database = database;
this.info = info;
this._log = _log;
@ -95,7 +85,7 @@ public class I2Plistener implements Runnable {
}
} catch (I2PException e) {
// bad shit
// bad stuff
System.out.println("Exception " + e);
}
} finally {
@ -103,7 +93,7 @@ public class I2Plistener implements Runnable {
serverSocket.close();
} catch (I2PException ex) {
}
// System.out.println("I2Plistener: Close");
// System.out.println("I2Plistener: Close");
}
}
}

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,11 +11,11 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
import java.util.Enumeration;
import java.util.Map;
import java.util.Properties;
/**
@ -47,10 +39,8 @@ public class Lifted {
*
**/
public static void copyProperties(Properties src_prop, Properties dest_prop) {
for (Enumeration propertyNames = src_prop.propertyNames();
propertyNames.hasMoreElements();) {
Object key = propertyNames.nextElement();
dest_prop.put(key, src_prop.get(key));
for (Map.Entry<Object, Object> e : src_prop.entrySet()) {
dest_prop.put((String)e.getKey(), (String)e.getValue());
}
}
}

View File

@ -0,0 +1,44 @@
package net.i2p.BOB;
import net.i2p.util.Log;
public class Logger {
public Log log;
private boolean logToStdout;
public Logger(Log log, boolean logToStdout) {
this.log = log;
this.logToStdout = logToStdout;
}
public void info(String msg) {
if (logToStdout)
System.out.println("INFO: " + msg);
if (log.shouldLog(Log.INFO))
log.info(msg);
}
public void warn(String msg) {
warn(msg, null);
}
public void warn(String msg, Throwable e) {
if (logToStdout) {
System.out.println("WARNING: " + msg);
if (e != null)
e.printStackTrace();
}
if (log.shouldLog(Log.WARN))
log.warn(msg, e);
}
public void error(String msg, Throwable e) {
if (logToStdout) {
System.out.println("ERROR: " + msg);
if (e != null)
e.printStackTrace();
}
if (log.shouldLog(Log.ERROR))
log.error(msg, e);
}
}

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -30,6 +22,7 @@ import java.net.ServerSocket;
import java.util.Properties;
import java.util.concurrent.atomic.AtomicBoolean;
import net.i2p.I2PException;
import net.i2p.client.I2PClient;
import net.i2p.client.streaming.I2PServerSocket;
import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.client.streaming.I2PSocketManagerFactory;
@ -44,7 +37,7 @@ import net.i2p.util.Log;
public class MUXlisten implements Runnable {
private NamedDB database, info;
private Log _log;
private Logger _log;
private I2PSocketManager socketManager;
private ByteArrayInputStream prikey;
private ThreadGroup tg;
@ -65,7 +58,7 @@ public class MUXlisten implements Runnable {
* @throws net.i2p.I2PException
* @throws java.io.IOException
*/
MUXlisten(AtomicBoolean lock, NamedDB database, NamedDB info, Log _log) throws I2PException, IOException, RuntimeException {
MUXlisten(AtomicBoolean lock, NamedDB database, NamedDB info, Logger _log) throws I2PException, IOException, RuntimeException {
try {
int port = 0;
InetAddress host = null;
@ -78,7 +71,7 @@ public class MUXlisten implements Runnable {
this.database.getWriteLock();
this.info.getWriteLock();
this.info.add("STARTING", new Boolean(true));
this.info.add("STARTING", Boolean.valueOf(true));
this.info.releaseWriteLock();
this.database.releaseWriteLock();
this.database.getReadLock();
@ -104,25 +97,25 @@ public class MUXlisten implements Runnable {
this.database.releaseReadLock();
this.info.releaseReadLock();
String i2cpHost = Q.getProperty(I2PClient.PROP_TCP_HOST, "127.0.0.1");
int i2cpPort = 7654;
String i2cpPortStr = Q.getProperty(I2PClient.PROP_TCP_PORT, "7654");
try {
i2cpPort = Integer.parseInt(i2cpPortStr);
} catch (NumberFormatException nfe) {
throw new IllegalArgumentException("Invalid I2CP port specified [" + i2cpPortStr + "]");
}
if (this.come_in) {
this.listener = new ServerSocket(port, backlog, host);
}
socketManager = I2PSocketManagerFactory.createManager(prikey, Q);
// I2PException, IOException, RuntimeException
// To bad we can't just catch and enumerate....
// } catch (I2PException e) {
// Something went bad.
// this.database.getWriteLock();
// this.info.getWriteLock();
// this.info.add("STARTING", new Boolean(false));
// this.info.releaseWriteLock();
// this.database.releaseWriteLock();
// throw new I2PException(e);
socketManager = I2PSocketManagerFactory.createManager(
prikey, i2cpHost, i2cpPort, Q);
} catch (IOException e) {
// Something went bad.
this.database.getWriteLock();
this.info.getWriteLock();
this.info.add("STARTING", new Boolean(false));
this.info.add("STARTING", Boolean.valueOf(false));
this.info.releaseWriteLock();
this.database.releaseWriteLock();
throw new IOException(e.toString());
@ -130,7 +123,7 @@ public class MUXlisten implements Runnable {
// Something went bad.
this.database.getWriteLock();
this.info.getWriteLock();
this.info.add("STARTING", new Boolean(false));
this.info.add("STARTING", Boolean.valueOf(false));
this.info.releaseWriteLock();
this.database.releaseWriteLock();
throw new RuntimeException(e);
@ -138,7 +131,7 @@ public class MUXlisten implements Runnable {
// Something else went bad.
this.database.getWriteLock();
this.info.getWriteLock();
this.info.add("STARTING", new Boolean(false));
this.info.add("STARTING", Boolean.valueOf(false));
this.info.releaseWriteLock();
this.database.releaseWriteLock();
e.printStackTrace();
@ -178,7 +171,7 @@ public class MUXlisten implements Runnable {
try {
wlock();
try {
info.add("RUNNING", new Boolean(true));
info.add("RUNNING", Boolean.valueOf(true));
} catch (Exception e) {
lock.set(false);
wunlock();
@ -194,7 +187,6 @@ public class MUXlisten implements Runnable {
lock.set(false);
return;
}
// socketManager.addDisconnectListener(new DisconnectListener());
lives.set(true);
lock.set(false);
quit:
@ -223,7 +215,7 @@ public class MUXlisten implements Runnable {
try {
wlock();
try {
info.add("STARTING", new Boolean(false));
info.add("STARTING", Boolean.valueOf(false));
} catch (Exception e) {
wunlock();
break quit;
@ -277,9 +269,9 @@ public class MUXlisten implements Runnable {
try {
wlock();
try {
info.add("STARTING", new Boolean(false));
info.add("STOPPING", new Boolean(true));
info.add("RUNNING", new Boolean(false));
info.add("STARTING", Boolean.valueOf(false));
info.add("STOPPING", Boolean.valueOf(true));
info.add("RUNNING", Boolean.valueOf(false));
} catch (Exception e) {
lock.set(false);
wunlock();
@ -313,14 +305,14 @@ public class MUXlisten implements Runnable {
// Hopefully nuke stuff here...
{
String boner = tg.getName();
String groupName = tg.getName();
try {
_log.warn("destroySocketManager " + boner);
_log.warn("destroySocketManager " + groupName);
socketManager.destroySocketManager();
_log.warn("destroySocketManager Successful" + boner);
_log.warn("destroySocketManager Successful" + groupName);
} catch (Exception e) {
// nop
_log.warn("destroySocketManager Failed" + boner);
_log.warn("destroySocketManager Failed" + groupName);
_log.warn(e.toString());
}
}
@ -328,9 +320,9 @@ public class MUXlisten implements Runnable {
try {
wlock();
try {
info.add("STARTING", new Boolean(false));
info.add("STOPPING", new Boolean(false));
info.add("RUNNING", new Boolean(false));
info.add("STARTING", Boolean.valueOf(false));
info.add("STOPPING", Boolean.valueOf(false));
info.add("RUNNING", Boolean.valueOf(false));
} catch (Exception e) {
lock.set(false);
wunlock();
@ -344,26 +336,25 @@ public class MUXlisten implements Runnable {
// Wait around till all threads are collected.
if (tg != null) {
String boner = tg.getName();
// System.out.println("BOB: MUXlisten: Starting thread collection for: " + boner);
_log.warn("BOB: MUXlisten: Starting thread collection for: " + boner);
// tg.interrupt(); // give my stuff a small smack again.
String groupName = tg.getName();
// System.out.println("BOB: MUXlisten: Starting thread collection for: " + groupName);
_log.warn("BOB: MUXlisten: Starting thread collection for: " + groupName);
if (tg.activeCount() + tg.activeGroupCount() != 0) {
// visit(tg, 0, boner);
// visit(tg, 0, groupName);
int foo = tg.activeCount() + tg.activeGroupCount();
// hopefully no longer needed!
// int bar = lives;
// System.out.println("BOB: MUXlisten: Waiting on threads for " + boner);
// System.out.println("\nBOB: MUXlisten: ThreadGroup dump BEGIN " + boner);
// visit(tg, 0, boner);
// System.out.println("BOB: MUXlisten: ThreadGroup dump END " + boner + "\n");
// System.out.println("BOB: MUXlisten: Waiting on threads for " + groupName);
// System.out.println("\nBOB: MUXlisten: ThreadGroup dump BEGIN " + groupName);
// visit(tg, 0, groupName);
// System.out.println("BOB: MUXlisten: ThreadGroup dump END " + groupName + "\n");
// Happily spin forever :-(
while (foo != 0) {
foo = tg.activeCount() + tg.activeGroupCount();
// if (lives != bar && lives != 0) {
// System.out.println("\nBOB: MUXlisten: ThreadGroup dump BEGIN " + boner);
// visit(tg, 0, boner);
// System.out.println("BOB: MUXlisten: ThreadGroup dump END " + boner + "\n");
// System.out.println("\nBOB: MUXlisten: ThreadGroup dump BEGIN " + groupName);
// visit(tg, 0, groupName);
// System.out.println("BOB: MUXlisten: ThreadGroup dump END " + groupName + "\n");
// }
// bar = lives;
try {
@ -373,8 +364,8 @@ public class MUXlisten implements Runnable {
}
}
}
// System.out.println("BOB: MUXlisten: Threads went away. Success: " + boner);
_log.warn("BOB: MUXlisten: Threads went away. Success: " + boner);
// System.out.println("BOB: MUXlisten: Threads went away. Success: " + groupName);
_log.warn("BOB: MUXlisten: Threads went away. Success: " + groupName);
tg.destroy();
// Zap reference to the ThreadGroup so the JVM can GC it.
tg = null;

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -31,7 +23,7 @@ package net.i2p.BOB;
public class NamedDB {
private volatile Object[][] data;
private volatile int index, writersWaiting, readers;
private int index, writersWaiting, readers;
/**
* make initial NULL object
@ -39,7 +31,6 @@ public class NamedDB {
*/
public NamedDB() {
this.data = new Object[1][2];
this.index = this.writersWaiting = this.readers = 0;
}
synchronized public void getReadLock() {

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -95,14 +87,9 @@ public class TCPio implements Runnable {
if (b > 0) {
Aout.write(a, 0, b);
} else if (b == 0) {
// Will this die? We'll see.
while(Ain.available() == 0) {
Thread.sleep(20);
}
// Thread.yield(); // this should act like a mini sleep.
// if (Ain.available() == 0) {
// Thread.sleep(10);
// }
} else {
/* according to the specs:
*
@ -129,7 +116,6 @@ public class TCPio implements Runnable {
Aout.close();
} catch (IOException ex) {
}
return;
}
}
}

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -27,12 +19,9 @@ import java.io.IOException;
import java.net.ServerSocket;
import java.net.Socket;
import java.net.SocketTimeoutException;
// import net.i2p.client.I2PSession;
// import net.i2p.client.I2PSessionException;
import java.util.concurrent.atomic.AtomicBoolean;
import net.i2p.client.streaming.I2PServerSocket;
import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.util.Log;
/**
* Listen on TCP port and connect to I2P
@ -42,7 +31,7 @@ import net.i2p.util.Log;
public class TCPlistener implements Runnable {
private NamedDB info, database;
private Log _log;
private Logger _log;
public I2PSocketManager socketManager;
public I2PServerSocket serverSocket;
private ServerSocket listener;
@ -55,7 +44,7 @@ public class TCPlistener implements Runnable {
* @param database
* @param _log
*/
TCPlistener(ServerSocket listener, I2PSocketManager S, NamedDB info, NamedDB database, Log _log, AtomicBoolean lives) {
TCPlistener(ServerSocket listener, I2PSocketManager S, NamedDB info, NamedDB database, Logger _log, AtomicBoolean lives) {
this.database = database;
this.info = info;
this._log = _log;

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -78,12 +70,10 @@ public class TCPtoI2P implements Runnable {
* @throws IOException
*/
private static String lnRead(InputStream in) throws IOException {
String S;
StringBuilder builder = new StringBuilder();
int b;
char c;
S = new String();
while (true) {
b = in.read();
if (b == 13) {
@ -94,10 +84,10 @@ public class TCPtoI2P implements Runnable {
// exit on anything not legal
break;
}
c = (char) (b & 0x7f); // We only really give a fuck about ASCII
S = new String(S + c);
c = (char) (b & 0x7f); // We only care about ASCII
builder.append(c);
}
return S;
return builder.toString();
}
/**
@ -108,20 +98,18 @@ public class TCPtoI2P implements Runnable {
* @throws java.io.IOException
*/
private void Emsg(String e, OutputStream out) throws IOException {
// Debugging System.out.println("ERROR TCPtoI2P: " + e);
out.write("ERROR ".concat(e).getBytes());
// Debugging System.out.println("ERROR TCPtoI2P: " + e);
out.write("ERROR ".concat(e).getBytes("UTF-8"));
out.write(13);
out.write(10);
out.flush();
}
// private void rlock() throws Exception {
private void rlock() {
database.getReadLock();
info.getReadLock();
}
// private void runlock() throws Exception {
private void runlock() {
info.releaseReadLock();
database.releaseReadLock();

View File

@ -1,17 +1,9 @@
/**
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* WTFPL
* Version 2, December 2004
*
* Copyright (C) sponge
* Planet Earth
* Everyone is permitted to copy and distribute verbatim or modified
* copies of this license document, and changing it is allowed as long
* as the name is changed.
*
* DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
* TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
*
* 0. You just DO WHAT THE FUCK YOU WANT TO.
*
* See...
*
@ -19,7 +11,7 @@
* and
* http://en.wikipedia.org/wiki/WTFPL
*
* ...for any additional details and liscense questions.
* ...for any additional details and license questions.
*/
package net.i2p.BOB;
@ -111,11 +103,13 @@ public class UDPIOthread implements I2PSessionListener, Runnable {
* @param size
*/
public void messageAvailable(I2PSession session, int msgId, long size) {
// _log.debug("Message available: id = " + msgId + " size = " + size);
// _log.debug("Message available: id = " + msgId + " size = " + size);
try {
byte msg[] = session.receiveMessage(msgId);
out.write(msg);
out.flush();
if (msg != null) {
out.write(msg);
out.flush();
}
} catch (I2PSessionException ise) {
up = false;
} catch (IOException ioe) {

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="java/src"/>
<classpathentry combineaccessrules="false" kind="src" path="/i2p_sdk"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="lib" path="/jetty/jettylib/javax.servlet.jar"/>
<classpathentry kind="output" path="build"/>
</classpath>

17
apps/addressbook/.project Normal file
View File

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>addressbook</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>

View File

@ -7,6 +7,7 @@
<property name="jar" value="addressbook.jar"/>
<property name="war" value="addressbook.war"/>
<property name="javac.compilerargs" value="" />
<property name="javac.version" value="1.6" />
<target name="init">
<mkdir dir="${build}"/>
@ -24,6 +25,18 @@
<typefound name="depend" />
</condition>
<target name="depend" if="depend.available">
<depend
cache="../../build"
srcdir="${src}"
destdir="${build}" >
<!-- Depend on classes instead of jars where available -->
<classpath>
<pathelement location="../../core/java/build/obj" />
</classpath>
</depend>
</target>
<target name="dependServlet" if="depend.available">
<depend
cache="../../build"
srcdir="${src}"
@ -37,9 +50,22 @@
</target>
<target name="compile" depends="init, depend">
<javac debug="true" deprecation="on" source="1.5" target="1.5"
<javac debug="true" deprecation="on" source="${javac.version}" target="${javac.version}"
includeAntRuntime="false"
srcdir="${src}" destdir="${build}">
srcdir="${src}" destdir="${build}"
excludes="net/i2p/addressbook/Servlet.java">
<compilerarg line="${javac.compilerargs}" />
<classpath>
<pathelement location="../../core/java/build/i2p.jar" />
</classpath>
</javac>
</target>
<target name="compileServlet" depends="init, dependServlet, compile">
<javac debug="true" deprecation="on" source="${javac.version}" target="${javac.version}"
includeAntRuntime="false"
srcdir="${src}" destdir="${build}"
includes="net/i2p/addressbook/Servlet.java">
<compilerarg line="${javac.compilerargs}" />
<classpath>
<pathelement location="../../core/java/build/i2p.jar" />
@ -48,11 +74,11 @@
</javac>
</target>
<!-- unused for now, as we oddly ship addressbook as a .war -->
<!-- unused for now (except for Android), as we oddly ship addressbook as a .war -->
<target name="jar" depends="compile, changes">
<jar basedir="${build}" destfile="${dist}/${jar}">
<!-- set if unset -->
<property name="workspace.changes" value="" />
<jar basedir="${build}" destfile="${dist}/${jar}">
<manifest>
<attribute name="Main-Class" value="addressbook.Daemon"/>
<attribute name="Implementation-Version" value="${full.version}" />
@ -64,7 +90,7 @@
</jar>
</target>
<target name="war" depends="compile, changes, warUpToDate" unless="war.uptodate">
<target name="war" depends="compileServlet, changes, warUpToDate" unless="war.uptodate">
<mkdir dir="${dist}/tmp"/>
<mkdir dir="${dist}/tmp/WEB-INF"/>
<mkdir dir="${dist}/tmp/WEB-INF/classes"/>

View File

@ -120,11 +120,11 @@ class AddressBook {
subscription.setLastFetched(I2PAppContext.getGlobalContext().clock().now());
subf = tmp;
} else {
a = Collections.EMPTY_MAP;
a = Collections.emptyMap();
tmp.delete();
}
} catch (IOException ioe) {
a = Collections.EMPTY_MAP;
a = Collections.emptyMap();
}
this.addresses = a;
this.subFile = subf;
@ -148,7 +148,7 @@ class AddressBook {
try {
a = ConfigParser.parse(file);
} catch (IOException exp) {
a = new HashMap();
a = new HashMap<String, String>();
}
this.addresses = a;
this.subFile = null;
@ -260,7 +260,7 @@ class AddressBook {
* An AddressBook to merge with.
* @param overwrite True to overwrite
* @param log
* The log to write messages about new addresses or conflicts to.
* The log to write messages about new addresses or conflicts to. May be null.
*
* @throws IllegalStateException if this was created with the Subscription constructor.
*/

View File

@ -138,7 +138,8 @@ class ConfigIterator implements Iterator<Map.Entry<String, String>> {
public boolean equals(Object o) {
if (!(o instanceof Map.Entry))
return false;
Map.Entry e = (Map.Entry) o;
@SuppressWarnings("unchecked")
Map.Entry<Object, Object> e = (Map.Entry<Object, Object>) o;
return key.equals(e.getKey()) && value.equals(e.getValue());
}
}

View File

@ -37,6 +37,7 @@ import java.util.Map;
import net.i2p.util.SecureFile;
import net.i2p.util.SecureFileOutputStream;
import net.i2p.util.SystemVersion;
/**
* Utility class providing methods to parse and write files in config file
@ -49,7 +50,7 @@ import net.i2p.util.SecureFileOutputStream;
*/
class ConfigParser {
private static final boolean isWindows = System.getProperty("os.name").startsWith("Win");
private static final boolean isWindows = SystemVersion.isWindows();
/**
* Strip the comments from a String. Lines that begin with '#' and ';' are
@ -86,11 +87,11 @@ class ConfigParser {
*
*/
public static Map<String, String> parse(BufferedReader input) throws IOException {
Map<String, String> result = new HashMap();
Map<String, String> result = new HashMap<String, String>();
String inputLine;
inputLine = input.readLine();
while (inputLine != null) {
inputLine = ConfigParser.stripComments(inputLine);
inputLine = stripComments(inputLine);
String[] splitLine = inputLine.split("=");
if (splitLine.length == 2) {
result.put(splitLine[0].trim().toLowerCase(Locale.US), splitLine[1].trim());
@ -115,7 +116,7 @@ class ConfigParser {
FileInputStream fileStream = new FileInputStream(file);
BufferedReader input = new BufferedReader(new InputStreamReader(
fileStream));
Map<String, String> rv = ConfigParser.parse(input);
Map<String, String> rv = parse(input);
try {
fileStream.close();
} catch (IOException ioe) {}
@ -135,7 +136,7 @@ class ConfigParser {
public static Map<String, String> parse(String string) throws IOException {
StringReader stringReader = new StringReader(string);
BufferedReader input = new BufferedReader(stringReader);
return ConfigParser.parse(input);
return parse(input);
}
/**
@ -152,7 +153,7 @@ class ConfigParser {
public static Map<String, String> parse(File file, Map<String, String> map) {
Map<String, String> result;
try {
result = ConfigParser.parse(file);
result = parse(file);
for (Map.Entry<String, String> entry : map.entrySet()) {
if (!result.containsKey(entry.getKey()))
result.put(entry.getKey(), entry.getValue());
@ -160,7 +161,7 @@ class ConfigParser {
} catch (IOException exp) {
result = map;
try {
ConfigParser.write(result, file);
write(result, file);
} catch (IOException exp2) {
}
}
@ -178,10 +179,10 @@ class ConfigParser {
*/
public static List<String> parseSubscriptions(BufferedReader input)
throws IOException {
List<String> result = new LinkedList();
List<String> result = new LinkedList<String>();
String inputLine = input.readLine();
while (inputLine != null) {
inputLine = ConfigParser.stripComments(inputLine).trim();
inputLine = stripComments(inputLine).trim();
if (inputLine.length() > 0) {
result.add(inputLine);
}
@ -204,7 +205,7 @@ class ConfigParser {
FileInputStream fileStream = new FileInputStream(file);
BufferedReader input = new BufferedReader(new InputStreamReader(
fileStream));
List<String> rv = ConfigParser.parseSubscriptions(input);
List<String> rv = parseSubscriptions(input);
try {
fileStream.close();
} catch (IOException ioe) {}
@ -223,7 +224,7 @@ class ConfigParser {
public static List<String> parseSubscriptions(String string) throws IOException {
StringReader stringReader = new StringReader(string);
BufferedReader input = new BufferedReader(stringReader);
return ConfigParser.parseSubscriptions(input);
return parseSubscriptions(input);
}
/**
@ -233,18 +234,30 @@ class ConfigParser {
*
* @param file
* A File to attempt to parse.
* @param list list of files to parse
* @param list The default subscriptions to be saved and returned if the file cannot be read
* @return A List consisting of one element for each line in file, or if
* file cannot be read, list.
*/
public static List<String> parseSubscriptions(File file, List<String> list) {
List<String> result;
try {
result = ConfigParser.parseSubscriptions(file);
result = parseSubscriptions(file);
// Fix up files that contain the old default
// which was changed in 0.9.11
if (result.remove(Daemon.OLD_DEFAULT_SUB)) {
for (String sub : list) {
if (!result.contains(sub))
result.add(sub);
}
try {
writeSubscriptions(result, file);
// TODO log
} catch (IOException ioe) {}
}
} catch (IOException exp) {
result = list;
try {
ConfigParser.writeSubscriptions(result, file);
writeSubscriptions(result, file);
} catch (IOException exp2) {
}
}
@ -288,8 +301,7 @@ class ConfigParser {
boolean success = false;
if (!isWindows) {
File tmp = SecureFile.createTempFile("temp-", ".tmp", file.getAbsoluteFile().getParentFile());
ConfigParser
.write(map, new BufferedWriter(new OutputStreamWriter(new SecureFileOutputStream(tmp), "UTF-8")));
write(map, new BufferedWriter(new OutputStreamWriter(new SecureFileOutputStream(tmp), "UTF-8")));
success = tmp.renameTo(file);
if (!success) {
tmp.delete();
@ -298,8 +310,7 @@ class ConfigParser {
}
if (!success) {
// hmm, that didn't work, try it the old way
ConfigParser
.write(map, new BufferedWriter(new OutputStreamWriter(new SecureFileOutputStream(file), "UTF-8")));
write(map, new BufferedWriter(new OutputStreamWriter(new SecureFileOutputStream(file), "UTF-8")));
}
}
@ -336,7 +347,7 @@ class ConfigParser {
*/
public static void writeSubscriptions(List<String> list, File file)
throws IOException {
ConfigParser.writeSubscriptions(list, new BufferedWriter(
writeSubscriptions(list, new BufferedWriter(
new OutputStreamWriter(new SecureFileOutputStream(file), "UTF-8")));
}

View File

@ -37,6 +37,7 @@ import net.i2p.client.naming.SingleFileNamingService;
import net.i2p.data.DataFormatException;
import net.i2p.data.Destination;
import net.i2p.util.SecureDirectory;
import net.i2p.util.SystemVersion;
/**
* Main class of addressbook. Performs updates, and runs the main loop.
@ -47,8 +48,11 @@ import net.i2p.util.SecureDirectory;
public class Daemon {
public static final String VERSION = "2.0.4";
private static final Daemon _instance = new Daemon();
private boolean _running;
private volatile boolean _running;
private static final boolean DEBUG = false;
private static final String DEFAULT_SUB = "http://i2p-projekt.i2p/hosts.txt";
/** @since 0.9.12 */
static final String OLD_DEFAULT_SUB = "http://www.i2p2.i2p/hosts.txt";
/**
* Update the router and published address books using remote data from the
@ -168,7 +172,7 @@ public class Daemon {
if (publishedNS == null)
publishedNS = new SingleFileNamingService(I2PAppContext.getGlobalContext(), published.getAbsolutePath());
success = publishedNS.putIfAbsent(key, dest);
if (!success) {
if (log != null && !success) {
try {
log.append("Save to published address book " + published.getCanonicalPath() + " failed for new key " + key);
} catch (IOException ioe) {}
@ -230,7 +234,7 @@ public class Daemon {
*/
public static void update(Map<String, String> settings, String home) {
File published = null;
boolean should_publish = Boolean.valueOf(settings.get("should_publish")).booleanValue();
boolean should_publish = Boolean.parseBoolean(settings.get("should_publish"));
if (should_publish)
published = new File(home, settings
.get("published_addressbook"));
@ -250,18 +254,18 @@ public class Daemon {
}
delay *= 60 * 60 * 1000;
List<String> defaultSubs = new LinkedList();
List<String> defaultSubs = new LinkedList<String>();
// defaultSubs.add("http://i2p/NF2RLVUxVulR3IqK0sGJR0dHQcGXAzwa6rEO4WAWYXOHw-DoZhKnlbf1nzHXwMEJoex5nFTyiNMqxJMWlY54cvU~UenZdkyQQeUSBZXyuSweflUXFqKN-y8xIoK2w9Ylq1k8IcrAFDsITyOzjUKoOPfVq34rKNDo7fYyis4kT5bAHy~2N1EVMs34pi2RFabATIOBk38Qhab57Umpa6yEoE~rbyR~suDRvD7gjBvBiIKFqhFueXsR2uSrPB-yzwAGofTXuklofK3DdKspciclTVzqbDjsk5UXfu2nTrC1agkhLyqlOfjhyqC~t1IXm-Vs2o7911k7KKLGjB4lmH508YJ7G9fLAUyjuB-wwwhejoWqvg7oWvqo4oIok8LG6ECR71C3dzCvIjY2QcrhoaazA9G4zcGMm6NKND-H4XY6tUWhpB~5GefB3YczOqMbHq4wi0O9MzBFrOJEOs3X4hwboKWANf7DT5PZKJZ5KorQPsYRSq0E3wSOsFCSsdVCKUGsAAAA/i2p/hosts.txt");
defaultSubs.add("http://www.i2p2.i2p/hosts.txt");
defaultSubs.add(DEFAULT_SUB);
SubscriptionList subscriptions = new SubscriptionList(subscriptionFile,
etagsFile, lastModifiedFile, lastFetchedFile, delay, defaultSubs, settings
.get("proxy_host"), Integer.parseInt(settings.get("proxy_port")));
Log log = new Log(logFile);
Log log = SystemVersion.isAndroid() ? null : new Log(logFile);
// If false, add hosts via naming service; if true, write hosts.txt file directly
// Default false
if (Boolean.valueOf(settings.get("update_direct")).booleanValue()) {
if (Boolean.parseBoolean(settings.get("update_direct"))) {
// Direct hosts.txt access
File routerFile = new File(home, settings.get("router_addressbook"));
AddressBook master;
@ -330,7 +334,7 @@ public class Daemon {
homeFile = new SecureDirectory(System.getProperty("user.dir"));
}
Map<String, String> defaultSettings = new HashMap();
Map<String, String> defaultSettings = new HashMap<String, String>();
defaultSettings.put("proxy_host", "127.0.0.1");
defaultSettings.put("proxy_port", "4444");
defaultSettings.put("master_addressbook", "../userhosts.txt");

View File

@ -41,9 +41,11 @@ import javax.servlet.http.HttpServletResponse;
*
*/
public class Servlet extends HttpServlet {
private DaemonThread thread;
private String nonce;
private static final String PROP_NONCE = "addressbook.nonce";
private static final long serialVersionUID = 1L;
private transient DaemonThread thread;
//private String nonce;
//private static final String PROP_NONCE = "addressbook.nonce";
/**
* Hack to allow susidns to kick the daemon when the subscription list changes.
@ -54,15 +56,15 @@ public class Servlet extends HttpServlet {
*/
public void service(HttpServletRequest request, HttpServletResponse response) throws IOException {
//System.err.println("Got request nonce = " + request.getParameter("nonce"));
if (this.thread != null && request.getParameter("wakeup") != null &&
this.nonce != null && this.nonce.equals(request.getParameter("nonce"))) {
//System.err.println("Sending interrupt");
this.thread.interrupt();
// no output
} else {
//if (this.thread != null && request.getParameter("wakeup") != null &&
// this.nonce != null && this.nonce.equals(request.getParameter("nonce"))) {
// //System.err.println("Sending interrupt");
// this.thread.interrupt();
// // no output
//} else {
PrintWriter out = response.getWriter();
out.write("I2P addressbook OK");
}
//}
}
/* (non-Javadoc)
@ -75,9 +77,9 @@ public class Servlet extends HttpServlet {
} catch (ServletException exp) {
System.err.println("Addressbook init exception: " + exp);
}
this.nonce = "" + Math.abs((new Random()).nextLong());
//this.nonce = "" + Math.abs((new Random()).nextLong());
// put the nonce where susidns can get it
System.setProperty(PROP_NONCE, this.nonce);
//System.setProperty(PROP_NONCE, this.nonce);
String[] args = new String[1];
args[0] = config.getInitParameter("home");
this.thread = new DaemonThread(args);

View File

@ -81,7 +81,7 @@ class SubscriptionIterator implements Iterator<AddressBook> {
// DataHelper.formatDuration(I2PAppContext.getGlobalContext().clock().now() - sub.getLastFetched()) +
// " ago but the minimum delay is " +
// DataHelper.formatDuration(this.delay));
return new AddressBook(Collections.EMPTY_MAP);
return new AddressBook(Collections.<String, String> emptyMap());
}
}

View File

@ -69,7 +69,7 @@ class SubscriptionList {
public SubscriptionList(File locationsFile, File etagsFile,
File lastModifiedFile, File lastFetchedFile, long delay, List<String> defaultSubs, String proxyHost,
int proxyPort) {
this.subscriptions = new LinkedList();
this.subscriptions = new LinkedList<Subscription>();
this.etagsFile = etagsFile;
this.lastModifiedFile = lastModifiedFile;
this.lastFetchedFile = lastFetchedFile;
@ -84,17 +84,17 @@ class SubscriptionList {
try {
etags = ConfigParser.parse(etagsFile);
} catch (IOException exp) {
etags = new HashMap();
etags = new HashMap<String, String>();
}
try {
lastModified = ConfigParser.parse(lastModifiedFile);
} catch (IOException exp) {
lastModified = new HashMap();
lastModified = new HashMap<String, String>();
}
try {
lastFetched = ConfigParser.parse(lastFetchedFile);
} catch (IOException exp) {
lastFetched = new HashMap();
lastFetched = new HashMap<String, String>();
}
for (String location : locations) {
this.subscriptions.add(new Subscription(location, etags.get(location),
@ -121,9 +121,9 @@ class SubscriptionList {
* won't be read back correctly; the '=' should be escaped.
*/
public void write() {
Map<String, String> etags = new HashMap();
Map<String, String> lastModified = new HashMap();
Map<String, String> lastFetched = new HashMap();
Map<String, String> etags = new HashMap<String, String>();
Map<String, String> lastModified = new HashMap<String, String>();
Map<String, String> lastFetched = new HashMap<String, String>();
for (Subscription sub : this.subscriptions) {
if (sub.getEtag() != null) {
etags.put(sub.getLocation(), sub.getEtag());

View File

@ -4,6 +4,15 @@
"http://java.sun.com/j2ee/dtds/web-app_2.2.dtd">
<web-app>
<filter>
<filter-name>XSSFilter</filter-name>
<filter-class>net.i2p.servlet.filters.XSSFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>XSSFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<servlet>
<servlet-name>addressbook</servlet-name>
<servlet-class>net.i2p.addressbook.Servlet</servlet-class>

View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry combineaccessrules="false" kind="src" path="/i2p_router"/>
<classpathentry combineaccessrules="false" kind="src" path="/i2p_sdk"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry combineaccessrules="false" kind="src" path="/installer"/>
<classpathentry kind="output" path="build"/>
</classpath>

17
apps/desktopgui/.project Normal file
View File

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>desktopgui</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>

View File

@ -7,13 +7,17 @@
<property name="jar" value="desktopgui.jar"/>
<property name="resources" value="resources"/>
<property name="javadoc" value="javadoc"/>
<property name="javac.compilerargs" value=""/>
<property name="javac.version" value="1.6" />
<property name="require.gettext" value="true" />
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<target name="init">
<mkdir dir="${build}"/>
<mkdir dir="${build}/${resources}"/>
<mkdir dir="${build}"/>
<mkdir dir="${build}/${resources}"/>
<mkdir dir="${build}/${javadoc}"/>
<mkdir dir="${dist}"/>
</target>
@ -24,7 +28,7 @@
</target>
<target name="compile" depends="init">
<javac debug="true" deprecation="on" source="1.5" target="1.5"
<javac debug="true" deprecation="on" source="${javac.version}" target="${javac.version}"
includeAntRuntime="false"
srcdir="${src}" destdir="${build}">
<compilerarg line="${javac.compilerargs}" />
@ -39,8 +43,9 @@
</copy>
</target>
<target name="bundle" >
<target name="bundle" unless="no.bundle">
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >
<env key="JAVA_HOME" value="${java.home}" />
<arg value="./bundle-messages.sh" />
</exec>
<exec executable="sh" osfamily="mac" failifexecutionfails="true" failonerror="${require.gettext}" >

View File

@ -1,3 +1,4 @@
#!/bin/sh
#
# Update messages_xx.po and messages_xx.class files,
# from both java and jsp sources.
@ -15,6 +16,10 @@ TMPFILE=build/javafiles.txt
export TZ=UTC
RC=0
if ! $(which javac > /dev/null 2>&1); then
export JAVAC=${JAVA_HOME}/../bin/javac
fi
if [ "$1" = "-p" ]
then
POUPDATE=1

View File

@ -11,6 +11,7 @@ msgstr ""
"POT-Creation-Date: 2011-02-20 11:53+0000\n"
"PO-Revision-Date: 2011-02-26 19:46-0000\n"
"Last-Translator: hamada <hamada@mail.i2p>\n"
"Language: ar\n"
"Language-Team: duck <duck@mail.i2p>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"

View File

@ -3,19 +3,19 @@
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
# foo <foo@bar>, 2009.
#
#
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: https://trac.i2p2.de/\n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-01-09 18:07+0000\n"
"PO-Revision-Date: 2011-03-22 15:49+0000\n"
"Last-Translator: blabla <blabla@trash-mail.com>\n"
"Language-Team: German <>\n"
"Language: de\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: de\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
@ -46,10 +46,10 @@ msgstr "I2P neustarten"
msgid "Stop I2P"
msgstr "I2P beenden"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:43
msgid "Tray icon configuration"
msgstr "Systemleistensymbol konfigurieren"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:46
msgid "Should tray icon be enabled?"
msgstr "Systemleistensymbol aktivieren?"

View File

@ -0,0 +1,56 @@
# I2P
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
# <lixtetrax@grhack.net>, 2012.
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: https://trac.i2p2.de/\n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2012-07-02 11:28+0000\n"
"Last-Translator: lixtetrax <lixtetrax@grhack.net>\n"
"Language-Team: Greek (http://www.transifex.com/projects/p/I2P/language/el/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: el\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
msgstr "Έναρξη Ι2Ρ"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "Το Ι2Ρ ξεκίνησε!"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
msgstr "Έναρξη"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "Έναρξη φυλλομετρητή Ι2Ρ"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
msgstr "Παραμετροποίηση desktopgui"
#: src/net/i2p/desktopgui/InternalTrayManager.java:67
msgid "Restart I2P"
msgstr "Επανεκκίνηση Ι2Ρ"
#: src/net/i2p/desktopgui/InternalTrayManager.java:85
msgid "Stop I2P"
msgstr "Τερματισμός Ι2Ρ"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
msgid "Tray icon configuration"
msgstr "Παραμετροποίηση εικονιδίου"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
msgid "Should tray icon be enabled?"
msgstr "Ενεργοποίηση εικονιδίου;"

View File

@ -8,11 +8,11 @@ msgid ""
msgstr ""
"Project-Id-Version: I2P desktopgui\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"POT-Creation-Date: 2014-01-09 19:27+0000\n"
"PO-Revision-Date: 2010-06-15 14:09+0100\n"
"Last-Translator: duck <duck@mail.i2p>\n"
"Language-Team: duck <duck@mail.i2p>\n"
"Language: \n"
"Language: en\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
@ -46,10 +46,10 @@ msgstr ""
msgid "Stop I2P"
msgstr ""
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:43
msgid "Tray icon configuration"
msgstr ""
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:46
msgid "Should tray icon be enabled?"
msgstr ""

View File

@ -2,21 +2,26 @@
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
# foo <foo@bar>, 2009.
#
# Translators:
# blabla <blabla@trash-mail.com>, 2011
# ducki2p <ducki2p@gmail.com>, 2011
# foo <foo@bar>, 2009
# Boxoa590, 2013
msgid ""
msgstr ""
"Project-Id-Version: I2P desktopgui\n"
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2011-03-30 21:58+0100\n"
"Last-Translator: magma <magma@mail.i2p>\n"
"Language-Team: duck <duck@mail.i2p>\n"
"Language: \n"
"POT-Creation-Date: 2014-01-09 19:14+0000\n"
"PO-Revision-Date: 2013-06-08 04:50+0000\n"
"Last-Translator: Boxoa590\n"
"Language-Team: French (http://www.transifex.com/projects/p/I2P/language/"
"fr/)\n"
"Language: fr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
@ -24,7 +29,7 @@ msgstr "Démarrer I2P"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "I2P démarre!"
msgstr "I2P démarre !"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
@ -32,7 +37,7 @@ msgstr "Démarrage"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "Lancer le navigateur"
msgstr "Lancer le navigateur I2P"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
@ -46,11 +51,10 @@ msgstr "Redémarrer I2P"
msgid "Stop I2P"
msgstr "Arrêter I2P"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:43
msgid "Tray icon configuration"
msgstr "Configuration de l'icône de notification"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:46
msgid "Should tray icon be enabled?"
msgstr "Activer l'icône de notification"
msgstr "Activer l'icône de notification ?"

View File

@ -0,0 +1,55 @@
# I2P
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: https://trac.i2p2.de/\n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2012-06-01 16:28+0000\n"
"Last-Translator: AdminLMH <lehetmashogy@i2pmail.org>\n"
"Language-Team: Hungarian (http://www.transifex.net/projects/p/I2P/language/hu/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: hu\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
msgstr "I2P indítása"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "I2P indul!"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
msgstr "indítás"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "I2P Böngésző Indítása"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
msgstr "Asztali Grafikus Felület Beállítása"
#: src/net/i2p/desktopgui/InternalTrayManager.java:67
msgid "Restart I2P"
msgstr "I2P Újraindítása"
#: src/net/i2p/desktopgui/InternalTrayManager.java:85
msgid "Stop I2P"
msgstr "I2P Leállítása"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
msgid "Tray icon configuration"
msgstr "Tálcaikon beállítása"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
msgid "Should tray icon be enabled?"
msgstr "Tálcaikon engedélyezve legyen?"

View File

@ -3,15 +3,17 @@
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
# <bovas85@gmail.com>, 2012.
# <jokjok@hotmail.it>, 2011.
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: https://trac.i2p2.de/\n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2011-06-09 17:09+0000\n"
"Last-Translator: mkkid <jokjok@hotmail.it>\n"
"Language-Team: Italian (http://www.transifex.net/projects/p/I2P/team/it/)\n"
"PO-Revision-Date: 2012-06-01 12:21+0000\n"
"Last-Translator: Leelium <bovas85@gmail.com>\n"
"Language-Team: Italian (http://www.transifex.net/projects/p/I2P/language/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
@ -48,10 +50,8 @@ msgstr "Ferma I2P"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
msgid "Tray icon configuration"
msgstr "Configurazione dell'icona nell'Area di notifica"
msgstr "Configurazione dell'icona nell'area di notifica"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
msgid "Should tray icon be enabled?"
msgstr "Vuoi che l'icona nell'Area di notifica venga abilitata?"
msgstr "Vuoi che l'icona nelll'rea di notifica venga abilitata?"

View File

@ -0,0 +1,56 @@
# I2P
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
# plazmism <gomidori@live.jp>, 2013
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2013-11-26 10:38+0000\n"
"Last-Translator: plazmism <gomidori@live.jp>\n"
"Language-Team: Japanese (http://www.transifex.com/projects/p/I2P/language/ja/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ja\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
msgstr "I2P を開始"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "I2P 起動中!"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
msgstr "起動中"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "I2P ブラウザを起動"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
msgstr "desktopgui を設定"
#: src/net/i2p/desktopgui/InternalTrayManager.java:67
msgid "Restart I2P"
msgstr "I2P を再起動"
#: src/net/i2p/desktopgui/InternalTrayManager.java:85
msgid "Stop I2P"
msgstr "I2P を停止"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
msgid "Tray icon configuration"
msgstr "トレイアイコン設定"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
msgid "Should tray icon be enabled?"
msgstr "トレイアイコンを有効にしますか?"

View File

@ -0,0 +1,57 @@
# I2P
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
# testsubject67 <deborinha97@hotmail.com>, 2014
# blueboy, 2013
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-01-09 19:27+0000\n"
"PO-Revision-Date: 2014-07-05 17:40+0000\n"
"Last-Translator: testsubject67 <deborinha97@hotmail.com>\n"
"Language-Team: Portuguese (Brazil) (http://www.transifex.com/projects/p/I2P/language/pt_BR/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: pt_BR\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
msgstr "Conectar-se à I2P"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "Conectando-se a I2P!"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
msgstr "Conectando"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "Lançar o navegador I2P "
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
msgstr "Configurar desktopgui"
#: src/net/i2p/desktopgui/InternalTrayManager.java:67
msgid "Restart I2P"
msgstr "Reinicializar o roteador I2P"
#: src/net/i2p/desktopgui/InternalTrayManager.java:85
msgid "Stop I2P"
msgstr "Interromper o roteador I2P"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:43
msgid "Tray icon configuration"
msgstr "Configuração de ícone de bandeja"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:46
msgid "Should tray icon be enabled?"
msgstr "Ativar ícone de bandeja?"

View File

@ -0,0 +1,57 @@
# I2P
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-01-09 19:03+0000\n"
"PO-Revision-Date: 2013-11-11 11:31+0000\n"
"Last-Translator: polearnik <polearnik@mail.ru>\n"
"Language-Team: Romanian (http://www.transifex.com/projects/p/I2P/language/"
"ro/)\n"
"Language: ro\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?"
"2:1));\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
msgstr "Start I2P"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "I2P se pornește!"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
msgstr "Începere"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "Lansare I2P Browser"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
msgstr "Configurarea desktopgui"
#: src/net/i2p/desktopgui/InternalTrayManager.java:67
msgid "Restart I2P"
msgstr "Restart I2P"
#: src/net/i2p/desktopgui/InternalTrayManager.java:85
msgid "Stop I2P"
msgstr "Stop I2P"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:43
msgid "Tray icon configuration"
msgstr "Configurare pictogramei din bara de sistem"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:46
msgid "Should tray icon be enabled?"
msgstr "Ar trebui să fie activata pictograma din bara de sistem?"

View File

@ -2,21 +2,24 @@
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
# foo <foo@bar>, 2009.
#
#
# Translators:
# ducki2p <ducki2p@gmail.com>, 2011
# foo <foo@bar>, 2009
# Роман Азаренко <transifex@basicxp.ru>, 2013
msgid ""
msgstr ""
"Project-Id-Version: I2P desktopgui\n"
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-02-19 17:26+0000\n"
"PO-Revision-Date: 2011-02-23 10:23+0500\n"
"Last-Translator: Hidden Z <hiddenz@mail.i2p>\n"
"Language-Team: duck <duck@mail.i2p>\n"
"Language: \n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2013-12-04 11:46+0000\n"
"Last-Translator: Bergitte <alvina_alexandrova@mail.ru>\n"
"Language-Team: Russian (Russia) (http://www.transifex.com/projects/p/I2P/language/ru_RU/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"Language: ru_RU\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
@ -32,7 +35,7 @@ msgstr "Запускается"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "Запустить I2P браузер"
msgstr "Запустить браузер I2P"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
@ -48,9 +51,8 @@ msgstr "Остановить I2P"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
msgid "Tray icon configuration"
msgstr "Настройка иконки в трее"
msgstr "Конфигурация значка в области уведомлений"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
msgid "Should tray icon be enabled?"
msgstr "Отображать ли иконку в трее?"
msgstr "Отображать ли значок в области уведомлений?"

View File

@ -0,0 +1,57 @@
# I2P
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
# Krantišek <jaksrn@gmail.com>, 2014
# Svistwarrior273 <romanbeno273@gmail.com>, 2014
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-01-09 19:27+0000\n"
"PO-Revision-Date: 2014-04-20 09:56+0000\n"
"Last-Translator: Svistwarrior273 <romanbeno273@gmail.com>\n"
"Language-Team: Slovak (http://www.transifex.com/projects/p/I2P/language/sk/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: sk\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
msgstr "Spustiť I2P"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "I2P sa spúšťa!"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
msgstr "Spúšťa sa"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "Spustiť I2P prehliadač"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
msgstr "Nakonfigurovať desktopgui"
#: src/net/i2p/desktopgui/InternalTrayManager.java:67
msgid "Restart I2P"
msgstr "Reštartovať I2P"
#: src/net/i2p/desktopgui/InternalTrayManager.java:85
msgid "Stop I2P"
msgstr "Zastaviť I2P"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:43
msgid "Tray icon configuration"
msgstr "Konfigurácia ikony v lište"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:46
msgid "Should tray icon be enabled?"
msgstr "Mala by byť ikona v lište povolená?"

View File

@ -0,0 +1,56 @@
# I2P
# Copyright (C) 2009 The I2P Project
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# Translators:
# Kaya Zeren <kayazeren@gmail.com>, 2013
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: https://trac.i2p2.de/\n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2013-04-26 06:07+0000\n"
"Last-Translator: Kaya Zeren <kayazeren@gmail.com>\n"
"Language-Team: Turkish (Turkey) (http://www.transifex.com/projects/p/I2P/language/tr_TR/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: tr_TR\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
msgstr "I2P başlasın"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "I2P is starting!"
msgstr "I2P başlatılıyor!"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:38
msgid "Starting"
msgstr "Başlatılıyor"
#: src/net/i2p/desktopgui/InternalTrayManager.java:26
msgid "Launch I2P Browser"
msgstr "I2P Tarayıcısınıın"
#: src/net/i2p/desktopgui/InternalTrayManager.java:50
msgid "Configure desktopgui"
msgstr "Masaüstü Arayüzünü Ayarlayın"
#: src/net/i2p/desktopgui/InternalTrayManager.java:67
msgid "Restart I2P"
msgstr "I2P Yeniden Başlasın"
#: src/net/i2p/desktopgui/InternalTrayManager.java:85
msgid "Stop I2P"
msgstr "I2P Durdurulsun"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
msgid "Tray icon configuration"
msgstr "Sistem tepsisi simgesi ayarı"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
msgid "Should tray icon be enabled?"
msgstr "Sistem tepsisi simgesi kullanılsın"

View File

@ -3,20 +3,22 @@
# This file is distributed under the same license as the desktopgui package.
# To contribute translations, see http://www.i2p2.de/newdevelopers
#
# <gribua@gmail.com>, 2011.
# Translators:
# Denis Blank <gribua@gmail.com>, 2011
# LinuxChata, 2014
msgid ""
msgstr ""
"Project-Id-Version: I2P\n"
"Report-Msgid-Bugs-To: https://trac.i2p2.de/\n"
"POT-Creation-Date: 2011-03-03 18:29+0000\n"
"PO-Revision-Date: 2011-06-19 14:01+0000\n"
"Last-Translator: Pharmasolin <gribua@gmail.com>\n"
"Language-Team: Ukrainian (Ukraine) (http://www.transifex.net/projects/p/I2P/team/uk_UA/)\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-01-09 19:27+0000\n"
"PO-Revision-Date: 2014-06-22 10:20+0000\n"
"Last-Translator: LinuxChata\n"
"Language-Team: Ukrainian (Ukraine) (http://www.transifex.com/projects/p/I2P/language/uk_UA/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: uk_UA\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2)\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
#: src/net/i2p/desktopgui/ExternalTrayManager.java:23
msgid "Start I2P"
@ -46,12 +48,10 @@ msgstr "Перезапустити I2P"
msgid "Stop I2P"
msgstr "Зупинити I2P"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:44
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:43
msgid "Tray icon configuration"
msgstr "Настройка трей-іконки"
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:47
#: src/net/i2p/desktopgui/gui/DesktopguiConfigurationFrame.java:46
msgid "Should tray icon be enabled?"
msgstr "Чм повинна трей-іконка бути включена?"
msgstr "Чи повинна трей-іконка бути включена?"

View File

@ -7,9 +7,6 @@ package net.i2p.desktopgui;
import javax.swing.SwingUtilities;
import javax.swing.UIManager;
import javax.swing.UnsupportedLookAndFeelException;
import java.awt.GraphicsEnvironment;
import net.i2p.I2PAppContext;
import net.i2p.desktopgui.router.RouterManager;
import net.i2p.desktopgui.util.*;
import net.i2p.util.Log;

View File

@ -1,28 +1,15 @@
package net.i2p.desktopgui;
import java.awt.AWTException;
import java.awt.Desktop;
import java.awt.Image;
import java.awt.MenuItem;
import java.awt.PopupMenu;
import java.awt.SystemTray;
import java.awt.Toolkit;
import java.awt.TrayIcon;
import java.awt.Desktop.Action;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.io.IOException;
import java.net.URI;
import java.net.URISyntaxException;
import java.net.URL;
import javax.swing.SwingWorker;
import net.i2p.desktopgui.i18n.DesktopguiTranslator;
import net.i2p.desktopgui.router.RouterManager;
import net.i2p.desktopgui.util.BrowseException;
import net.i2p.desktopgui.util.ConfigurationManager;
import net.i2p.desktopgui.util.I2PDesktop;
import net.i2p.util.Log;
/**

View File

@ -32,7 +32,6 @@ public class DesktopguiConfigurationFrame extends javax.swing.JFrame {
* WARNING: Do NOT modify this code. The content of this method is
* always regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
@ -115,7 +114,7 @@ public class DesktopguiConfigurationFrame extends javax.swing.JFrame {
System.out.println("Enabling desktopgui");
}
try {
RouterManager.getRouterContext().setProperty(property, value);
RouterManager.getRouterContext().router().saveConfig(property, value);
} catch (Exception ex) {
Logger.getLogger(DesktopguiConfigurationFrame.class.getName()).log(Level.SEVERE, null, ex);
}

View File

@ -5,8 +5,6 @@ import java.io.IOException;
import org.tanukisoftware.wrapper.WrapperManager;
import net.i2p.I2PAppContext;
import net.i2p.desktopgui.i18n.DesktopguiTranslator;
import net.i2p.desktopgui.util.ConfigurationManager;
import net.i2p.router.Router;
import net.i2p.router.RouterContext;
import net.i2p.util.Log;

View File

@ -78,7 +78,7 @@ public class ConfigurationManager {
* @return The value of a configuration: true if found, defaultValue if not found.
*/
public boolean getBooleanConfiguration(String arg, boolean defaultValue) {
Boolean value = ((Boolean) booleanConfigurations.get("startWithI2P"));
Boolean value = booleanConfigurations.get("startWithI2P");
System.out.println(value);
if(value != null) {
return value;

View File

@ -1,13 +1,8 @@
package net.i2p.desktopgui.util;
import java.awt.Desktop;
import java.awt.TrayIcon;
import java.awt.Desktop.Action;
import java.io.IOException;
import java.net.URI;
import java.net.URISyntaxException;
import net.i2p.desktopgui.router.RouterManager;
import net.i2p.util.Log;
public class I2PDesktop {

View File

@ -1,106 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project basedir="." default="all" name="fortuna">
<property name="cvs.base.dir" value="java/gnu-crypto" />
<property name="cvs.etc.dir" value="${cvs.base.dir}/etc" />
<property name="cvs.lib.dir" value="${cvs.base.dir}/lib" />
<property name="cvs.object.dir" value="${cvs.base.dir}/classes" />
<property name="cvs.base.crypto.object.dir" value="${cvs.object.dir}/gnu/crypto" />
<property name="cvs.cipher.object.dir" value="${cvs.base.crypto.object.dir}/cipher" />
<property name="cvs.hash.object.dir" value="${cvs.base.crypto.object.dir}/hash" />
<property name="cvs.prng.object.dir" value="${cvs.base.crypto.object.dir}/prng" />
<patternset id="fortuna.files">
<include name="${cvs.base.crypto.object.dir}/Registry.class"/>
<include name="${cvs.prng.object.dir}/Fortuna*.class"/>
<include name="${cvs.prng.object.dir}/BasePRNG.class"/>
<include name="${cvs.prng.object.dir}/RandomEventListener.class"/>
<include name="${cvs.prng.object.dir}/IRandom.class"/>
<include name="${cvs.cipher.object.dir}/CipherFactory.class"/>
<include name="${cvs.cipher.object.dir}/IBlockCipher.class"/>
<include name="${cvs.hash.object.dir}/HashFactory.class"/>
<include name="${cvs.hash.object.dir}/IMessageDigest.class"/>
</patternset>
<target name="all" depends="build,jar"
description="Create and test the custom Fortuna library" />
<target name="build" depends="-init,checkout"
description="Build the source and tests">
<ant dir="${cvs.base.dir}" target="jar" />
</target>
<target name="builddep" />
<target name="checkout" depends="-init" unless="cvs.source.available"
description="Check out GNU Crypto sources from CVS HEAD">
<cvs cvsRoot=":ext:anoncvs@savannah.gnu.org:/cvsroot/gnu-crypto"
cvsRsh="ssh"
dest="java"
package="gnu-crypto" />
</target>
<target name="clean"
description="Remove generated tests and object files">
<ant dir="${cvs.base.dir}" target="clean" />
</target>
<target name="cleandep" />
<target name="compile" />
<target name="distclean" depends="clean"
description="Remove all generated files">
<delete dir="build" />
<delete dir="jartemp" />
<!--
Annoyingly the GNU Crypto distclean task called here doesn't clean
*all* derived files from java/gnu-crypto/lib like it should.....
-->
<ant dir="${cvs.base.dir}" target="distclean" />
<!--
.....and so we mop up the rest ourselves.
-->
<delete dir="${cvs.lib.dir}" />
</target>
<target name="-init">
<available property="cvs.source.available" file="${cvs.base.dir}" />
</target>
<target name="jar" depends="build"
description="Create the custom Fortuna jar library">
<delete dir="build" />
<delete dir="jartemp" />
<mkdir dir="build" />
<mkdir dir="jartemp/${cvs.object.dir}" />
<copy todir="jartemp">
<fileset dir=".">
<patternset refid="fortuna.files" />
</fileset>
</copy>
<jar basedir="jartemp/${cvs.object.dir}" jarfile="build/fortuna.jar">
<manifest>
<section name="fortuna">
<attribute name="Implementation-Title" value="I2P Custom GNU Crypto Fortuna Library" />
<attribute name="Implementation-Version" value="CVS HEAD" />
<attribute name="Implementation-Vendor" value="Free Software Foundation" />
<attribute name="Implementation-Vendor-Id" value="FSF" />
<attribute name="Implementation-URL" value="http://www.gnu.org/software/gnu-crypto" />
</section>
</manifest>
</jar>
<delete dir="jartemp" />
</target>
<target name="test" depends="jar"
description="Perform crypto tests on custom Fortuna jar library" />
<!--
Add this when Fortuna tests are added to GNU Crypto, else write some
-->
<target name="update" depends="checkout"
description="Update GNU Crypto sources to latest CVS HEAD">
<cvs command="update -d" cvsRsh="ssh" dest="java/gnu-crypto" />
</target>
</project>

9
apps/i2psnark/.classpath Normal file
View File

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="java/src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry combineaccessrules="false" kind="src" path="/i2p_sdk"/>
<classpathentry combineaccessrules="false" kind="src" path="/jetty"/>
<classpathentry combineaccessrules="false" kind="src" path="/ministreaming"/>
<classpathentry kind="output" path="java/build/obj"/>
</classpath>

17
apps/i2psnark/.project Normal file
View File

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>i2psnark</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>

Binary file not shown.

After

Width:  |  Height:  |  Size: 733 B

View File

@ -17,25 +17,28 @@
<classpath>
<pathelement location="../../../core/java/build/obj" />
<pathelement location="../../ministreaming/java/build/obj" />
<pathelement location="../../jetty/jettylib/org.mortbay.jetty.jar" />
<pathelement location="../../jetty/jettylib/javax.servlet.jar" />
<pathelement location="../../jetty/jettylib/jetty-util.jar" />
</classpath>
</depend>
</target>
<property name="javac.compilerargs" value="" />
<property name="javac.version" value="1.6" />
<property name="require.gettext" value="true" />
<condition property="no.bundle">
<isfalse value="${require.gettext}" />
</condition>
<target name="compile" depends="depend">
<mkdir dir="./build" />
<mkdir dir="./build/obj" />
<javac
srcdir="./src"
debug="true" deprecation="on" source="1.5" target="1.5"
debug="true" deprecation="on" source="${javac.version}" target="${javac.version}"
destdir="./build/obj"
includeAntRuntime="false"
classpath="../../../core/java/build/i2p.jar:../../jetty/jettylib/org.mortbay.jetty.jar:../../jetty/jettylib/javax.servlet.jar:../../jetty/jettylib/jetty-util.jar:../../ministreaming/java/build/mstreaming.jar" >
classpath="../../../core/java/build/i2p.jar:../../jetty/jettylib/javax.servlet.jar:../../ministreaming/java/build/mstreaming.jar" >
<compilerarg line="${javac.compilerargs}" />
</javac>
</target>
@ -57,7 +60,7 @@
<target name="jar" depends="builddep, compile, jarUpToDate, listChangedFiles" unless="jar.uptodate" >
<!-- set if unset -->
<property name="workspace.changes.tr" value="" />
<jar destfile="./build/i2psnark.jar" basedir="./build/obj" includes="**/*.class" excludes="**/I2PSnarkServlet*.class **/messages_*.class">
<jar destfile="./build/i2psnark.jar" basedir="./build/obj" includes="**/*.class" excludes="**/web/* **/messages_*.class">
<manifest>
<attribute name="Main-Class" value="org.klomp.snark.Snark" />
<attribute name="Class-Path" value="i2p.jar mstreaming.jar streaming.jar" />
@ -72,7 +75,7 @@
<target name="jarUpToDate">
<uptodate property="jar.uptodate" targetfile="build/i2psnark.jar" >
<srcfiles dir= "build/obj" includes="**/*.class" excludes="**/I2PSnarkServlet*.class **/messages_*.class" />
<srcfiles dir= "build/obj" includes="**/*.class" excludes="**/web/* **/messages_*.class" />
</uptodate>
<condition property="shouldListChanges" >
<and>
@ -80,7 +83,7 @@
<isset property="jar.uptodate" />
</not>
<not>
<isset property="wjar.uptodate" />
<isset property="war.uptodate" />
</not>
<isset property="mtn.available" />
</and>
@ -100,9 +103,11 @@
<copy todir="build/icons/.icons" >
<fileset dir="../icons/" />
</copy>
<!-- mime.properties must be in with the classes -->
<copy file="../mime.properties" todir="build/obj/org/klomp/snark/web" />
<war destfile="../i2psnark.war" webxml="../web.xml" >
<!-- include only the web stuff, as of 0.7.12 the router will add i2psnark.jar to the classpath for the war -->
<classes dir="./build/obj" includes="**/web/*.class" />
<classes dir="./build/obj" includes="**/web/*" />
<fileset dir="build/icons/" />
<manifest>
<attribute name="Implementation-Version" value="${full.version}" />
@ -120,10 +125,11 @@
</uptodate>
</target>
<target name="bundle" depends="compile">
<target name="bundle" depends="compile" unless="no.bundle">
<!-- Update the messages_*.po files.
We need to supply the bat file for windows, and then change the fail property to true -->
<exec executable="sh" osfamily="unix" failifexecutionfails="true" failonerror="${require.gettext}" >
<env key="JAVA_HOME" value="${java.home}" />
<arg value="./bundle-messages.sh" />
</exec>
<exec executable="sh" osfamily="mac" failifexecutionfails="true" failonerror="${require.gettext}" >
@ -169,7 +175,6 @@
<copy file="../../jetty/jettylib/commons-logging.jar" tofile="./dist/lib/commons-logging.jar" />
<copy file="../../jetty/jettylib/javax.servlet.jar" tofile="./dist/lib/javax.servlet.jar" />
<copy file="../../jetty/jettylib/org.mortbay.jetty.jar" tofile="./dist/lib/org.mortbay.jetty.jar" />
<copy file="../../jetty/jettylib/jasper-compiler.jar" tofile="./dist/lib/jasper-compiler.jar" />
<copy file="../../jetty/jettylib/jasper-runtime.jar" tofile="./dist/lib/jasper-runtime.jar" />
<copy file="../../ministreaming/java/build/mstreaming.jar" tofile="./dist/lib/mstreaming.jar" />
<copy file="../../streaming/java/build/streaming.jar" tofile="./dist/lib/streaming.jar" />

View File

@ -1,3 +1,4 @@
#!/bin/sh
#
# Update messages_xx.po and messages_xx.class files,
# from both java and jsp sources.
@ -14,6 +15,10 @@ TMPFILE=build/javafiles.txt
export TZ=UTC
RC=0
if ! $(which javac > /dev/null 2>&1); then
export JAVAC=${JAVA_HOME}/../bin/javac
fi
if [ "$1" = "-p" ]
then
POUPDATE=1

View File

@ -4,7 +4,6 @@
*/
package org.klomp.snark;
import java.util.Arrays;
import java.util.Properties;
import net.i2p.client.I2PSessionException;
@ -37,7 +36,9 @@ class BWLimits {
return rv;
}
/****
public static void main(String args[]) {
System.out.println(Arrays.toString(getBWLimits("127.0.0.1", 7654)));
}
****/
}

View File

@ -39,7 +39,6 @@ public class BitField
this.size = size;
int arraysize = ((size-1)/8)+1;
bitfield = new byte[arraysize];
this.count = 0;
}
/**
@ -60,7 +59,6 @@ public class BitField
// cleared or clear them explicitly ourselves.
System.arraycopy(bitfield, 0, this.bitfield, 0, arraysize);
this.count = 0;
for (int i = 0; i < size; i++)
if (get(i))
this.count++;
@ -99,9 +97,11 @@ public class BitField
throw new IndexOutOfBoundsException(Integer.toString(bit));
int index = bit/8;
int mask = 128 >> (bit % 8);
if ((bitfield[index] & mask) == 0) {
count++;
bitfield[index] |= mask;
synchronized(this) {
if ((bitfield[index] & mask) == 0) {
count++;
bitfield[index] |= mask;
}
}
}

View File

@ -0,0 +1,60 @@
/* CompleteListener - Callback for Snark events
Copyright (C) 2003 Mark J. Wielaard
This file is part of Snark.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
package org.klomp.snark;
/**
* Callback for Snark events.
* @since 0.9.4 moved from Snark.java
*/
public interface CompleteListener {
public void torrentComplete(Snark snark);
public void updateStatus(Snark snark);
/**
* We transitioned from magnet mode, we have now initialized our
* metainfo and storage. The listener should now call getMetaInfo()
* and save the data to disk.
*
* @return the new name for the torrent or null on error
* @since 0.8.4
*/
public String gotMetaInfo(Snark snark);
/**
* @since 0.9
*/
public void fatal(Snark snark, String error);
/**
* @since 0.9.2
*/
public void addMessage(Snark snark, String message);
/**
* @since 0.9.4
*/
public void gotPiece(Snark snark);
// not really listeners but the easiest way to get back to an optional SnarkManager
public long getSavedTorrentTime(Snark snark);
public BitField getSavedTorrentBitField(Snark snark);
}

View File

@ -29,75 +29,110 @@ import net.i2p.I2PAppContext;
import net.i2p.I2PException;
import net.i2p.client.streaming.I2PServerSocket;
import net.i2p.client.streaming.I2PSocket;
import net.i2p.data.Hash;
import net.i2p.util.I2PAppThread;
import net.i2p.util.Log;
import net.i2p.util.ObjectCounter;
import net.i2p.util.SimpleTimer2;
/**
* Accepts connections on a TCP port and routes them to sub-acceptors.
* Accepts connections on a I2PServerSocket and routes them to PeerAcceptors.
*/
public class ConnectionAcceptor implements Runnable
class ConnectionAcceptor implements Runnable
{
private final Log _log = I2PAppContext.getGlobalContext().logManager().getLog(ConnectionAcceptor.class);
private I2PServerSocket serverSocket;
private PeerAcceptor peeracceptor;
private final PeerAcceptor peeracceptor;
private Thread thread;
private I2PSnarkUtil _util;
private final I2PSnarkUtil _util;
private final ObjectCounter<Hash> _badCounter = new ObjectCounter<Hash>();
private final SimpleTimer2.TimedEvent _cleaner;
private boolean stop;
private boolean socketChanged;
private volatile boolean stop;
public ConnectionAcceptor(I2PSnarkUtil util) { _util = util; }
// protocol errors before blacklisting.
private static final int MAX_BAD = 1;
private static final long BAD_CLEAN_INTERVAL = 30*60*1000;
/**
* Multitorrent. Caller MUST call startAccepting()
*/
public ConnectionAcceptor(I2PSnarkUtil util, PeerCoordinatorSet set) {
_util = util;
_cleaner = new Cleaner();
peeracceptor = new PeerAcceptor(set);
}
public synchronized void startAccepting(PeerCoordinatorSet set, I2PServerSocket socket) {
if (serverSocket != socket) {
if ( (peeracceptor == null) || (peeracceptor.coordinators != set) )
peeracceptor = new PeerAcceptor(set);
serverSocket = socket;
/**
* May be called even when already running. May be called to start up again after halt().
*/
public synchronized void startAccepting() {
stop = false;
socketChanged = true;
if (_log.shouldLog(Log.WARN))
_log.warn("ConnectionAcceptor startAccepting new thread? " + (thread == null));
if (thread == null) {
thread = new I2PAppThread(this, "I2PSnark acceptor");
thread.setDaemon(true);
thread.start();
_cleaner.reschedule(BAD_CLEAN_INTERVAL, false);
}
}
}
public ConnectionAcceptor(I2PSnarkUtil util, I2PServerSocket serverSocket,
/**
* Unused (single torrent).
* Do NOT call startAccepting().
*/
public ConnectionAcceptor(I2PSnarkUtil util,
PeerAcceptor peeracceptor)
{
this.serverSocket = serverSocket;
this.peeracceptor = peeracceptor;
_util = util;
socketChanged = false;
stop = false;
thread = new I2PAppThread(this, "I2PSnark acceptor");
thread.setDaemon(true);
thread.start();
_cleaner = new Cleaner();
}
public void halt()
/**
* May be restarted later with startAccepting().
*/
public synchronized void halt()
{
if (stop) return;
stop = true;
locked_halt();
Thread t = thread;
if (t != null) {
t.interrupt();
thread = null;
}
}
I2PServerSocket ss = serverSocket;
if (ss != null)
/**
* Caller must synch
* @since 0.9.9
*/
private void locked_halt()
{
I2PServerSocket ss = _util.getServerSocket();
if (ss != null) {
try
{
ss.close();
}
catch(I2PException ioe) { }
Thread t = thread;
if (t != null)
t.interrupt();
}
_badCounter.clear();
_cleaner.cancel();
}
public void restart() {
serverSocket = _util.getServerSocket();
socketChanged = true;
/**
* Effectively unused, would only be called if we changed
* I2CP host/port, which is hidden in the gui if in router context
* FIXME this only works if already running
*/
public synchronized void restart() {
Thread t = thread;
if (t != null)
t.interrupt();
@ -105,21 +140,32 @@ public class ConnectionAcceptor implements Runnable
public int getPort()
{
return 6881; // serverSocket.getLocalPort();
return TrackerClient.PORT; // serverSocket.getLocalPort();
}
public void run()
{
try {
run2();
} finally {
synchronized(this) {
thread = null;
}
}
}
private void run2()
{
while(!stop)
{
if (socketChanged) {
// ok, already updated
socketChanged = false;
}
I2PServerSocket serverSocket = _util.getServerSocket();
while ( (serverSocket == null) && (!stop)) {
if (!(_util.isConnecting() || _util.connected())) {
stop = true;
break;
}
try { Thread.sleep(10*1000); } catch (InterruptedException ie) {}
serverSocket = _util.getServerSocket();
if (serverSocket == null)
try { Thread.sleep(10*1000); } catch (InterruptedException ie) {}
}
if(stop)
break;
@ -127,18 +173,26 @@ public class ConnectionAcceptor implements Runnable
{
I2PSocket socket = serverSocket.accept();
if (socket == null) {
if (socketChanged) {
continue;
} else {
I2PServerSocket ss = _util.getServerSocket();
if (ss != serverSocket) {
serverSocket = ss;
socketChanged = true;
}
}
} else {
if (socket.getPeerDestination().equals(_util.getMyDestination())) {
_util.debug("Incoming connection from myself", Snark.ERROR);
_log.error("Incoming connection from myself");
try { socket.close(); } catch (IOException ioe) {}
continue;
}
Hash h = socket.getPeerDestination().calculateHash();
if (socket.getLocalPort() == 80) {
_badCounter.increment(h);
if (_log.shouldLog(Log.WARN))
_log.error("Dropping incoming HTTP from " + h);
try { socket.close(); } catch (IOException ioe) {}
continue;
}
int bad = _badCounter.count(h);
if (bad >= MAX_BAD) {
if (_log.shouldLog(Log.WARN))
_log.warn("Rejecting connection from " + h +
" after " + bad + " failures, max is " + MAX_BAD);
try { socket.close(); } catch (IOException ioe) {}
continue;
}
@ -148,33 +202,43 @@ public class ConnectionAcceptor implements Runnable
}
catch (I2PException ioe)
{
if (!socketChanged) {
_util.debug("Error while accepting: " + ioe, Snark.ERROR);
stop = true;
int level = stop ? Log.WARN : Log.ERROR;
if (_log.shouldLog(level))
_log.log(level, "Error while accepting", ioe);
synchronized(this) {
if (!stop) {
locked_halt();
thread = null;
stop = true;
}
}
}
catch (IOException ioe)
{
_util.debug("Error while accepting: " + ioe, Snark.ERROR);
stop = true;
int level = stop ? Log.WARN : Log.ERROR;
if (_log.shouldLog(level))
_log.log(level, "Error while accepting", ioe);
synchronized(this) {
if (!stop) {
locked_halt();
thread = null;
stop = true;
}
}
}
// catch oom?
}
try
{
if (serverSocket != null)
serverSocket.close();
}
catch (I2PException ignored) { }
if (_log.shouldLog(Log.WARN))
_log.warn("ConnectionAcceptor closed");
}
private class Handler implements Runnable {
private I2PSocket _socket;
private final I2PSocket _socket;
public Handler(I2PSocket socket) {
_socket = socket;
}
public void run() {
try {
InputStream in = _socket.getInputStream();
@ -182,13 +246,33 @@ public class ConnectionAcceptor implements Runnable
// this is for the readahead in PeerAcceptor.connection()
in = new BufferedInputStream(in);
if (_log.shouldLog(Log.DEBUG))
_log.debug("Handling socket from " + _socket.getPeerDestination().calculateHash().toBase64());
_log.debug("Handling socket from " + _socket.getPeerDestination().calculateHash());
peeracceptor.connection(_socket, in, out);
} catch (PeerAcceptor.ProtocolException ihe) {
_badCounter.increment(_socket.getPeerDestination().calculateHash());
if (_log.shouldLog(Log.INFO))
_log.info("Protocol error from " + _socket.getPeerDestination().calculateHash(), ihe);
try { _socket.close(); } catch (IOException ignored) { }
} catch (IOException ioe) {
if (_log.shouldLog(Log.DEBUG))
_log.debug("Error handling connection from " + _socket.getPeerDestination().calculateHash().toBase64(), ioe);
_log.debug("Error handling connection from " + _socket.getPeerDestination().calculateHash(), ioe);
try { _socket.close(); } catch (IOException ignored) { }
}
}
}
/** @since 0.9.1 */
private class Cleaner extends SimpleTimer2.TimedEvent {
public Cleaner() {
super(_util.getContext().simpleTimer2());
}
public void timeReached() {
if (stop)
return;
_badCounter.clear();
schedule(BAD_CLEAN_INTERVAL);
}
}
}

View File

@ -24,7 +24,7 @@ package org.klomp.snark;
/**
* Callback used when some peer changes state.
*/
public interface CoordinatorListener
interface CoordinatorListener
{
/**
* Called when the PeerCoordinator notices a change in the state of a peer.
@ -37,7 +37,20 @@ public interface CoordinatorListener
*/
void gotMetaInfo(PeerCoordinator coordinator, MetaInfo metainfo);
/**
* Is this number of uploaders over the per-torrent limit?
*/
public boolean overUploadLimit(int uploaders);
/**
* Are we currently over the upstream bandwidth limit?
*/
public boolean overUpBWLimit();
/**
* Is the total (in Bps) over the upstream bandwidth limit?
*/
public boolean overUpBWLimit(long total);
public void addMessage(String message);
}

View File

@ -1,5 +1,7 @@
package org.klomp.snark;
import net.i2p.data.ByteArray;
/**
* Callback used to fetch data
* @since 0.8.2
@ -10,5 +12,5 @@ interface DataLoader
* This is the callback that PeerConnectionOut calls to get the data from disk
* @return bytes or null for errors
*/
public byte[] loadData(int piece, int begin, int length);
public ByteArray loadData(int piece, int begin, int length);
}

View File

@ -28,7 +28,10 @@ abstract class ExtensionHandler {
public static final int ID_PEX = 2;
/** not ut_pex since the compact format is different */
public static final String TYPE_PEX = "i2p_pex";
/** Pieces * SHA1 Hash length, + 25% extra for file names, benconding overhead, etc */
public static final int ID_DHT = 3;
/** not using the option bit since the compact format is different */
public static final String TYPE_DHT = "i2p_dht";
/** Pieces * SHA1 Hash length, + 25% extra for file names, bencoding overhead, etc */
private static final int MAX_METADATA_SIZE = Storage.MAX_PIECES * 20 * 5 / 4;
private static final int PARALLEL_REQUESTS = 3;
@ -36,20 +39,24 @@ abstract class ExtensionHandler {
/**
* @param metasize -1 if unknown
* @param pexAndMetadata advertise these capabilities
* @param dht advertise DHT capability
* @return bencoded outgoing handshake message
*/
public static byte[] getHandshake(int metasize, boolean pexAndMetadata) {
Map<String, Object> handshake = new HashMap();
Map<String, Integer> m = new HashMap();
public static byte[] getHandshake(int metasize, boolean pexAndMetadata, boolean dht) {
Map<String, Object> handshake = new HashMap<String, Object>();
Map<String, Integer> m = new HashMap<String, Integer>();
if (pexAndMetadata) {
m.put(TYPE_METADATA, Integer.valueOf(ID_METADATA));
m.put(TYPE_PEX, Integer.valueOf(ID_PEX));
if (metasize >= 0)
handshake.put("metadata_size", Integer.valueOf(metasize));
}
if (dht) {
m.put(TYPE_DHT, Integer.valueOf(ID_DHT));
}
// include the map even if empty so the far-end doesn't NPE
handshake.put("m", m);
handshake.put("p", Integer.valueOf(6881));
handshake.put("p", Integer.valueOf(TrackerClient.PORT));
handshake.put("v", "I2PSnark");
handshake.put("reqq", Integer.valueOf(5));
return BEncoder.bencode(handshake);
@ -65,6 +72,8 @@ abstract class ExtensionHandler {
handleMetadata(peer, listener, bs, log);
else if (id == ID_PEX)
handlePEX(peer, listener, bs, log);
else if (id == ID_DHT)
handleDHT(peer, listener, bs, log);
else if (log.shouldLog(Log.INFO))
log.info("Unknown extension msg " + id + " from " + peer);
}
@ -87,6 +96,12 @@ abstract class ExtensionHandler {
// peer state calls peer listener calls sendPEX()
}
if (msgmap.get(TYPE_DHT) != null) {
if (log.shouldLog(Log.DEBUG))
log.debug("Peer supports DHT extension: " + peer);
// peer state calls peer listener calls sendDHT()
}
MagnetState state = peer.getMagnetState();
if (msgmap.get(TYPE_METADATA) == null) {
@ -95,7 +110,8 @@ abstract class ExtensionHandler {
// drop if we need metainfo and we haven't found anybody yet
synchronized(state) {
if (!state.isInitialized()) {
log.debug("Dropping peer, we need metadata! " + peer);
if (log.shouldLog(Log.DEBUG))
log.debug("Dropping peer, we need metadata! " + peer);
peer.disconnect();
}
}
@ -109,7 +125,8 @@ abstract class ExtensionHandler {
// drop if we need metainfo and we haven't found anybody yet
synchronized(state) {
if (!state.isInitialized()) {
log.debug("Dropping peer, we need metadata! " + peer);
if (log.shouldLog(Log.DEBUG))
log.debug("Dropping peer, we need metadata! " + peer);
peer.disconnect();
}
}
@ -259,7 +276,7 @@ abstract class ExtensionHandler {
/** REQUEST and REJECT are the same except for message type */
private static void sendMessage(Peer peer, int type, int piece) {
Map<String, Object> map = new HashMap();
Map<String, Object> map = new HashMap<String, Object>();
map.put("msg_type", Integer.valueOf(type));
map.put("piece", Integer.valueOf(piece));
byte[] payload = BEncoder.bencode(map);
@ -274,7 +291,7 @@ abstract class ExtensionHandler {
}
private static void sendPiece(Peer peer, int piece, byte[] data) {
Map<String, Object> map = new HashMap();
Map<String, Object> map = new HashMap<String, Object>();
map.put("msg_type", Integer.valueOf(TYPE_DATA));
map.put("piece", Integer.valueOf(piece));
map.put("total_size", Integer.valueOf(data.length));
@ -310,17 +327,20 @@ abstract class ExtensionHandler {
BDecoder dec = new BDecoder(is);
BEValue bev = dec.bdecodeMap();
Map<String, BEValue> map = bev.getMap();
byte[] ids = map.get("added").getBytes();
bev = map.get("added");
if (bev == null)
return;
byte[] ids = bev.getBytes();
if (ids.length < HASH_LENGTH)
return;
int len = Math.min(ids.length, (I2PSnarkUtil.MAX_CONNECTIONS - 1) * HASH_LENGTH);
List<PeerID> peers = new ArrayList(len / HASH_LENGTH);
List<PeerID> peers = new ArrayList<PeerID>(len / HASH_LENGTH);
for (int off = 0; off < len; off += HASH_LENGTH) {
byte[] hash = new byte[HASH_LENGTH];
System.arraycopy(ids, off, hash, 0, HASH_LENGTH);
if (DataHelper.eq(hash, peer.getPeerID().getDestHash()))
continue;
PeerID pID = new PeerID(hash);
PeerID pID = new PeerID(hash, listener.getUtil());
peers.add(pID);
}
// could include ourselves, listener must remove
@ -332,6 +352,28 @@ abstract class ExtensionHandler {
}
}
/**
* Receive the DHT port numbers
* @since DHT
*/
private static void handleDHT(Peer peer, PeerListener listener, byte[] bs, Log log) {
if (log.shouldLog(Log.DEBUG))
log.debug("Got DHT msg from " + peer);
try {
InputStream is = new ByteArrayInputStream(bs);
BDecoder dec = new BDecoder(is);
BEValue bev = dec.bdecodeMap();
Map<String, BEValue> map = bev.getMap();
int qport = map.get("port").getInt();
int rport = map.get("rport").getInt();
listener.gotPort(peer, qport, rport);
} catch (Exception e) {
if (log.shouldLog(Log.INFO))
log.info("DHT msg exception from " + peer, e);
//peer.disconnect(false);
}
}
/**
* added.f and dropped unsupported
* @param pList non-null
@ -340,7 +382,7 @@ abstract class ExtensionHandler {
public static void sendPEX(Peer peer, List<Peer> pList) {
if (pList.isEmpty())
return;
Map<String, Object> map = new HashMap();
Map<String, Object> map = new HashMap<String, Object>();
byte[] peers = new byte[HASH_LENGTH * pList.size()];
int off = 0;
for (Peer p : pList) {
@ -359,4 +401,22 @@ abstract class ExtensionHandler {
}
}
/**
* Send the DHT port numbers
* @since DHT
*/
public static void sendDHT(Peer peer, int qport, int rport) {
Map<String, Object> map = new HashMap<String, Object>();
map.put("port", Integer.valueOf(qport));
map.put("rport", Integer.valueOf(rport));
byte[] payload = BEncoder.bencode(map);
try {
int hisMsgCode = peer.getHandshakeMap().get("m").getMap().get(TYPE_DHT).getInt();
peer.sendExtension(hisMsgCode, payload);
} catch (Exception e) {
// NPE, no DHT caps
//if (log.shouldLog(Log.INFO))
// log.info("DHT msg exception to " + peer, e);
}
}
}

View File

@ -1,16 +1,14 @@
package org.klomp.snark;
import java.io.ByteArrayOutputStream;
import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import java.util.Properties;
import java.util.Set;
import java.util.StringTokenizer;
import net.i2p.I2PAppContext;
import net.i2p.I2PException;
import net.i2p.client.I2PSession;
@ -20,6 +18,7 @@ import net.i2p.client.streaming.I2PSocket;
import net.i2p.client.streaming.I2PSocketEepGet;
import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.client.streaming.I2PSocketManagerFactory;
import net.i2p.client.streaming.I2PSocketOptions;
import net.i2p.data.Base32;
import net.i2p.data.DataFormatException;
import net.i2p.data.Destination;
@ -30,12 +29,11 @@ import net.i2p.util.FileUtil;
import net.i2p.util.Log;
import net.i2p.util.SecureDirectory;
import net.i2p.util.SecureFile;
import net.i2p.util.SimpleScheduler;
import net.i2p.util.SimpleTimer;
import net.i2p.util.Translate;
import org.klomp.snark.dht.DHT;
//import org.klomp.snark.dht.KRPC;
import org.klomp.snark.dht.KRPC;
/**
* I2P specific helpers for I2PSnark
@ -46,6 +44,7 @@ import org.klomp.snark.dht.DHT;
public class I2PSnarkUtil {
private final I2PAppContext _context;
private final Log _log;
private final String _baseName;
private boolean _shouldProxy;
private String _proxyHost;
@ -53,44 +52,60 @@ public class I2PSnarkUtil {
private String _i2cpHost;
private int _i2cpPort;
private final Map<String, String> _opts;
private I2PSocketManager _manager;
private volatile I2PSocketManager _manager;
private boolean _configured;
private final Set<Hash> _shitlist;
private volatile boolean _connecting;
private final Set<Hash> _banlist;
private int _maxUploaders;
private int _maxUpBW;
private int _maxConnections;
private final File _tmpDir;
private int _startupDelay;
private boolean _shouldUseOT;
private boolean _shouldUseDHT;
private boolean _areFilesPublic;
private String _openTrackerString;
private List<String> _openTrackers;
private DHT _dht;
private static final int EEPGET_CONNECT_TIMEOUT = 45*1000;
private static final int EEPGET_CONNECT_TIMEOUT_SHORT = 5*1000;
public static final int DEFAULT_STARTUP_DELAY = 3;
public static final boolean DEFAULT_USE_OPENTRACKERS = true;
public static final String DEFAULT_OPENTRACKERS = "http://tracker.welterde.i2p/a";
public static final int DEFAULT_MAX_UP_BW = 8; //KBps
public static final int MAX_CONNECTIONS = 16; // per torrent
public static final String PROP_MAX_BW = "i2cp.outboundBytesPerSecond";
//private static final boolean ENABLE_DHT = true;
public static final boolean DEFAULT_USE_DHT = true;
public static final String EEPGET_USER_AGENT = "I2PSnark";
public I2PSnarkUtil(I2PAppContext ctx) {
this(ctx, "i2psnark");
}
/**
* @param baseName generally "i2psnark"
* @since Jetty 7
*/
public I2PSnarkUtil(I2PAppContext ctx, String baseName) {
_context = ctx;
_log = _context.logManager().getLog(Snark.class);
_opts = new HashMap();
_baseName = baseName;
_opts = new HashMap<String, String>();
//setProxy("127.0.0.1", 4444);
setI2CPConfig("127.0.0.1", 7654, null);
_shitlist = new ConcurrentHashSet();
_configured = false;
_banlist = new ConcurrentHashSet<Hash>();
_maxUploaders = Snark.MAX_TOTAL_UPLOADERS;
_maxUpBW = DEFAULT_MAX_UP_BW;
_maxConnections = MAX_CONNECTIONS;
_startupDelay = DEFAULT_STARTUP_DELAY;
_shouldUseOT = DEFAULT_USE_OPENTRACKERS;
// FIXME split if default has more than one
_openTrackers = Collections.singletonList(DEFAULT_OPENTRACKERS);
_shouldUseDHT = DEFAULT_USE_DHT;
// This is used for both announce replies and .torrent file downloads,
// so it must be available even if not connected to I2CP.
// so much for multiple instances
_tmpDir = new SecureDirectory(ctx.getTempDir(), "i2psnark");
_tmpDir = new SecureDirectory(ctx.getTempDir(), baseName);
FileUtil.rmdir(_tmpDir, false);
_tmpDir.mkdirs();
}
@ -115,6 +130,9 @@ public class I2PSnarkUtil {
}
******/
/** @since 0.9.1 */
public I2PAppContext getContext() { return _context; }
public boolean configured() { return _configured; }
public void setI2CPConfig(String i2cpHost, int i2cpPort, Map opts) {
@ -136,7 +154,7 @@ public class I2PSnarkUtil {
}
/**
* This updates the session options and tells the router
* This updates ALL the session options (not just the bw) and tells the router
* @param limit KBps
*/
public void setMaxUpBW(int limit) {
@ -184,29 +202,35 @@ public class I2PSnarkUtil {
/** @since 0.8.9 */
public void setFilesPublic(boolean yes) { _areFilesPublic = yes; }
/** @since 0.9.1 */
public File getTempDir() { return _tmpDir; }
/**
* Connect to the router, if we aren't already
*/
synchronized public boolean connect() {
if (_manager == null) {
_connecting = true;
// try to find why reconnecting after stop
if (_log.shouldLog(Log.DEBUG))
_log.debug("Connecting to I2P", new Exception("I did it"));
Properties opts = _context.getProperties();
if (_opts != null) {
for (Iterator iter = _opts.keySet().iterator(); iter.hasNext(); ) {
String key = (String)iter.next();
opts.setProperty(key, _opts.get(key).toString());
}
for (Map.Entry<String, String> entry : _opts.entrySet() )
opts.setProperty(entry.getKey(), entry.getValue());
}
if (opts.getProperty("inbound.nickname") == null)
opts.setProperty("inbound.nickname", "I2PSnark");
opts.setProperty("inbound.nickname", _baseName.replace("i2psnark", "I2PSnark"));
if (opts.getProperty("outbound.nickname") == null)
opts.setProperty("outbound.nickname", "I2PSnark");
opts.setProperty("outbound.nickname", _baseName.replace("i2psnark", "I2PSnark"));
if (opts.getProperty("outbound.priority") == null)
opts.setProperty("outbound.priority", "-10");
// Dont do this for now, it is set in I2PSocketEepGet for announces,
// we don't need fast handshake for peer connections.
//if (opts.getProperty("i2p.streaming.connectDelay") == null)
// opts.setProperty("i2p.streaming.connectDelay", "500");
if (opts.getProperty(I2PSocketOptions.PROP_CONNECT_TIMEOUT) == null)
opts.setProperty(I2PSocketOptions.PROP_CONNECT_TIMEOUT, "75000");
if (opts.getProperty("i2p.streaming.inactivityTimeout") == null)
opts.setProperty("i2p.streaming.inactivityTimeout", "240000");
if (opts.getProperty("i2p.streaming.inactivityAction") == null)
@ -222,12 +246,20 @@ public class I2PSnarkUtil {
if (opts.getProperty("i2p.streaming.maxConnsPerMinute") == null)
opts.setProperty("i2p.streaming.maxConnsPerMinute", "2");
if (opts.getProperty("i2p.streaming.maxTotalConnsPerMinute") == null)
opts.setProperty("i2p.streaming.maxTotalConnsPerMinute", "6");
opts.setProperty("i2p.streaming.maxTotalConnsPerMinute", "8");
if (opts.getProperty("i2p.streaming.maxConnsPerHour") == null)
opts.setProperty("i2p.streaming.maxConnsPerHour", "20");
if (opts.getProperty("i2p.streaming.enforceProtocol") == null)
opts.setProperty("i2p.streaming.enforceProtocol", "true");
if (opts.getProperty("i2p.streaming.disableRejectLogging") == null)
opts.setProperty("i2p.streaming.disableRejectLogging", "true");
if (opts.getProperty("i2p.streaming.answerPings") == null)
opts.setProperty("i2p.streaming.answerPings", "false");
_manager = I2PSocketManagerFactory.createManager(_i2cpHost, _i2cpPort, opts);
_connecting = false;
}
// FIXME this only instantiates krpc once, left stuck with old manager
//if (ENABLE_DHT && _manager != null && _dht == null)
// _dht = new KRPC(_context, _manager.getSession());
if (_shouldUseDHT && _manager != null && _dht == null)
_dht = new KRPC(_context, _baseName, _manager.getSession());
return (_manager != null);
}
@ -239,15 +271,35 @@ public class I2PSnarkUtil {
public boolean connected() { return _manager != null; }
/** @since 0.9.1 */
public boolean isConnecting() { return _manager == null && _connecting; }
/**
* For FetchAndAdd
* @return null if not connected
* @since 0.9.1
*/
public I2PSocketManager getSocketManager() {
return _manager;
}
/**
* Destroy the destination itself
*/
public void disconnect() {
public synchronized void disconnect() {
if (_dht != null) {
_dht.stop();
_dht = null;
}
I2PSocketManager mgr = _manager;
// FIXME this can cause race NPEs elsewhere
_manager = null;
_shitlist.clear();
mgr.destroySocketManager();
_banlist.clear();
if (mgr != null) {
if (_log.shouldLog(Log.DEBUG))
_log.debug("Disconnecting from I2P", new Exception("I did it"));
mgr.destroySocketManager();
}
// this will delete a .torrent file d/l in progress so don't do that...
FileUtil.rmdir(_tmpDir, false);
// in case the user will d/l a .torrent file next...
@ -265,32 +317,49 @@ public class I2PSnarkUtil {
if (addr.equals(getMyDestination()))
throw new IOException("Attempt to connect to myself");
Hash dest = addr.calculateHash();
if (_shitlist.contains(dest))
throw new IOException("Not trying to contact " + dest.toBase64() + ", as they are shitlisted");
if (_banlist.contains(dest))
throw new IOException("Not trying to contact " + dest.toBase64() + ", as they are banlisted");
try {
// TODO opts.setPort(xxx); connect(addr, opts)
// DHT moved above 6881 in 0.9.9
I2PSocket rv = _manager.connect(addr);
if (rv != null)
_shitlist.remove(dest);
_banlist.remove(dest);
return rv;
} catch (I2PException ie) {
_shitlist.add(dest);
SimpleScheduler.getInstance().addEvent(new Unshitlist(dest), 10*60*1000);
throw new IOException("Unable to reach the peer " + peer + ": " + ie.getMessage());
_banlist.add(dest);
_context.simpleScheduler().addEvent(new Unbanlist(dest), 10*60*1000);
IOException ioe = new IOException("Unable to reach the peer " + peer);
ioe.initCause(ie);
throw ioe;
}
}
private class Unshitlist implements SimpleTimer.TimedEvent {
private class Unbanlist implements SimpleTimer.TimedEvent {
private Hash _dest;
public Unshitlist(Hash dest) { _dest = dest; }
public void timeReached() { _shitlist.remove(_dest); }
public Unbanlist(Hash dest) { _dest = dest; }
public void timeReached() { _banlist.remove(_dest); }
}
/**
* fetch the given URL, returning the file it is stored in, or null on error
* Fetch the given URL, returning the file it is stored in, or null on error.
* No retries.
*/
public File get(String url) { return get(url, true, 0); }
/**
* @param rewrite if true, convert http://KEY.i2p/foo/announce to http://i2p/KEY/foo/announce
*/
public File get(String url, boolean rewrite) { return get(url, rewrite, 0); }
/**
* @param retries if < 0, set timeout to a few seconds
*/
public File get(String url, int retries) { return get(url, true, retries); }
/**
* @param retries if < 0, set timeout to a few seconds
*/
public File get(String url, boolean rewrite, int retries) {
if (_log.shouldLog(Log.DEBUG))
_log.debug("Fetching [" + url + "] proxy=" + _proxyHost + ":" + _proxyPort + ": " + _shouldProxy);
@ -299,7 +368,7 @@ public class I2PSnarkUtil {
// we could use the system tmp dir but deleteOnExit() doesn't seem to work on all platforms...
out = SecureFile.createTempFile("i2psnark", null, _tmpDir);
} catch (IOException ioe) {
ioe.printStackTrace();
_log.error("temp file error", ioe);
if (out != null)
out.delete();
return null;
@ -311,12 +380,22 @@ public class I2PSnarkUtil {
//_log.debug("Rewritten url [" + fetchURL + "]");
//EepGet get = new EepGet(_context, _shouldProxy, _proxyHost, _proxyPort, retries, out.getAbsolutePath(), fetchURL);
// Use our tunnel for announces and .torrent fetches too! Make sure we're connected first...
if (!connected()) {
if (!connect())
int timeout;
if (retries < 0) {
if (!connected())
return null;
timeout = EEPGET_CONNECT_TIMEOUT_SHORT;
retries = 0;
} else {
timeout = EEPGET_CONNECT_TIMEOUT;
if (!connected()) {
if (!connect())
return null;
}
}
EepGet get = new I2PSocketEepGet(_context, _manager, retries, out.getAbsolutePath(), fetchURL);
if (get.fetch()) {
get.addHeader("User-Agent", EEPGET_USER_AGENT);
if (get.fetch(timeout)) {
if (_log.shouldLog(Log.DEBUG))
_log.debug("Fetch successful [" + url + "]: size=" + out.length());
return out;
@ -328,6 +407,47 @@ public class I2PSnarkUtil {
}
}
/**
* Fetch to memory
* @param retries if < 0, set timeout to a few seconds
* @param initialSize buffer size
* @param maxSize fails if greater
* @return null on error
* @since 0.9.4
*/
public byte[] get(String url, boolean rewrite, int retries, int initialSize, int maxSize) {
if (_log.shouldLog(Log.DEBUG))
_log.debug("Fetching [" + url + "] to memory");
String fetchURL = url;
if (rewrite)
fetchURL = rewriteAnnounce(url);
int timeout;
if (retries < 0) {
if (!connected())
return null;
timeout = EEPGET_CONNECT_TIMEOUT_SHORT;
retries = 0;
} else {
timeout = EEPGET_CONNECT_TIMEOUT;
if (!connected()) {
if (!connect())
return null;
}
}
ByteArrayOutputStream out = new ByteArrayOutputStream(initialSize);
EepGet get = new I2PSocketEepGet(_context, _manager, retries, -1, maxSize, null, out, fetchURL);
get.addHeader("User-Agent", EEPGET_USER_AGENT);
if (get.fetch(timeout)) {
if (_log.shouldLog(Log.DEBUG))
_log.debug("Fetch successful [" + url + "]: size=" + out.size());
return out.toByteArray();
} else {
if (_log.shouldLog(Log.WARN))
_log.warn("Fetch failed [" + url + "]");
return null;
}
}
public I2PServerSocket getServerSocket() {
I2PSocketManager mgr = _manager;
if (mgr != null)
@ -390,11 +510,12 @@ public class I2PSnarkUtil {
if (sess != null) {
byte[] b = Base32.decode(ip.substring(0, BASE32_HASH_LENGTH));
if (b != null) {
Hash h = new Hash(b);
//Hash h = new Hash(b);
Hash h = Hash.create(b);
if (_log.shouldLog(Log.INFO))
_log.info("Using existing session for lookup of " + ip);
try {
return sess.lookupDest(h);
return sess.lookupDest(h, 15*1000);
} catch (I2PSessionException ise) {
}
}
@ -445,30 +566,26 @@ public class I2PSnarkUtil {
}
/** @param ot non-null */
public void setOpenTrackerString(String ot) {
_openTrackerString = ot;
public void setOpenTrackers(List<String> ot) {
_openTrackers = ot;
}
public String getOpenTrackerString() {
if (_openTrackerString == null)
return DEFAULT_OPENTRACKERS;
return _openTrackerString;
}
/** comma delimited list open trackers to use as backups */
/** sorted map of name to announceURL=baseURL */
/** List of open trackers to use as backups
* @return non-null, possibly unmodifiable, empty if disabled
*/
public List<String> getOpenTrackers() {
if (!shouldUseOpenTrackers())
return null;
List<String> rv = new ArrayList(1);
String trackers = getOpenTrackerString();
StringTokenizer tok = new StringTokenizer(trackers, ", ");
while (tok.hasMoreTokens())
rv.add(tok.nextToken());
if (rv.isEmpty())
return null;
return rv;
return Collections.emptyList();
return _openTrackers;
}
/**
* List of open trackers to use as backups even if disabled
* @return non-null
* @since 0.9.4
*/
public List<String> getBackupTrackers() {
return _openTrackers;
}
public void setUseOpenTrackers(boolean yes) {
@ -478,6 +595,22 @@ public class I2PSnarkUtil {
public boolean shouldUseOpenTrackers() {
return _shouldUseOT;
}
/** @since DHT */
public synchronized void setUseDHT(boolean yes) {
_shouldUseDHT = yes;
if (yes && _manager != null && _dht == null) {
_dht = new KRPC(_context, _baseName, _manager.getSession());
} else if (!yes && _dht != null) {
_dht.stop();
_dht = null;
}
}
/** @since DHT */
public boolean shouldUseDHT() {
return _shouldUseDHT;
}
/**
* Like DataHelper.toHexString but ensures no loss of leading zero bytes
@ -494,40 +627,6 @@ public class I2PSnarkUtil {
return buf.toString();
}
/** hook between snark's logger and an i2p log */
void debug(String msg, int snarkDebugLevel) {
debug(msg, snarkDebugLevel, null);
}
void debug(String msg, int snarkDebugLevel, Throwable t) {
if (t instanceof OutOfMemoryError) {
try { Thread.sleep(100); } catch (InterruptedException ie) {}
try {
t.printStackTrace();
} catch (Throwable tt) {}
try {
System.out.println("OOM thread: " + Thread.currentThread().getName());
} catch (Throwable tt) {}
}
switch (snarkDebugLevel) {
case 0:
case 1:
_log.error(msg, t);
break;
case 2:
_log.warn(msg, t);
break;
case 3:
case 4:
_log.info(msg, t);
break;
case 5:
case 6:
default:
_log.debug(msg, t);
break;
}
}
private static final String BUNDLE_NAME = "org.klomp.snark.web.messages";
/** lang in routerconsole.lang property, else current locale */

View File

@ -0,0 +1,143 @@
/*
* Released into the public domain
* with no warranty of any kind, either expressed or implied.
*/
package org.klomp.snark;
import java.util.Map;
import java.util.Properties;
import net.i2p.client.I2PSession;
import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.util.Log;
import net.i2p.util.SimpleTimer2;
/**
* Periodically check for idle condition based on connected peers,
* and reduce/restore tunnel count as necessary.
* We can't use the I2CP idle detector because it's based on traffic,
* so DHT and announces would keep it non-idle.
*
* @since 0.9.7
*/
class IdleChecker extends SimpleTimer2.TimedEvent {
private final SnarkManager _mgr;
private final I2PSnarkUtil _util;
private final PeerCoordinatorSet _pcs;
private final Log _log;
private int _consec;
private int _consecNotRunning;
private boolean _isIdle;
private static final long CHECK_TIME = 63*1000;
private static final int MAX_CONSEC_IDLE = 4;
private static final int MAX_CONSEC_NOT_RUNNING = 20;
/**
* Caller must schedule
*/
public IdleChecker(SnarkManager mgr, PeerCoordinatorSet pcs) {
super(mgr.util().getContext().simpleTimer2());
_util = mgr.util();
_log = _util.getContext().logManager().getLog(IdleChecker.class);
_mgr = mgr;
_pcs = pcs;
}
public void timeReached() {
if (_util.connected()) {
boolean torrentRunning = false;
boolean hasPeers = false;
for (PeerCoordinator pc : _pcs) {
if (!pc.halted()) {
torrentRunning = true;
if (pc.getPeers() > 0) {
hasPeers = true;
break;
}
}
}
if (torrentRunning) {
_consecNotRunning = 0;
} else {
if (_consecNotRunning++ >= MAX_CONSEC_NOT_RUNNING) {
if (_log.shouldLog(Log.WARN))
_log.warn("Closing tunnels on idle");
_util.disconnect();
_mgr.addMessage(_util.getString("I2P tunnel closed."));
schedule(3 * CHECK_TIME);
return;
}
}
if (hasPeers) {
if (_isIdle)
restoreTunnels();
} else {
if (!_isIdle) {
if (_consec++ >= MAX_CONSEC_IDLE)
reduceTunnels();
}
}
} else {
_isIdle = false;
_consec = 0;
_consecNotRunning = 0;
}
schedule(CHECK_TIME);
}
/**
* Reduce to 1 in / 1 out tunnel
*/
private void reduceTunnels() {
_isIdle = true;
if (_log.shouldLog(Log.INFO))
_log.info("Reducing tunnels on idle");
setTunnels("1", "1", "0", "0");
}
/**
* Restore tunnel count
*/
private void restoreTunnels() {
_isIdle = false;
if (_log.shouldLog(Log.INFO))
_log.info("Restoring tunnels on activity");
Map<String, String> opts = _util.getI2CPOptions();
String i = opts.get("inbound.quantity");
if (i == null)
i = "3";
String o = opts.get("outbound.quantity");
if (o == null)
o = "3";
String ib = opts.get("inbound.backupQuantity");
if (ib == null)
ib = "0";
String ob= opts.get("outbound.backupQuantity");
if (ob == null)
ob = "0";
setTunnels(i, o, ib, ob);
}
/**
* Set in / out / in backup / out backup tunnel counts
*/
private void setTunnels(String i, String o, String ib, String ob) {
_consec = 0;
I2PSocketManager mgr = _util.getSocketManager();
if (mgr != null) {
I2PSession sess = mgr.getSession();
if (sess != null) {
Properties newProps = new Properties();
newProps.setProperty("inbound.quantity", i);
newProps.setProperty("outbound.quantity", o);
newProps.setProperty("inbound.backupQuantity", ib);
newProps.setProperty("outbound.backupQuantity", ob);
sess.updateOptions(newProps);
}
}
}
}

View File

@ -5,10 +5,9 @@ import java.io.IOException;
import java.io.InputStream;
import java.util.HashMap;
import java.util.Map;
import java.util.Random;
import net.i2p.I2PAppContext;
import net.i2p.data.DataHelper;
import net.i2p.util.RandomSource;
import org.klomp.snark.bencode.BDecoder;
import org.klomp.snark.bencode.BEValue;
@ -27,7 +26,6 @@ import org.klomp.snark.bencode.BEValue;
*/
class MagnetState {
public static final int CHUNK_SIZE = 16*1024;
private static final Random random = I2PAppContext.getGlobalContext().random();
private final byte[] infohash;
private boolean complete;
@ -129,7 +127,7 @@ class MagnetState {
throw new IllegalArgumentException("not initialized");
if (complete)
throw new IllegalArgumentException("complete");
int rand = random.nextInt(totalChunks);
int rand = RandomSource.getInstance().nextInt(totalChunks);
for (int i = 0; i < totalChunks; i++) {
int chk = (i + rand) % totalChunks;
if (!(have.get(chk) || requested.get(chk))) {
@ -189,9 +187,9 @@ class MagnetState {
* @return true if this was the last piece
* @throws NPE, IllegalArgumentException, IOException, ...
*/
public MetaInfo buildMetaInfo() throws Exception {
private MetaInfo buildMetaInfo() throws Exception {
// top map has nothing in it but the info map (no announce)
Map<String, BEValue> map = new HashMap();
Map<String, BEValue> map = new HashMap<String, BEValue>();
InputStream is = new ByteArrayInputStream(metainfoBytes);
BDecoder dec = new BDecoder(is);
BEValue bev = dec.bdecodeMap();

View File

@ -0,0 +1,212 @@
package org.klomp.snark;
import java.io.UnsupportedEncodingException;
import java.net.URI;
import java.net.URISyntaxException;
import java.util.ArrayList;
import java.util.List;
import java.util.Locale;
import net.i2p.data.Base32;
/**
*
* @since 0.9.4 moved from I2PSnarkServlet
*/
public class MagnetURI {
private final String _tracker;
private final String _name;
private final byte[] _ih;
/** BEP 9 */
public static final String MAGNET = "magnet:";
public static final String MAGNET_FULL = MAGNET + "?xt=urn:btih:";
/** http://sponge.i2p/files/maggotspec.txt */
public static final String MAGGOT = "maggot://";
/**
* @param url non-null
*/
public MagnetURI(I2PSnarkUtil util, String url) throws IllegalArgumentException {
String ihash;
String name;
String trackerURL = null;
if (url.startsWith(MAGNET)) {
// magnet:?xt=urn:btih:0691e40aae02e552cfcb57af1dca56214680c0c5&tr=http://tracker2.postman.i2p/announce.php
String xt = getParam("xt", url);
if (xt == null || !xt.startsWith("urn:btih:"))
throw new IllegalArgumentException();
ihash = xt.substring("urn:btih:".length());
trackerURL = getTrackerParam(url);
name = util.getString("Magnet") + ' ' + ihash;
String dn = getParam("dn", url);
if (dn != null)
name += " (" + Storage.filterName(dn) + ')';
} else if (url.startsWith(MAGGOT)) {
// maggot://0691e40aae02e552cfcb57af1dca56214680c0c5:0b557bbdf8718e95d352fbe994dec3a383e2ede7
ihash = url.substring(MAGGOT.length()).trim();
int col = ihash.indexOf(':');
if (col >= 0)
ihash = ihash.substring(0, col);
name = util.getString("Magnet") + ' ' + ihash;
} else {
throw new IllegalArgumentException();
}
byte[] ih = null;
if (ihash.length() == 32) {
ih = Base32.decode(ihash);
} else if (ihash.length() == 40) {
// Like DataHelper.fromHexString() but ensures no loss of leading zero bytes
ih = new byte[20];
try {
for (int i = 0; i < 20; i++) {
ih[i] = (byte) (Integer.parseInt(ihash.substring(i*2, (i*2) + 2), 16) & 0xff);
}
} catch (NumberFormatException nfe) {
ih = null;
}
}
if (ih == null || ih.length != 20)
throw new IllegalArgumentException();
_ih = ih;
_name = name;
_tracker = trackerURL;
}
/**
* @return 20 bytes or null
*/
public byte[] getInfoHash() {
return _ih;
}
/**
* @return pretty name or null
*/
public String getName() {
return _name;
}
/**
* @return tracker url or null
*/
public String getTrackerURL() {
return _tracker;
}
/**
* @return first decoded parameter or null
*/
private static String getParam(String key, String uri) {
int idx = uri.indexOf('?' + key + '=');
if (idx >= 0) {
idx += key.length() + 2;
} else {
idx = uri.indexOf('&' + key + '=');
if (idx >= 0)
idx += key.length() + 2;
}
if (idx < 0 || idx > uri.length())
return null;
String rv = uri.substring(idx);
idx = rv.indexOf('&');
if (idx >= 0)
rv = rv.substring(0, idx);
else
rv = rv.trim();
return decode(rv);
}
/**
* @return all decoded parameters or null
* @since 0.9.1
*/
private static List<String> getMultiParam(String key, String uri) {
int idx = uri.indexOf('?' + key + '=');
if (idx >= 0) {
idx += key.length() + 2;
} else {
idx = uri.indexOf('&' + key + '=');
if (idx >= 0)
idx += key.length() + 2;
}
if (idx < 0 || idx > uri.length())
return null;
List<String> rv = new ArrayList<String>();
while (true) {
String p = uri.substring(idx);
uri = p;
idx = p.indexOf('&');
if (idx >= 0)
p = p.substring(0, idx);
else
p = p.trim();
rv.add(decode(p));
idx = uri.indexOf('&' + key + '=');
if (idx < 0)
break;
idx += key.length() + 2;
}
return rv;
}
/**
* @return first valid I2P tracker or null
* @since 0.9.1
*/
private static String getTrackerParam(String uri) {
List<String> trackers = getMultiParam("tr", uri);
if (trackers == null)
return null;
for (String t : trackers) {
try {
URI u = new URI(t);
String protocol = u.getScheme();
String host = u.getHost();
if (protocol == null || host == null ||
!protocol.toLowerCase(Locale.US).equals("http") ||
!host.toLowerCase(Locale.US).endsWith(".i2p"))
continue;
return t;
} catch(URISyntaxException use) {}
}
return null;
}
/**
* Decode %xx encoding, convert to UTF-8 if necessary
* Copied from i2ptunnel LocalHTTPServer
* @since 0.9.1
*/
private static String decode(String s) {
if (!s.contains("%"))
return s;
StringBuilder buf = new StringBuilder(s.length());
boolean utf8 = false;
for (int i = 0; i < s.length(); i++) {
char c = s.charAt(i);
if (c != '%') {
buf.append(c);
} else {
try {
int val = Integer.parseInt(s.substring(++i, (++i) + 1), 16);
if ((val & 0x80) != 0)
utf8 = true;
buf.append((char) val);
} catch (IndexOutOfBoundsException ioobe) {
break;
} catch (NumberFormatException nfe) {
break;
}
}
}
if (utf8) {
try {
return new String(buf.toString().getBytes("ISO-8859-1"), "UTF-8");
} catch (UnsupportedEncodingException uee) {}
}
return buf.toString();
}
}

View File

@ -23,8 +23,13 @@ package org.klomp.snark;
import java.io.DataOutputStream;
import java.io.IOException;
// Used to queue outgoing connections
// sendMessage() should be used to translate them to wire format.
import net.i2p.data.ByteArray;
import net.i2p.util.ByteCache;
/**
* Used to queue outgoing connections
* sendMessage() should be used to translate them to wire format.
*/
class Message
{
final static byte KEEP_ALIVE = -1;
@ -69,6 +74,9 @@ class Message
// now unused
//SimpleTimer.TimedEvent expireEvent;
private static final int BUFSIZE = PeerState.PARTSIZE;
private static final ByteCache _cache = ByteCache.getInstance(16, BUFSIZE);
/** Utility method for sending a message through a DataStream. */
void sendMessage(DataOutputStream dos) throws IOException
{
@ -79,11 +87,15 @@ class Message
return;
}
ByteArray ba;
// Get deferred data
if (data == null && dataLoader != null) {
data = dataLoader.loadData(piece, begin, length);
if (data == null)
ba = dataLoader.loadData(piece, begin, length);
if (ba == null)
return; // hmm will get retried, but shouldn't happen
data = ba.getData();
} else {
ba = null;
}
// Calculate the total length in bytes
@ -139,6 +151,10 @@ class Message
// Send actual data
if (type == BITFIELD || type == PIECE || type == EXTENSION)
dos.write(data, off, len);
// Was pulled from cache in Storage.getPiece() via dataLoader
if (ba != null && ba.getData().length == BUFSIZE)
_cache.release(ba, false);
}
@Override

View File

@ -61,6 +61,10 @@ public class MetaInfo
private final byte[] piece_hashes;
private final long length;
private final boolean privateTorrent;
private final List<List<String>> announce_list;
private final String comment;
private final String created_by;
private final long creation_date;
private Map<String, BEValue> infoMap;
/**
@ -69,9 +73,11 @@ public class MetaInfo
* @param announce may be null
* @param files null for single-file torrent
* @param lengths null for single-file torrent
* @param announce_list may be null
*/
MetaInfo(String announce, String name, String name_utf8, List<List<String>> files, List<Long> lengths,
int piece_length, byte[] piece_hashes, long length, boolean privateTorrent)
int piece_length, byte[] piece_hashes, long length, boolean privateTorrent,
List<List<String>> announce_list)
{
this.announce = announce;
this.name = name;
@ -83,6 +89,10 @@ public class MetaInfo
this.piece_hashes = piece_hashes;
this.length = length;
this.privateTorrent = privateTorrent;
this.announce_list = announce_list;
this.comment = null;
this.created_by = null;
this.creation_date = 0;
// TODO if we add a parameter for other keys
//if (other != null) {
@ -141,6 +151,49 @@ public class MetaInfo
this.announce = val.getString();
}
// BEP 12
val = m.get("announce-list");
if (val == null) {
this.announce_list = null;
} else {
this.announce_list = new ArrayList<List<String>>();
List<BEValue> bl1 = val.getList();
for (BEValue bev : bl1) {
List<BEValue> bl2 = bev.getList();
List<String> sl2 = new ArrayList<String>();
for (BEValue bev2 : bl2) {
sl2.add(bev2.getString());
}
this.announce_list.add(sl2);
}
}
// misc. optional top-level stuff
val = m.get("comment");
String st = null;
if (val != null) {
try {
st = val.getString();
} catch (InvalidBEncodingException ibee) {}
}
this.comment = st;
val = m.get("created by");
st = null;
if (val != null) {
try {
st = val.getString();
} catch (InvalidBEncodingException ibee) {}
}
this.created_by = st;
val = m.get("creation date");
long time = 0;
if (val != null) {
try {
time = val.getLong() * 1000;
} catch (InvalidBEncodingException ibee) {}
}
this.creation_date = time;
val = m.get("info");
if (val == null)
throw new InvalidBEncodingException("Missing info map");
@ -163,7 +216,18 @@ public class MetaInfo
// BEP 27
val = info.get("private");
privateTorrent = val != null && val.getString().equals("1");
if (val != null) {
Object o = val.getValue();
// Is it supposed to be a number or a string?
// i2psnark does it as a string. BEP 27 doesn't say.
// Transmission does numbers. So does libtorrent.
// We handle both as of 0.9.9.
// We switch to storing as number as of 0.9.14.
privateTorrent = "1".equals(o) ||
((o instanceof Number) && ((Number) o).intValue() == 1);
} else {
privateTorrent = false;
}
val = info.get("piece length");
if (val == null)
@ -197,9 +261,9 @@ public class MetaInfo
if (size == 0)
throw new InvalidBEncodingException("zero size files list");
List<List<String>> m_files = new ArrayList(size);
List<List<String>> m_files_utf8 = new ArrayList(size);
List<Long> m_lengths = new ArrayList(size);
List<List<String>> m_files = new ArrayList<List<String>>(size);
List<List<String>> m_files_utf8 = new ArrayList<List<String>>(size);
List<Long> m_lengths = new ArrayList<Long>(size);
long l = 0;
for (int i = 0; i < list.size(); i++)
{
@ -225,7 +289,7 @@ public class MetaInfo
if (path_length == 0)
throw new InvalidBEncodingException("zero size file path list");
List<String> file = new ArrayList(path_length);
List<String> file = new ArrayList<String>(path_length);
Iterator<BEValue> it = path_list.iterator();
while (it.hasNext()) {
String s = it.next().getString();
@ -248,7 +312,7 @@ public class MetaInfo
path_list = val.getList();
path_length = path_list.size();
if (path_length > 0) {
file = new ArrayList(path_length);
file = new ArrayList<String>(path_length);
it = path_list.iterator();
while (it.hasNext())
file.add(it.next().getString());
@ -296,6 +360,15 @@ public class MetaInfo
return announce;
}
/**
* Returns a list of lists of urls.
*
* @since 0.9.5
*/
public List<List<String>> getAnnounceList() {
return announce_list;
}
/**
* Returns the original 20 byte SHA1 hash over the bencoded info map.
*/
@ -351,6 +424,33 @@ public class MetaInfo
return lengths;
}
/**
* The comment string or null.
* Not available for locally-created torrents.
* @since 0.9.7
*/
public String getComment() {
return this.comment;
}
/**
* The created-by string or null.
* Not available for locally-created torrents.
* @since 0.9.7
*/
public String getCreatedBy() {
return this.created_by;
}
/**
* The creation date (ms) or zero.
* Not available for locally-created torrents.
* @since 0.9.7
*/
public long getCreationDate() {
return this.creation_date;
}
/**
* Returns the number of pieces.
*/
@ -417,9 +517,33 @@ public class MetaInfo
sha1.update(bs, off, length);
byte[] hash = sha1.digest();
for (int i = 0; i < 20; i++)
for (int i = 0; i < 20; i++) {
if (hash[i] != piece_hashes[20 * piece + i])
return false;
}
return true;
}
/**
* @return good
* @since 0.9.1
*/
boolean checkPiece(PartialPiece pp) {
int piece = pp.getPiece();
byte[] hash;
try {
hash = pp.getHash();
} catch (IOException ioe) {
// Could be caused by closing a peer connnection
// we don't want the exception to propagate through
// to Storage.putPiece()
_log.warn("Error checking", ioe);
return false;
}
for (int i = 0; i < 20; i++) {
if (hash[i] != piece_hashes[20 * piece + i])
return false;
}
return true;
}
@ -447,12 +571,18 @@ public class MetaInfo
/**
* Creates a copy of this MetaInfo that shares everything except the
* announce URL.
* Drops any announce-list.
* Preserves infohash and info map, including any non-standard fields.
* @param announce may be null
*/
public MetaInfo reannounce(String announce)
public MetaInfo reannounce(String announce) throws InvalidBEncodingException
{
return new MetaInfo(announce, name, name_utf8, files,
lengths, piece_length,
piece_hashes, length, privateTorrent);
Map<String, BEValue> m = new HashMap<String, BEValue>();
if (announce != null)
m.put("announce", new BEValue(DataHelper.getUTF8(announce)));
Map<String, BEValue> info = createInfoMap();
m.put("info", new BEValue(info));
return new MetaInfo(m);
}
/**
@ -460,10 +590,12 @@ public class MetaInfo
*/
public synchronized byte[] getTorrentData()
{
Map m = new HashMap();
Map<String, Object> m = new HashMap<String, Object>();
if (announce != null)
m.put("announce", announce);
Map info = createInfoMap();
if (announce_list != null)
m.put("announce-list", announce_list);
Map<String, BEValue> info = createInfoMap();
m.put("info", info);
// don't save this locally, we should only do this once
return BEncoder.bencode(m);
@ -483,32 +615,48 @@ public class MetaInfo
// or else we will lose any non-standard keys and corrupt the infohash.
if (infoMap != null)
return Collections.unmodifiableMap(infoMap);
// we should only get here if serving a magnet on a torrent we created
if (_log.shouldLog(Log.WARN))
_log.warn("Creating new infomap", new Exception());
// otherwise we must create it
Map info = new HashMap();
info.put("name", name);
Map<String, BEValue> info = new HashMap<String, BEValue>();
info.put("name", new BEValue(DataHelper.getUTF8(name)));
if (name_utf8 != null)
info.put("name.utf-8", name_utf8);
info.put("name.utf-8", new BEValue(DataHelper.getUTF8(name_utf8)));
// BEP 27
if (privateTorrent)
info.put("private", "1");
// switched to number in 0.9.14
//info.put("private", new BEValue(DataHelper.getUTF8("1")));
info.put("private", new BEValue(Integer.valueOf(1)));
info.put("piece length", Integer.valueOf(piece_length));
info.put("pieces", piece_hashes);
info.put("piece length", new BEValue(Integer.valueOf(piece_length)));
info.put("pieces", new BEValue(piece_hashes));
if (files == null)
info.put("length", Long.valueOf(length));
info.put("length", new BEValue(Long.valueOf(length)));
else
{
List l = new ArrayList();
List<BEValue> l = new ArrayList<BEValue>();
for (int i = 0; i < files.size(); i++)
{
Map file = new HashMap();
file.put("path", files.get(i));
if ( (files_utf8 != null) && (files_utf8.size() > i) )
file.put("path.utf-8", files_utf8.get(i));
file.put("length", lengths.get(i));
l.add(file);
Map<String, BEValue> file = new HashMap<String, BEValue>();
List<String> fi = files.get(i);
List<BEValue> befiles = new ArrayList<BEValue>(fi.size());
for (int j = 0; j < fi.size(); j++) {
befiles.add(new BEValue(DataHelper.getUTF8(fi.get(j))));
}
file.put("path", new BEValue(befiles));
if ( (files_utf8 != null) && (files_utf8.size() > i) ) {
List<String> fiu = files_utf8.get(i);
List<BEValue> beufiles = new ArrayList<BEValue>(fiu.size());
for (int j = 0; j < fiu.size(); j++) {
beufiles.add(new BEValue(DataHelper.getUTF8(fiu.get(j))));
}
file.put("path.utf-8", new BEValue(beufiles));
}
file.put("length", new BEValue(lengths.get(i)));
l.add(new BEValue(file));
}
info.put("files", l);
info.put("files", new BEValue(l));
}
// TODO if we add the ability for other keys in the first constructor

View File

@ -1,6 +1,24 @@
package org.klomp.snark;
import java.io.DataInputStream;
import java.io.DataOutput;
import java.io.File;
import java.io.IOException;
import java.io.RandomAccessFile;
import java.security.MessageDigest;
import net.i2p.I2PAppContext;
import net.i2p.crypto.SHA1;
import net.i2p.data.ByteArray;
import net.i2p.util.ByteCache;
import net.i2p.util.Log;
import net.i2p.util.SecureFile;
/**
* Store the received data either on the heap or in a temp file.
* The third option, to write chunks directly to the destination file,
* is unimplemented.
*
* This is the class passed from PeerCoordinator to PeerState so
* PeerState may start requests.
*
@ -8,45 +26,84 @@ package org.klomp.snark;
* a piece is not completely downloaded, for example
* when the Peer disconnects or chokes.
*
* New objects for the same piece are created during the end game -
* this object should not be shared among multiple peers.
*
* @since 0.8.2
*/
class PartialPiece implements Comparable {
class PartialPiece implements Comparable<PartialPiece> {
private final int piece;
// we store the piece so we can use it in compareTo()
private final Piece piece;
// null if using temp file
private final byte[] bs;
private final int off;
private final long createdTime;
private int off;
//private final long createdTime;
private File tempfile;
private RandomAccessFile raf;
private final int pclen;
private final File tempDir;
private static final int BUFSIZE = PeerState.PARTSIZE;
private static final ByteCache _cache = ByteCache.getInstance(16, BUFSIZE);
// Any bigger than this, use temp file instead of heap
private static final int MAX_IN_MEM = 128 * 1024;
// May be reduced on OOM
private static int _max_in_mem = MAX_IN_MEM;
/**
* Used by PeerCoordinator.
* Creates a new PartialPiece, with no chunks yet downloaded.
* Allocates the data.
* Allocates the data storage area, either on the heap or in the
* temp directory, depending on size.
*
* @param piece Piece number requested.
* @param len must be equal to the piece length
*/
public PartialPiece (int piece, int len) throws OutOfMemoryError {
public PartialPiece (Piece piece, int len, File tempDir) {
this.piece = piece;
this.bs = new byte[len];
this.off = 0;
this.createdTime = 0;
this.pclen = len;
//this.createdTime = 0;
this.tempDir = tempDir;
// temps for finals
byte[] tbs = null;
try {
if (len <= MAX_IN_MEM) {
try {
tbs = new byte[len];
return;
} catch (OutOfMemoryError oom) {
if (_max_in_mem > PeerState.PARTSIZE)
_max_in_mem /= 2;
Log log = I2PAppContext.getGlobalContext().logManager().getLog(PartialPiece.class);
log.logAlways(Log.WARN, "OOM creating new partial piece");
// fall through to use temp file
}
}
// delay creating temp file until required in read()
} finally {
// finals
this.bs = tbs;
}
}
/**
* Used by PeerState.
* Creates a new PartialPiece, with chunks up to but not including
* firstOutstandingRequest already downloaded and stored in the Request byte array.
* Caller must synchronize
*
* Note that this cannot handle gaps; chunks after a missing chunk cannot be saved.
* That would be harder.
*
* @param firstOutstandingRequest the first request not fulfilled for the piece
* @since 0.9.1
*/
public PartialPiece (Request firstOutstandingRequest) {
this.piece = firstOutstandingRequest.piece;
this.bs = firstOutstandingRequest.bs;
this.off = firstOutstandingRequest.off;
this.createdTime = System.currentTimeMillis();
private void createTemp() throws IOException {
//tfile = SecureFile.createTempFile("piece", null, tempDir);
// debug
tempfile = SecureFile.createTempFile("piece_" + piece.getId() + '_', null, tempDir);
//I2PAppContext.getGlobalContext().logManager().getLog(PartialPiece.class).warn("Created " + tempfile);
// tfile.deleteOnExit() ???
raf = new RandomAccessFile(tempfile, "rw");
// Do not preallocate the file space.
// Not necessary to call setLength(), file is extended when written
//traf.setLength(len);
}
/**
@ -55,33 +112,199 @@ class PartialPiece implements Comparable {
*/
public Request getRequest() {
return new Request(this.piece, this.bs, this.off, Math.min(this.bs.length - this.off, PeerState.PARTSIZE));
return new Request(this, this.off, Math.min(this.pclen - this.off, PeerState.PARTSIZE));
}
/** piece number */
public int getPiece() {
return this.piece;
return this.piece.getId();
}
/** how many bytes are good */
/**
* @since 0.9.1
*/
public int getLength() {
return this.pclen;
}
/**
* How many bytes are good - only valid by setDownloaded()
*/
public int getDownloaded() {
return this.off;
}
/**
* Call this before returning a PartialPiece to the PeerCoordinator
* @since 0.9.1
*/
public void setDownloaded(int offset) {
this.off = offset;
}
/****
public long getCreated() {
return this.createdTime;
}
****/
/**
* Highest downloaded first
* Piece must be complete.
* The SHA1 hash of the completely read data.
* @since 0.9.1
*/
public int compareTo(Object o) throws ClassCastException {
return ((PartialPiece)o).off - this.off; // reverse
public byte[] getHash() throws IOException {
MessageDigest sha1 = SHA1.getInstance();
if (bs != null) {
sha1.update(bs);
} else {
int read = 0;
int buflen = Math.min(pclen, BUFSIZE);
ByteArray ba;
byte[] buf;
if (buflen == BUFSIZE) {
ba = _cache.acquire();
buf = ba.getData();
} else {
ba = null;
buf = new byte[buflen];
}
synchronized (this) {
if (raf == null)
throw new IOException();
raf.seek(0);
while (read < pclen) {
int rd = raf.read(buf, 0, Math.min(buf.length, pclen - read));
if (rd < 0)
break;
read += rd;
sha1.update(buf, 0, rd);
}
}
if (ba != null)
_cache.release(ba, false);
if (read < pclen)
throw new IOException();
}
return sha1.digest();
}
/**
* Blocking.
* @since 0.9.1
*/
public void read(DataInputStream din, int off, int len) throws IOException {
if (bs != null) {
din.readFully(bs, off, len);
} else {
// read in fully before synching on raf
ByteArray ba;
byte[] tmp;
if (len == BUFSIZE) {
ba = _cache.acquire();
tmp = ba.getData();
} else {
ba = null;
tmp = new byte[len];
}
din.readFully(tmp);
synchronized (this) {
if (raf == null)
createTemp();
raf.seek(off);
raf.write(tmp);
}
if (ba != null)
_cache.release(ba, false);
}
}
/**
* Piece must be complete.
* Caller must synchronize on out and seek to starting point.
* Caller must call release() when done with the whole piece.
*
* @param out stream to write to
* @param offset offset in the piece
* @param len length to write
* @since 0.9.1
*/
public void write(DataOutput out, int offset, int len) throws IOException {
if (bs != null) {
out.write(bs, offset, len);
} else {
int read = 0;
int buflen = Math.min(len, BUFSIZE);
ByteArray ba;
byte[] buf;
if (buflen == BUFSIZE) {
ba = _cache.acquire();
buf = ba.getData();
} else {
ba = null;
buf = new byte[buflen];
}
synchronized (this) {
if (raf == null)
throw new IOException();
raf.seek(offset);
while (read < len) {
int rd = Math.min(buf.length, len - read);
raf.readFully(buf, 0, rd);
read += rd;
out.write(buf, 0, rd);
}
}
if (ba != null)
_cache.release(ba, false);
}
}
/**
* Release all resources.
*
* @since 0.9.1
*/
public void release() {
if (bs == null) {
synchronized (this) {
if (raf != null)
locked_release();
}
//if (raf != null)
// I2PAppContext.getGlobalContext().logManager().getLog(PartialPiece.class).warn("Released " + tempfile);
}
}
/**
* Caller must synchronize
*
* @since 0.9.1
*/
private void locked_release() {
try {
raf.close();
} catch (IOException ioe) {
I2PAppContext.getGlobalContext().logManager().getLog(PartialPiece.class).warn("Error closing " + raf, ioe);
}
tempfile.delete();
}
/*
* Highest priority first,
* then rarest first,
* then highest downloaded first
*/
public int compareTo(PartialPiece opp) {
int d = this.piece.compareTo(opp.piece);
if (d != 0)
return d;
return opp.off - this.off; // reverse
}
@Override
public int hashCode() {
return piece * 7777;
return piece.getId() * 7777;
}
/**
@ -92,13 +315,13 @@ class PartialPiece implements Comparable {
public boolean equals(Object o) {
if (o instanceof PartialPiece) {
PartialPiece pp = (PartialPiece)o;
return pp.piece == this.piece;
return pp.piece.getId() == this.piece.getId();
}
return false;
}
@Override
public String toString() {
return "Partial(" + piece + ',' + off + ',' + bs.length + ')';
return "Partial(" + piece.getId() + ',' + off + ',' + pclen + ')';
}
}

View File

@ -28,6 +28,8 @@ import java.io.OutputStream;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicLong;
import net.i2p.I2PAppContext;
import net.i2p.client.streaming.I2PSocket;
@ -37,7 +39,7 @@ import net.i2p.util.Log;
import org.klomp.snark.bencode.BEValue;
public class Peer implements Comparable
public class Peer implements Comparable<Peer>
{
private final Log _log = I2PAppContext.getGlobalContext().logManager().getLog(Peer.class);
// Identifying property, the peer id of the other side.
@ -68,8 +70,10 @@ public class Peer implements Comparable
private I2PSocket sock;
private boolean deregister = true;
private static long __id;
private long _id;
private static final AtomicLong __id = new AtomicLong();
private final long _id;
private final AtomicBoolean _disconnected = new AtomicBoolean();
final static long CHECK_PERIOD = PeerCoordinator.CHECK_PERIOD; // 40 seconds
final static int RATE_DEPTH = PeerCoordinator.RATE_DEPTH; // make following arrays RATE_DEPTH long
private long uploaded_old[] = {-1,-1,-1};
@ -80,7 +84,9 @@ public class Peer implements Comparable
static final long OPTION_FAST = 0x0000000000000004l;
static final long OPTION_DHT = 0x0000000000000001l;
/** we use a different bit since the compact format is different */
/* no, let's use an extension message
static final long OPTION_I2P_DHT = 0x0000000040000000l;
*/
static final long OPTION_AZMP = 0x1000000000000000l;
private long options;
@ -96,7 +102,7 @@ public class Peer implements Comparable
this.my_id = my_id;
this.infohash = infohash;
this.metainfo = metainfo;
_id = ++__id;
_id = __id.incrementAndGet();
//_log.debug("Creating a new peer with " + peerID.toString(), new Exception("creating"));
}
@ -121,7 +127,7 @@ public class Peer implements Comparable
byte[] id = handshake(in, out);
this.peerID = new PeerID(id, sock.getPeerDestination());
_id = ++__id;
_id = __id.incrementAndGet();
if (_log.shouldLog(Log.DEBUG))
_log.debug("Creating a new peer " + peerID.toString(), new Exception("creating " + _id));
}
@ -188,9 +194,8 @@ public class Peer implements Comparable
* Compares the PeerIDs.
* @deprecated unused?
*/
public int compareTo(Object o)
public int compareTo(Peer p)
{
Peer p = (Peer)o;
int rv = peerID.compareTo(p.peerID);
if (rv == 0) {
if (_id > p._id) return 1;
@ -269,15 +274,17 @@ public class Peer implements Comparable
_log.debug("Peer supports extensions, sending reply message");
int metasize = metainfo != null ? metainfo.getInfoBytes().length : -1;
boolean pexAndMetadata = metainfo == null || !metainfo.isPrivate();
out.sendExtension(0, ExtensionHandler.getHandshake(metasize, pexAndMetadata));
boolean dht = util.getDHT() != null;
out.sendExtension(0, ExtensionHandler.getHandshake(metasize, pexAndMetadata, dht));
}
if ((options & OPTION_I2P_DHT) != 0 && util.getDHT() != null) {
if (_log.shouldLog(Log.DEBUG))
_log.debug("Peer supports DHT, sending PORT message");
int port = util.getDHT().getPort();
out.sendPort(port);
}
// Old DHT PORT message
//if ((options & OPTION_I2P_DHT) != 0 && util.getDHT() != null) {
// if (_log.shouldLog(Log.DEBUG))
// _log.debug("Peer supports DHT, sending PORT message");
// int port = util.getDHT().getPort();
// out.sendPort(port);
//}
// Send our bitmap
if (bitfield != null)
@ -355,7 +362,7 @@ public class Peer implements Comparable
String bittorrentProtocol = new String(bs, "UTF-8");
if (!"BitTorrent protocol".equals(bittorrentProtocol))
throw new IOException("Handshake failure, expected "
+ "'Bittorrent protocol', got '"
+ "'BitTorrent protocol', got '"
+ bittorrentProtocol + "'");
// Handshake read - options
@ -453,6 +460,8 @@ public class Peer implements Comparable
void disconnect()
{
if (!_disconnected.compareAndSet(false, true))
return;
PeerState s = state;
if (s != null)
{
@ -460,7 +469,7 @@ public class Peer implements Comparable
if (this.deregister) {
PeerListener p = s.listener;
if (p != null) {
List<PartialPiece> pcs = s.returnPartialPieces();
List<Request> pcs = s.returnPartialPieces();
if (!pcs.isEmpty())
p.savePartialPieces(this, pcs);
// now covered by savePartialPieces
@ -472,9 +481,11 @@ public class Peer implements Comparable
PeerConnectionIn in = s.in;
if (in != null)
in.disconnect();
PeerConnectionOut out = s.out;
if (out != null)
out.disconnect();
// this is blocking in streaming, so do this after closing the socket
// so it won't really block
//PeerConnectionOut out = s.out;
//if (out != null)
// out.disconnect();
PeerListener pl = s.listener;
if (pl != null)
pl.disconnected(this);
@ -488,6 +499,13 @@ public class Peer implements Comparable
_log.warn("Error disconnecting " + toString(), ioe);
}
}
if (s != null) {
// this is blocking in streaming, so do this after closing the socket
// so it won't really block
PeerConnectionOut out = s.out;
if (out != null)
out.disconnect();
}
}
/**

View File

@ -26,8 +26,6 @@ import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.SequenceInputStream;
import java.util.Iterator;
import net.i2p.I2PAppContext;
import net.i2p.client.streaming.I2PSocket;
import net.i2p.data.Base64;
@ -40,12 +38,16 @@ import net.i2p.util.Log;
* protocol connection. The PeerAcceptor will then create a new peer
* if the PeerCoordinator wants more peers.
*/
public class PeerAcceptor
class PeerAcceptor
{
private final Log _log = I2PAppContext.getGlobalContext().logManager().getLog(PeerAcceptor.class);
private final PeerCoordinator coordinator;
final PeerCoordinatorSet coordinators;
/** shorten timeout while reading handshake */
private static final long HASH_READ_TIMEOUT = 45*1000;
public PeerAcceptor(PeerCoordinator coordinator)
{
this.coordinator = coordinator;
@ -69,11 +71,20 @@ public class PeerAcceptor
// talk about, and we can just look for that in our list of active torrents.
byte peerInfoHash[] = null;
if (in instanceof BufferedInputStream) {
// multitorrent
in.mark(LOOKAHEAD_SIZE);
peerInfoHash = readHash(in);
long timeout = socket.getReadTimeout();
socket.setReadTimeout(HASH_READ_TIMEOUT);
try {
peerInfoHash = readHash(in);
} catch (IOException ioe) {
// unique exception so ConnectionAcceptor can blame the peer
throw new ProtocolException(ioe.toString());
}
socket.setReadTimeout(timeout);
in.reset();
} else {
// is this working right?
// Single torrent - is this working right?
try {
peerInfoHash = readHash(in);
if (_log.shouldLog(Log.INFO))
@ -104,9 +115,8 @@ public class PeerAcceptor
}
} else {
// multitorrent capable, so lets see what we can handle
for (Iterator iter = coordinators.iterator(); iter.hasNext(); ) {
PeerCoordinator cur = (PeerCoordinator)iter.next();
PeerCoordinator cur = coordinators.get(peerInfoHash);
if (cur != null) {
if (DataHelper.eq(cur.getInfoHash(), peerInfoHash)) {
if (cur.needPeers())
{
@ -130,22 +140,49 @@ public class PeerAcceptor
}
}
private static final String PROTO_STR = "BitTorrent protocol";
private static final int PROTO_STR_LEN = PROTO_STR.length();
private static final int PROTO_LEN = PROTO_STR_LEN + 1;
private static final int[] PROTO = new int[PROTO_LEN];
static {
PROTO[0] = PROTO_STR_LEN;
for (int i = 0; i < PROTO_STR_LEN; i++) {
PROTO[i+1] = PROTO_STR.charAt(i);
}
}
/** 48 */
private static final int LOOKAHEAD_SIZE = 1 + // chr(19)
"BitTorrent protocol".length() +
private static final int LOOKAHEAD_SIZE = PROTO_LEN +
8 + // blank, reserved
20; // infohash
/**
* Read ahead to the infohash, throwing an exception if there isn't enough data
* Read ahead to the infohash, throwing an exception if there isn't enough data.
* Also check the first 20 bytes for the correct protocol here and throw IOE if bad,
* so we don't hang waiting for 48 bytes if it's not a bittorrent client.
* The 20 bytes are checked again in Peer.handshake().
*/
private byte[] readHash(InputStream in) throws IOException {
byte buf[] = new byte[LOOKAHEAD_SIZE];
private static byte[] readHash(InputStream in) throws IOException {
for (int i = 0; i < PROTO_LEN; i++) {
int b = in.read();
if (b != PROTO[i])
throw new IOException("Bad protocol 0x" + Integer.toHexString(b) + " at byte " + i);
}
DataHelper.skip(in, 8);
byte buf[] = new byte[20];
int read = DataHelper.read(in, buf);
if (read != buf.length)
throw new IOException("Unable to read the hash (read " + read + ")");
byte rv[] = new byte[20];
System.arraycopy(buf, buf.length-rv.length, rv, 0, rv.length);
return rv;
return buf;
}
/**
* A unique exception so we can tell the ConnectionAcceptor about non-BT connections
* @since 0.9.1
*/
public static class ProtocolException extends IOException {
public ProtocolException(String s) {
super(s);
}
}
}

View File

@ -24,7 +24,10 @@ import java.util.ArrayList;
import java.util.List;
import java.util.Random;
import net.i2p.I2PAppContext;
import net.i2p.data.DataHelper;
import net.i2p.util.Log;
import org.klomp.snark.dht.DHT;
/**
* TimerTask that checks for good/bad up/downloader. Works together
@ -36,16 +39,18 @@ class PeerCheckerTask implements Runnable
private final PeerCoordinator coordinator;
private final I2PSnarkUtil _util;
private final Log _log;
private final Random random;
private int _runCount;
PeerCheckerTask(I2PSnarkUtil util, PeerCoordinator coordinator)
{
_util = util;
_log = util.getContext().logManager().getLog(PeerCheckerTask.class);
random = util.getContext().random();
this.coordinator = coordinator;
}
private static final Random random = I2PAppContext.getGlobalContext().random();
public void run()
{
_runCount++;
@ -67,9 +72,10 @@ class PeerCheckerTask implements Runnable
// Keep track of peers we remove now,
// we will add them back to the end of the list.
List<Peer> removed = new ArrayList();
List<Peer> removed = new ArrayList<Peer>();
int uploadLimit = coordinator.allowedUploaders();
boolean overBWLimit = coordinator.overUpBWLimit();
DHT dht = _util.getDHT();
for (Peer peer : peerList) {
// Remove dying peers
@ -82,6 +88,14 @@ class PeerCheckerTask implements Runnable
continue;
}
if (peer.getInactiveTime() > PeerCoordinator.MAX_INACTIVE) {
if (_log.shouldLog(Log.WARN))
_log.warn("Disconnecting peer idle " +
DataHelper.formatDuration(peer.getInactiveTime()) + ": " + peer);
peer.disconnect();
continue;
}
if (!peer.isChoking())
uploaders++;
@ -92,14 +106,15 @@ class PeerCheckerTask implements Runnable
peer.setRateHistory(upload, download);
peer.resetCounters();
_util.debug(peer + ":", Snark.DEBUG);
_util.debug(" ul: " + upload*1024/KILOPERSECOND
if (_log.shouldLog(Log.DEBUG)) {
_log.debug(peer + ":"
+ " ul: " + upload*1024/KILOPERSECOND
+ " dl: " + download*1024/KILOPERSECOND
+ " i: " + peer.isInterested()
+ " I: " + peer.isInteresting()
+ " c: " + peer.isChoking()
+ " C: " + peer.isChoked(),
Snark.DEBUG);
+ " C: " + peer.isChoked());
}
// Choke a percentage of them rather than all so it isn't so drastic...
// unless this torrent is over the limit all by itself.
@ -120,8 +135,8 @@ class PeerCheckerTask implements Runnable
// Check if it still wants pieces from us.
if (!peer.isInterested())
{
_util.debug("Choke uninterested peer: " + peer,
Snark.INFO);
if (_log.shouldLog(Log.DEBUG))
_log.debug("Choke uninterested peer: " + peer);
peer.setChoking(true);
uploaders--;
coordinator.uploaders--;
@ -131,8 +146,8 @@ class PeerCheckerTask implements Runnable
}
else if (overBWLimitChoke)
{
_util.debug("BW limit (" + upload + "/" + uploaded + "), choke peer: " + peer,
Snark.INFO);
if (_log.shouldLog(Log.DEBUG))
_log.debug("BW limit (" + upload + "/" + uploaded + "), choke peer: " + peer);
peer.setChoking(true);
uploaders--;
coordinator.uploaders--;
@ -144,7 +159,8 @@ class PeerCheckerTask implements Runnable
else if (peer.isInteresting() && peer.isChoked())
{
// If they are choking us make someone else a downloader
_util.debug("Choke choking peer: " + peer, Snark.DEBUG);
if (_log.shouldLog(Log.DEBUG))
_log.debug("Choke choking peer: " + peer);
peer.setChoking(true);
uploaders--;
coordinator.uploaders--;
@ -156,7 +172,8 @@ class PeerCheckerTask implements Runnable
else if (!peer.isInteresting() && !coordinator.completed())
{
// If they aren't interesting make someone else a downloader
_util.debug("Choke uninteresting peer: " + peer, Snark.DEBUG);
if (_log.shouldLog(Log.DEBUG))
_log.debug("Choke uninteresting peer: " + peer);
peer.setChoking(true);
uploaders--;
coordinator.uploaders--;
@ -170,8 +187,8 @@ class PeerCheckerTask implements Runnable
&& download == 0)
{
// We are downloading but didn't receive anything...
_util.debug("Choke downloader that doesn't deliver:"
+ peer, Snark.DEBUG);
if (_log.shouldLog(Log.DEBUG))
_log.debug("Choke downloader that doesn't deliver: " + peer);
peer.setChoking(true);
uploaders--;
coordinator.uploaders--;
@ -198,10 +215,14 @@ class PeerCheckerTask implements Runnable
// send PEX
if ((_runCount % 17) == 0 && !peer.isCompleted())
coordinator.sendPeers(peer);
peer.keepAlive();
// cheap failsafe for seeds connected to seeds, stop pinging and hopefully
// the inactive checker (above) will eventually disconnect it
if (coordinator.getNeededLength() > 0 || !peer.isCompleted())
peer.keepAlive();
// announce them to local tracker (TrackerClient does this too)
if (_util.getDHT() != null && (_runCount % 5) == 0) {
_util.getDHT().announce(coordinator.getInfoHash(), peer.getPeerID().getDestHash());
if (dht != null && (_runCount % 5) == 0) {
dht.announce(coordinator.getInfoHash(), peer.getPeerID().getDestHash(),
peer.isCompleted());
}
}
@ -215,8 +236,8 @@ class PeerCheckerTask implements Runnable
|| uploaders > uploadLimit)
&& worstDownloader != null)
{
_util.debug("Choke worst downloader: " + worstDownloader,
Snark.DEBUG);
if (_log.shouldLog(Log.DEBUG))
_log.debug("Choke worst downloader: " + worstDownloader);
worstDownloader.setChoking(true);
coordinator.uploaders--;
@ -249,8 +270,8 @@ class PeerCheckerTask implements Runnable
}
// announce ourselves to local tracker (TrackerClient does this too)
if (_util.getDHT() != null && (_runCount % 16) == 0) {
_util.getDHT().announce(coordinator.getInfoHash());
if (dht != null && (_runCount % 16) == 0) {
dht.announce(coordinator.getInfoHash(), coordinator.completed());
}
}
}

Some files were not shown because too many files have changed in this diff Show More