Package: richkit
RichkitRichkit is a python3 package that provides tools taking a domain name as input, and returns addtional information on that domain. It can be an analysis of the domain itself, looked up from data-bases, retrieved from other services, or some combination thereof.The purpose of richkit is to provide a reusable library of domain name-related analysis, lookups, and retrieval functions, that are shared within the Network Security research group at Aalborg University, and also availble to the public for reuse and modification.Documentation can be found athttps://richkit.readthedocs.io/en/latest/.RequirementsPython >= 3.5InstallationIn order to install richikit just type in the terminalpip install richkitUsageThe following codes can be used to retrieve the TLD and the URL category, respectively.Retriving effective top level domain of a given url:>>>fromrichkit.analyseimporttld>>>urls=["www.aau.dk","www.github.com","www.google.com"]>>>>>>forurlinurls:...print(tld(url))dkcomcomRetriving category of a given url:>>>fromrichkit.retrieve.symantecimportfetch_from_internet>>>fromrichkit.retrieve.symantecimportLocalCategoryDB>>>>>>urls=["www.aau.dk","www.github.com","www.google.com"]>>>>>>local_db=LocalCategoryDB()>>>forurlinurls:...url_category=local_db.get_category(url)...ifurl_category=='':...url_category=fetch_from_internet(url)...print(url_category)EducationTechnology/InternetSearchEngines/PortalsModulesRichkit define a set of functions categorized by the following modules:richkit.analyse: This module provides functions that can be applied to a domain  name. Similarly torichkit.lookup, and in contrast torichkit.retrieve, this is done without disclosing the domain name to third parties and breaching confidentiality.richkit.lookup: This modules provides the ability to look up domain names in local resources, i.e. the domain name cannot be sent of to third parties. The module might fetch resources, such as lists or databasese, but this must be done in a way that keeps the domain name confidential. Contrast this withrichkit.retrieve.richkit.retrieve: This module provides the ability to retrieve data on domain names of any sort. It comes without the "confidentiality contract" ofrichkit.lookup.Run Tests on DockerIn order to prevent any problems regarding to environment, we are providingDockerfile.testfile which basically constructs a docker image to run tests of Richkit.The only thing to add is justMAXMIND_LICENCE_KEYin.github/local-test/run-test.shat line 3. It is required to pass the test cases forlookupmodule.Commands to test them in Docker environment.docker build -t richkit-test -f Dockerfile.test .: Builds required image to run test casesdocker run -e MAXMIND_LICENSE_KEY="<licence-key> " richkit-test: Runsrun-test.shfile in Docker image.ContributingContributions are most welcome.We use thegitflowbranching strategy, so if you plan to push a branch to this repository
please follow that. Note that we test branch names with.githooks/check-branch-name.py. The git pre-commit hook can be used
to automatically check this on commit. An example that can be used
directly as follows is available on linux, and can be enabled like
this (assumingpython>=3.6andbash):ln -s $(pwd)/.githooks/pre-commit.linux.sample $(pwd)/.git/hooks/pre-commitCreditsLogo designed byindepedenthand