usr/src/lib/libxmlrpc-c/xmlrpc.1
changeset 0 b34509ac961f
child 11 87960ed158f9
equal deleted inserted replaced
-1:000000000000 0:b34509ac961f
       
     1 '\" t
       
     2 .\"
       
     3 .\" CDDL HEADER START
       
     4 .\"
       
     5 .\" The contents of this file are subject to the terms of the
       
     6 .\" Common Development and Distribution License (the "License").
       
     7 .\" You may not use this file except in compliance with the License.
       
     8 .\"
       
     9 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
       
    10 .\" or http://www.opensolaris.org/os/licensing.
       
    11 .\" See the License for the specific language governing permissions
       
    12 .\" and limitations under the License.
       
    13 .\"
       
    14 .\" When distributing Covered Code, include this CDDL HEADER in each
       
    15 .\" file and include the License file at usr/src/OPENSOLARIS.LICENSE.
       
    16 .\" If applicable, add the following below this CDDL HEADER, with the
       
    17 .\" fields enclosed by brackets "[]" replaced with your own identifying
       
    18 .\" information: Portions Copyright [yyyy] [name of copyright owner]
       
    19 .\"
       
    20 .\" CDDL HEADER END
       
    21 .\"
       
    22 .\" Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
       
    23 .\" Use is subject to license terms.
       
    24 .\"
       
    25 .\" ident	"@(#)xmlrpc.1	1.1	09/06/17 SMI"
       
    26 .\"
       
    27 .TH xmlrpc 1 "Feb 27 2009" "SunOS 5.11" "User Commands" 
       
    28 .SH NAME
       
    29 xmlrpc \- make an XML-RPC remote procedure call (RPC) and display the response
       
    30 .SH SYNOPSIS
       
    31 .LP
       
    32 .nf
       
    33 \fBxmlrpc\fR \fIurl\fR \fImethodName\fR \fIparameter\fR \fI...\fR [\fB-transport=transportname\fR] 
       
    34     [\fB-username=username -password=password\fR] 
       
    35     [\fB-curlinterface={interface|host}\fR] 
       
    36     [\fB-curlnoverifypeer\fR] [\fB-curlnoverifyhost\fR] 
       
    37 .fi
       
    38 
       
    39 .SH DESCRIPTION
       
    40 .sp
       
    41 .LP
       
    42 
       
    43 xmlrpc makes an XML-RPC remote procedure call (RPC) and displays the response. xmlrpc runs an XML-RPC client.
       
    44 
       
    45 This program is mainly useful for debugging and learning about XML-RPC servers. XML-RPC is such that the RPCs normally need to be made by a program rather than a person to be of use.
       
    46 
       
    47 .SH OPERANDS
       
    48 .sp
       
    49 .LP
       
    50 
       
    51 The following operands are supported:
       
    52 
       
    53 .sp
       
    54 .ne 2
       
    55 .mk
       
    56 .na
       
    57 \fB\fIurl\fR\fR
       
    58 .ad
       
    59 .RS 16n
       
    60 .rt
       
    61 This is the URL of the XML-RPC server. As XML-RPC uses HTTP, this must be an HTTP url. However, if you don't specify a type ("http:") in the URL, xmlrpc assumes an "http://" prefix and a "/RPC2" suffix. RPC2 is the conventional file name for an XML-RPC responder.
       
    62 .RE
       
    63 
       
    64 .sp
       
    65 .ne 2
       
    66 .mk
       
    67 .na
       
    68 \fB\fImethodName\fR\fR
       
    69 .ad
       
    70 .RS 16n
       
    71 .rt
       
    72 The name of the XML-RPC method you want to invoke.
       
    73 .RE
       
    74 
       
    75 .sp
       
    76 .ne 2
       
    77 .mk
       
    78 .na
       
    79 \fB\fIparameter ...\fR\fR
       
    80 .ad
       
    81 .RS 16n
       
    82 .rt
       
    83 parameter:
       
    84 
       
    85 i/integer | s/string | b/{true|false|t|f} | d/realnum | n/ | string 
       
    86 
       
    87 The list of parameters for the RPC. xmlrpc turns each of these arguments into an XML-RPC parameter, in the order given. You may specify no parameters if you like.
       
    88 
       
    89 You specify the data type of the parameter with a prefix ending in a slash. Example: i/5. Here, the "i" signifies an integer data type. "5" is the value.
       
    90 
       
    91 xmlrpc is capable of only a subset of the possible XML-RPC types, as follows by prefix:
       
    92 
       
    93 .sp
       
    94 .ne 2
       
    95 .mk
       
    96 .na
       
    97 \fB\fBi/\fR\fR
       
    98 .ad
       
    99 .RS 4n
       
   100 .rt
       
   101 integer (<int4>)
       
   102 .RE
       
   103     
       
   104 .sp
       
   105 .ne 2
       
   106 .mk
       
   107 .na
       
   108 \fB\fBs/\fR\fR
       
   109 .ad
       
   110 .RS 4n
       
   111 .rt
       
   112 string (<string>)
       
   113 .RE
       
   114      
       
   115 .sp
       
   116 .ne 2
       
   117 .mk
       
   118 .na
       
   119 \fB\fBb/\fR\fR
       
   120 .ad
       
   121 .RS 4n
       
   122 .rt
       
   123 boolean (<boolean>)
       
   124 .RE
       
   125 
       
   126 .sp
       
   127 .ne 2
       
   128 .mk
       
   129 .na
       
   130 \fB\fBd/\fR\fR
       
   131 .ad
       
   132 .RS 4n
       
   133 .rt
       
   134 double (<double>) (i.e. real number)
       
   135 .RE
       
   136 
       
   137 .sp
       
   138 .ne 2
       
   139 .mk
       
   140 .na
       
   141 \fB\fBn/\fR\fR
       
   142 .ad
       
   143 .RS 4n
       
   144 .rt
       
   145 nil (<nil>)
       
   146 .RE
       
   147 
       
   148 As a shortcut, if you don't specify a prefix (i.e. your argument does not contain a slash), xmlrpc assumes string data type.
       
   149 .RE
       
   150 
       
   151 .SH OPTIONS
       
   152 .sp
       
   153 .LP
       
   154 The following options are supported:
       
   155 
       
   156 .PP
       
   157 -transport=transportname
       
   158 .RS 4
       
   159 This selects the XML transport facility (e.g. libwww) that xmlrpc uses to perform the RPC.
       
   160 
       
   161 The name transportname is one that the Xmlrpc-c programming library recognizes. This is typically libwww, curl, and wininet.
       
   162 
       
   163 By default, xmlrpc lets the Xmlrpc-c library choose. 
       
   164 .RE
       
   165 
       
   166 .PP
       
   167 -username=username
       
   168 -password=password
       
   169 .RS 4
       
   170 These options, which must be used together, cause the client to authenticate itself to the server, if the server requires it, using HTTP Basic Authentication and the specified username and password.
       
   171 .RE
       
   172 
       
   173 .PP
       
   174 -curlinterface={interface|host}
       
   175 .RS 4
       
   176 This option gives the "interface" option for a Curl XML transport.
       
   177 
       
   178 The exact meaning of this option is up to the Curl library, and the best documentation for it is the manual for the 'curl' program that comes with the Curl library.
       
   179 
       
   180 But essentially, it chooses the local network interface through which to send the RPC. It causes the Curl library to perform a "bind" operation on the socket it uses for the communication. It can be the name of a network interface (e.g. on Linux, "eth1") or an IP address of the interface or a host name that resolves to the IP address of the interface. Unfortunately, you can't explicitly state which form you're specifying, so there's some ambiguity.
       
   181 
       
   182 Examples:
       
   183 
       
   184     * -interface=eth1
       
   185     * -interface=64.171.19.66
       
   186     * -interface=giraffe.giraffe-data.com 
       
   187 
       
   188 This option causes xmlrpc to default to using the Curl XML transport. You may not specify any other transport. 
       
   189 .RE
       
   190 
       
   191 .PP
       
   192 -curlnoverifypeer
       
   193 .RS 4
       
   194 This option gives the "no_ssl_verifypeer" option for the Curl XML transport, which is essentially the CURLOPT_SSL_VERIFYPEER option of the Curl library.
       
   195 
       
   196 See the curl_easy_setopt() man page for details on this, but essentially it means that the client does not authenticate the server's certificate of identity -- it just believes whatever the server says.
       
   197 
       
   198 You may want to use -curlnoverifyhost as well. Since you're not authenticating the server's identity, there's not much sense in checking it.
       
   199 
       
   200 This option causes xmlrpc to default to using the Curl XML transport. You may not specify any other transport. 
       
   201 .RE
       
   202 
       
   203 .PP
       
   204 -curlnoverifyhost
       
   205 .RS 4
       
   206 This option gives the "no_ssl_verifyhost" option for the Curl XML transport, which is essentially the CURLOPT_SSL_VERIFYHOST option of the Curl library.
       
   207 
       
   208 See the curl_easy_setopt() man page for details on this, but essentially it means that the client does not verify the server's identity. It just assumes that if the server answers the IP address of the server as indicated by the URL (probably via host name), then it's the intended server.
       
   209 
       
   210 You may want to use -curlnoverifypeer as well. As long as you don't care who the server says it is, there's no point in authenticating its identity.
       
   211 
       
   212 This option causes xmlrpc to default to using the Curl XML transport. You may not specify any other transport. 
       
   213 .RE
       
   214 
       
   215 .SH EXAMPLES
       
   216 .LP
       
   217 \fBExample 1 \fRViewing File Permissions
       
   218 .sp
       
   219 .LP
       
   220 The following example shows how to display detailed information about a file.
       
   221 
       
   222 .sp
       
   223 .in +2
       
   224 .nf
       
   225 $ xmlrpc http://localhost:8080/RPC2 sample.add i/3 i/5
       
   226 Result:
       
   227     Integer: 8
       
   228 .fi
       
   229 .in -2
       
   230 .sp
       
   231 
       
   232 .sp
       
   233 .in +2
       
   234 .nf
       
   235 $ xmlrpc http://xmlrpc.server.net/~bryanh echostring \\
       
   236     "s/This is a string"
       
   237 Result:
       
   238     String: This is a string
       
   239 .fi
       
   240 .in -2
       
   241 .sp
       
   242 
       
   243 .sp
       
   244 .in +2
       
   245 .nf
       
   246 $ xmlrpc http://xmlrpc.server.net/~bryanh echostring \\
       
   247     "This is a string in shortcut syntax"
       
   248 Result:
       
   249     String: This is a string in shortcut syntax
       
   250 .fi
       
   251 .in -2
       
   252 .sp
       
   253 
       
   254 .sp
       
   255 .in +2
       
   256 .nf
       
   257 $ xmlrpc http://xmlrpc.server.net sample.add i/3 i/5 \\
       
   258     -transport=curl -curlinterface=eth1 \\
       
   259     -username=bryanh -password=passw0rd
       
   260 Result:
       
   261     Integer: 8
       
   262 .fi
       
   263 .in -2
       
   264 .sp
       
   265 
       
   266 .SH ATTRIBUTES
       
   267 See
       
   268 .BR attributes (5)
       
   269 for descriptions of the following attributes:
       
   270 .sp
       
   271 .TS
       
   272 box;
       
   273 cbp-1 | cbp-1
       
   274 l | l .
       
   275 ATTRIBUTE TYPE	ATTRIBUTE VALUE
       
   276 =
       
   277 Availability	SUNWlibxmlrpc-c
       
   278 =
       
   279 Interface Stability	Uncommitted
       
   280 .TE 
       
   281 .PP
       
   282 .SH "SEE ALSO"
       
   283 .PP
       
   284 \fIhttp://xmlrpc-c\&.sourceforge\&.net\fR
       
   285 .SH NOTES
       
   286 .TP
       
   287 Source for libxmlrpc-c is available on:
       
   288 .sp
       
   289 http://opensolaris.org