{"id":20280938,"url":"https://github.com/philipjscott/plisten","last_synced_at":"2026-05-12T14:01:23.579Z","repository":{"id":135378123,"uuid":"162520441","full_name":"philipjscott/plisten","owner":"philipjscott","description":" Register callback functions that trigger on tcp/udp requests.","archived":false,"fork":false,"pushed_at":"2019-01-27T15:31:30.000Z","size":21,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-02T21:53:37.041Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://godoc.org/github.com/ScottyFillups/plisten/pkg/dnsl","language":"Go","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/philipjscott.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-12-20T03:15:20.000Z","updated_at":"2020-05-02T14:09:30.000Z","dependencies_parsed_at":"2023-05-12T17:15:48.351Z","dependency_job_id":null,"html_url":"https://github.com/philipjscott/plisten","commit_stats":null,"previous_names":["scottyfillups/plisten"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/philipjscott/plisten","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philipjscott%2Fplisten","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philipjscott%2Fplisten/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philipjscott%2Fplisten/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philipjscott%2Fplisten/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/philipjscott","download_url":"https://codeload.github.com/philipjscott/plisten/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philipjscott%2Fplisten/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32942147,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-12T09:19:52.626Z","status":"ssl_error","status_checked_at":"2026-05-12T09:17:33.438Z","response_time":102,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":"2024-11-14T13:38:22.159Z","updated_at":"2026-05-12T14:01:23.538Z","avatar_url":"https://github.com/philipjscott.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# plisten\n\nRegister callback functions that trigger on tcp/udp requests. Currently only supports DNS; I may add more functionality in the future.\n\n## Documentation\n\nThe godoc can be found here: https://godoc.org/github.com/ScottyFillups/plisten/pkg/dnsl\n\n## Installation\n\nThe binary provided in `cmd/` is currently just a DNS sniffer that logs requests; in the future I'm considering making a CLI for sniffing different layers (eg. HTTP)\n\n```\ngo get github.com/ScottyFillups/plisten/cmd/plisten\n```\n\nIf `$GOPATH/bin` is in your `$PATH`, then you can invoke the binary:\n\n```\nsudo plisten\n```\n\n## Usage\n\n```go\npackage main\n\nimport (\n\t\"github.com/ScottyFillups/plisten/pkg/dnsl\"\n\t\"fmt\"\n\t\"log\"\n)\n\nfunc logDNSWarn(d *dnsl.DNSListener, match string) {\n\tfmt.Println(\"You visited: \" + match + \". Shouldn't you be working?\")\n}\n\nfunc main() {\n\tdataChan := make(chan dnsl.Packet)\n\tdl := dnsl.New()\n\n\terr := dl.Listen(dataChan)\n\tif err != nil {\n\t\tlog.Fatal(\"Failed to initialize DNS listener\")\n\t}\n\n\terr = dl.Register(\".*facebook.*\", logDNSWarn)\n\tif err != nil {\n\t\tlog.Fatal(\"Failed to compile regexp\")\n\t}\n\n\tfor data := range dataChan {\n\t\tif data.Error != nil {\n\t\t\tfmt.Println(data.Error)\n\t\t\tdl.Close()\n\t\t\tbreak\n\t\t}\n\n\t\tfmt.Println(data.Host)\n\t}\n}\n```\n\nSee `/examples` for more specific and creative usages.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphilipjscott%2Fplisten","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphilipjscott%2Fplisten","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphilipjscott%2Fplisten/lists"}