Network checks
dns lookupdns lookupdns reversedns reversetcp checktcp checktcp bannertcp bannertcp check_manytcp check_manytls certificatetls certificatetls certificatetls expires_intls expires_intls expires_intls parsetls parseip infoip in_cidrip cidrip to_longip from_longhttp checkhttp check
dns lookup <name>
Description
The A records of a name with the resolvers of the system: JSON array of {type, value} sorted by address. A name without a record gives []
The A records of a name with the resolvers of the system: JSON array of {type, value} sorted by address. A name without a record gives []
Parameters
name: The DNS name (IDN accepted, 253 characters at most) - String - required
name: The DNS name (IDN accepted, 253 characters at most) - String - required
admin
dns lookup "localhost"
mentdb
[{"type": "A", "value": "127.0.0.1"}]
dns lookup <name> <json_params>
Description
DNS records with parameters: type (A | AAAA | MX | TXT | CNAME | NS | SOA | SRV | CAA | PTR, default A), server (a DNS server: ip, name, ip:port or [ipv6]:port, by default the resolvers of the system), timeout_ms (5000). Fields: A, AAAA, CNAME, NS, PTR, TXT: value (the strings of a TXT record are joined); MX: priority, exchange (sorted by priority); SRV: priority, weight, port, target (priority, then the highest weight); SOA: mname, rname, serial, refresh, retry, expire, minimum; CAA: flags, tag, value
DNS records with parameters: type (A | AAAA | MX | TXT | CNAME | NS | SOA | SRV | CAA | PTR, default A), server (a DNS server: ip, name, ip:port or [ipv6]:port, by default the resolvers of the system), timeout_ms (5000). Fields: A, AAAA, CNAME, NS, PTR, TXT: value (the strings of a TXT record are joined); MX: priority, exchange (sorted by priority); SRV: priority, weight, port, target (priority, then the highest weight); SOA: mname, rname, serial, refresh, retry, expire, minimum; CAA: flags, tag, value
Parameters
name: The DNS name - String - required
json_params: The parameters - String - required
name: The DNS name - String - required
json_params: The parameters - String - required
admin
dns lookup "test.local" "{\"type\": \"MX\", \"server\": \"127.0.0.1:21053\", \"timeout_ms\": 1500}"
mentdb
[{"type": "MX", "priority": 10, "exchange": "mx1.test.local"}, {"type": "MX", "priority": 20, "exchange": "mx2.test.local"}]
Fixed result from a real call on a local test server (127.0.0.1): TXT records (fake UDP DNS server)
admin
dns lookup "test.local" "{\"type\": \"TXT\", \"server\": \"127.0.0.1:21053\"}"
mentdb
[{"type": "TXT", "value": "quote\"back\\slash é"}, {"type": "TXT", "value": "simple"}, {"type": "TXT", "value": "v=spf1 include:_spf.test.local -all"}]
Fixed result from a real call on a local test server (127.0.0.1): SRV records (fake UDP DNS server)
admin
dns lookup "_sip._tcp.test.local" "{\"type\": \"SRV\", \"server\": \"127.0.0.1:21053\"}"
mentdb
[{"type": "SRV", "priority": 10, "weight": 9, "port": 5060, "target": "sip1.test.local"}, {"type": "SRV", "priority": 10, "weight": 1, "port": 5061, "target": "sip3.test.local"}, {"type": "SRV", "priority": 20, "weight": 5, "port": 5060, "target": "sip2.test.local"}]
Fixed result from a real call on a local test server (127.0.0.1): CAA records (fake UDP DNS server)
admin
dns lookup "test.local" "{\"type\": \"CAA\", \"server\": \"127.0.0.1:21053\"}"
mentdb
[{"type": "CAA", "flags": 128, "tag": "iodef", "value": "mailto:a@test.local"}, {"type": "CAA", "flags": 0, "tag": "issue", "value": "letsencrypt.org"}]
Fixed result from a real call on a local test server (127.0.0.1): NXDOMAIN gives an empty array (fake UDP DNS server)
admin
dns lookup "missing.test.local" "{\"server\": \"127.0.0.1:21053\"}"
mentdb
[]
dns reverse <ip>
Description
The names of an IP address (PTR records of in-addr.arpa or ip6.arpa) with the resolvers of the system. A host name is refused
The names of an IP address (PTR records of in-addr.arpa or ip6.arpa) with the resolvers of the system. A host name is refused
Parameters
ip: The IP address - String - required
ip: The IP address - String - required
admin
dns reverse "127.0.0.1"
mentdb
[{"type": "PTR", "value": "localhost"}]
dns reverse <ip> <json_params>
Description
The names of an IP address with parameters: server, timeout_ms (5000)
The names of an IP address with parameters: server, timeout_ms (5000)
Parameters
ip: The IP address - String - required
json_params: The parameters - String - required
ip: The IP address - String - required
json_params: The parameters - String - required
admin
dns reverse "127.0.0.1" "{\"server\": \"127.0.0.1:21053\"}"
mentdb
[{"type": "PTR", "value": "localhost.example"}]
tcp check <host> <port>
Description
Is a TCP port open? JSON {host, port, open, latency_ms, address, error} within 3 seconds. A refused port is a result, not an error
Is a TCP port open? JSON {host, port, open, latency_ms, address, error} within 3 seconds. A refused port is a result, not an error
Parameters
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
admin
tcp check "127.0.0.1" "21025"
mentdb
{"host": "127.0.0.1", "port": 21025, "open": true, "latency_ms": 0.2, "address": "127.0.0.1", "error": null}
tcp check <host> <port> <json_params>
Description
Is a TCP port open, with parameters: timeout_ms (3000, name resolution included)
Is a TCP port open, with parameters: timeout_ms (3000, name resolution included)
Parameters
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
json_params: The parameters - String - required
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
json_params: The parameters - String - required
admin
tcp check "127.0.0.1" "21027" "{\"timeout_ms\": 1000}"
mentdb
{"host": "127.0.0.1", "port": 21027, "open": false, "latency_ms": 0.1, "address": "127.0.0.1", "error": "refused"}
tcp check_many <json_targets>
Description
Check several TCP ports in parallel (16 threads): a JSON array of tcp check results in the order of the targets. All the targets are validated before the first connection
Check several TCP ports in parallel (16 threads): a JSON array of tcp check results in the order of the targets. All the targets are validated before the first connection
Parameters
json_targets: The targets: JSON array of {host, port} or of strings host:port ([ipv6]:port), 1000 at most - String - required
json_targets: The targets: JSON array of {host, port} or of strings host:port ([ipv6]:port), 1000 at most - String - required
admin
tcp check_many "[{\"host\": \"127.0.0.1\", \"port\": 21025}, \"127.0.0.1:21027\"]"
mentdb
[{"host": "127.0.0.1", "port": 21025, "open": true, "latency_ms": 0.2, "address": "127.0.0.1", "error": null}, {"host": "127.0.0.1", "port": 21027, "open": false, "latency_ms": 0.1, "address": "127.0.0.1", "error": "refused"}]
tcp check_many <json_targets> <json_params>
Description
Check several TCP ports with parameters: timeout_ms (3000 for each target), threads (16, 64 at most), deadline_ms (120000: the targets not done then get error deadline)
Check several TCP ports with parameters: timeout_ms (3000 for each target), threads (16, 64 at most), deadline_ms (120000: the targets not done then get error deadline)
Parameters
json_targets: The targets - String - required
json_params: The parameters - String - required
json_targets: The targets - String - required
json_params: The parameters - String - required
admin
tcp check_many "[\"127.0.0.1:21025\", \"127.0.0.1:21443\"]" "{\"threads\": 2, \"timeout_ms\": 1000}"
mentdb
[{"host": "127.0.0.1", "port": 21025, "open": true, "latency_ms": 0.2, "address": "127.0.0.1", "error": null}, {"host": "127.0.0.1", "port": 21443, "open": true, "latency_ms": 0.2, "address": "127.0.0.1", "error": null}]
tls certificate <host>
Description
Read the certificate of a server on port 443, see the next entries for the fields
Read the certificate of a server on port 443, see the next entries for the fields
Parameters
host: The host name or IP address - String - required
host: The host name or IP address - String - required
admin
tls certificate "localhost"
mentdb
Sorry, an error appears (cannot read the certificate of localhost:443 (refused)).
tls certificate <host> <port_or_params>
Description
Read the certificate of a server: subject, issuer, not_before, not_after, days_left (negative when expired), expired, san, serial (hexadecimal), sig_alg, key_alg, key_bits, self_signed, sha256, protocol, cipher, chain (every certificate sent, the server first), trusted (with the default trust of the JDK), trust_error, hostname_match. The second argument is the port or the JSON parameters
Read the certificate of a server: subject, issuer, not_before, not_after, days_left (negative when expired), expired, san, serial (hexadecimal), sig_alg, key_alg, key_bits, self_signed, sha256, protocol, cipher, chain (every certificate sent, the server first), trusted (with the default trust of the JDK), trust_error, hostname_match. The second argument is the port or the JSON parameters
Parameters
host: The host name or IP address - String - required
port_or_params: The port (443) or the JSON parameters - String - required
host: The host name or IP address - String - required
port_or_params: The port (443) or the JSON parameters - String - required
admin
tls certificate "localhost" "21443"
mentdb
{"subject": "CN=localhost,O=MentDB Test", "issuer": "CN=localhost,O=MentDB Test", "not_before": "2026-11-04T04:03:00Z", "not_after": "2036-11-01T04:03:00Z", "days_left": 3649, "expired": false, "san": ["localhost", "*.test.local", "127.0.0.1"], "serial": "CE0FB69C41B1D178", "sig_alg": "SHA384withRSA", "key_alg": "RSA", "key_bits": 2048, "self_signed": true, "sha256": "aab99cfa3ffa64c94ce4afd3df8da2abff4ad08e758254567fd08b07ed467ff5", "protocol": "TLSv1.3", "cipher": "TLS_AES_256_GCM_SHA384", "chain": [{"subject": "CN=localhost,O=MentDB Test", "issuer": "CN=localhost,O=MentDB Test", "not_before": "2026-11-04T04:03:00Z", "not_after": "2036-11-01T04:03:00Z", "days_left": 3649, "expired": false, "san": ["localhost", "*.test.local", "127.0.0.1"], "serial": "CE0FB69C41B1D178", "sig_alg": "SHA384withRSA", "key_alg": "RSA", "key_bits": 2048, "self_signed": true, "sha256": "aab99cfa3ffa64c94ce4afd3df8da2abff4ad08e758254567fd08b07ed467ff5"}], "trusted": false, "trust_error": "PKIX path building failed: unable to find valid certification path to requested target", "hostname_match": true}
tls certificate <host> <port> <json_params>
Description
Read the certificate of a server with parameters: timeout_ms (5000, for the whole call), sni (the name to send: by default the host when it is a name, nothing for an IP; false for no SNI), now (ISO date for days_left, the current time by default)
Read the certificate of a server with parameters: timeout_ms (5000, for the whole call), sni (the name to send: by default the host when it is a name, nothing for an IP; false for no SNI), now (ISO date for days_left, the current time by default)
Parameters
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
json_params: The parameters - String - required
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
json_params: The parameters - String - required
admin
tls certificate "localhost" "21444" "{\"timeout_ms\": 2000, \"now\": \"2026-11-04T00:00:00Z\"}"
mentdb
{"subject": "CN=expired.local", "issuer": "CN=expired.local", "not_before": "2025-09-30T04:03:01Z", "not_after": "2025-10-30T04:03:01Z", "days_left": -370, "expired": true, "san": [], "serial": "C11001F1AA91A073", "sig_alg": "SHA384withECDSA", "key_alg": "EC", "key_bits": 256, "self_signed": true, "sha256": "f514dac6347d3d83e7b6c7faf45834b1f92720b367eca76665c7d8d7fa40ab15", "protocol": "TLSv1.3", "cipher": "TLS_AES_256_GCM_SHA384", "chain": [{"subject": "CN=expired.local", "issuer": "CN=expired.local", "not_before": "2025-09-30T04:03:01Z", "not_after": "2025-10-30T04:03:01Z", "days_left": -370, "expired": true, "san": [], "serial": "C11001F1AA91A073", "sig_alg": "SHA384withECDSA", "key_alg": "EC", "key_bits": 256, "self_signed": true, "sha256": "f514dac6347d3d83e7b6c7faf45834b1f92720b367eca76665c7d8d7fa40ab15"}], "trusted": false, "trust_error": "PKIX path building failed: unable to find valid certification path to requested target", "hostname_match": false}
tls expires_in <host>
Description
The days left before the certificate of a server on port 443 expires (negative when expired). An error when the certificate cannot be read
The days left before the certificate of a server on port 443 expires (negative when expired). An error when the certificate cannot be read
Parameters
host: The host name or IP address - String - required
host: The host name or IP address - String - required
admin
tls expires_in "localhost"
mentdb
Sorry, an error appears (cannot read the certificate of localhost:443 (refused)).
tls expires_in <host> <port>
Description
The days left before the certificate of a server expires
The days left before the certificate of a server expires
Parameters
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
admin
tls expires_in "localhost" "21444"
mentdb
-371
tls expires_in <host> <port> <json_params>
Description
The days left before the certificate of a server expires, with parameters: timeout_ms, sni, now
The days left before the certificate of a server expires, with parameters: timeout_ms, sni, now
Parameters
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
json_params: The parameters - String - required
host: The host name or IP address - String - required
port: The TCP port (1 to 65535) - Number - required
json_params: The parameters - String - required
admin
tls expires_in "localhost" "21443" "{\"now\": \"2026-11-04T00:00:00Z\"}"
mentdb
3650
tls parse <pem_or_path>
Description
Read a certificate offline: PEM text (several certificates: the first is described, all are in chain; 20 at most) or a path to a PEM or DER file (1 MB at most, same rights as file load). Same fields as tls certificate without the connection (protocol, cipher, trusted). days_left depends on the current date
Read a certificate offline: PEM text (several certificates: the first is described, all are in chain; 20 at most) or a path to a PEM or DER file (1 MB at most, same rights as file load). Same fields as tls certificate without the connection (protocol, cipher, trusted). days_left depends on the current date
Parameters
pem_or_path: The PEM text, or a file path - String - required
pem_or_path: The PEM text, or a file path - String - required
admin
json load "tuto_c" (tls parse "-----BEGIN CERTIFICATE----- MIIBozCCAUmgAwIBAgIJAL3RQktPUik7MAoGCCqGSM49BAMDMC0xEDAOBgNVBAoT B0V4YW1wbGUxGTAXBgNVBAMTEHNob3AuZXhhbXBsZS5jb20wHhcNMjUxMjMxMjAw MDAwWhcNMzUxMjI5MjAwMDAwWjAtMRAwDgYDVQQKEwdFeGFtcGxlMRkwFwYDVQQD ExBzaG9wLmV4YW1wbGUuY29tMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEDDVe m4FkT134yeZvEeFtVgMW8UOTalNiDd/BsiGHQdw29ymqnmPOC+j+yHSg3YukL9MK U3fMMAICSjmsDdyVeqNSMFAwHQYDVR0OBBYEFJ9Mu6PRYe+YQdBPGOTBy51c8FY1 MC8GA1UdEQQoMCaCEHNob3AuZXhhbXBsZS5jb22CEiouc2hvcC5leGFtcGxlLmNv bTAKBggqhkjOPQQDAwNIADBFAiBCBEMCGsIEZI/AitisvBaoYm7JmINwMCKlMv7R 2J7bVwIhAOweFccYp1LVvdw9ALH89Fm/NHN47s1+X9b/UZZUAZ3m -----END CERTIFICATE-----"); -> "[res]" (json select "tuto_c" "/subject"); json unload "tuto_c"; [res]
mentdb
CN=shop.example.com,O=Example
tls parse <pem_or_path> <json_params>
Description
Read a certificate offline with parameters: now (ISO date for days_left), host (adds hostname_match for this name)
Read a certificate offline with parameters: now (ISO date for days_left), host (adds hostname_match for this name)
Parameters
pem_or_path: The PEM text, or a file path - String - required
json_params: The parameters - String - required
pem_or_path: The PEM text, or a file path - String - required
json_params: The parameters - String - required
admin
tls parse "-----BEGIN CERTIFICATE----- MIIBozCCAUmgAwIBAgIJAL3RQktPUik7MAoGCCqGSM49BAMDMC0xEDAOBgNVBAoT B0V4YW1wbGUxGTAXBgNVBAMTEHNob3AuZXhhbXBsZS5jb20wHhcNMjUxMjMxMjAw MDAwWhcNMzUxMjI5MjAwMDAwWjAtMRAwDgYDVQQKEwdFeGFtcGxlMRkwFwYDVQQD ExBzaG9wLmV4YW1wbGUuY29tMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEDDVe m4FkT134yeZvEeFtVgMW8UOTalNiDd/BsiGHQdw29ymqnmPOC+j+yHSg3YukL9MK U3fMMAICSjmsDdyVeqNSMFAwHQYDVR0OBBYEFJ9Mu6PRYe+YQdBPGOTBy51c8FY1 MC8GA1UdEQQoMCaCEHNob3AuZXhhbXBsZS5jb22CEiouc2hvcC5leGFtcGxlLmNv bTAKBggqhkjOPQQDAwNIADBFAiBCBEMCGsIEZI/AitisvBaoYm7JmINwMCKlMv7R 2J7bVwIhAOweFccYp1LVvdw9ALH89Fm/NHN47s1+X9b/UZZUAZ3m -----END CERTIFICATE-----" "{\"now\": \"2026-11-04T00:00:00Z\", \"host\": \"www.shop.example.com\"}"
mentdb
{"subject": "CN=shop.example.com,O=Example", "issuer": "CN=shop.example.com,O=Example", "not_before": "2025-12-31T20:00:00Z", "not_after": "2035-12-29T20:00:00Z", "days_left": 3342, "expired": false, "san": ["shop.example.com", "*.shop.example.com"], "serial": "BDD1424B4F52293B", "sig_alg": "SHA384withECDSA", "key_alg": "EC", "key_bits": 256, "self_signed": true, "sha256": "f092c722ad8219caabb004e2dfdb7d20a527dc1288e05728a26dbcbcdd3ffaa2", "chain": [{"subject": "CN=shop.example.com,O=Example", "issuer": "CN=shop.example.com,O=Example", "not_before": "2025-12-31T20:00:00Z", "not_after": "2035-12-29T20:00:00Z", "days_left": 3342, "expired": false, "san": ["shop.example.com", "*.shop.example.com"], "serial": "BDD1424B4F52293B", "sig_alg": "SHA384withECDSA", "key_alg": "EC", "key_bits": 256, "self_signed": true, "sha256": "f092c722ad8219caabb004e2dfdb7d20a527dc1288e05728a26dbcbcdd3ffaa2"}], "hostname_match": true}
ip info <ip>
Description
Describe an IP address offline: version, normalized (RFC 5952 for IPv6), expanded (IPv6), integer (a string), reverse_name, zone (when given), ipv4_mapped, ipv4, private (RFC 1918, fc00::/7), loopback, link_local, multicast, unspecified, documentation, carrier_nat (100.64.0.0/10), benchmark (198.18.0.0/15), broadcast, reserved, global (none of the others). A host name is refused, it is never resolved
Describe an IP address offline: version, normalized (RFC 5952 for IPv6), expanded (IPv6), integer (a string), reverse_name, zone (when given), ipv4_mapped, ipv4, private (RFC 1918, fc00::/7), loopback, link_local, multicast, unspecified, documentation, carrier_nat (100.64.0.0/10), benchmark (198.18.0.0/15), broadcast, reserved, global (none of the others). A host name is refused, it is never resolved
Parameters
ip: The IP address literal - String - required
ip: The IP address literal - String - required
admin
ip info "192.168.1.10"
mentdb
{"version": 4, "normalized": "192.168.1.10", "integer": "3232235786", "reverse_name": "10.1.168.192.in-addr.arpa", "ipv4_mapped": false, "private": true, "loopback": false, "link_local": false, "multicast": false, "unspecified": false, "documentation": false, "carrier_nat": false, "benchmark": false, "broadcast": false, "reserved": false, "global": false}
An IPv6 address is normalized
admin
ip info "2001:0DB8:0:0::0001"
mentdb
{"version": 6, "normalized": "2001:db8::1", "expanded": "2001:0db8:0000:0000:0000:0000:0000:0001", "integer": "42540766411282592856903984951653826561", "reverse_name": "1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.8.b.d.0.1.0.0.2.ip6.arpa", "ipv4_mapped": false, "private": false, "loopback": false, "link_local": false, "multicast": false, "unspecified": false, "documentation": true, "carrier_nat": false, "benchmark": false, "broadcast": false, "reserved": false, "global": false}
A mapped address is classified by its IPv4 address
admin
ip info "::ffff:10.0.0.1"
mentdb
{"version": 6, "normalized": "::ffff:10.0.0.1", "expanded": "0000:0000:0000:0000:0000:ffff:0a00:0001", "integer": "281470849515521", "reverse_name": "1.0.0.0.0.0.a.0.f.f.f.f.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa", "ipv4_mapped": true, "ipv4": "10.0.0.1", "private": true, "loopback": false, "link_local": false, "multicast": false, "unspecified": false, "documentation": false, "carrier_nat": false, "benchmark": false, "broadcast": false, "reserved": false, "global": false}
Used in use cases (1 recipe)
Security engineer › Check a source address against an allow list of networks
Security engineer › Check a source address against an allow list of networks
ip in_cidr <ip> <cidr>
Description
Is an IP address in a CIDR range? 1 or 0. An IPv4 address and an IPv6 range (or the reverse) give 0, except the IPv4-mapped addresses, compared as IPv4
Is an IP address in a CIDR range? 1 or 0. An IPv4 address and an IPv6 range (or the reverse) give 0, except the IPv4-mapped addresses, compared as IPv4
Parameters
ip: The IP address - String - required
cidr: The range, ex: 192.168.1.0/24 - String - required
ip: The IP address - String - required
cidr: The range, ex: 192.168.1.0/24 - String - required
admin
ip in_cidr "192.168.1.10" "192.168.1.0/24"
mentdb
1
Out of the range
admin
ip in_cidr "192.168.2.10" "192.168.1.0/24"
mentdb
0
IPv6
admin
ip in_cidr "2001:db8::5" "2001:db8::/32"
mentdb
1
Used in use cases (1 recipe)
Security engineer › Check a source address against an allow list of networks
Security engineer › Check a source address against an allow list of networks
ip cidr <cidr>
Description
Describe a CIDR range: version, cidr, prefix, network, mask, broadcast, first, last, count. IPv4 also: wildcard, usable (first and last are the usable hosts; /31 and /32 have no broadcast). IPv6: no broadcast, first and last are the whole range, count is a string
Describe a CIDR range: version, cidr, prefix, network, mask, broadcast, first, last, count. IPv4 also: wildcard, usable (first and last are the usable hosts; /31 and /32 have no broadcast). IPv6: no broadcast, first and last are the whole range, count is a string
Parameters
cidr: The range: the host bits may be set - String - required
cidr: The range: the host bits may be set - String - required
admin
ip cidr "192.168.1.77/24"
mentdb
{"version": 4, "cidr": "192.168.1.0/24", "prefix": 24, "network": "192.168.1.0", "mask": "255.255.255.0", "wildcard": "0.0.0.255", "broadcast": "192.168.1.255", "first": "192.168.1.1", "last": "192.168.1.254", "count": 256, "usable": 254}
A point-to-point /31
admin
ip cidr "10.0.0.0/31"
mentdb
{"version": 4, "cidr": "10.0.0.0/31", "prefix": 31, "network": "10.0.0.0", "mask": "255.255.255.254", "wildcard": "0.0.0.1", "broadcast": null, "first": "10.0.0.0", "last": "10.0.0.1", "count": 2, "usable": 2}
An IPv6 /32
admin
ip cidr "2001:db8::1/32"
mentdb
{"version": 6, "cidr": "2001:db8::/32", "prefix": 32, "network": "2001:db8::", "mask": "ffff:ffff::", "broadcast": null, "first": "2001:db8::", "last": "2001:db8:ffff:ffff:ffff:ffff:ffff:ffff", "count": "79228162514264337593543950336"}
Used in use cases (1 recipe)
Security engineer › Check a source address against an allow list of networks
Security engineer › Check a source address against an allow list of networks
ip to_long <ip>
Description
An IPv4 address as an integer (an IPv4-mapped address is accepted)
An IPv4 address as an integer (an IPv4-mapped address is accepted)
Parameters
ip: The IPv4 address - String - required
ip: The IPv4 address - String - required
admin
ip to_long "192.168.1.10"
mentdb
3232235786
ip from_long <number>
Description
An integer from 0 to 4294967295 as an IPv4 address
An integer from 0 to 4294967295 as an IPv4 address
Parameters
number: The integer - Number - required
number: The integer - Number - required
admin
ip from_long "3232235786"
mentdb
192.168.1.10
http check <url>
Description
Is a URL up? A HEAD request within 5 seconds: JSON {ok (status 200 to 399), status, latency_ms (until the headers), tls_days_left (https), error}. A failed request is a result
Is a URL up? A HEAD request within 5 seconds: JSON {ok (status 200 to 399), status, latency_ms (until the headers), tls_days_left (https), error}. A failed request is a result
Parameters
url: The http or https URL, without a user or a password - String - required
url: The http or https URL, without a user or a password - String - required
admin
http check "http://127.0.0.1:21080/ok"
mentdb
{"ok": true, "status": 200, "latency_ms": 1.3, "tls_days_left": null, "error": null}
http check <url> <json_params>
Description
Is a URL up, with parameters: timeout_ms (5000), method (HEAD or GET), expect_status (a status or a list, instead of 200 to 399), contains (a text the body must contain: the request becomes a GET, adds contains_found), max_bytes (1048576, 10 MB at most: the part of the body searched), follow (false), insecure (false: true accepts any certificate and any host name, for a check only), now (ISO date for tls_days_left). An untrusted or expired certificate gives ok false and tls_days_left is still read
Is a URL up, with parameters: timeout_ms (5000), method (HEAD or GET), expect_status (a status or a list, instead of 200 to 399), contains (a text the body must contain: the request becomes a GET, adds contains_found), max_bytes (1048576, 10 MB at most: the part of the body searched), follow (false), insecure (false: true accepts any certificate and any host name, for a check only), now (ISO date for tls_days_left). An untrusted or expired certificate gives ok false and tls_days_left is still read
Parameters
url: The URL - String - required
json_params: The parameters - String - required
url: The URL - String - required
json_params: The parameters - String - required
admin
http check "http://127.0.0.1:21080/ok" "{\"contains\": \"hello\", \"expect_status\": 200}"
mentdb
{"ok": true, "status": 200, "latency_ms": 0.9, "tls_days_left": null, "contains_found": true, "error": null}
Fixed result from a real call on a local test server (127.0.0.1): a redirect followed
admin
http check "http://127.0.0.1:21080/redir" "{\"follow\": true}"
mentdb
{"ok": true, "status": 200, "latency_ms": 1.5, "tls_days_left": null, "error": null}
Fixed result from a real call on a local test server (127.0.0.1): an expired self-signed certificate on a local HTTPS server
admin
http check "https://localhost:21446/ok" "{\"timeout_ms\": 2000, \"now\": \"2026-11-04T00:00:00Z\"}"
mentdb
{"ok": false, "status": null, "latency_ms": 3.8, "tls_days_left": -370, "error": "tls: (certificate_unknown) PKIX path building failed: unable to find valid certification path to requested target"}
Fixed result from a real call on a local test server (127.0.0.1): a closed port
admin
http check "http://127.0.0.1:21027/" "{\"timeout_ms\": 1000}"
mentdb
{"ok": false, "status": null, "latency_ms": 0.8, "tls_days_left": null, "error": "refused"}
