malwaredb / malwaredb-rs

MalwareDB: bookkeeping for malware, goodware, and unknown files with relationship discovery
https://malwaredb.net/
Apache License 2.0
28 stars 4 forks source link
cybersecurity forensics-tools hacktoberfest malware malware-analysis malware-research

MalwareDB

TestLintCrossCrates.io VersionOpenSSF ScorecardOpenSSF Best Practices

Inspired by VXCage and VirusTotal, MalwareDB is a malware knowledge management system which handles the bookkeeping regarding malware/goodware samples: hashes, origination, similarity, file types, and more. Its intention is to help malware/cybersecurity researchers, forensic investigators, and others who have a need to handle malware, or other files of potentially unknown origin. This is very much a work in progress and alpha-quality project at present.

Key Features:

Requirements:

Status

This project is in active development and not yet stable, nor are all the features implemented.

Installation

Install from source. Check out the repository and build (recommended), or build from crates.io:

Server Features (which are all opt-in):

Future

Getting Started:

  1. Compile from source, ideally with --features=admin,sqlite.
  2. Create your configuration file. Compile with the sqlite feature to use SQLite. This is more for testing and evaluation than using in a real environment. See the example file in the root of the repository for an example.
    • If the storage section is empty (it's optional), then MalwareDB will only store the metadata about the files, and will not store the samples. That means getting the original file will not be available.
  3. Place the config file in /etc/mdb_server/mdb_config.toml on Linux, or /usr/local/etc/mdb_server/mdb_config.toml on FreeBSD for automatic config file detection. Otherwise, run with mdb_server run load /path/to/file, or mdb_server run config to specify arguments on the command line. Run with --help to see details.

Administrative Items

  1. Since you compiled with the admin feature above, you can run mdb_server admin --help to see administrative options. Admin options require -c /path/to/config.toml to prevent making accidental changes. Note: using the admin command interactions with the database directly, so the server does not need to be running.
  2. List users with: mdb_server admin -c /path/to/config.toml list users. There is a default admin user, but no password is set. So let's set one.
  3. Reset Admin's password: mdb_server admin -c /path/to/config.toml reset-password --uname admin. You'll be prompted for the password and it won't echo. The admin user doesn't do anything special at the moment, but that will change.
  4. File are organized by sources, and groups have access to sources. So groups and sources must be added and linked to be able to add files.
    • Create a source, look at the command line options: mdb_server admin -c /path/to/config.toml create source --help
    • Create a group, look at the command line options: mdb_server admin -c /path/to/config.toml create group --help
    • Add the group to the source, look at the command line options: mdb_server admin -c /path/to/config.toml add-group-to-source --help
    • Add the user to the group, look at the command line options: mdb_server admin -c /path/to/config.toml add-user-to-group --help
  5. Now, use the client to login with mdb_client while mdb_server is running: mdb_client login http://localhost:8080 admin, replacing the URL with the actual IP and port you chose in the server configuration file.
  6. Test that the client works with mdb_client whoami, it should show the user information and available groups and sources.

Loading Files

Downloading Files

Searching for Similar Files

Misc. Client Commands

Goals

Some overall goals and design: