Commit Graph

1231 Commits

Author SHA1 Message Date
zzz ba694d4702 i2psnark: Fix check for existing base file when adding via create form
don't use the filtered name
2026-05-17 12:27:06 -04:00
zzz a9ded0827d i2psnark: Use unfiltered base file name if it exists
reported by: Igillis
2026-05-17 12:23:03 -04:00
zzz 479154c75e i2psnark: Add check for empty filenames
reported by: bottomlineit.co.za
2026-05-17 12:16:33 -04:00
zzz 85499fbb8b Hoist random() calls out of session synch blocks 2026-05-10 09:06:00 -04:00
zzz 98fb8c2af5 javadoc corrections 2026-05-07 11:40:42 -04:00
zzz f13ba5d987 i2psnark: Refactor nonces
Replace the webapp-wide nonce with two session-bound nonce queues,
one for the outer section and details/config pages, one for
the inner (XHR) section.

Any form-stuffing scripts that grab the nonce must be updated
to store and return the session cookie also.

related changes to follow

reported by: bottomlineit.co.za
2026-05-07 11:14:35 -04:00
zzz 566d4f86e6 i2psnark: Remove support for ancient name.utf-8 and path.utf-8 metainfo entries
These were non-standard old pre-utf8 fields, and were never well-tested code paths.
name and path are always UTF-8 now according to the specs.
utf-8 flavors bypassed some sanitization.

reported by: bottomlineit.co.za
2026-05-01 18:09:52 -04:00
zzz 818d0dfd5f i2psnark: Fix autostart of completed torrents when added to the directory
by not saving the torrent config file twice
(once via storageAllChecked() and once via storageCompleted() from Storage.checkCreateFiles())
the 1st call set running=true but the 2nd set running=false
2026-04-26 15:42:16 -04:00
zzz ba572bd1bd spotbugs fixes all over 2026-04-25 09:53:32 -04:00
zzz f55a7f8de8 i2psnark: Add Tixati ID 2026-02-14 14:01:59 -05:00
zzz 98644e565f i2psnark: Clear bw limiters on session stop 2026-02-14 13:08:51 -05:00
zzz 9afba936d0 i2psnark: Increase max piece size to 64 MB
This seems to be the consensus, see https://github.com/rndusr/torf/issues/38
2026-01-20 07:59:44 -05:00
zzz 895f316c0b Build: javadoc target fixes 2025-12-05 12:07:50 -05:00
zzz 3ded02b585 i2psnark: Migrate to enctype 6,4 2025-12-03 11:34:30 -05:00
zzz 01129f0218 Conversion to Jetty 12 / Java 17
- Basic console (tested)
- SSL console (tested)
- Auth (tested)
- Debug logging (tested)
- Console request log (tested)

- I2PControl separate port (untested)
- Eepsite request log (untested)

TODO:

- Eepsites + migration
- Debian with or without Jetty 12
- Snark standalone
- Tomcat upgrade
- Checkin jetty jars
- Cleanups
2025-10-11 09:44:10 -04:00
zzz 502efa8349 i2psnark: Handle UDP trackers in magnet links
- Fix NPE announcing magnet to UDP tracker
- Prep for handling multiple trackers in magnet links
2025-08-10 11:49:46 -04:00
eyedeekay e132b2a441 UDPTrackerClient: Fix Javadoc describing DG2 tracker mechanics 2025-07-29 10:10:04 -04:00
zzz bc8e6c053a i2psnark: Fix form error message if GET but POST required 2025-07-17 18:21:18 -04:00
zzz e612fb937b i2psnark: Note UDP announce URLs
- Add alt postman b32
- StringBuilder cleanup
2025-07-04 07:13:54 -04:00
zzz e389512d4e i2psnark: UDP announce fixes
- Fix retransmissions, timeouts, backoff
- Remove unused cleaner and random key
- Javadoc and log fixes
2025-07-04 07:01:51 -04:00
zzz 18d356fecb Partial fix for display of UDP tracker URLs 2025-06-26 07:33:53 -04:00
zzz 965ed2c8bf Honor public files flag when saving torrent file after edit 2025-06-26 07:29:38 -04:00
zzz 6eacc5e4db Don't AIOOBE on bad announce reply 2025-06-26 07:25:22 -04:00
zzz 602fe2b9ca Add UDP tracker for testing 2025-06-26 07:23:16 -04:00
zzz d53949f970 i2psnark: Update UDP tracker (Proposal 160) (#504)
from three years ago,
to match current version of Proposal 160.
Revert back to standard BEP 15 from "fast mode".
Add TrackerClient and I2PSnarkUtil changes.
Datagram2/3 hooked in.
Variable lifetime handled.

Co-authored-by: zzz <zzz@i2pmail.org>
Reviewed-on: http://git.idk.i2p/I2P_Developers/i2p.i2p/pulls/504
Reviewed-by: idk <idki2p@mail.i2p>
2025-06-21 06:47:28 -04:00
zzz 0bc47c9040 i2psnark: Add new tracker 2025-05-14 11:38:39 -04:00
zzz 6af930ce84 i2psnark: Update known opentrackers list 2025-05-12 15:21:49 -04:00
zzz 52dc75cc9b i2psnark: Change search of multiple tokens from OR to AND 2025-05-09 07:37:56 -04:00
zzz 59c17869ed i2psnark: Remove ElGamal peer support 2025-04-27 13:00:25 -04:00
zzz e7774feb12 i2psnark: Remove outstanding requests from pieces when connection is replaced
Hopefully fixes rare case where torrents get stuck.
Tested that it doesn't break anything, but was never able to reproduce the issue.

As reported in torrent at http://tracker2.postman.i2p/index.php?view=TorrentDetail&id=85798
Fix adapted and greatly simplified from source code included in that torrent.
Apparently from old trac ticket #691.
Credit: smtorrents

Also:
- Fix place where removePeerFromPieces() was being called twice,
  once directly and once from disconnect(true).
- Fix javadoc for Peer.disconnect()
- Fix log typo
- Add comments

Description from OP of that torrent:

This update now finally fixes the decades old ticket number 691 which prevents torrents to complete from time to time. The bug manifests itself by keeping a couple of outstanding pieces (> 8, so we never get into the endgame) that are marked as requested from a peerID, with a corresponding peer that has long gone. Those pieces are never requested from any other peer. There are consequently more peerIDs than peers connected.

The only place in code, where peers and peer IDs are mixed up, is a reconnect logic that tries to reuse an existing connection while keeping outstanding requests from the old connection, when the other end tries to reconnect.

Keeping old requests is faulty by itself because someone reconnecting to us will definitely have dropped our previous requests, so we must do the same. The fix now always drops previous connections along with all outstanding requests.
2025-04-20 12:06:28 -04:00
zzz 5cfa74d785 i2psnark, i2ptunnel: Use Long.compare() in sorters
available in Java 7 / Android API 19 (our minSDK is currently 20)
2025-04-20 09:29:06 -04:00
zzz 51dbd493fe i2psnark: Add 2nd tie break for peer count when sorting by status 2025-04-20 09:18:39 -04:00
zzz 9daa5763ba i2psnark: Show lifetime download rate since added on details page 2025-04-20 08:56:50 -04:00
zzz 9a29b456e0 i2psnark: Show current tunnel config in dropdowns even if outside normal range
if user changed i2psnark.config manually
as reported at http://ramble.i2p/f/I2P/5704
2025-04-20 08:51:43 -04:00
zzz 705e24f0bf i2psnark: DTG/Bubble notifications on torrent add failures 2025-03-30 07:08:27 -04:00
zzz c83b092955 i2psnark: Use torrent name instead of torrent file name in DTG/bubble completion notifications 2025-03-19 09:49:17 -04:00
zzz de2f2007c4 Console: Improve writing efficiency
replace out.write(buf.toString) with out.append(buf)
to eliminate extra copy and object churn
2025-02-23 20:45:06 -05:00
zzz 940205f8c8 Merge branch 'bubbles' into 'master'
Console: Add support for notification bubbles

See merge request i2p-hackers/i2p.i2p!230
2025-02-22 11:07:44 +00:00
zzz 652d55a95c Console: Add support for notification bubbles 2025-02-22 11:07:43 +00:00
zzz b915327fba i2psnark: Add config message for changing down bw limit 2025-02-21 15:26:42 -05:00
zzz c248a999a4 Streaming: Promote profile properties to interface
i2ptunnel: set bulk profile for servers;
i2psnark: set bulk profile;
Prep for tunnel bw params (proposal 168)
2025-02-21 10:22:24 -05:00
zzz f0e3f6eaf3 i2psnark: Reduce PeerCoordinator CHECK_PERIOD interval
to make the choke/unchoke cycles a little faster
2025-02-07 13:51:26 -05:00
zzz f09262ac48 i2psnark: require POST on all forms 2025-01-17 12:16:27 +00:00
zzz 37cdade492 Build: Fix some deprecation warnings all over 2024-11-28 17:17:11 -05:00
zzz f7d2893751 Add complete Gan Chinese translation 2024-11-26 12:15:32 -05:00
zzz 30a3806da8 i2psnark: Recognize EepTorrent client 2024-11-20 08:59:27 -05:00
zzz 910a44484f javadoc fix 2024-09-25 08:22:02 -04:00
zzz bca5b65b1a i2psnark: Prevent changing infohash in metainfo edit CLI
Tweaks to previous MR:
_ Use new constructor for edit CLI
- Javadocs for new constructor
- Add new_url_list param to new constructor
- Set creation date if unset
2024-09-20 09:47:58 -04:00
marek 702f95b384 Fix broken info hash after torrent edit. 2024-09-04 19:16:37 +00:00
zzz eec09d4c9c i2psnark: Reduce minimum bandwidth, reduce max connections if low bandwidth
per user request
2024-08-09 09:59:57 -04:00