{"id":16991032,"url":"https://github.com/gin66/mac_utun","last_synced_at":"2025-03-22T15:30:57.792Z","repository":{"id":57635984,"uuid":"111987012","full_name":"gin66/mac_utun","owner":"gin66","description":"Create macOS utun device from rust","archived":false,"fork":false,"pushed_at":"2019-01-20T08:53:17.000Z","size":10,"stargazers_count":23,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-18T13:16:05.848Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","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/gin66.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}},"created_at":"2017-11-25T08:01:52.000Z","updated_at":"2024-09-05T16:00:02.000Z","dependencies_parsed_at":"2022-09-26T20:21:24.127Z","dependency_job_id":null,"html_url":"https://github.com/gin66/mac_utun","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gin66%2Fmac_utun","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gin66%2Fmac_utun/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gin66%2Fmac_utun/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gin66%2Fmac_utun/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gin66","download_url":"https://codeload.github.com/gin66/mac_utun/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244978500,"owners_count":20541862,"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-10-14T03:24:37.639Z","updated_at":"2025-03-22T15:30:57.436Z","avatar_url":"https://github.com/gin66.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mac_utun\n\nCreate utun device on macos.\n\n## Usage\n\nIn Cargo.toml include:\n\n```\nmac_utun = \"0.6\"\n```\n\nImport the get_utun function:\n\n``` Rust\nuse mac_utun::get_utun;\n```\n\nJust need to call this function. It will search for the first available utun-device\nstarting from 0. As you may know, root permission is necessary to create a utun-device.\n\n``` Rust\npub fn get_utun() -\u003e Result\u003c(UdpSocket,String)\u003e\n```\n\nIn case of error, the last OS-Error will be returned.\nIn case of success, an UDP-socket and the interface name (e.g. \"utun0\") will be returned.\n\nUDP-socket is a nice choice, because rust will perform the necessary clean up itself.\n\n## Test\n\nThere is only one test case defined:\n\nIt checks the list of network interfaces before, during and after utun is opened.\nExpected behaviour: The returned utun is only in the list _during_ utun is opened.\n\n## Contributions\n\nThanks for pull request from [Feng Yingcai](https://github.com/fengyc)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgin66%2Fmac_utun","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgin66%2Fmac_utun","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgin66%2Fmac_utun/lists"}