See through all Border Gateway Protocol (BGP) data with a monocle.
cargo install monoclebrew install monocleUsing cargo-binstall
Install cargo-binstall first:
cargo install cargo-binstallThen install monocle using cargo binstall
cargo binstall monoclePull the pre-built image or build locally:
# Build the image locally
docker build -t bgpkit/monocle:latest .
# Or use docker compose
docker compose buildRun monocle commands:
# Show help
docker run --rm bgpkit/monocle:latest
# Run a command (e.g., inspect an ASN)
docker run --rm bgpkit/monocle:latest inspect 13335
# Run with persistent data directory
docker run --rm -v monocle-data:/data bgpkit/monocle:latest inspect 13335
# Start the WebSocket server
docker run --rm -p 8080:8080 -v monocle-data:/data bgpkit/monocle:latest server --address 0.0.0.0 --port 8080
# Using docker compose for server mode
docker compose up -dMonocle can also be used as a library in your Rust projects. Add it to your Cargo.toml:
[dependencies]
# Default: full CLI binary with all features
monocle = "1.1"
# Library only - all lenses and database operations
monocle = { version = "1.1", default-features = false, features = ["lib"] }
# Library + WebSocket server
monocle = { version = "1.1", default-features = false, features = ["server"] }Monocle uses a simplified feature system with three options:
| Feature | Description | Implies |
|---|---|---|
lib |
Complete library (database + all lenses + display) | - |
server |
WebSocket server for programmatic API access | lib |
cli (default) |
Full CLI binary with all functionality | lib, server |
The following documentation files are available in the repository:
| File | Description |
|---|---|
README.md (this file) |
User-facing CLI and library overview |
ARCHITECTURE.md |
Overall project structure and design principles |
DEVELOPMENT.md |
Contributor guide for adding lenses and fixing bugs |
AGENTS.md |
AI coding agent guidelines and code style |
CHANGELOG.md |
Version history and breaking changes |
src/server/README.md |
WebSocket API specification |
src/lens/README.md |
Lens module patterns and conventions |
src/database/README.md |
Database module overview |
examples/README.md |
Usage examples by feature tier |
The library is organized into the following core modules:
-
database: All database functionality (requireslibfeature)core: Connection management and schema definitionssession: One-time storage for search resultsmonocle: Main monocle database with ASInfo, AS2Rel, RPKI, and Pfx2as caching
-
lens: High-level business logic (requireslibfeature)time: Time parsing and formatting lenscountry: Country code/name lookup lensip: IP information lookup lensparse: MRT file parsing lens with progress trackingsearch: BGP message search lens with progress trackingrpki: RPKI validation and data lenspfx2as: Prefix-to-AS mapping typesas2rel: AS-level relationships lensinspect: Unified AS/prefix inspection lens
-
server: WebSocket API server (requiresserverfeature)
For detailed architecture documentation, see ARCHITECTURE.md.
use monocle::database::MonocleDatabase;
use monocle::lens::inspect::{InspectLens, InspectQueryOptions};
fn main() -> anyhow::Result<()> {
// Open the monocle database
let db = MonocleDatabase::open_in_dir("~/.local/share/monocle")?;
// Create a lens
let lens = InspectLens::new(&db);
// Query AS information
let options = InspectQueryOptions::default();
let results = lens.query_asn(13335, &options)?;
println!("AS{}: {}", results.asn, results.name.unwrap_or_default());
Ok(())
}use monocle::lens::parse::{ParseLens, ParseFilters, ParseProgress};
use std::sync::Arc;
fn main() -> anyhow::Result<()> {
let lens = ParseLens::new();
let filters = ParseFilters::default();
// Define a progress callback
let callback = Arc::new(|progress: ParseProgress| {
match progress {
ParseProgress::Started { file_path } => {
eprintln!("Started parsing: {}", file_path);
}
ParseProgress::Update { messages_processed, rate, .. } => {
eprintln!("Processed {} messages ({:.0} msg/s)",
messages_processed, rate.unwrap_or(0.0));
}
ParseProgress::Completed { total_messages, duration_secs, .. } => {
eprintln!("Completed: {} messages in {:.2}s", total_messages, duration_secs);
}
}
});
// Parse with progress tracking
let elems = lens.parse_with_progress(
&filters,
"path/to/file.mrt",
Some(callback)
)?;
for elem in elems {
println!("{:?}", elem);
}
Ok(())
}Subcommands:
parse: parse individual MRT filessearch: search for matching messages from all available public MRT filesserver: start a WebSocket server for programmatic accessinspect: unified AS and prefix information lookupcountry: utility to look up country name and codetime: utility to convert time between unix timestamp and RFC3339 stringas2rel: AS-level relationship lookup between ASNspfx2as: prefix-to-ASN mapping lookup with RPKI validationrpki: RPKI validation and ROA/ASPA listingip: IP information lookupconfig: configuration display and database management (refresh, backup, sources)
All commands support the following global options:
--format <FORMAT>: Output format (table, markdown, json, json-pretty, json-line, psv)--json: Shortcut for--format json-pretty--debug: Print debug information
Top-level help menu:
โ monocle --help
A commandline application to search, parse, and process BGP information in public sources.
Usage: monocle [OPTIONS] <COMMAND>
Commands:
parse Parse individual MRT files given a file path, local or remote
search Search BGP messages from all available public MRT files
server Start the WebSocket server (ws://<address>:<port>/ws, health: http://<address>:<port>/health)
inspect Unified AS and prefix information lookup
country Country name and code lookup utilities
time Time conversion utilities
rpki RPKI utilities
ip IP information lookup
as2rel AS-level relationship lookup between ASNs
pfx2as Prefix-to-ASN mapping lookup
config Show monocle configuration, data paths, and database management
help Print this message or the help of the given subcommand(s)
Options:
-c, --config <CONFIG> configuration file path (default: $XDG_CONFIG_HOME/monocle/monocle.toml)
--debug Print debug information
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Parsing a single MRT file given a local path or a remote URL.
โ monocle parse --help
Parse individual MRT files given a file path, local or remote
Usage: monocle parse [OPTIONS] <FILE>
Arguments:
<FILE>
File path to an MRT file, local or remote
Options:
--pretty
Pretty-print JSON output
--debug
Print debug information
-M, --mrt-path <MRT_PATH>
MRT output file path
-f, --fields <FIELDS>
Comma-separated list of fields to output. Available fields: type, timestamp, peer_ip, peer_asn, prefix, as_path, origin, next_hop, local_pref, med, communities, atomic, aggr_asn, aggr_ip, collector
--format <FORMAT>
Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json
Output as JSON objects (shortcut for --format json-pretty)
--order-by <ORDER_BY>
Order output by field (enables buffering)
Possible values:
- timestamp: Order by timestamp (default)
- prefix: Order by network prefix
- peer_ip: Order by peer IP address
- peer_asn: Order by peer AS number
- as_path: Order by AS path (string comparison)
- next_hop: Order by next hop IP address
--no-update
Disable automatic database updates (use existing cached data only)
--order <ORDER>
Order direction (asc or desc, default: asc)
Possible values:
- asc: Ascending order (smallest/oldest first)
- desc: Descending order (largest/newest first)
[default: asc]
--time-format <TIME_FORMAT>
Timestamp output format for non-JSON output (unix or rfc3339)
Possible values:
- unix: Unix timestamp (integer or float) - default for backward compatibility
- rfc3339: RFC3339/ISO 8601 format (e.g., "2023-10-11T15:00:00Z")
[default: unix]
-o, --origin-asn <ORIGIN_ASN>
Filter by origin AS Number(s), comma-separated. Prefix with ! to exclude
-p, --prefix <PREFIX>
Filter by network prefix(es), comma-separated. Prefix with ! to exclude
-s, --include-super
Include super-prefixes when filtering
-S, --include-sub
Include sub-prefixes when filtering
-j, --peer-ip <PEER_IP>
Filter by peer IP address(es)
-J, --peer-asn <PEER_ASN>
Filter by peer ASN(s), comma-separated. Prefix with ! to exclude
-C, --community <COMMUNITIES>
Filter by BGP community value(s), comma-separated (`A:B` or `A:B:C`). Each part can be a number or `*` wildcard (e.g., `*:100`, `13335:*`, `57866:104:31`). Prefix with ! to exclude
[aliases: --communities]
-m, --elem-type <ELEM_TYPE>
Filter by elem type: announce (a) or withdraw (w)
Possible values:
- a: BGP announcement
- w: BGP withdrawal
-t, --start-ts <START_TS>
Filter by start unix timestamp inclusive
-T, --end-ts <END_TS>
Filter by end unix timestamp inclusive
-d, --duration <DURATION>
Duration from the start-ts or end-ts, e.g. 1h
-a, --as-path <AS_PATH>
Filter by AS path regex string
-h, --help
Print help (see a summary with '-h')
-V, --version
Print version
The parse and search commands support filtering by multiple values with OR logic:
# Match elements from ANY of the specified origin ASNs
monocle parse file.mrt -o 13335,15169,8075
# Match ANY of the specified prefixes
monocle parse file.mrt -p 1.1.1.0/24,8.8.8.0/24
# Match elements from ANY of the specified peer ASNs
monocle parse file.mrt -J 174,2914Use the ! prefix to exclude values:
# Exclude elements from AS13335
monocle parse file.mrt -o '!13335'
# Exclude elements from AS13335 AND AS15169
monocle parse file.mrt -o '!13335,!15169'Note: Cannot mix positive and negative values in the same filter.
Use -f or --fields to select which columns to display:
# Show only prefix, as_path, and origin
monocle parse file.mrt -f prefix,as_path,origin
# Available fields: type, timestamp, peer_ip, peer_asn, prefix, as_path, origin,
# next_hop, local_pref, med, communities, atomic, aggr_asn, aggr_ip, collectorUse --order-by and --order to sort the output:
# Sort by timestamp ascending (default)
monocle parse file.mrt --order-by timestamp
# Sort by prefix descending
monocle parse file.mrt --order-by prefix --order descUse --time-format to change timestamp output format:
# Unix timestamp (default)
monocle parse file.mrt --time-format unix
# RFC3339/ISO 8601 format
monocle parse file.mrt --time-format rfc3339Example: parse a remote MRT file and show only announcements for a specific prefix:
โ monocle parse https://data.ris.ripe.net/rrc00/2024.01/updates.20240101.0000.gz \
-p 1.1.1.0/24 -m a | head -5
โโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโฌโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโฌโโโโโโโโโโโโโโฌโโโโโโโโโฌโโโโโโโโโโโฌโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโ
โ type โ timestamp โ peer_ip โ peer_asn โ prefix โ as_path โ origin โ origin_asns โ next_hop โ local_pref โ med โ communities โ atomic โ aggr_asn โ aggr_ip โ only_to_customer โ unknown โ deprecated โ collector โ
โโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโผโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโผโโโโโโโโโโโโโโผโโโโโโโโโผโโโโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโค
โ announce โ 2024-01-01 00:00:44 โ 2001:7f8:4::9d85:1 โ 40325 โ 1.1.1.0/24 โ 40325 13335 โ IGP โ 13335 โ 2001:7f8:4::9d85:1 โ โ โ โ false โ โ โ โ โ โ โ
โ announce โ 2024-01-01 00:00:50 โ 2001:7f8:4::3:2e8b:1 โ 208571 โ 1.1.1.0/24 โ 208571 6939 13335 โ IGP โ 13335 โ 2001:7f8:4::3:2e8b:1 โ โ โ โ false โ โ โ โ โ โ โ
The output contains the following fields:
| Field | Description |
|---|---|
type |
Message type: announce or withdraw |
timestamp |
Message timestamp in UTC |
peer_ip |
IP address of the BGP peer |
peer_asn |
ASN of the BGP peer |
prefix |
Network prefix being announced/withdrawn |
as_path |
AS path (space-separated) |
origin |
Origin type: IGP, EGP, or INCOMPLETE |
origin_asns |
Origin AS number(s) |
next_hop |
Next hop IP address |
local_pref |
Local preference value |
med |
Multi-exit discriminator |
communities |
BGP communities |
atomic |
Atomic aggregate flag |
aggr_asn |
Aggregator ASN |
aggr_ip |
Aggregator IP |
only_to_customer |
OTC attribute (RFC 9234) |
unknown |
Unknown attributes |
deprecated |
Deprecated attributes |
collector |
Collector name (for search results) |
JSON output example:
{
"type": "announce",
"timestamp": "2024-01-01T00:00:44Z",
"peer_ip": "2001:7f8:4::9d85:1",
"peer_asn": 40325,
"prefix": "1.1.1.0/24",
"as_path": "40325 13335",
"origin": "IGP",
"origin_asns": [13335],
"next_hop": "2001:7f8:4::9d85:1",
"local_pref": null,
"med": null,
"communities": [],
"atomic": false,
"aggr_asn": null,
"aggr_ip": null,
"only_to_customer": null,
"unknown": null,
"deprecated": null,
"collector": null
}Search for BGP messages from all available public MRT files using BGPKIT Broker.
โ monocle search --help
Search BGP messages from all available public MRT files
Usage: monocle search [OPTIONS]
Options:
--dry-run
Dry-run, do not download or parse
--debug
Print debug information
--sqlite-path <SQLITE_PATH>
SQLite output file path
--format <FORMAT>
Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
-M, --mrt-path <MRT_PATH>
MRT output file path
--json
Output as JSON objects (shortcut for --format json-pretty)
--sqlite-reset
SQLite reset database content if exists
--broker-files
Output matching broker files (URLs) and exit without searching
--no-update
Disable automatic database updates (use existing cached data only)
-f, --fields <FIELDS>
Comma-separated list of fields to output. Available fields: type, timestamp, peer_ip, peer_asn, prefix, as_path, origin, next_hop, local_pref, med, communities, atomic, aggr_asn, aggr_ip, collector
--order-by <ORDER_BY>
Order output by field (enables buffering)
Possible values:
- timestamp: Order by timestamp (default)
- prefix: Order by network prefix
- peer_ip: Order by peer IP address
- peer_asn: Order by peer AS number
- as_path: Order by AS path (string comparison)
- next_hop: Order by next hop IP address
--order <ORDER>
Order direction (asc or desc, default: asc)
Possible values:
- asc: Ascending order (smallest/oldest first)
- desc: Descending order (largest/newest first)
[default: asc]
--time-format <TIME_FORMAT>
Timestamp output format for non-JSON output (unix or rfc3339)
Possible values:
- unix: Unix timestamp (integer or float) - default for backward compatibility
- rfc3339: RFC3339/ISO 8601 format (e.g., "2023-10-11T15:00:00Z")
[default: unix]
--use-cache
Use the default XDG cache directory ($XDG_CACHE_HOME/monocle) for MRT files. Overridden by --cache-dir if both are specified
--cache-dir <CACHE_DIR>
Override cache directory for downloaded MRT files. Files are stored as {cache-dir}/{collector}/{path}. If a file already exists in cache, it will be used instead of downloading
-o, --origin-asn <ORIGIN_ASN>
Filter by origin AS Number(s), comma-separated. Prefix with ! to exclude
-p, --prefix <PREFIX>
Filter by network prefix(es), comma-separated. Prefix with ! to exclude
-s, --include-super
Include super-prefixes when filtering
-S, --include-sub
Include sub-prefixes when filtering
-j, --peer-ip <PEER_IP>
Filter by peer IP address(es)
-J, --peer-asn <PEER_ASN>
Filter by peer ASN(s), comma-separated. Prefix with ! to exclude
-C, --community <COMMUNITIES>
Filter by BGP community value(s), comma-separated (`A:B` or `A:B:C`). Each part can be a number or `*` wildcard (e.g., `*:100`, `13335:*`, `57866:104:31`). Prefix with ! to exclude
[aliases: --communities]
-m, --elem-type <ELEM_TYPE>
Filter by elem type: announce (a) or withdraw (w)
Possible values:
- a: BGP announcement
- w: BGP withdrawal
-t, --start-ts <START_TS>
Filter by start unix timestamp inclusive
-T, --end-ts <END_TS>
Filter by end unix timestamp inclusive
-d, --duration <DURATION>
Duration from the start-ts or end-ts, e.g. 1h
-a, --as-path <AS_PATH>
Filter by AS path regex string
-c, --collector <COLLECTOR>
Filter by collector, e.g., rrc00 or route-views2
-P, --project <PROJECT>
Filter by route collection project, i.e., riperis or routeviews
-D, --dump-type <DUMP_TYPE>
Specify data dump type to search (updates or RIB dump)
Possible values:
- updates: BGP updates only
- rib: BGP RIB dump only
- rib-updates: BGP RIB dump and BGP updates
[default: updates]
-h, --help
Print help (see a summary with '-h')
-V, --version
Print version
Enable local caching with --use-cache (default XDG cache path) or --cache-dir (custom path):
# Cache MRT files under $XDG_CACHE_HOME/monocle
monocle search -t 2024-01-01 -d 1h -p 1.1.1.0/24 --use-cache
# Cache MRT files to a custom directory
monocle search -t 2024-01-01 -d 1h -p 8.8.8.0/24 --cache-dir /tmp/mrt-cache
# --cache-dir overrides --use-cache when both are specified
monocle search -t 2024-01-01 -d 1h -p 8.8.8.0/24 --use-cache --cache-dir /tmp/mrt-cacheFeatures:
- Files are cached as
{cache-dir}/{collector}/{path}(e.g.,cache/rrc00/2024.01/updates.20240101.0000.gz) - Uses
.partialextension during downloads to handle interrupted transfers - Broker query caching: When caching is enabled (
--use-cacheor--cache-dir), broker API results are cached in SQLite at{cache-dir}/broker-cache.sqlite3 - Default cache path for
--use-cacheis$XDG_CACHE_HOME/monocle(fallback:~/.cache/monocle) - Only queries with end time >2 hours in the past are cached (recent data may still change)
- Enables offline operation: run search once with network, then run same search again without network using cached results
Example: search for BGP announcements for a prefix during a specific time window:
โ monocle search -t 2024-01-01T00:00:00Z -T 2024-01-01T00:01:00Z \
-c rrc00 -p 1.1.1.0/24 -m a
Use --broker-files to see the list of MRT files that would be queried without actually parsing them:
โ monocle search -t 2024-01-01T00:00:00Z -T 2024-01-01T01:00:00Z \
-c rrc00 --broker-files
Parse and convert time strings between various formats.
โ monocle time --help
Time conversion utilities
Usage: monocle time [OPTIONS] [TIME]...
Arguments:
[TIME]... Time stamp or time string to convert
Options:
-s, --simple Simple output, only print the converted time (RFC3339 format)
--debug Print debug information
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Examples:
โ monocle time 1704067200
โโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ unix โ rfc3339 โ human โ
โโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ 1704067200 โ 2024-01-01T00:00:00Z โ Mon, Jan 1, 2024 at 12:00:00 AM UTC โ
โโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ monocle time "2024-01-01T00:00:00Z"
โโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ unix โ rfc3339 โ human โ
โโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ 1704067200 โ 2024-01-01T00:00:00Z โ Mon, Jan 1, 2024 at 12:00:00 AM UTC โ
โโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ monocle time "yesterday" "last week"
Unified AS and prefix information lookup. Replaces the former whois and pfx2as commands.
By default, inspect shows all available information for ASN and prefix queries, including:
- Basic: AS name, country, organization, and PeeringDB info (website, IRR AS-SET)
- Prefixes: Announced prefixes with RPKI validation status
- Connectivity: AS relationships (upstreams, peers, downstreams)
- RPKI: ROAs and ASPA records
When querying multiple ASNs, a glance table is automatically shown first, providing a quick overview of all queried ASNs before the detailed per-ASN information.
โ monocle inspect --help
Unified AS and prefix information lookup
Usage: monocle inspect [OPTIONS] [QUERY]...
Arguments:
[QUERY]... One or more queries: ASN (13335, AS13335), prefix (1.1.1.0/24), IP (1.1.1.1), or name (cloudflare)
Options:
-a, --asn Force treat queries as ASNs
--debug Print debug information
-p, --prefix Force treat queries as prefixes
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
-n, --name Force treat queries as name search
-c, --country <COUNTRY> Search by country code (e.g., US, DE)
--json Output as JSON objects (shortcut for --format json-pretty)
--no-update Disable automatic database updates (use existing cached data only)
--show <SECTION> Select data sections to display (can be repeated). Overrides defaults. Available: basic, prefixes, connectivity, rpki, all
--full Show all data sections with no limits
--full-roas Show all RPKI ROAs (default: top 10)
--full-prefixes Show all prefixes (default: top 10)
--full-connectivity Show all neighbors (default: top 5 per category)
--limit <N> Limit search results (default: 20)
-u, --update Force refresh the asinfo database
-h, --help Print help
-V, --version Print version
Examples:
# Look up AS by number (shows all information by default)
โ monocle inspect 13335
Query: 13335 (type: asn)
โโโ Basic Information โโโ
ASN: AS13335
Name: CLOUDFLARENET
Country: US
Org: Cloudflare, Inc.
Org ID: CLOUD14-ARIN
Website: https://www.cloudflare.com
AS-SET: AS13335:AS-CLOUDFLARE
โโโ Announced Prefixes โโโ
Total: 5526 (2409 IPv4, 3117 IPv6)
RPKI Validation: valid 5071 (91.8%), invalid 1 (0.0%), unknown 454 (8.2%)
โญโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโฎ
โ Prefix โ Validation โ
โโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโค
โ 103.186.74.0/24 โ unknown โ
โ ... โ ... โ
โฐโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโฏ
(showing 10 of 5526 prefixes, use --full-prefixes to show all)
โโโ Connectivity โโโ
...
(results truncated, use --full-connectivity to show all)
โโโ RPKI โโโ
ROAs: 4420 total (2754 IPv4, 1666 IPv6)
...
(ROA list truncated, use --full-roas to show all)
# Query multiple ASNs (glance table shown first)
โ monocle inspect 13335 15169
โโโ Glance โโโ
โญโโโโโโโโโโฌโโโโโโโโโโโโโโโโฌโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโฎ
โ ASN โ Name โ Country โ Org โ
โโโโโโโโโโโผโโโโโโโโโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโค
โ AS13335 โ CLOUDFLARENET โ US โ Cloudflare, Inc. โ
โ AS15169 โ GOOGLE โ US โ Google LLC โ
โฐโโโโโโโโโโดโโโโโโโโโโโโโโโโดโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโฏ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Query: 13335 (type: asn)
โโโ Basic Information โโโ
...
# Search by name
โ monocle inspect -n cloudflare
Query: cloudflare (type: name)
โโโ Search Results โโโ
Found: 5 matches
โญโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโฎ
โ ASN โ Name โ Country โ
โโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโค
โ 13335 โ CLOUDFLARENET โ US โ
โ ... โ ... โ ... โ
โฐโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโฏ
# Look up prefix
โ monocle inspect 1.1.1.0/24
Query: 1.1.1.0/24 (type: prefix)
โโโ Announced Prefix โโโ
โญโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโฌโโโโโโโโโโโโโฎ
โ Matched Prefix โ Match Type โ ASN โ Validation โ
โโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโค
โ 1.1.1.0/24 โ exact โ AS13335 โ valid โ
โฐโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโดโโโโโโโโโโโโโฏ
โโโ Covering ROAs โโโ
โญโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโฎ
โ Prefix โ Max Length โ Origin ASN โ TA โ
โโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโค
โ 1.1.1.0/24 โ 24 โ AS13335 โ APNIC โ
โฐโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโฏ
# Show only basic information
โ monocle inspect 13335 --show basic
Look up country names and codes.
โ monocle country --help
Country name and code lookup utilities
Usage: monocle country [OPTIONS] [QUERY]
Arguments:
[QUERY] Search query: country code (e.g., "US") or partial name (e.g., "united")
Options:
-a, --all List all countries
--debug Print debug information
-s, --simple Output as simple text (code: name)
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Examples:
โ monocle country US
โโโโโโโโฌโโโโโโโโโโโโโโโโ
โ code โ name โ
โโโโโโโโผโโโโโโโโโโโโโโโโค
โ US โ United States โ
โโโโโโโโดโโโโโโโโโโโโโโโโ
โ monocle country germany
โโโโโโโโฌโโโโโโโโโโ
โ code โ name โ
โโโโโโโโผโโโโโโโโโโค
โ DE โ Germany โ
โโโโโโโโดโโโโโโโโโโ
Look up AS-level relationships between ASNs using BGPKIT's AS relationship data.
โ monocle as2rel --help
AS-level relationship lookup between ASNs
Usage: monocle as2rel [OPTIONS] <ASNS>...
Arguments:
<ASNS>...
One or more ASNs to query relationships for
- Single ASN: shows all relationships for that ASN - Two ASNs: shows the relationship between them - Multiple ASNs: shows relationships for all pairs (asn1 < asn2)
Options:
-u, --update
Force update the local as2rel database
--debug
Print debug information
--update-with <UPDATE_WITH>
Update with a custom data file (local path or URL)
--format <FORMAT>
Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--no-explain
Hide the explanation text
--json
Output as JSON objects (shortcut for --format json-pretty)
--sort-by-asn
Sort by ASN2 ascending instead of connected percentage descending
--no-update
Disable automatic database updates (use existing cached data only)
--show-name
Show organization name for ASN2 (from asinfo database)
--show-full-name
Show full organization name without truncation (default truncates to 20 chars)
--min-visibility <PERCENT>
Minimum visibility percentage (0-100) to include in results
Filters out relationships seen by fewer than this percentage of peers.
--single-homed
Only show ASNs that are single-homed to the queried ASN
An ASN is single-homed if it has exactly one upstream provider. This finds ASNs where the queried ASN is their ONLY upstream.
Only applicable when querying a single ASN.
--is-upstream
Only show relationships where the queried ASN is an upstream (provider)
Shows the downstream customers of the queried ASN. Only applicable when querying a single ASN.
--is-downstream
Only show relationships where the queried ASN is a downstream (customer)
Shows the upstream providers of the queried ASN. Only applicable when querying a single ASN.
--is-peer
Only show peer relationships
Only applicable when querying a single ASN.
-h, --help
Print help (see a summary with '-h')
-V, --version
Print version
Output columns:
asn1/asn2: The two ASNs being comparedconnected: Percentage of peers that see any connection between the ASNspeer: Percentage seeing pure peering relationshipas1_upstream: Percentage seeing ASN1 as upstream of ASN2as2_upstream: Percentage seeing ASN2 as upstream of ASN1
Examples:
# Look up relationship between two ASNs
โ monocle as2rel 13335 174
โโโโโโโโโฌโโโโโโโฌโโโโโโโโโโโโฌโโโโโโโโฌโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโ
โ asn1 โ asn2 โ connected โ peer โ as1_upstreamโ as2_upstreamโ
โโโโโโโโโผโโโโโโโผโโโโโโโโโโโโผโโโโโโโโผโโโโโโโโโโโโโโผโโโโโโโโโโโโโโค
โ 13335 โ 174 โ 95.2% โ 85.1% โ 2.3% โ 7.8% โ
โโโโโโโโโดโโโโโโโดโโโโโโโโโโโโดโโโโโโโโดโโโโโโโโโโโโโโดโโโโโโโโโโโโโโ
# Show all relationships for an ASN with names
โ monocle as2rel 13335 --show-name | head -10
# Find ASNs that are single-homed to AS2914 (NTT)
โ monocle as2rel 2914 --single-homed --show-name
# Find single-homed ASNs with at least 10% visibility
โ monocle as2rel 2914 --single-homed --min-visibility 10
# Show only downstream customers of an ASN
โ monocle as2rel 2914 --is-upstream --show-name
# Show only upstream providers of an ASN
โ monocle as2rel 13335 --is-downstream --show-name
# Show relationships among multiple ASNs (all pairs)
โ monocle as2rel 174 2914 3356 --show-name
Look up prefix-to-ASN mappings. Query by prefix to find origin ASNs, or by ASN to find announced prefixes. Results include RPKI validation status for each prefix-ASN pair.
โ monocle pfx2as --help
Prefix-to-ASN mapping lookup
Query by prefix to find origin ASNs, or by ASN to find announced prefixes. Includes RPKI validation status for each prefix-ASN pair.
Usage: monocle pfx2as [OPTIONS] <QUERY>
Arguments:
<QUERY>
Query: an IP prefix (e.g., 1.1.1.0/24) or ASN (e.g., 13335, AS13335)
Options:
-u, --update
Force update the local pfx2as database
--debug
Print debug information
--include-sub
Include sub-prefixes (more specific) in results when querying by prefix
--format <FORMAT>
Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--include-super
Include super-prefixes (less specific) in results when querying by prefix
--json
Output as JSON objects (shortcut for --format json-pretty)
--show-name
Show AS name for each origin ASN
--no-update
Disable automatic database updates (use existing cached data only)
--show-full-name
Show full AS name without truncation (default truncates to 20 chars)
-l, --limit <N>
Limit the number of results (default: no limit)
-h, --help
Print help (see a summary with '-h')
-V, --version
Print version
Examples:
# Look up a prefix - shows origin ASN and RPKI validation status
โ monocle pfx2as 1.1.1.0/24
โญโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโฎ
โ prefix โ origin_asn โ rpki โ
โโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโค
โ 1.1.1.0/24 โ 13335 โ valid โ
โฐโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโฏ
# Look up with AS name
โ monocle pfx2as 1.1.1.0/24 --show-name
โญโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโฌโโโโโโโโฎ
โ prefix โ origin_asn โ as_name โ rpki โ
โโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโผโโโโโโโโค
โ 1.1.1.0/24 โ 13335 โ CLOUDFLARENET โ valid โ
โฐโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโดโโโโโโโโฏ
# Look up by ASN - shows all prefixes announced by the ASN
โ monocle pfx2as 13335 --limit 5 --show-name
โญโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโฎ
โ prefix โ origin_asn โ as_name โ rpki โ
โโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโผโโโโโโโโโโโโค
โ 172.69.7.0/24 โ 13335 โ CLOUDFLARENET โ valid โ
โ 2606:4700:839a::/48 โ 13335 โ CLOUDFLARENET โ valid โ
โ 8.36.218.0/24 โ 13335 โ CLOUDFLARENET โ not_found โ
โ 2400:cb00:b8e6::/48 โ 13335 โ CLOUDFLARENET โ valid โ
โ 172.68.134.0/24 โ 13335 โ CLOUDFLARENET โ valid โ
โฐโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโดโโโโโโโโโโโโฏ
# Include sub-prefixes (more specific prefixes)
โ monocle pfx2as 8.8.0.0/16 --include-sub --limit 5 --show-name
โญโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโฎ
โ prefix โ origin_asn โ as_name โ rpki โ
โโโโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโค
โ 8.0.0.0/12 โ 3356 โ LEVEL3 โ not_found โ
โ 8.8.8.0/24 โ 15169 โ GOOGLE โ valid โ
โ 8.8.249.0/24 โ 989 โ ANAXA3-ASN โ valid โ
โ 8.8.216.0/24 โ 13781 โ ENERGYNET โ valid โ
โ 8.8.64.0/24 โ 3356 โ LEVEL3 โ not_found โ
โฐโโโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโโโฏ
# Include super-prefixes (less specific prefixes)
โ monocle pfx2as 1.1.1.0/24 --include-super
# JSON output
โ monocle pfx2as 13335 --limit 3 --json
[
{
"prefix": "172.69.7.0/24",
"origin_asn": 13335,
"rpki": "valid"
},
{
"prefix": "2606:4700:839a::/48",
"origin_asn": 13335,
"rpki": "valid"
},
{
"prefix": "8.36.218.0/24",
"origin_asn": 13335,
"rpki": "not_found"
}
]
RPKI utilities for validation and listing ROAs/ASPAs.
Data sources:
- Current data: Cloudflare's rpki.json (cached locally in SQLite)
- Historical data: RIPE NCC RPKI archives and RPKIviews
โ monocle rpki --help
RPKI utilities
Usage: monocle rpki [OPTIONS] <COMMAND>
Commands:
validate validate a prefix-asn pair using cached RPKI data
roas list ROAs from RPKI data (current or historical via bgpkit-commons)
aspas list ASPAs from RPKI data (current or historical via bgpkit-commons)
help Print this message or the help of the given subcommand(s)
Options:
--debug Print debug information
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Validate a prefix-ASN pair against cached RPKI data. Implements RFC 6811 validation logic:
- Valid: Covering ROA exists with matching ASN and prefix length โค max_length
- Invalid: Covering ROA exists but ASN doesn't match or prefix length exceeds max_length
- NotFound: No covering ROA exists for the prefix
โ monocle rpki validate --help
validate a prefix-asn pair using cached RPKI data
Usage: monocle rpki validate [OPTIONS] [RESOURCES] [RESOURCES]...
Arguments:
[RESOURCES] [RESOURCES]... Two resources: one prefix and one ASN (order does not matter)
Options:
-r, --refresh Force refresh the RPKI cache before validation
--debug Print debug information
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Examples:
โ monocle rpki validate 1.1.1.0/24 13335
โโโโโโโโโโโโโโฌโโโโโโโโฌโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ prefix โ asn โ status โ reason โ
โโโโโโโโโโโโโโผโโโโโโโโผโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ 1.1.1.0/24 โ 13335 โ Valid โ Covered by ROA: 1.1.1.0/24-24 โ
โโโโโโโโโโโโโโดโโโโโโโโดโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ monocle rpki validate 1.1.1.0/24 12345
โโโโโโโโโโโโโโฌโโโโโโโโฌโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ prefix โ asn โ status โ reason โ
โโโโโโโโโโโโโโผโโโโโโโโผโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ 1.1.1.0/24 โ 12345 โ Invalid โ ASN mismatch: ROA allows 13335, got 12345 โ
โโโโโโโโโโโโโโดโโโโโโโโดโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
List ROAs from RPKI data. Supports both current (cached from Cloudflare) and historical data.
โ monocle rpki roas --help
list ROAs from RPKI data (current or historical via bgpkit-commons)
Usage: monocle rpki roas [OPTIONS] [RESOURCES]...
Arguments:
[RESOURCES]... Filter by resources (prefixes or ASNs, auto-detected)
Options:
--date <DATE> Load historical data for this date (YYYY-MM-DD)
--debug Print debug information
--source <SOURCE> Historical data source: ripe, rpkiviews (default: ripe) [default: ripe]
--collector <COLLECTOR> RPKIviews collector: soborost, massars, attn, kerfuffle (default: soborost) [default: soborost]
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
-r, --refresh Force refresh the RPKI cache (only applies to current data)
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Examples:
# List ROAs for an ASN (current data)
โ monocle rpki roas 13335
โโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโฌโโโโโโโโโโโโโ
โ asn โ prefix โ max_length โ
โโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโผโโโโโโโโโโโโโค
โ 13335 โ 1.0.0.0/24 โ 24 โ
โ 13335 โ 1.1.1.0/24 โ 24 โ
โ ... โ ... โ ... โ
โโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโดโโโโโโโโโโโโโ
# List ROAs for a prefix
โ monocle rpki roas 1.1.1.0/24
โโโโโโโโโฌโโโโโโโโโโโโโฌโโโโโโโโโโโโโ
โ asn โ prefix โ max_length โ
โโโโโโโโโผโโโโโโโโโโโโโผโโโโโโโโโโโโโค
โ 13335 โ 1.1.1.0/24 โ 24 โ
โโโโโโโโโดโโโโโโโโโโโโโดโโโโโโโโโโโโโ
# Historical data from a specific date
โ monocle rpki roas 13335 --date 2024-01-01 --source ripe
List ASPAs (Autonomous System Provider Authorizations) from RPKI data.
โ monocle rpki aspas --help
list ASPAs from RPKI data (current or historical via bgpkit-commons)
Usage: monocle rpki aspas [OPTIONS]
Options:
--customer <CUSTOMER> Filter by customer ASN
--debug Print debug information
--provider <PROVIDER> Filter by provider ASN
--date <DATE> Load historical data for this date (YYYY-MM-DD)
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
--source <SOURCE> Historical data source: ripe, rpkiviews (default: ripe) [default: ripe]
--collector <COLLECTOR> RPKIviews collector: soborost, massars, attn, kerfuffle (default: soborost) [default: soborost]
--no-update Disable automatic database updates (use existing cached data only)
-r, --refresh Force refresh the RPKI cache (only applies to current data)
-h, --help Print help
-V, --version Print version
Examples:
# List all ASPAs
โ monocle rpki aspas | head -10
# Filter by customer ASN
โ monocle rpki aspas --customer 13335
# Filter by provider ASN
โ monocle rpki aspas --provider 174
Look up information about IP addresses.
โ monocle ip --help
IP information lookup
Usage: monocle ip [OPTIONS] [IP]
Arguments:
[IP] IP address to look up (optional)
Options:
--simple Print IP address only (e.g., for getting the public IP address quickly)
--debug Print debug information
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Examples:
# Look up a specific IP
โ monocle ip 1.1.1.1
โโโโโโโโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Field โ Value โ
โโโโโโโโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ ip โ 1.1.1.1 โ
โ asn โ 13335 โ
โ as_name โ CLOUDFLARENET โ
โ country โ AU โ
โ ... โ ... โ
โโโโโโโโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
# Get your public IP info
โ monocle ip
Show monocle configuration, data paths, and manage the database.
โ monocle config --help
Show monocle configuration, data paths, and database management
Usage: monocle config [OPTIONS] [COMMAND]
Commands:
update Update data source(s)
backup Backup the database to a destination
sources List available data sources and their status
help Print this message or the help of the given subcommand(s)
Options:
--debug Print debug information
--format <FORMAT> Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json Output as JSON objects (shortcut for --format json-pretty)
-v, --verbose Show detailed information about all data files
--no-update Disable automatic database updates (use existing cached data only)
-h, --help Print help
-V, --version Print version
Examples:
# Show configuration and database status
โ monocle config
Configuration:
Config file: ~/.config/monocle/monocle.toml
Data directory: ~/.local/share/monocle
Cache directory: ~/.cache/monocle
SQLite Database: ~/.local/share/monocle/monocle-data.sqlite3
Size: 45.2 MB
ASInfo: 120415 ASes
AS2Rel: 1234567 relationships
RPKI: 784188 ROAs, 388 ASPAs (updated 2 hours ago)
Pfx2as: 1000000 prefixes
# Update all data sources
โ monocle config update
# Update a specific source
โ monocle config update --asinfo
โ monocle config update --rpki
# Backup the database
โ monocle config backup ~/monocle-backup.sqlite3
# List available data sources
โ monocle config sources
Notes:
- Persistent data is stored in a single SQLite file at
{data-dir}/monocle-data.sqlite3 - The default cache directory (
$XDG_CACHE_HOME/monocle) is created and used on demand when runningmonocle search --use-cache
Start a WebSocket server for programmatic access to monocle functionality.
โ monocle server --help
Start the WebSocket server (ws://<address>:<port>/ws, health: http://<address>:<port>/health)
Note: This requires building with the `server` feature enabled.
Usage: monocle server [OPTIONS]
Options:
--address <ADDRESS>
Address to bind to (default: 127.0.0.1)
[default: 127.0.0.1]
--debug
Print debug information
--port <PORT>
Port to listen on (default: 8080)
[default: 8080]
--data-dir <DATA_DIR>
Monocle data directory (default: $XDG_DATA_HOME/monocle)
--format <FORMAT>
Output format: table, markdown, json, json-pretty, json-line, psv (default varies by command)
--json
Output as JSON objects (shortcut for --format json-pretty)
--max-concurrent-ops <MAX_CONCURRENT_OPS>
Maximum concurrent operations per connection (0 = unlimited)
--max-message-size <MAX_MESSAGE_SIZE>
Maximum websocket message size in bytes
--no-update
Disable automatic database updates (use existing cached data only)
--connection-timeout-secs <CONNECTION_TIMEOUT_SECS>
Idle timeout in seconds
--ping-interval-secs <PING_INTERVAL_SECS>
Ping interval in seconds
-h, --help
Print help (see a summary with '-h')
-V, --version
Print version
Endpoints:
- WebSocket:
ws://<address>:<port>/ws - Health check:
http://<address>:<port>/health
Features:
- JSON-RPC style request/response protocol
- Streaming support with progress reporting for parse/search operations
- Operation cancellation via
op_id - DB-first policy: queries read from local SQLite cache
Available methods:
system.info,system.methods- Server introspectiontime.parse- Time string parsingip.lookup,ip.public- IP information lookuprpki.validate,rpki.roas,rpki.aspas- RPKI operationsas2rel.search,as2rel.relationship,as2rel.update- AS relationshipspfx2as.lookup- Prefix-to-ASN mappingcountry.lookup- Country code/name lookupinspect.query,inspect.refresh- Unified AS/prefix inspectionparse.start,parse.cancel- MRT file parsing (streaming)search.start,search.cancel- BGP message search (streaming)database.status,database.refresh- Database management
For detailed protocol specification, see src/server/README.md.
Example:
โ monocle server
Starting WebSocket server on 127.0.0.1:8080
WebSocket: ws://127.0.0.1:8080/ws
Health: http://127.0.0.1:8080/health
โ monocle server --address 0.0.0.0 --port 3000
Starting WebSocket server on 0.0.0.0:3000
