+ for (i = 1; i < cmd->argc; i++) {
+ if (!strcasecmp(cmd->argv[i], "-details")) {
+ details = TRUE;
+ } else if (!strcasecmp(cmd->argv[i], "-pubkey") && cmd->argc > i + 1) {
+ pubkey = cmd->argv[i + 1];
+ i++;
+ } else {
+ /* We assume that the first parameter is the nickname, if it isn't
+ -details or -pubkey. The last parameter should always be the count */
+ if (i == 1) {
+ nick = TRUE;
+ } else if (i == cmd->argc - 1) {
+ int c = atoi(cmd->argv[i]);
+ SILC_PUT32_MSB(c, count);
+ tmp = count;
+ }
+ }
+ }
+
+ if (details) {
+ /* if pubkey is set, add all attributes to the
+ attrs buffer, except public key */
+ if (pubkey) {
+ attrs = silc_client_attributes_request(SILC_ATTRIBUTE_USER_INFO,
+ SILC_ATTRIBUTE_SERVICE,
+ SILC_ATTRIBUTE_STATUS_MOOD,
+ SILC_ATTRIBUTE_STATUS_FREETEXT,
+ SILC_ATTRIBUTE_STATUS_MESSAGE,
+ SILC_ATTRIBUTE_PREFERRED_LANGUAGE,
+ SILC_ATTRIBUTE_PREFERRED_CONTACT,
+ SILC_ATTRIBUTE_TIMEZONE,
+ SILC_ATTRIBUTE_GEOLOCATION,
+ SILC_ATTRIBUTE_DEVICE_INFO, 0);
+ } else {