Args
Types
Link copied to clipboard
class AnnouncePeer(val infoHash: Sha1Hash, val port: Int, val token: ByteArray, val impliedPort: Boolean = false, val seed: Boolean = false, val name: String? = null) : DhtMessage.Args
announce_peer {info_hash, port, token, implied_port?, seed?, n?}: BEP-5. When impliedPort is set the responder uses the UDP source port instead of port (a["implied_port"] = 1).
Link copied to clipboard
find_node {target}: BEP-5.
Link copied to clipboard
ping: no arguments beyond id.
Link copied to clipboard
put {token, v, [k, sig, seq, salt, cas]}: BEP-44. item is the value to store; DhtItem.bencodedValue is what travels as a["v"], and the mutable extras (k/sig/seq/salt) come from a MutableItem. cas is the optional compare-and-swap expected sequence number.