nix2intel

nix2intel

DomainTwistex - Domain name permutation engine in Elixir using Rust NIFs

DomainTwistEx

This library helps organizations protect themselves against several types of domain-based cyber attacks. It specifically looks for:

  • Typosquatting: When attackers register misspelled versions of legitimate domains (like “gooogle[.]com” instead of “google.com”)
  • Phishing Infrastructure: Domains set up to impersonate trusted organizations in email-based attacks
  • Brand Impersonation: Domains created to look like legitimate company websites

How It Works

The library combines Elixir’s powerful ecosystem with Rust’s performance through Rustler NIFs. This makes it particularly effective for scanning and analyzing large numbers of potential threat domains quickly and efficiently.

Features

  • Domain Variation Generator: Creates possible misspellings that attackers might use, including:
    • Missing characters (microsft[.]com)
    • Replaced characters (rnicrosoft[.]com)
    • Extra characters (micrrosoft[.]com)
    • Swapped characters (micrsooft[.]com)
    • Common typing mistakes
    • Look-alike characters (using similar-looking letters)
  • Email Server Detection: Checks if suspicious domains are set up to receive email
  • Fast, Concurrent Analysis: Examines many domains simultaneously for quick results

Contributing

We welcome contributions! You can:

  • Report bugs
  • Suggest new features
  • Submit code changes
  • Help improve documentation

License

BSD-3-Clause

Links

https://github.com/osintowl/domaintwistex

Most Liked

benwilson512

benwilson512

Author of Craft GraphQL APIs in Elixir with Absinthe

Hey @nix2intel can you say a bit more about the package and its uses here in your post?

D4no0

D4no0

I feel using a NIF for this is overkill, as ultimately the bottleneck will be always the requests you send to those permutated domains.

dimitarvp

dimitarvp

What’s the significance of a NIF (Rust) here? Why is it needed?

Last Post!

nix2intel

nix2intel

For anyone interested i made some recent changes, and will be implementing what @filmor just suggested in the coming days, but as an example, I ran this tool against forum.elixirforum.com 's domain and it found this:

  %{
    nameservers: ["ns2.ownidentity.com", "ns1.ownidentity.com"],
    kind: "Tld",
    fqdn: "elixirforum.it",
    ip_addresses: ["217.70.146.10"],
    mx_records: [%{priority: 10, server: "gmail-smtp-in.l.google.com"}],
    resolvable: true,
    server_response: %{
      server: "Microsoft-IIS/10.0",
      headers: %{
        "Accept-Ranges" => "bytes",
        "Connection" => "close",
        "Content-Length" => "444",
        "Content-Type" => "text/html",
        "Date" => "Sat, 18 Jan 2025 00:14:52 GMT",
        "ETag" => "\"0c4edd728bd71:0\"",
        "Last-Modified" => "Thu, 25 Feb 2021 03:46:48 GMT",
        "Server" => "Microsoft-IIS/10.0",
        "X-Powered-By" => "ASP.NET"
      },
      status_code: "200"
    },
    txt_records: [],
    tld: "it"
  },

is it malicious? probably not, but it is something I would potential check mail logs on for elixirforum, the domain is hosting an unconfigured plesk server that may be on a windows machine (always skeptical as I sometimes spoof headers as well) that is configured to use gmail as it’s mail servers. In our environment we’d likely add rules to either block the domain outright to avoid potential business email compromise accounts, or make rules in our organizational email for it. We would also monitor for changes to things like this.

Where Next?

Popular in Announcing Top

mischov
import Meeseeks.CSS html = HTTPoison.get!("https://news.ycombinator.com/").body for story <- Meeseeks.all(html, css("tr.athing")) do...
New
josevalim
Yes, yet another parser combinator library! Most of the parser combinators in the ecosystem are either compile-time, often using AST tra...
159 19834 141
New
josevalim
EDIT: since Ecto 3.0 final version is out, this post was amended to use the final versions in the instructions below. Hi everyone, We a...
New
msaraiva
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
564 44139 214
New
mplatts
With HEEX released we decided to start a components library using Tailwind CSS - check it out here: Petal Components. We also have a boi...
New
zachdaniel
Ash Framework What is Ash? Ash Framework is a declarative, resource-oriented application development framework for Elixir. A resource can...
New
bluzky
You may know https://ui.shadcn.com/, a UI component library for React. I really love it’s design style and components. I’ve built some co...
384 14553 119
New

Other popular topics Top

nobody
Hi! In PHP: $_SERVER[‘SERVER_ADDR’] - in Elixir? Searched the docs for ip address and the web, no good results. Thanks!
New
JeremM34
Hello, how can I check the Phoenix version ? Thanks !
New
sen
Hi All, I set a environment variables in dev.exs , like below code. when i start server, how can i set the ${enable} value? thanks. d...
New
sergio_101
I am VERY much an elixir newbie. I have taken one elixir course and one phoenix course on Udemy. During that course, I saw the instructor...
New
Patoshizzle
After calling mix ecto.create I get this error: 17:00:32.162 [error] GenServer #PID<0.412.0> terminating ** (Postgrex.Error) FATAL...
New
TunkShif
This post is an instruction guide to help you setup your Neovim for Elixir development from scratch. It includes general information on h...
274 42533 114
New

We're in Beta

About us Mission Statement