{"id":13622171,"url":"https://github.com/bittorrent/libutp","last_synced_at":"2025-04-08T10:33:10.395Z","repository":{"id":916158,"uuid":"678022","full_name":"bittorrent/libutp","owner":"bittorrent","description":"uTorrent Transport Protocol library","archived":false,"fork":false,"pushed_at":"2023-10-19T22:11:58.000Z","size":273,"stargazers_count":1130,"open_issues_count":50,"forks_count":265,"subscribers_count":129,"default_branch":"master","last_synced_at":"2025-04-01T09:26:51.588Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://github.com/bittorrent/libutp","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bittorrent.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2010-05-20T22:32:57.000Z","updated_at":"2025-03-21T11:56:58.000Z","dependencies_parsed_at":"2023-01-11T16:03:19.046Z","dependency_job_id":"397dec9a-7742-4dd3-99cc-4d3217dacbb8","html_url":"https://github.com/bittorrent/libutp","commit_stats":{"total_commits":139,"total_committers":25,"mean_commits":5.56,"dds":0.4460431654676259,"last_synced_commit":"2b364cbb0650bdab64a5de2abb4518f9f228ec44"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bittorrent%2Flibutp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bittorrent%2Flibutp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bittorrent%2Flibutp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bittorrent%2Flibutp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bittorrent","download_url":"https://codeload.github.com/bittorrent/libutp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247824268,"owners_count":21002240,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T21:01:15.127Z","updated_at":"2025-04-08T10:33:10.357Z","avatar_url":"https://github.com/bittorrent.png","language":"C++","funding_links":[],"categories":["BitTorrent","C++","Uncategorized"],"sub_categories":["Uncategorized"],"readme":"# libutp - The uTorrent Transport Protocol library.\nCopyright (c) 2010 BitTorrent, Inc.\n\nuTP is a TCP-like implementation of [LEDBAT][ledbat] documented as a BitTorrent\nextension in [BEP-29][bep29]. uTP provides reliable, ordered delivery\nwhile maintaining minimum extra delay. It is implemented on top of UDP to be\ncross-platform and functional today. As a result, uTP is the primary transport\nfor uTorrent peer-to-peer connections.\n\nuTP is written in C++, but the external interface is strictly C (ANSI C89).\n\n## The Interface\n\nThe uTP socket interface is a bit different from the Berkeley socket API to\navoid the need for our own select() implementation, and to make it easier to\nwrite event-based code with minimal buffering.\n\nWhen you create a uTP socket, you register a set of callbacks. Most notably, the\non_read callback is a reactive callback which occurs when bytes arrive off the\nnetwork. The write side of the socket is proactive, and you call UTP_Write to\nindicate the number of bytes you wish to write. As packets are created, the\non_write callback is called for each packet, so you can fill the buffers with\ndata.\n\nThe libutp interface is not thread-safe. It was designed for use in a\nsingle-threaded asyncronous context, although with proper synchronization\nit may be used from a multi-threaded environment as well.\n\nSee utp.h for more details and other API documentation.\n\n## Example\n\nSee ucat.c. Build with:\n \n   make ucat\n\n## Building\n\nuTP has been known to build on Windows with MSVC and on linux and OS X with gcc.\nOn Windows, use the MSVC project files (utp.sln, and friends). On other platforms,\nbuilding the shared library is as simple as:\n\n    make\n\nTo build one of the examples, which will statically link in everything it needs\nfrom libutp:\n\n    cd utp_test \u0026\u0026 make\n\n## Packaging and API\n\nThe libutp API is considered unstable, and probably always will be. We encourage\nyou to test with the version of libutp you have, and be mindful when upgrading.\nFor this reason, it is probably also a good idea to bundle libutp with your\napplication.\n\n## License\n\nlibutp is released under the [MIT][lic] license.\n\n## Related Work\n\nResearch and analysis of congestion control mechanisms can be found [here.][survey]\n\n[ledbat]: http://datatracker.ietf.org/wg/ledbat/charter/\n[bep29]: http://www.bittorrent.org/beps/bep_0029.html\n[lic]: http://www.opensource.org/licenses/mit-license.php\n[survey]: http://datatracker.ietf.org/doc/draft-ietf-ledbat-survey/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbittorrent%2Flibutp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbittorrent%2Flibutp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbittorrent%2Flibutp/lists"}