# Tables of Query Types Supported by the RIPE Database

# Table 1: Queries Using Primary and Lookup Keys

Lookup key(s) Objects Returned
<ip-lookup> (IPv4 address prefix, range or single address) inetnum, route objects with exact match on the specified key. If the exact match does not exist, the objects with the smallest less specific match are returned. When you specify a single address, an inet-rtr object whose “ifaddr:” attribute matches the query argument is also returned..
<ip-lookup>(IPv6 address prefix or single address) inet6num, route6 objects with exact match on a specified key. If the exact match does not exist, the objects with the smallest less specific match are returned. If you specify a single address, an inet-rtr object whose “interface:” attribute matches the query argument is also returned.
<netname> inetnum and inet6num objects whose “netname:” attribute matches the query argument.
<as-number> aut-num object whose “aut-num:” attribute matches the query argument and an as-block object with the range containing the aut-num object, if it exists.
<as-number> - <as-number> (range of <as-number> separated by “-“) as-block object whose primary key defines a range that exactly matches or fully contains the range specified in the query argument.
<reverse-domain> domain and inet-rtr objects whose primary keys match the query argument.
<irt-name> irt object whose primary key matches the query argument.
<Person-name> person and role objects whose “person:” or “role:” attributes contain the name specified in the query argument.
<set-name> A set whose primary key matches the query argument.
<nic-handle> person or role object whose “nic-hdl:” attribute matches the query argument.
<mntner-name> mntner object whose primary key matches the query argument.
<org-id> organisation object whose primary key matches the query argument.
<key-cert-id> key-cert object whose primary key matches the query argument.
<poem> poem object whose primary key matches the query argument.
<poetic-form> poetic-form object whose primary key matches the query argument.

# Table 2: Queries For IP Networks table

Flag Lookup Key(s) Objects Returned or Effect
-x
--exact
<ip-lookup> Only inetnum, inet6num, route, route6 or domain objects that exactly match the prefix. If no exact match is found, no objects are returned.
-M
--all-more
<ip-lookup> All level more specific inetnum, inet6num, route, route6 or domain objects, excluding exact matches.
-m
--one-more
<ip-lookup> First level more specific inetnum, inet6num, route or route6 objects, excluding exact matches.
-L
--all-less
<ip-lookup> All level less specific inetnum, inet6num, route, route6 or domain objects, including exact matches.
-l
--one-less
<ip-lookup> First level less specific inetnum, inet6num, route, route6 or domain objects, excluding exact matches.
-d
--reverse-domain
<ip-lookup> When used with “-x”, “-M”, “-m”, “-L” and “-l” flags, both address and route object types and domain object types are returned.
-c
--irt
<ip-lookup> The smallest, less specific inetnum or inet6num object found encompassing the range specified in the query argument. Also any irt objects found referenced from the returned inetnum or inet6num, or referenced from the first less specific inetnum or inet6num to the returned object that has such a reference.
-b
--abuse-contact
Provides a brief output of ranges with associated abuse contact information.

# Table 3: Query Flag Arguments to the “-” Query Flag and the Corresponding Inverse Keys

Flag Argument (Alternative Form) Lookup Key(s) Objects Returned
am (abuse-mailbox) <e-mail> Objects whose “abuse-mailbox:” attribute matches the query argument.
ac (admin-c) <nic-handle> or <person- name> Objects whose “admin-c:” attributes match the query argument.
at (auth) <key-cert-id> mntner objects whose “auth:” attribute matches the query argument. Please note that encrypted passwords and SSO usernames cannot be inverse- searched, but only PGPKEY and X509 certicates.
fp (ngerprint) <fingerprint> key-cert objects whose “fingerpr:” attribute matches the query argument.
pn (person) <nic-handle> or <person- name> Objects whose “admin-c:”, “tech-c:”, “zone-c:” or “author:” attribute matches the query argument.
iy (irt-nfy) <e-mail> irt objects whose “irt-nfy:” attribute matches the query argument.
la (local-as) <as-number> inet-rtr objects whose “local-as:” attribute matches the query argument.
mi (mnt-irt) <irt-name> inetnum and inet6num objects whose “mnt-irt:” attribute matches the query argument.
mr (mbrs-by-ref) <mntner- name> Set objects (as-set, route-set and rtr-set) whose “mbrs-by-ref:” attribute matches the query argument.
mo (member-of) <set-name> Objects whose “member-of:” attribute matches the query argument and their membership claim is validated by the “mbrs-by-ref:” attribute of the set. Absence of the “mbrs-by-ref:” attribute means that the membership is only defined by the “members:” attribute of the set.
mb (mnt-by) <mntner- name> Objects whose “mnt-by:” attribute matches the query argument.
md (mnt-domains) <mntner- name> Objects whose “mnt-domains:” attribute matches the query argument.
ml (mnt-lower) <mntner- name> Objects whose “mnt-lower:” attribute matches the query argument.
mn (mnt-nfy) <e-mail> mntner objects whose “mnt-nfy:” attribute matches the query argument.
mu (mnt-routes) <mntner- name> aut-num, inetnum, route and route6 objects whose “mnt-routes:” attribute matches the query argument.
mz (mnt-ref) <mntner- name> Returns all objects whose “mnt-ref:” attribute matches the query argument.
ny (notify) <e-mail> Objects whose “notify:” attribute matches the query argument.
ns (nserver) <domain- name> or <ip- lookup> (IPv4/IPv6 address) domain objects whose “nserver:” attribute matches the query argument.
or (origin) <as-name> route and route6 objects whose “origin:” attribute matches the query argument.
org <org-id> Objects whose “organisation:” attribute matches the query argument.
tc (tech-c) <nic-handle> or <person- name> Objects whose “tech-c:” attribute matches the query argument.
dt (upd-to) <e-mail> mntner objects whose “upd-to:” attribute matches the query argument.
zc (zone-c) <nic-handle> or <person- name> Objects whose “zone-c:” attribute matches the query argument.

# Table 4: Query Support For Tools

Flag Lookup Key(s) Effect
-F --brief Produces output using shorthand notation for attribute names. Produces slower responses.
-K --primary- keys Requests that only the primary keys of an object be returned. The exceptions are set objects, where the “members:” attributes will also be returned. This flag does not apply to person and role objects.
-k --persistent- connection (optional normal query) Requests a persistent connection. After returning the result, the connection will not be closed by the server and a client may issue multiple queries on the same connection. The server implements a “stop-and-wait” protocol, whereby no next query can be sent before receiving a reply for the previous one. Use RIPE Whois client to be able to send queries in batch mode. Except the first “-k query”, “-k” without an argument closes the persistent connection.

# Table 5: Miscellaneous Queries

Flag Flag Argument Effect
-r --no- referenced Switches off lookups for referenced contact information after retrieving the objects that match the lookup key.
-B --no- filtering Switches off default filtering of objects.
-G --no- grouping Switches off grouping of associated objects.
-T --select- types Comma separated list of object types, no white space is allowed Restricts the types of primary objects to lookup in the query.
-a --all- sources Specifies that the server should perform lookups in all available sources. See also “-q sources” query.
-s --sources Comma separated list of sources, no white space is allowed. Specifies which sources are to be looked up when performing a query and in which order.
--list- versions
--diff- versions <version-number: version- number> Indicates the difference between given historical versions of the object.
--show- version <version-number> Returns the historical version of the object with this index number. Must use --list- versions to get the index numbers.
--types Lists available RPSL object types.
--version Displays the current software version.
--list- sources Returns the current set of sources along with the information required for mirroring.
--resource Search all sources for the specified resource and returns the authoritative one. Placeholders are omitted.
--show- personal Include referenced person and role objects in results.
--no- personal Filter referenced person and role objects from results. A client can be blocked for excessive querying of these objects.

# Table 6: Informational Queries

The following notations are used in this table:

<object-type> means full or abbreviated name;

Flag Flag Argument Effect
-q sources Returns the current set of sources along with the information required for mirroring.
-q version Displays the current version of the server.
-t --template <object- type> Requests a template for the specified object type.
-v --verbose <object- type> Requests a verbose template for the specified object type.