{"id":13775000,"url":"https://github.com/emileaben/scapy-dns-ninja","last_synced_at":"2025-12-27T11:59:01.684Z","repository":{"id":23389808,"uuid":"26751540","full_name":"emileaben/scapy-dns-ninja","owner":"emileaben","description":"Minimal DNS answering machine, for customized/programmable answers","archived":false,"fork":false,"pushed_at":"2015-02-02T05:02:47.000Z","size":200,"stargazers_count":13,"open_issues_count":0,"forks_count":3,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-08-03T17:11:12.685Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/emileaben.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-11-17T10:22:05.000Z","updated_at":"2021-12-12T21:02:17.000Z","dependencies_parsed_at":"2022-08-22T00:10:34.659Z","dependency_job_id":null,"html_url":"https://github.com/emileaben/scapy-dns-ninja","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/emileaben%2Fscapy-dns-ninja","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emileaben%2Fscapy-dns-ninja/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emileaben%2Fscapy-dns-ninja/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emileaben%2Fscapy-dns-ninja/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/emileaben","download_url":"https://codeload.github.com/emileaben/scapy-dns-ninja/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225027328,"owners_count":17409410,"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-03T17:01:32.606Z","updated_at":"2025-12-27T11:59:01.625Z","avatar_url":"https://github.com/emileaben.png","language":"Python","funding_links":[],"categories":["\u003ca id=\"01f99d208e245eb44f15f720043b50d4\"\u003e\u003c/a\u003eScapy"],"sub_categories":[],"readme":"Scapy experiment for measurement infrastructures (like RIPE Atlas) to probe multiple IP lists.\n\nneeds a local config file called 'ninja-server.conf' in yaml format. Example:\n\n    ---\n    ServerIP: 192.168.0.1\n    ServerDomain: random-ip.emileaben.com\n\nThis code acts as a DNS server, and when it receives an A or AAAA request it returns an IP address from a specified list.\n\nFor DNS A queries lists are called *dests.v4.txt*, for AAAA queries *dests.v6.txt*. If both of these don't exist but a file called *dests.cnames.txt* exists, this file will be used and will generate CNAME redirects towards the hostnames in this file.\n\nIf the server is queried for a label in this form:\n\n    \u003clistname\u003e.\u003cserverdomain\u003e\n\nit will try to find a dests.v[46].txt file in the local \u003clistname\u003e directory, and serve IPs from there.\nIf there is no match it will use the IP-lists file(s) in the `_default` directory.\n\nexample (with config file above):\n\nquery for amsterdam-nl.random-ip.emilaben.com\n\nwill cause the server to look for an ip-list file (either dests.v[46].txt) in the local ./amsterdam-nl/ directory. If it exists it will load it, randomize the list, and serve an IP from it. The next query for this name will get the next IP from the randomized list.\nAt the end of the list, it will be randomized again, and the first IP from the randomized list will be returned again.\n\nINSTALL\n=======\n\nCreate a *ninja-server.conf* file, as explained above, and then run the ./dns-ninja-server.py process. Because this doesn't listen on a UDP port, but sniffs traffic coming in, care should be taken not to send out ICMP destination unreachable messages. For example, Linux/iptables:\n    iptables -I OUTPUT -p icmp --icmp-type destination-unreachable -j DROP\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femileaben%2Fscapy-dns-ninja","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Femileaben%2Fscapy-dns-ninja","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femileaben%2Fscapy-dns-ninja/lists"}