Hi Nick, you are correct, the -V (or --client) flag is used to identify a client, and (optionally) can be used to proxy queries. If no comma is included in the argument, it is only used to identify the client. This flag is optional, and has no effect on the query response. If a comma and an IP address is appended to the argument, it is used to proxy the query on behalf of this IP address. The IP address can be IPv4 or IPv6, this clarification has been included in the latest documentation, available here: https://www.ripe.net/data-tools/support/documentation/ripe-database-document... The client (proxy) flag is documented in section 15. Regards, Ed Shryane RIPE NCC
On 15 Nov 2014, at 20:11, Nick Hilliard <nick@inex.ie> wrote:
Could someone from RIPE clarify the semantics for the -V query?
In the database query reference manual, section 2.6 it says:
-V --client <client-tag> Sends information about the client to the server.
But in section 2.11, it says:
The database server provides a facility for such proxy clients that allows accounting to be based on the IP address of the clients using the proxy to query the RIPE Database and not on the IP address of the proxy server. This is done using the ā-Vā flag as follows:
-V <version>,<ipv4-address>
where
<version> is a client tag that usually represents the software version that the proxy uses <ipv4-address> is the IPv4 address of the client that queries the database using the proxy
According to the source code, the argument for the -V parameter is passed into the QueryFlag.CLIENT variable and then parsed using getProxyIp(). If the format looks like "version,ipv4addr" then the argument is passed to the proxy accounting mechanism for rate limiting. But if the argument is not formatted like this, it looks like the "-V" parameter is ignored.
Is this understanding correct, and should all whois clients use the "-V" query to pass their client ID to the whois server by default?
As an aside, the isProxyValid() function uses InetAddresses.isInetAddress(), which suggests that the code should also understand "-V <version>,<ipv6-address>". If this is correct+tested, the documentation should be updated.
Nick