{"id":31701729,"url":"https://github.com/getlantern/go-natty","last_synced_at":"2025-10-08T21:08:01.081Z","repository":{"id":20639055,"uuid":"23920898","full_name":"getlantern/go-natty","owner":"getlantern","description":"Go language wrapper around the natty NAT-traversal utility","archived":false,"fork":false,"pushed_at":"2018-08-10T08:38:51.000Z","size":109408,"stargazers_count":35,"open_issues_count":5,"forks_count":9,"subscribers_count":18,"default_branch":"master","last_synced_at":"2025-08-15T06:52:06.680Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","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/getlantern.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":"2014-09-11T14:08:37.000Z","updated_at":"2025-02-17T16:06:00.000Z","dependencies_parsed_at":"2022-08-05T09:00:18.649Z","dependency_job_id":null,"html_url":"https://github.com/getlantern/go-natty","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/getlantern/go-natty","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getlantern%2Fgo-natty","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getlantern%2Fgo-natty/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getlantern%2Fgo-natty/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getlantern%2Fgo-natty/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/getlantern","download_url":"https://codeload.github.com/getlantern/go-natty/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getlantern%2Fgo-natty/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000716,"owners_count":26082837,"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-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","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":[],"created_at":"2025-10-08T21:07:57.166Z","updated_at":"2025-10-08T21:08:01.076Z","avatar_url":"https://github.com/getlantern.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"go-natty [![Travis CI Status](https://travis-ci.org/getlantern/go-natty.svg?branch=master)](https://travis-ci.org/getlantern/go-natty)\u0026nbsp;[![Coverage Status](https://coveralls.io/repos/getlantern/go-natty/badge.png)](https://coveralls.io/r/getlantern/go-natty)\u0026nbsp;[![GoDoc](https://godoc.org/github.com/getlantern/go-natty/natty?status.png)](http://godoc.org/github.com/getlantern/go-natty/natty)\n==========\ngo-natty provides a Go wrapper around the\n[natty](https://github.com/getlantern/natty) NAT-traversal utility.\n\nTo install:\n\n`go get github.com/getlantern/go-natty`\n\nFor docs:\n\n[`godoc github.com/getlantern/go-natty/natty`](https://godoc.org/github.com/getlantern/go-natty/natty)\n\n## Embedding Natty\n\nTo build the go files that embed the natty executables for different platforms,\njust place the binaries into the right subfolder of `binaries` and then run\n`embednatty.bash`. This script takes care of code signing the Windows and OS X\nexecutables.\n\nThis script signs the Windows executable, which requires that\n[osslsigncode](http://sourceforge.net/projects/osslsigncode/) utility be\ninstalled. On OS X with homebrew, you can do this with\n`brew install osslsigncode`.\n\nYou will also need to set the environment variables BNS_CERT and BNS_CERT_PASS\nto point to [bns-cert.p12](https://github.com/getlantern/too-many-secrets/blob/master/bns_cert.p12)\nand its [password](https://github.com/getlantern/too-many-secrets/blob/master/build-installers/env-vars.txt#L3)\nso that the script can sign the Windows executable.\n\nThis script also signs the OS X executable, which requires you to our OS X\nsigning certificate, available [here](https://github.com/getlantern/too-many-secrets/blob/master/osx-code-signing-certificate.p12).\nThe password is [here](https://github.com/getlantern/too-many-secrets/blob/master/osx-code-signing-certificate.p12.txt).\n\n## Demo\n\nThere's a [demo application](https://github.com/getlantern/go-natty/tree/master/demo) available.\nYou can build it from inside the demo folder by running `go build .` which will\ncreate a demo executable.\n\nThe client and server signal with each other using\n[waddell](getlantern/waddell) and the client sends UDP packets to the server\nonce NAT-traversal is complete. The client finds the server on waddell using\nits waddell id.\n\n### Example Demo Session\n\n#### Server\n\n```bash\nMacintosh% ./natty-demo-osx -mode server                                                            \n2014/09/16 18:41:36 Starting server, waddell id is \"e6679a41-0003-4f9b-8ae4-671a8a196d13\"\n2014/09/16 18:41:49 Got five tuple: \u0026{udp 192.168.1.160:55285 192.168.1.160:60530}\n2014/09/16 18:41:49 Listening for UDP packets at: 192.168.1.160:55285\n2014/09/16 18:41:49 Got UDP message from 192.168.1.160:60530: 'Hello from 192.168.1.160:60530'\n2014/09/16 18:41:50 Got UDP message from 192.168.1.160:60530: 'Hello from 192.168.1.160:60530'\n2014/09/16 18:41:51 Got UDP message from 192.168.1.160:60530: 'Hello from 192.168.1.160:60530'\n2014/09/16 18:41:52 Got UDP message from 192.168.1.160:60530: 'Hello from 192.168.1.160:60530'\n```\n\nNote - you have to specify the waddell id emitted by the server when running the\nclient.\n\n#### Client\n\n```bash\nMacintosh% ./natty-demo-osx -mode client -server \"e6679a41-0003-4f9b-8ae4-671a8a196d13\"\n2014/09/16 18:41:46 Starting client, connecting to server e6679a41-0003-4f9b-8ae4-671a8a196d13 ...\n2014/09/16 18:41:48 Got five tuple: \u0026{udp 192.168.1.160:60530 192.168.1.160:55285}\n2014/09/16 18:41:49 Sending UDP message: Hello from 192.168.1.160:60530\n2014/09/16 18:41:50 Sending UDP message: Hello from 192.168.1.160:60530\n2014/09/16 18:41:51 Sending UDP message: Hello from 192.168.1.160:60530\n2014/09/16 18:41:52 Sending UDP message: Hello from 192.168.1.160:60530\n```\n\nAcknowledgements:\n\ngo-natty is just a wrapper around [natty](https://github.com/getlantern/natty),\nwhich is itself just a wrapper around the\n[WebRTC Native Code Package](http://www.webrtc.org/webrtc-native-code-package).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgetlantern%2Fgo-natty","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgetlantern%2Fgo-natty","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgetlantern%2Fgo-natty/lists"}