Machinae Security Intelligence Collector
Project description
Codebase - Bring Automater to python3 compatibility while making the code more pythonic
Configuration - Use a more human readable configuration format (YAML)
Inputs - Support JSON parsing out-of-the-box without the need to write regular expressions, but still support regex scraping when needed
Outputs - Support additional output types, including JSON, while making extraneous output optional
Installation
Machinae can be installed using pip3:
pip3 install machinae
Or, if you’re feeling adventurous, can be installed directly from github:
pip3 install git+https://github.com/HurricaneLabs/machinae.git
Configuration File
fortinet_classify: default: true
Or, conversely, to disable a site, such as Virus Total pDNS:
vt_ip: default: false vt_domain: default: false
Usage
Machinae usage is very similar to Automater:
usage: machinae [-h] [-c CONFIG] [-d DELAY] [-f FILE] [--nomerge] [-o {D,J,N}] [-O {ipv4,ipv6,fqdn,email,sslfp,hash,url}] [-q] [-s SITES] targets [targets ...]
See above for details on the -c/--config and --nomerge options.
- Machinae supports a -d/--delay option, like Automater. However, Machinaeuses 0 by default.
Machinae output is controlled by two arguments:
-o controls the output format, and can be followed by a single character to indicated the desired type of output:
N is the default output (“Normal”)
D is the default output, but dot characters are replaced
J is JSON output
-f/--file specifies the file where output should be written. The default is “-” for stdout.
- Machinae will attempt to auto-detect the type of target passed in (Machinaerefers to targets as “observables” and the type as “otype”). This detection canbe overridden with the -O/--otype option. The choices are listed in theusage
- By default, Machinae operates in verbose mode. In this mode, it will outputstatus information about the services it is querying on the console as they arequeried. This output will always be written to stdout, regardless of the outputsetting. To disable verbose mode, use -q
By default, Machinae will run through all services in the configuration that apply to each target’s otype and are not marked as “default: false”. To modify this behavior, you can:
Pass a comma separated list of sites to run (use the top level key from the configuration).
Pass the special keyword all to run through all services including those marked as “default: false”
Note that in both cases, otype validation is still applied.
- Machinae supports passing an HTTP proxy on the command line using the-H/--http-proxy argument. If no proxy is specified, machinae will search thestandard HTTP_PROXY and HTTPS_PROXY environment variables, as well as theless standard http_proxy and https_proxy environment variables.
- Lastly, a list of targets should be passed. All arguments other than theoptions listed above will be interpreted as targets.
Out-of-the-Box Data Sources
Machinae comes with out-of-the-box support for the following data sources:
IPVoid
URLVoid
URL Unshortener (http://www.toolsvoid.com/unshorten-url)
Malc0de
SANS
FreeGeoIP (freegeoip.io)
Fortinet Category
VirusTotal pDNS (via web scrape - commented out)
VirusTotal pDNS (via JSON API)
VirusTotal URL Report (via JSON API)
VirusTotal File Report (via JSON API)
Reputation Authority
ThreatExpert
VxVault
ProjectHoneypot
McAfee Threat Intelligence
StopForumSpam
Cymru MHR
ICSI Certificate Notary
TotalHash (disabled by default)
DomainTools Parsed Whois (Requires API key)
DomainTools Reverse Whois (Requires API key)
DomainTools Reputation
IP WHOIS (Using RIR REST interfaces)
With additional data sources on the way.
HTTP Basic Authentication and Configuration
passivetotal: ['myemail@example.com', 'my_api_key']
Inside the site configuration under request you will see a key such as:
json: request: url: '...' auth: passivetotal
Disabled by default
The following sites are disabled by default
Fortinet Category (fortinet_classify)
Telize Geo IP (telize)
TotalHash (totalhash_ip)
DomainTools Parsed Whois (domaintools_parsed_whois)
DomainTools Reverse Whois (domaintools_reverse_whois)
DomainTools Reputation (domaintools_reputation)
PassiveTotal Passive DNS (passivetotal_pdns)
PassiveTotal Whois (passivetotal_whois)
PassiveTotal SSL Certificate History (passivetotal_sslcert)
PassiveTotal Host Attribute Components (passivetotal_components)
PassiveTotal Host Attribute Trackers (passivetotal_trackers)
MaxMind GeoIP2 Passive Insight (maxmind)
FraudGuard (fraudguard)
Shodan (shodan)
Output Formats
Adding additional sites
*** COMING SOON ***
Known Issues
Some ISP’s on IPvoid contain double-encoded HTML entities, which are not double-decoded
Upcoming Features
Add IDS rule search functionality (VRT/ET)
Add “More info” link for sites
Add “dedup” option to parser settings
Add option for per-otype request settings
Add custom per-site output for error codes
Version History
Version 1.4.0 (2016-04-20)
New features
“-a”/”–auth” option for passing an auth config file
Thanks johannestaas for the submission
“-H”/”–http-proxy” option, and environment support, for HTTP proxies
New sites
Passivetotal (various forms, thanks johannestaas)
MaxMind
FraudGuard
Shodan
Updated sites
FreeGeoIP (replaced freegeoip.net with freegeoip.io)
Version 1.3.4 (2016-04-01)
Bug fixes
Convert exceptions to str when outputting to JSON
Should actually close #14
Version 1.3.3 (2016-03-28)
Bug fixes
Correctly handle error results when outputting to JSON
Closes #14
Thanks Den1al for the bug report
Version 1.3.2 (2016-03-10)
New features
“Short” output mode - simply output yes/no/error for each site
“-i”/”–infile” option for passing a file with list of targets
Version 1.3.1 (2016-03-08)
Version 1.3.0 (2016-03-07)
New sites
Cymon.io - Threat intel aggregator/tracker by eSentire
New features
Support simple paginated responses
Support url encoding ‘target’ in request URL
Support url decoding values in results
Version 1.2.0 (2016-02-16)
New features
Support for sites returning multiple JSON documents
Ability to specify time format for relative time parameters
Ability to parse Unix timestamps in results and display in ISO-8601 format
Ability to specify status codes to ignore per-API
New sites
DNSDB - FarSight Security Passive DNS Data base (premium)
Version 1.1.2 (2015-11-26)
New sites
Telize (premium) - GeoIP site (premium)
Freegeoip - GeoIP site (free)
CIF - CIFv2 API support, from csirtgadgets.org
New features
Ability to specify labels for single-line multimatch JSON outputs
Ability to specify relative time parameters using relatime library
Version 1.0.1 (2015-10-13)
Fixed a false-positive bug with Spamhaus (Github#10)
Version 1.0.0 (2015-07-02)
Initial release
License Info
The MIT License (MIT)
Copyright (c) 2015 Hurricane Labs LLC
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file machinae-1.4.0.tar.gz
.
File metadata
- Download URL: machinae-1.4.0.tar.gz
- Upload date:
- Size: 20.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0dc97e2aa2fe368f16d3333460d1e6e7054e2f0e915bbfe27a6ae34fcceb4da5 |
|
MD5 | 5fd0718e12ee92fec7412149eaff2db7 |
|
BLAKE2b-256 | e132fcf173886cb51cbba843a9eb4e6550d71c8f5f9aefec08dc08359232e022 |