Ecosyste.ms: OpenCollective

An open API service for software projects hosted on Open Collective.

github.com/alanmcgovern/monotorrent

The official repository for MonoTorrent, a bittorrent library for .NET
https://github.com/alanmcgovern/monotorrent

[core] Test different combinations of incremental hashing

Add some tests verifying that writing the blocks for a Piece
with 3 blocks, in every permutation...

0f0569db95a4f9374d24213fc62bca23277cfb20 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Make DiskManager get it's info from an interface

DiskManager now uses 'ITorrentData' to retrieve the list
of files, the torrent size and the piec...

5f981b9aea3ba5d47014be49b9c255cd9b6cf548 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Add tests covering most aspects of DiskManager

This includes adding the capability to test the ratelimiting
code by faking how fast time is pro...

2f5254ecf886f60d975a6dd28fcfa651e3ac7a95 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Clean up MemoryWriter and MemoryWriterTests

Add some APIs so we can check the cache hits and misses from
the MemoryWriter.

e6cf286d9fcf0959c2ee629d241c635c1f3c1012 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Tweak DiskManager/PieceWriter to separate concerns

The DiskManager now stores/uses an IPieceWriter rather than
the old PieceWriter abstract class. ...

9f1f13ffb2f52b9960db8d28751a9cd9d356027e authored about 5 years ago by Alan McGovern <[email protected]>
[core] Use an extension method instead of Toolbox.RaiseAsyncEvent

It's a bit nicer to have an extension method 'InvokeAsync' as it
is more natural. It allows usin...

90994385d2d4ee481465d69eba4aef83afb838ad authored about 5 years ago by Alan McGovern <[email protected]>
[core] Treat LocalPeerDiscovery like the Dht engine

The Dht engine is something we can Announce to, in order to inform
other peers we are downloadin...

7659bbb35d1a1822c58f1b077b93449eb0987e0e authored about 5 years ago by Alan McGovern <[email protected]>
[test] Add tests ensuring PeerExchange is ignored for private torrents

d01245e9c00713a97618099db8da4d1f12ebeb59 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Don't announce PeerExchange support for private torrents

PeerExchange messages would never be sent, or processed, for
private torrents. However to be a l...

1c017025fa1df270fa28f58d852cbb531e14c666 authored about 5 years ago by Alan McGovern <[email protected]>
[tests] Add tests covering localpeerlistener

Just makes sure that external peers cannot be added
to a private torrent using a bad ILocalPeerL...

d70e6725972b8864a547a5487908d2dcf08005f9 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Move the handling of Dht announces out of TorrentManager

The DhtEngine is registered at the ClientEngine, so the ClientEngine
should be the only one addi...

4348240ae5856e205a70c90c3b245a8a5b274588 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Tweak the previous patch to keep the new methods hidden

Also we need to call the new method when adding peers from
trackers!

91f9d7995866e19921f12a6fbaa983161dab4896 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Add a test covering adding tracker peers to a private torrent

Covers fix in a863bba8a202dbb3033357f4eda8ad0b712e454f

70378fa6f2f5fee77d483c43a1db9ea57c163544 authored about 5 years ago by Alan McGovern <[email protected]>
fixed problem in AddPeerAsync with peers from private trackers

f55ba6a2246815bd0fef33ffa4381c49cb7d80ec authored about 5 years ago by skelder <[email protected]>
[core] Do some cleanups to the EngineSettings

Some small renaming and better handling of default values.

a86ba7fedffdc368904fcbee5c8f24c565da8e05 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Rewrite hashing mode

Take advantage of the ability to await the hash checking code
to simplify concerns.

HashingMode...

edb68f00ed68606a05416c187db4adb2ed9a4ac3 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Clean up ErrorMode

Use autoprops. Rely on the base implementation of HandlePeerConnected
to do the right thing when...

db2d9f1c45edc9328aa279d687ea2a7d3a43f884 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Clean up StoppedMode

Use auto props, use spaces instead of tabs, rely on the base
implementation of 'HandlePeerConnec...

a6d6f82364875e592ec0d39ccafc9900d4714182 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure that PeerId.TorrentManager is never null

Only one place in the code created this before the TorrentManager
was known. It is trivial to de...

d3c2544155aa42708bf1441f263babe4b33b07b0 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure an IConnection is always passed to the PeerId constructor

Two different connections to the same ip/port/peerid should be treated
as distinct sessions as i...

1dd8245846a715d10536e1f32fa7243c27ff4ffc authored about 5 years ago by Alan McGovern <[email protected]>
[core] StartAsync does not wait for the entire hashcheck to complete

StartAsync should signal that it is 'Complete' as soon as the mode
transitions to anything that ...

4f244d39f15d5c6a0cc79987ff2ba6a7c893322f authored about 5 years ago by Alan McGovern <[email protected]>
[core] Remove the 'Direction' property from PeerConnected events

The PeerConnected/PeerDisconnected events expose the PeerId which
has Connected/Disconnected. Th...

9fc6f6319e7ad744266969b34193225198beaf97 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Move TorrentEventArgs to autoprops

0fe62dad2fea16f5cf2fbe8f83c9f441d01194f6 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Optimise stopping a TorrentManager

As stopping a torrentmanager boils down to waiting for a few
Tasks to complete, we can simplify ...

fb4787159edb1c656cd24a5a43412ef7e7ada7a1 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Make TorrentManager.ConnectionAttemptFailed public

This has been reworked to provide better insight into why
an outgoing connection attempt may hav...

7075e2acac65122491480c57cdcbd9332219e141 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Add code comments to EngineSettings and use autoprops

3b23a4cacf0b4fb02715f127fa45ab348ed3ca50 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Rename Peer.Encryption to Peer.AllowedEncryption

This is consistent with the rest of the codebase and indicates that
these are just the range of ...

c6d2bdad4f900394c7af65f8578e48216f2c253b authored about 5 years ago by Alan McGovern <[email protected]>
[core] Add code comments to EncryptionTypes

3528e979a64e4ac2c55822c34f02669f36301be7 authored about 5 years ago by Alan McGovern <[email protected]>
[build] Run GitInfo dependent targets only after it has been restored

If the project has not been restored and something directly, or
indirectly, results in the custo...

e41c4fbdc1039d4c029c0051e354c0835fdf264e authored about 5 years ago by Alan McGovern <[email protected]>
[build] Make all builds deterministic by default

Now releases can be independently re-created in a bit-identical
way. It still relies on having t...

d8c14ca865b457243840fb18fddb45a3f435bf0d authored about 5 years ago by Alan McGovern <[email protected]>
[core] Tweak the semantics of TorrentManager.StopAsync

The task returned by this method will transition to the
'Completed' state only when the Mode has...

820d1cebfc9d256eae75b9f05db2a88cdbca1539 authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] Allow comparing peers using PeerId

We still default to using IPAddress/Port as some bittorrent
clients randomise their peerid, maki...

7bcd469e8522a025ad310744000e955d72b184a4 authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] Use auto-props instead of fields+props in TrackerServer

Also add a lot of code comments to explain the properties/methods.

2ee0e417c3ca888df27bb56946c8b17ffeef8ad8 authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] Remove some unnecssary locking in RequestMonitor

The underlying SpeedMonitor is threadsafe, so there's no
need to add additional locking inside R...

1ac4c0d2ac5a047ce3d80e31a92650459a4a54cf authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] The scrape response should not be hex encoded

The infohash should just be a 20byte BEncodedString. Only the
original http scrape request needs...

a4fdd73ba9f529f7597d0c9fc4e328467af4648a authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] Rename and update some of the Tracker code

I wanted to clean up some naming collisions between namespaces.

In the MonoTorrent.Tracker name...

ab72c54d2bad7ee90601945964779b55d0e4b5ba authored about 5 years ago by Alan McGovern <[email protected]>
[tests] Add a test checking sync and async DHT message sends

A bad blocking Wait or .Result could hang the loop, so ensure
that nothing deadlocks for both th...

889ad2222ef50ede4994ffaf64f5cd0c55dbe681 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Remove MonoTorrentCollection from the solution

We don't need a custom collection implementation.

daafb0ba196afdc5e434e5e7313518d0cb5686a5 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Remove another MonoTorrentCollection usage

2728a26d43eee36c01ce549c815a4c36da078da0 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Remove usages of MonoTorrentCollection

026ca8ffa7502b29256f5a5f61c7241d197bbc65 authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Add some code comments and remove unnecessary locks

d6fa20b44191e2acc286c3df8fe5023ae1a41077 authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Move some argument checks to use 'nameof'

c4f1f5c69b4fc454067d8e3ed1f0ed6285cbaa69 authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Add a missing license header

87317e55fc45d421a3fcaeb00e277e2398f27add authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Add some null checks to Equals/CompareTo

This is just code hygiene, these are never null at runtime.

053cf159b07671fa6b91702ce0188b02ae8857e4 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Remove some more .Result calls

These ones were right after an 'await' so they are guaranteed to
succeed every time, but for cod...

b5fabb630a09a9e9b720d4f050ddb4147ee14eba authored about 5 years ago by Alan McGovern <[email protected]>
[core] Remove another blocking .Result

We don't need to do a blocking .Result anymore as the containing
method (StartAsync) is now async!

07b32c2467ee13b144ded1a70918216cce883154 authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Add a ConfigureAwait(false) and remove a .Wait

Blocking is bad in general, so remove blocking calls. Also
add a ConfigureAwait false to reduce ...

7e3d3a7f21db3a675540b757494e6537724b1145 authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Move the message timeout to MessageLoop

b99a3132043c2800ce46bf47bc7703474fb942b9 authored about 5 years ago by Alan McGovern <[email protected]>
[doc] Add another bit to the feature set

ea527251c342028a18d7dedffba64cacec99e5bd authored about 5 years ago by Alan McGovern <[email protected]>
[tests] Add a test covering UDP tracker announces returning peers

15250d1a207c0664d40fae651624913af85a9cbf authored about 5 years ago by Alan McGovern <[email protected]>
[core] Properly handle announce/announce-list when editing torrents

If we used to have a list of trackers and it was removed, ensure
we remove the 'announce-list' k...

52c0c32c70034ae560b9ed8ad8495b10d75faf26 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure we don't double network-convert the connection id

The connection ID should be written in network byte order, which
is handled automatically by the...

210239f883fb59b0ba12296e8737f959ba39d9a9 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Have a reusable method to decode compact peer data

Less code is better!

1d9c7badc151cc1a5d30228df2fb464f00cfb78c authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure UDP tracker Announces handle PeerIds correctly

This needs to be treated as a BEncodedString and not a normal
.NET string

3efc69da1dbb5bb31681650dc4089e24a16d0a39 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Clean up BEncodedString.cs and add a `UrlEncode()` method

e9bfa7d8f405e656d9127ba9308c505cbbb40299 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Fix some more cases of incorrect string/BEncodedString

These should all be maintained as BEncodedStrings so the raw
bytes are never corrupted. The test...

372c39ea0b8f2a3376a4884f4af3ceafc893be73 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure Peer.Decode doesn't corrupt BEncodedStrings

The tracker response should be kept as it's original
BEncodedString instead of being converted t...

b48ee16b63bcf92f3c24728f3df851ec605eed6c authored about 5 years ago by Alan McGovern <[email protected]>
[core] Remove an unused property from PieceMessage

Nothing used DataOffset anymore as the data is always at the start
of the 'Data' byte array.

Ta...

506acd276e2b27d77d7a70cda0b14671021e8430 authored about 5 years ago by Alan McGovern <[email protected]>
[doc] Update the readme again

753dbb0cee4e3dc2c0c021634e63447144346021 authored about 5 years ago by Alan McGovern <[email protected]>
Create CONTRIBUTING.md

8bdbe78082edd9e66e631ffdff65d7efed8c8f51 authored about 5 years ago by Alan McGovern <[email protected]>
Update README.md (#113)

[doc] Update the README with list of implemented BEPs

8949ce69b335759244ad505b9eefe4be63170d68 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Allow nulling out string properties in TorrentEditor

cc190b5801d563994a950b69b435c57a7df90b79 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Try to incrementally hash pieces as they arrive

In the majority case we request blocks (more or less) in order
and so we can hash each block as ...

5fabd3ee3ce451c26c9da60ae5f1580036d955ac authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure EncryptorFactory actually receives the data we requested

If the initial buffer is unencrypted we can return it straight away
if plain text connections ar...

69eaf7b5eb489924f164b0b2bce6bdf6a4ebfc16 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Refactor PeerID out of EncryptorFactory

This is one fewer places where the catch-all 'PeerId' is not
actually needed. This simplifies th...

e0cbf358cfbe76ff9589eedd652080ae73882238 authored about 5 years ago by Alan McGovern <[email protected]>
[test] Ensure connections are disposed if they deadlock

If the test takes more than 5 seconds then let's dispose
the connection and allow the test to fa...

7f98fa014671c3052765ee1233e171f62a5f6e9e authored about 5 years ago by Alan McGovern <[email protected]>
[core] Represent PeerID and TrackerID as a BEncodedString

This can be arbitrary bytes, but must be exactly 20 bytes in length.
As such we should treat it ...

b16816cba3373fedb8ce42dd4a3135ea8703ea6d authored about 5 years ago by Alan McGovern <[email protected]>
[core] Fix a bug from dcd7b5509bb1

The first block when requesting a piece using the fast peer extensions
was silently discarded in...

b777dcb229f8e1ee424742cfe42ffedefb5c5206 authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] User async/await in the HttpTrackerListener

55c8e4d106c249f6b9a3c0c6fea13cdfaabc3d16 authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] Generate useful and random tracker IDs

They indicate that monotorrent is used, the version which is running
and then end in a random un...

49460101cd7c3ea0dacb1aba2cc45f09633f82bb authored about 5 years ago by Alan McGovern <[email protected]>
[tracker] Ensure parameters are url encoded/decoded appropriately

Some tests were added to cover cases where different strings
contained characters which need esc...

02ba386396f4092488b1ceaded48d191c2bf5661 authored about 5 years ago by Alan McGovern <[email protected]>
[build] Use GitInfo to dynamically set the version

15db91d1ca00d9d99f516f57d649779dd6cc2f8b authored about 5 years ago by Alan McGovern <[email protected]>
Move files around some more

6a31bbffc4538f2c60b3a9c0c4633a4f79b9f7aa authored about 5 years ago by Alan McGovern <[email protected]>
Add some more missing license headers on files

691885217530272d1622860e1593542a4bfa211b authored about 5 years ago by Alan McGovern <[email protected]>
[core] MonoTorrentCollection and some enums should be internal

MonoTorrentCollection is not really needed, so hide it so it
can be removed later. Also remove s...

880cd1922ca218f227eb28e22a54eb8fcfd2d6f1 authored about 5 years ago by Alan McGovern <[email protected]>
[build] Remove an old/stale binary

dfbcc08caf904c2cfca1d7fecb5dac7dd7066c99 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Add a factory for creating PeerListeners

115ea40cfec0bc30b29767220875a80afa8a14b4 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Hide more implementations behind interfaces

It's easier to maintain if I don't expose the implementations of
all the listeners as public API...

572c123928dedc0228cd9e4e36ee400b7d0f4fde authored about 5 years ago by Alan McGovern <[email protected]>
[core] Add another overload for TrackerListener.Create

f0c0c93cdaf7b8d61e47ed86d21941e2991ab4a6 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Clean up Cancellation and setting Status for Listeners

Share more code for these common tasks :)

4280202ae4050975f04bd8c1085d86dd23df1b71 authored about 5 years ago by Alan McGovern <[email protected]>
[core] 'Check' should not be a public class

This was just to save some lines of code writing argument null
checkers.

f844e5999de0f46886f6a7573a223c163ccc2f81 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Delete unused files

c12dadebc7344ec4223813bd2352134d12a72676 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Renamespace things into 'MonoTorrent'

Move things from MonoTorrent.Common -> MonoTorrent.

If it's a common type then it should be in ...

edf7c95f765c66fc73c60487bcdccc4b60eec21d authored about 5 years ago by Alan McGovern <[email protected]>
[core] Make all the PeerMessages internal

Users of the library don't need to interact with these at all.

dcd7b5509bb185bac0de6b5d890ca9b52f391679 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Delete LoggingPicker

The tests cover all the cases nowadays, so this shouldn't be needed.

af491b2cc71c3ac389ea878718a6633a77ea8110 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Make the standard messages internal too

392b92e3be2c756cb575dd67f7174e5d3510fb96 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Hide and clean up the impl details of udp tracker messages

ee5336ad71618ee6b366b38c532396946f043d90 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Move some files

8c90a90a271a90ae91e5857c4e1f514b9fead272 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure that MagnetLink has no mutable state

Huzzah!

e97f8656e65eec10608a2454f6ab65afef14809d authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Move IDhtEngine to the Dht namespace

The original reason for this split is that OpenSUSE wanted to ship
a build of MonoTorrent which ...

8db727351eadafb36a86b0208e22c3766ebeb499 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Update the MagnetLink support

The MagnetLink object is immutable. There's a static Parse method
which takes the raw string, an...

d63ec3c159c321df18893cc89a9a79f6ed68805f authored about 5 years ago by Alan McGovern <[email protected]>
[core] Hide the Tracker HTTP/UDP listeners

Expose them as IListener and use ListenerFactory to obtain
either a UDP or HTTP listener. This a...

50f227e26756e6de749eaec6d6fbaef1854cc1b9 authored about 5 years ago by Alan McGovern <[email protected]>
[dht] Re-namespace NullDhtEngine into MonoTorrent.Dht

9c67647b31e953203b8ab94aaa307beea94adfda authored about 5 years ago by Alan McGovern <[email protected]>
[core] Hide some more classes and add missing copyright headers

5e35d947372317ffdebde3215abdb566c2d08a4f authored about 5 years ago by Alan McGovern <[email protected]>
[core] Make an ILocalPeerListener interface

a5c1e4e3fb1eb56662891939d1695b43630d8476 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Rename some tracker interfaces/classes

Change IListener to ITrackerListener so I don't have two different
IListener interfaces in the l...

0212ffadf005855411527c633528bb823f6a1b0d authored about 5 years ago by Alan McGovern <[email protected]>
[core] Move some files around

24d68153eac1920f9cfd6816d5da87a320274cbb authored about 5 years ago by Alan McGovern <[email protected]>
[core] Clean up TrackerTier

Expose the trackers as a readonly IList.

8538a28c04e00cea77d38f84d826eafa41cf7956 authored about 5 years ago by Alan McGovern <[email protected]>
[core] Ensure TrackerManager.CurrentTracker is always non-null

Document this as returning the Tracker which will be used for
Announce/Scrape requests (when no ...

7f48c28a265fbb8d78d67e68962f49c4ac511001 authored about 5 years ago by Alan McGovern <[email protected]>
[build] Add a build badge

ee5429f6a5af11b0deaf9c97090f95300f3200bf authored about 5 years ago by Alan McGovern <[email protected]>