{"id":23007438,"url":"https://github.com/xor-bits/eznet","last_synced_at":"2025-07-23T14:34:17.993Z","repository":{"id":44372092,"uuid":"455544857","full_name":"xor-bits/eznet","owner":"xor-bits","description":"a simple net lib","archived":false,"fork":false,"pushed_at":"2023-01-05T05:38:57.000Z","size":163,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-11T22:03:10.795Z","etag":null,"topics":["asynchronous","network-programming"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xor-bits.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-02-04T12:47:50.000Z","updated_at":"2022-07-10T13:17:54.000Z","dependencies_parsed_at":"2023-02-03T13:45:26.299Z","dependency_job_id":null,"html_url":"https://github.com/xor-bits/eznet","commit_stats":null,"previous_names":["overpeek/eznet"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/xor-bits/eznet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xor-bits%2Feznet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xor-bits%2Feznet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xor-bits%2Feznet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xor-bits%2Feznet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xor-bits","download_url":"https://codeload.github.com/xor-bits/eznet/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xor-bits%2Feznet/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266694573,"owners_count":23969795,"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","status":"online","status_checked_at":"2025-07-23T02:00:09.312Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["asynchronous","network-programming"],"created_at":"2024-12-15T08:15:37.445Z","updated_at":"2025-07-23T14:34:17.969Z","avatar_url":"https://github.com/xor-bits.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n# eznet\n\neasy net lib\n\n[![dependency status](https://deps.rs/repo/github/Overpeek/eznet/status.svg)](https://deps.rs/repo/github/Overpeek/eznet)\n[![build status](https://github.com/Overpeek/eznet/actions/workflows/rust.yml/badge.svg)](https://github.com/Overpeek/eznet/actions)\n[![crates.io](https://img.shields.io/crates/v/eznet.svg?label=eznet)](https://crates.io/crates/eznet)\n[![docs.rs](https://docs.rs/eznet/badge.svg)](https://docs.rs/eznet/)\n\n\u003c/div\u003e\n\n[ENet](http://enet.bespin.org/)/[laminar](https://github.com/TimonPost/laminar)\nstyle, [Quinn](https://github.com/quinn-rs/quinn) ([QUIC](https://en.wikipedia.org/wiki/QUIC))\nbased, simple to use and async net lib with configurable reliability and ordering.\n\n## Features:\n\n- Packets are encrypted (but not really securely [TODO](#todo): 1)\n\n- Reliable ordered, reliable sequenced, reliable unordered, unreliable sequenced and unreliable unordered packets\n\n- Easy to use\n\n- Async/await\n\n## Example:\n\n```rust\n// examples/simple-server.rs\nlet mut listener = Listener::bind(\"127.0.0.1:13331\".parse().unwrap()).unwrap();\n\nwhile let Ok(socket) = listener.next().await {\n    socket\n        .send(Packet::ordered(format!(\"Hello {}!\", socket.remote()), None))\n        .await\n        .unwrap();\n}\n\n// examples/simple-client.rs\nlet mut socket = Socket::connect(\"127.0.0.1:13331\".parse().unwrap())\n    .await\n    .unwrap();\n\nprintln!(\n    \"{}\",\n    std::str::from_utf8(\u0026socket.recv().await.unwrap().bytes[..]).unwrap()\n);\n```\n\n## TODO:\n\n- [ ] Encryption doesn't protect\n      from MITM attacks at the moment.\n      Only self signed server side\n      certificates are used and clients\n      accept everything. Add certificates,\n      private keys, server names and DNS. (1)\n\n- [x] Open socket magic byte test to\n      filter out random scanners and\n      'accidental' connections. (2)\n\n- [ ] Disconnect message when closing. (3)\n\n- [ ] Configurable buffer capacity. (4)\n\n- [x] if packets are sent slightly faster\n      than once per millisecond, none of them\n      get actually sent, all of them are buffered. (5)\n\n- [x] actually drop 'old' sequenced packets (6)\n\n- [ ] list of breaking versions and\n      testing it when filtering (7)\n\n- [ ] More unit tests\n\n- [ ] Socket events. (Disconnect, Timeout, Packet, ...)\n\n## License\n\nLicensed under either of [MIT license](LICENSE-MIT) or [Apache-2.0](LICENSE-APACHE) license.\n\nI am not a lawyer.\n\n## MSRV\n\nCurrently the Minimum Supported Rust Version is **1.58**.\nI do not care to 'minimize' this and it is what it is.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxor-bits%2Feznet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxor-bits%2Feznet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxor-bits%2Feznet/lists"}