Commit Graph

50 Commits

Author SHA1 Message Date
eed8d9c61b fixed dangerous comparison (== != .equals) [thanks mihi!] 2004-08-25 00:00:04 +00:00
cc085755aa oOo's patch to add support for temporary name<-->destination assignment (w00t!)
to use this, make a link going to http://some.name.i2p/some/path/blah?i2paddresshelper=base64Destination
e.g. http://whitehouse.gov.i2p/?i2paddresshelper=FpCkYW5pwVz36sSHoBuRT4ZvGif9QC9oQUWfz-wu4zEnJ1ewlAvinPuw3YnXUKmgLFZ0UY3wB7wqd0eQYiW2ZV1bwVhXvsyGV5ZehzxGaFu05IspCJjyaMIe90z5fyda4KgzyBwHKqwjGX57SMyn2cZhXbCKF6aNuipWxYOnL65uATDbw3jShEtL9v9299ohhGA3EcrYk3u86FgLmsOdi2GZruxy2RzioA-VKhaZl4RSJs6dFHPUYWgeLF3gT7Ciy-HbMZdDuiLTEX7mUlO0UZwnzT8mjUDeeYfyWtv9arwv-rAMeXxAVUYm7X2dDHN8TvmQCZ~LiQrnGmGReSIDKVT4u59xZX2Qg0GZf0fA5LRSW1zHLrlZWDJfNeESW57RlOkA9DDDOxwSVSw8LUQN-hPsoz~AgwA-vDklNWULqvp4lLifEJUlr5ZmnWrviLr6W6cHhdJBl89VzMThoknb5UibIvwTnu~tfA0rkyILXX07hdaoXF~prptuOhMtEcV2AAAA
this is better than the existing http://i2p/base64Destination/ since images at that page will now resolve
the name is resolved only if/when the hosts.txt doesn't have a matching entry (aka no spoofing duck.i2p),
but the name is *not* persisted to hosts.txt - if you restart your tunnel (or router, if they're in the same JVM), the address helper is lost
2004-08-21 22:39:27 +00:00
cb5e3efd8a don't force start the tunnels too early - only instantiate the tunnelControllerGroup when the CLI is run (aka after 2 minutes whem TunnelControllerGroup.main is called from clients.config) 2004-08-21 22:05:02 +00:00
3053c797e8 handle removal and addition (duh) 2004-08-19 22:02:28 +00:00
410abaf92c handle the tunnels being instantiated prior to the CLI being inoked
(aka someone went to /i2ptunnel/ before the 2 minute delay passes)
2004-08-19 21:11:42 +00:00
fccb172e20 * Display both the hash and the full destination associated with each tunnel on
the /i2ptunnel/ page so they can easily be shared.
* By default, try to create any needed private key files (for server tunnels only)
* keep track of the I2PSession objects used by the I2PTunnel instances (only needed
for exposing the associated Destination)
2004-08-19 17:36:27 +00:00
d2fc24e792 deal with no proxy available
more carefully retrieve a proxy
logging (w/ unique requestId)
2004-08-15 20:44:14 +00:00
9cc96f45d0 * add a main() to TunnelControllerGroup which can be used as a clientApp.*
* new config property to have a tunnel start on load (default=true), so tunnels, er, start on load
* use i2ptunnel.config instead of i2ptunnel.cfg (for consistency)
* minor refactoring
2004-08-14 02:03:45 +00:00
4dfcf1c1c8 updated boundary condition (thanks mule/oOo) 2004-08-08 01:35:45 +00:00
cdb4576bd7 per mule's patch, added support for a round robin across multiple outproxies
instead of the standard 'httpclient 4444' or 'httpclient 4444 squid.i2p', you can now specify a comma delimited list of outproxies:
'httpclient 4444 squid.i2p,www1.squid.i2p,www2.squid.i2p' and each individual http request goes through a randomly selected proxy
there are a few general issues with this, such as a lack of affinity (web applications that require a session to always come from a single IP address will break)
but it should work most of the time.
2004-08-05 18:17:33 +00:00
3f70593ca8 precompile all of the JSPs so that people with JREs instead of JDKs can load this up 2004-08-05 02:24:00 +00:00
83cf815160 * add new and generally ugly components to allow web based control of tunnels
* build an i2ptunnel.war
2004-08-03 08:21:29 +00:00
fea62a529b * don't use static props on the I2PTunnel for I2CP / etc so that we can safely keep multiple instances alive
* propogate errors (if the I2CP host isnt reachable, the socket manager
won't be created) and handle appropriately
2004-08-03 08:18:10 +00:00
5850ad1217 typo fix, thanks Connelly
(duck)
2004-07-15 16:02:53 +00:00
7b9db07f13 target=1.3 and source=1.3, not target=1.1 and source=1.3
(this is what caused the runtime errors on sun jvms but not on kaffe)
((aka i slacked and didn't test sufficiently.  off with my head))
this now builds and runs fine in sun 1.3-1.5 jvms, as well as kaffe
2004-07-12 16:39:22 +00:00
3bc0e0fc8a added source and target declarations for the javac commands so we can build with the 1.5^W5.0 JDK
(also added deprecation, since, well, we can :)
2004-07-11 04:16:59 +00:00
a788d30f34 added support for new 'clientoptions' command which alters the properties passed when creating subsequent I2CP connections
e.g.: -e "clientoptions tunnels.depthInbound=0" -e "httpclient 6666"
this updates so many files because they all need a reference to an I2PTunnel object on construction so they query tunnel.getClientOptions() instead of System.getProperties
2004-07-10 16:59:49 +00:00
8c9f58b939 Misc. stuff: javadoc, UNUSED...
shendaras
2004-07-02 02:54:04 +00:00
d3f3f3bdf7 use the socketManager's new setName function (to let us log more easily) 2004-06-28 13:23:24 +00:00
5c1e001a73 logging 2004-06-27 19:39:45 +00:00
727f4c3bb5 Another rfc2068 fix.
ERR_REQUEST_DENIED now returns a 403 status code. Note that I'm assuming
this error occurs because the proxy is configured to not allow connection
to non-i2p destinations. If it's issued for other reasons we might want
to consider using 503 instead.
2004-05-24 07:28:24 +00:00
7372ad0cc4 A few changes to make proxy return the proper rfc2068 status codes
instead of 404 for everything.

ERR_DESTINATION_UNKNOWN now returns 503 instead of 404 with a slightly
more clear error message.

ERR_TIMEOUT now returns 504 gateway timeout.
2004-05-24 07:08:02 +00:00
ca6884dbca imports (sorry, includes alphabetizing, wee)
(shendaras)
2004-05-24 03:21:21 +00:00
097a4647a8 handle i2ptunnel server connection .accept()s asynchronously so we don't refuse lots of requests, causing intermittent "failures"
use the new async error listening interface of the ministreaming lib
truckloads of logging
2004-05-19 15:20:55 +00:00
292363eb65 imports (sorry, includes alphabetizing, wee)
(shendaras)
2004-05-17 03:38:53 +00:00
ff0023a889 big ol' memory, cpu usage, and shutdown handling update. main changes include:
* rather than have all jobs created hooked into the clock for offset updates, have the jobQueue stay hooked up and update any active jobs accordingly (killing a memory leak of a JobTiming objects - one per job)
* dont go totally insane during shutdown and log like mad (though the clientApp things still log like mad, since they don't know the router is going down)
* adjust memory buffer sizes based on real world values so we don't have to expand/contract a lot
* dont display things that are completely useless (who cares what the first 32 bytes of a public key are?)
* reduce temporary object creation
* use more efficient collections at times
* on shutdown, log some state information (ready/timed jobs, pending messages, etc)
* explicit GC every 10 jobs.  yeah, not efficient, but just for now we'll keep 'er in there
* only reread the router config file if it changes (duh)
2004-05-16 04:54:50 +00:00
45ec73c115 include a unique request id in the client runner thread name
minor cleanup
2004-05-07 03:33:23 +00:00
e0e7211852 lets default the read timeout to 5 minutes for clients (that hanging irc disconnect / not disconnected thing) 2004-05-05 22:57:43 +00:00
07aa2e280d strip the Connection, Keep-Alive, and Proxy-Connection headers, and always inject Connection: close
(this is the cause of the intermittent "view $page through squid, try to view eepsite, end up requesting through squid" bug)
2004-05-05 07:29:48 +00:00
59aec9d289 expose the read timeout for the client and put the default read timeout back to -1 for the server (override via command line, etc) 2004-05-05 03:36:18 +00:00
3db8b63cde by default, set the readTimeout to 3 minutes, NOT infinity. Overridable as before (setting the timeout to -1)
add a unique id to the server thread
2004-05-04 08:16:41 +00:00
6edf5d1e4f add a unique id to the thread names 2004-05-04 08:15:18 +00:00
a23fa6fadd allow multiple concurrent connections to be created
added a unique ID to more threads
2004-05-04 08:14:19 +00:00
51eb77e409 logging 2004-05-04 08:13:01 +00:00
2bfbe1ca27 logging (toss a unique ID onto the handler / inactivity threads) 2004-05-03 03:36:38 +00:00
1a38271104 made the event name more consistent 2004-04-30 23:01:35 +00:00
e73eb55d75 don't create two contexts just for this I2PTunnel (one implicit from the static new Log(I2PTunnel.class) and one explicit) 2004-04-24 12:51:15 +00:00
393b1d7674 big ol' update to strip out the singletons, replacing them with
a rooted app context.  The core itself has its own I2PAppContext
(see its javadoc for, uh, docs), and the router extends that to
expose the router's singletons.  The main point of this is to
make it so that we can run multiple routers in the same JVM, even
to allow different apps in the same JVM to switch singleton
implementations (e.g. run some routers with one set of profile
calculators, and other routers with a different one).
There is still some work to be done regarding the actual boot up
of multiple routers in a JVM, as well as their configuration,
though the plan is to have the RouterContext override the
I2PAppContext's getProperty/getPropertyNames methods to read from
a config file (seperate ones per context) instead of using the
System.getProperty that the base I2PAppContext uses.
Once the multi-router is working, i'll shim in a VMCommSystem
that doesn't depend upon sockets or threads to read/write (and
that uses configurable message send delays / disconnects / etc,
perhaps using data from the routerContext.getProperty to drive it).
I could hold off until the sim is all working, but there's a
truckload of changes in here and I hate dealing with conflicts ;)
Everything works - I've been running 'er for a while and kicked
the tires a bit, but if you see something amiss, please let me
know.
2004-04-24 11:54:35 +00:00
c29a6b95ae Increased logging priority for connection timeouts
(human)
2004-04-23 14:18:48 +00:00
4fe7105e2f Implemented timeout handling to I2PTunnelServer 2004-04-21 17:58:26 +00:00
90350786e6 s/InterruptedException/InterruptedIOException/
(human)
2004-04-20 15:43:04 +00:00
d945eb6fcf Made all the ministreaming-based apps aware of the new exceptions thrown by
I2PSocketManager.connect()
(human)
2004-04-19 21:47:06 +00:00
7b824e6178 kill long lines
[mihi]
2004-04-14 23:27:50 +00:00
17a1b11f66 beginning of format, updated imports. (shendaras) 2004-04-10 11:45:02 +00:00
8a8e68146f beginning of format, updated imports. (shendaras) 2004-04-10 11:39:00 +00:00
c47bfce010 Some crappy, half-assed attempt at javadoc stuff; removed (commented out, rather) the fromProxy stuff for *Handler.java. Feel free to put it back in if it's really needed....
(shendaras)
2004-04-10 06:27:18 +00:00
f37c0ed612 name all threads, and (nearly) always use I2PThread (in case we add some pooling/throttling/monitoring or whatnot later) 2004-04-09 01:22:04 +00:00
44bbcd7033 make build process "a bit" faster
[mihi]
2004-04-08 18:24:07 +00:00
be13c14376 javadoc cleanup to remove those damn warnings 2004-04-08 09:07:53 +00:00
77bd69c5e5 beginning of branch i2p.i2p.i2p 2004-04-08 04:41:54 +00:00