-https://doc.libsodium.org/
To Do:
-*hashing/cryptography
-*bencoding/decoding
-*file system
--networking
- -tcp/udp support
--architecture
- -epoll
- -daemonize
- -configuration
- -signal handler for reset/reload
- -threads
- -adding torrents
- -generating pieces/doing hashing
- -network thread(s)
- *logging
--considerations
- -testing network protocols
- -threads
- -memory considerations
- -pieces
- -requests
- -torrents
- -peers
- -rate limiting
- -benchmarking
- -must
- -trackers
- -metrics
-
-Stage 0:
-*priority queue
-*networking
-*session
-peer
- -rate limit interface
- -where to add?
- -handler?
- -each specific request?
- *peer protocol
- *header
- *handshake
- *choke
- *unchoke
- *interested
- *not_interested
- *choke_received
- *unchoke_received
- *interested_received
- *not_interested_received
- *keepalive
- *keepalive_received
- *have
- *have_received
- *bitfield
- *bitfield_received
- *bitfield_toggle
- -decide how and when to send piece rather than hashes
- -do all of one then other
- -alternate
- -FIFO
- -how many of each are common for a torrent?
- -measure? LATER?
- -request
- -request_receivied
- -piece
+ -piece - HERE
-piece_received
-no-op, should just discard and should never receive
-cancel
-hashes_received
-hash_reject
-hash_reject_received
+ -rate limit interface
+ -where to add?
+ -handler?
+ -each specific request?
+ -queue
+ -decide on split process
+ -all of pieces, then hashes?
+ -alternating? bool flag stored in struct peer
-tests
-header
-handshake
-init/free
-send/receive
-toggle/has
+ -request
+-refactor pqueue
+ -use?
+ -access with hashmap
+ -pqueue only for pieces loaded in memory?
+ -load up pieces in memory and add to pqueue
+ -once reach max size, start removing least accessed
-tests
-watch
-refactor
-distinct directories per test
-generate man page
-document cli/config options
+-configuration reload
Stage 1:
-basic bittorrent functionality